	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_finish_tmp_packfile            ## -- Begin function finish_tmp_packfile
	.p2align	4, 0x90
_finish_tmp_packfile:                   ## @finish_tmp_packfile
	.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	%r9, %r12
	movq	%r8, %r15
	movl	%ecx, %r14d
	movq	%rdx, %r13
	movq	%rdi, %rbx
	movl	(%rdi), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	%rsi, -56(%rbp)                 ## 8-byte Spill
	movq	%rsi, %rdi
	callq	_adjust_shared_perm
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	callq	_die_errno
LBB0_2:
	xorl	%edi, %edi
	movq	%r13, %rsi
	movl	%r14d, %edx
	movq	%r15, %rcx
	movq	%r12, %r8
	callq	_write_idx_file
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_adjust_shared_perm
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	leaq	L_.str.1(%rip), %rdi
	callq	_die_errno
LBB0_4:
	movq	%r12, %rdi
	callq	_hash_to_hex
	leaq	L_.str.2(%rip), %rsi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_strbuf_addf
	movl	4(%rbx), %esi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_rename
	testq	%rax, %rax
	movl	-44(%rbp), %r14d                ## 4-byte Reload
	je	LBB0_6
## %bb.5:
	leaq	L_.str.3(%rip), %rdi
	callq	_die_errno
LBB0_6:
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_strbuf_setlen
	movq	%r12, %rdi
	callq	_hash_to_hex
	leaq	L_.str.4(%rip), %rsi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_strbuf_addf
	movl	4(%rbx), %esi
	movq	%r15, %rdi
	callq	_rename
	testq	%rax, %rax
	je	LBB0_8
## %bb.7:
	leaq	L_.str.5(%rip), %rdi
	callq	_die_errno
LBB0_8:
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_strbuf_setlen
	movq	%r15, %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_free                           ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unable to make temporary pack file readable"

L_.str.1:                               ## @.str.1
	.asciz	"unable to make temporary index file readable"

L_.str.2:                               ## @.str.2
	.asciz	"%s.pack"

L_.str.3:                               ## @.str.3
	.asciz	"unable to rename temporary pack file"

L_.str.4:                               ## @.str.4
	.asciz	"%s.idx"

L_.str.5:                               ## @.str.5
	.asciz	"unable to rename temporary index file"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_finish_tmp_packfile            ; -- Begin function finish_tmp_packfile
	.p2align	2
_finish_tmp_packfile:                   ; @finish_tmp_packfile
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x22, x5
	mov	x21, x4
	mov	x24, x3
	mov	x25, x2
	mov	x23, x1
	mov	x20, x0
	ldr	w19, [x0]
	mov	x0, x1
	bl	_adjust_shared_perm
	cbz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_die_errno
LBB0_2:
	mov	x0, #0
	mov	x1, x25
	mov	x2, x24
	mov	x3, x21
	mov	x4, x22
	bl	_write_idx_file
	mov	x21, x0
	bl	_adjust_shared_perm
	cbz	x0, LBB0_4
; %bb.3:
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_die_errno
LBB0_4:
	mov	x0, x22
	bl	_hash_to_hex
	mov	x2, x0
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_strbuf_addf
	ldr	w1, [x20, #4]
	mov	x0, x23
	bl	_rename
	cbz	x0, LBB0_6
; %bb.5:
Lloh6:
	adrp	x0, l_.str.3@PAGE
Lloh7:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_die_errno
LBB0_6:
	mov	x0, x20
	mov	x1, x19
	bl	_strbuf_setlen
	mov	x0, x22
	bl	_hash_to_hex
	mov	x2, x0
Lloh8:
	adrp	x1, l_.str.4@PAGE
Lloh9:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x20
	bl	_strbuf_addf
	ldr	w1, [x20, #4]
	mov	x0, x21
	bl	_rename
	cbz	x0, LBB0_8
; %bb.7:
Lloh10:
	adrp	x0, l_.str.5@PAGE
Lloh11:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_die_errno
LBB0_8:
	mov	x0, x20
	mov	x1, x19
	bl	_strbuf_setlen
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_free
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unable to make temporary pack file readable"

l_.str.1:                               ; @.str.1
	.asciz	"unable to make temporary index file readable"

l_.str.2:                               ; @.str.2
	.asciz	"%s.pack"

l_.str.3:                               ; @.str.3
	.asciz	"unable to rename temporary pack file"

l_.str.4:                               ; @.str.4
	.asciz	"%s.idx"

l_.str.5:                               ; @.str.5
	.asciz	"unable to rename temporary index file"

.subsections_via_symbols
