	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function filesys_load_directory_tree
_filesys_load_directory_tree:           ## @filesys_load_directory_tree
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	leaq	-32(%rbp), %rdi
	movl	$4, %esi
	callq	_bread
	xorl	%edi, %edi
	cmpl	$-2, -32(%rbp)
	setge	%dil
	callq	_assert
	cmpl	$-2, -32(%rbp)
	jne	LBB0_2
## %bb.1:
	xorl	%r15d, %r15d
	jmp	LBB0_6
LBB0_2:
	movq	_tot_directory_nodes@GOTPCREL(%rip), %rax
	incl	(%rax)
	movl	$56, %edi
	callq	_zmalloc0
	movq	%rax, %r15
	movq	%rax, %rdi
	movl	$4, %esi
	callq	_bread
	leaq	4(%r15), %rdi
	movl	$4, %esi
	callq	_bread
	leaq	8(%r15), %rdi
	movl	$4, %esi
	callq	_bread
	leaq	12(%r15), %rdi
	movl	$4, %esi
	callq	_bread
	leaq	-28(%rbp), %rdi
	movl	$4, %esi
	callq	_bread
	movl	-32(%rbp), %eax
	movl	%eax, 16(%r15)
	movq	%r14, 48(%r15)
	movl	-28(%rbp), %edi
	incl	%edi
	callq	_zmalloc
	movq	%rax, 24(%r15)
	movq	$0, 40(%r15)
	movl	-28(%rbp), %esi
	movq	%rax, %rdi
	callq	_bread
	movq	24(%r15), %rdx
	movslq	-28(%rbp), %rax
	movl	$0, (%rdx,%rax,4)
	leaq	L_.str(%rip), %rsi
	movl	$3, %edi
	callq	_vkprintf
	cmpl	$0, 16(%r15)
	jns	LBB0_6
## %bb.3:
	movq	%r15, %rdi
	callq	_filesys_load_directory_tree
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	movq	%r15, %r14
	addq	$40, %r14
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	addq	$32, %rcx
	cmpq	$0, 40(%r15)
	movq	%rax, %rbx
	cmoveq	%r14, %rcx
	movq	%rax, (%rcx)
	movq	%r15, %rdi
	callq	_filesys_load_directory_tree
	movq	%rbx, %rcx
	testq	%rax, %rax
	jne	LBB0_5
LBB0_6:
	movq	%r15, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_tot_directory_nodes,4,2        ## @tot_directory_nodes
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"load_index: %s\n"

	.no_dead_strip	_filesys_load_directory_tree
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function filesys_load_directory_tree
_filesys_load_directory_tree:           ; @filesys_load_directory_tree
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x20, x0
	add	x0, sp, #12
	mov	w1, #4
	bl	_bread
	ldr	w8, [sp, #12]
	cmn	w8, #3
	cset	w0, gt
	bl	_assert
	ldr	w8, [sp, #12]
	cmn	w8, #2
	b.ne	LBB0_2
; %bb.1:
	mov	x19, #0
	b	LBB0_6
LBB0_2:
Lloh0:
	adrp	x8, _tot_directory_nodes@GOTPAGE
Lloh1:
	ldr	x8, [x8, _tot_directory_nodes@GOTPAGEOFF]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
	mov	w0, #56
	bl	_zmalloc0
	mov	x19, x0
	mov	w1, #4
	bl	_bread
	add	x0, x19, #4
	mov	w1, #4
	bl	_bread
	add	x0, x19, #8
	mov	w1, #4
	bl	_bread
	add	x0, x19, #12
	mov	w1, #4
	bl	_bread
	add	x0, sp, #8
	mov	w1, #4
	bl	_bread
	ldr	w8, [sp, #12]
	str	w8, [x19, #16]
	str	x20, [x19, #48]
	ldr	w8, [sp, #8]
	add	w0, w8, #1
	bl	_zmalloc
	str	x0, [x19, #24]
	mov	x20, x19
	str	xzr, [x20, #40]!
	ldr	w1, [sp, #8]
	bl	_bread
	ldr	x2, [x19, #24]
	ldrsw	x8, [sp, #8]
	str	wzr, [x2, x8, lsl #2]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #3
	bl	_vkprintf
	ldr	w8, [x19, #16]
	tbz	w8, #31, LBB0_6
; %bb.3:
	mov	x0, x19
	bl	_filesys_load_directory_tree
	cbz	x0, LBB0_6
; %bb.4:
	mov	x8, #0
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	mov	x21, x0
	ldr	x9, [x19, #40]
	add	x8, x8, #32
	cmp	x9, #0
	csel	x8, x20, x8, eq
	str	x0, [x8]
	mov	x0, x19
	bl	_filesys_load_directory_tree
	mov	x8, x21
	cbnz	x0, LBB0_5
LBB0_6:
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_tot_directory_nodes,4,2        ; @tot_directory_nodes
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"load_index: %s\n"

	.no_dead_strip	_filesys_load_directory_tree
.subsections_via_symbols
