	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function write_tree
_write_tree:                            ## @write_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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_entries@GOTPCREL(%rip), %r13
	movq	(%r13), %rdi
	movq	_used@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	_ent_compare@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_QSORT
	movl	(%r12), %edx
	testl	%edx, %edx
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	jle	LBB0_1
## %bb.2:
	movq	(%r13), %rcx
	leaq	-1(%rdx), %rsi
	movl	%edx, %eax
	andl	$3, %eax
	cmpq	$3, %rsi
	jae	LBB0_4
## %bb.3:
	xorl	%edi, %edi
	xorl	%esi, %esi
	jmp	LBB0_6
LBB0_1:
	xorl	%esi, %esi
	jmp	LBB0_9
LBB0_4:
	andl	$-4, %edx
	xorl	%edi, %edi
	xorl	%esi, %esi
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rcx,%rdi,8), %rbx
	addq	16(%rbx), %rsi
	movq	8(%rcx,%rdi,8), %rbx
	addq	16(%rbx), %rsi
	movq	16(%rcx,%rdi,8), %rbx
	addq	16(%rbx), %rsi
	movq	24(%rcx,%rdi,8), %rbx
	movq	16(%rbx), %rbx
	addq	%rbx, %rsi
	addq	$128, %rsi
	addq	$4, %rdi
	cmpq	%rdi, %rdx
	jne	LBB0_5
LBB0_6:
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	leaq	(%rcx,%rdi,8), %rcx
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rcx,%rdx,8), %rdi
	movq	16(%rdi), %rdi
	addq	%rdi, %rsi
	addq	$32, %rsi
	incq	%rdx
	cmpq	%rdx, %rax
	jne	LBB0_8
LBB0_9:
	leaq	-48(%rbp), %rdi
	callq	_strbuf_init
	cmpl	$0, (%r12)
	jle	LBB0_12
## %bb.10:
	xorl	%r14d, %r14d
	leaq	-48(%rbp), %rbx
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rax
	movq	%r13, %r15
	movq	(%rax,%r14,8), %r13
	movl	4(%r13), %ecx
	movl	8(%r13), %edx
	movq	%rbx, %rdi
	leaq	L_.str(%rip), %rsi
	xorl	%r8d, %r8d
	callq	_strbuf_addf
	movl	(%r13), %esi
	movq	%r15, %r13
	movq	_the_hash_algo@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_strbuf_add
	incq	%r14
	movslq	(%r12), %rax
	cmpq	%rax, %r14
	jl	LBB0_11
LBB0_12:
	movl	-48(%rbp), %esi
	movl	-44(%rbp), %edi
	movq	_tree_type@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	callq	_write_object_file
	leaq	-48(%rbp), %rdi
	callq	_strbuf_release
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_entries,8,3                    ## @entries
	.comm	_used,4,2                       ## @used
	.comm	_ent_compare,4,2                ## @ent_compare
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%o %s%c"

	.comm	_the_hash_algo,8,3              ## @the_hash_algo
	.comm	_tree_type,4,2                  ## @tree_type
	.no_dead_strip	_write_tree
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function write_tree
_write_tree:                            ; @write_tree
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x0
Lloh0:
	adrp	x21, _entries@GOTPAGE
Lloh1:
	ldr	x21, [x21, _entries@GOTPAGEOFF]
	ldr	x0, [x21]
Lloh2:
	adrp	x22, _used@GOTPAGE
Lloh3:
	ldr	x22, [x22, _used@GOTPAGEOFF]
	ldr	w1, [x22]
Lloh4:
	adrp	x8, _ent_compare@GOTPAGE
Lloh5:
	ldr	x8, [x8, _ent_compare@GOTPAGEOFF]
Lloh6:
	ldr	w2, [x8]
	bl	_QSORT
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_3
; %bb.1:
	ldr	x9, [x21]
	cmp	w8, #4
	b.hs	LBB0_4
; %bb.2:
	mov	x10, #0
	mov	x1, #0
	b	LBB0_7
LBB0_3:
	mov	x1, #0
	b	LBB0_9
LBB0_4:
	mov	x12, #0
	mov	x13, #0
	mov	x14, #0
	mov	x15, #0
	and	x10, x8, #0xfffffffc
	add	x11, x9, #16
	mov	x16, x10
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldp	x17, x0, [x11, #-16]
	ldp	x1, x2, [x11], #32
	ldr	x17, [x17, #16]
	ldr	x0, [x0, #16]
	ldr	x1, [x1, #16]
	add	x12, x12, x17
	add	x13, x13, x0
	ldr	x17, [x2, #16]
	add	x14, x14, x1
	add	x15, x15, x17
	add	x12, x12, #32
	add	x13, x13, #32
	add	x14, x14, #32
	add	x15, x15, #32
	subs	x16, x16, #4
	b.ne	LBB0_5
; %bb.6:
	add	x11, x13, x12
	add	x11, x14, x11
	add	x1, x15, x11
	cmp	x10, x8
	b.eq	LBB0_9
LBB0_7:
	add	x9, x9, x10, lsl #3
	sub	x8, x8, x10
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x9], #8
	ldr	x10, [x10, #16]
	add	x10, x1, x10
	add	x1, x10, #32
	subs	x8, x8, #1
	b.ne	LBB0_8
LBB0_9:
	add	x0, sp, #8
	bl	_strbuf_init
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_12
; %bb.10:
	mov	x23, #0
Lloh7:
	adrp	x20, l_.str@PAGE
Lloh8:
	add	x20, x20, l_.str@PAGEOFF
Lloh9:
	adrp	x24, _the_hash_algo@GOTPAGE
Lloh10:
	ldr	x24, [x24, _the_hash_algo@GOTPAGEOFF]
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21]
	ldr	x25, [x8, x23, lsl #3]
	ldp	w3, w2, [x25, #4]
	add	x0, sp, #8
	mov	x1, x20
	mov	w4, #0
	bl	_strbuf_addf
	ldr	w1, [x25]
	ldr	x8, [x24]
	ldr	w2, [x8]
	add	x0, sp, #8
	bl	_strbuf_add
	add	x23, x23, #1
	ldrsw	x8, [x22]
	cmp	x23, x8
	b.lt	LBB0_11
LBB0_12:
	ldp	w1, w0, [sp, #8]
Lloh11:
	adrp	x8, _tree_type@GOTPAGE
Lloh12:
	ldr	x8, [x8, _tree_type@GOTPAGEOFF]
Lloh13:
	ldr	w2, [x8]
	mov	x3, x19
	bl	_write_object_file
	add	x0, sp, #8
	bl	_strbuf_release
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_entries,8,3                    ; @entries
	.comm	_used,4,2                       ; @used
	.comm	_ent_compare,4,2                ; @ent_compare
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%o %s%c"

	.comm	_the_hash_algo,8,3              ; @the_hash_algo
	.comm	_tree_type,4,2                  ; @tree_type
	.no_dead_strip	_write_tree
.subsections_via_symbols
