	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_read_loose_object              ## -- Begin function read_loose_object
	.p2align	4, 0x90
_read_loose_object:                     ## @read_loose_object
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, %rbx
	movq	%rcx, %r12
	movq	%rdx, -88(%rbp)                 ## 8-byte Spill
	movq	%rsi, -80(%rbp)                 ## 8-byte Spill
	movq	%rdi, %r14
	movq	%rsp, -64(%rbp)                 ## 8-byte Spill
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_MAX_HEADER_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	%r15, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r13
	movq	%rbx, -104(%rbp)                ## 8-byte Spill
	movq	$0, (%rbx)
	movq	_the_repository@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-96(%rbp), %rcx
	movq	%r14, %rsi
	xorl	%edx, %edx
	callq	_map_loose_object_1
	testq	%rax, %rax
	je	LBB0_12
## %bb.1:
	movq	-96(%rbp), %rdx
	leaq	-52(%rbp), %rdi
	movq	%rax, -112(%rbp)                ## 8-byte Spill
	movq	%rax, %rsi
	movq	%r13, %rcx
	movl	%r15d, %r8d
	callq	_unpack_loose_header
	testq	%rax, %rax
	js	LBB0_2
## %bb.4:
	movq	%r13, %rdi
	movq	%r12, %rsi
	callq	_parse_loose_header
	movq	-88(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, (%rcx)
	movq	_OBJ_BLOB@GOTPCREL(%rip), %rcx
	movq	(%r12), %rdx
	cmpl	(%rcx), %eax
	jne	LBB0_8
## %bb.5:
	movq	_big_file_threshold@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdx
	jbe	LBB0_8
## %bb.6:
	leaq	-52(%rbp), %rdi
	movq	%r13, %rsi
	movq	%r14, %rcx
	movq	-80(%rbp), %r8                  ## 8-byte Reload
	callq	_check_stream_oid
	testq	%rax, %rax
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	jns	LBB0_13
## %bb.7:
	movl	$-1, %ebx
	jmp	LBB0_14
LBB0_12:
	leaq	L_.str(%rip), %rdi
	callq	__
	movl	%eax, %edi
	movq	%r14, %rsi
	callq	_error_errno
	movl	$-1, %ebx
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	jmp	LBB0_15
LBB0_2:
	leaq	L_.str.1(%rip), %rdi
	callq	__
	movl	%eax, %edi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_error
	jmp	LBB0_3
LBB0_8:
	movq	%r14, -72(%rbp)                 ## 8-byte Spill
	leaq	-52(%rbp), %rdi
	movq	%r13, %rsi
	movq	-80(%rbp), %r13                 ## 8-byte Reload
	movq	%r13, %rcx
	callq	_unpack_loose_rest
	movq	-104(%rbp), %r14                ## 8-byte Reload
	movq	%rax, (%r14)
	testq	%rax, %rax
	je	LBB0_9
## %bb.10:
	movq	%rax, %rbx
	movq	(%r12), %r15
	movq	-88(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	callq	_type_name
	movq	%r13, %rdi
	movq	%rbx, %rsi
	movq	%r15, %rdx
	movl	%eax, %ecx
	callq	_check_object_signature
	testq	%rax, %rax
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	je	LBB0_13
## %bb.11:
	leaq	L_.str.4(%rip), %rdi
	callq	__
	movl	%eax, %ebx
	movq	%r13, %rdi
	callq	_oid_to_hex
	movl	%ebx, %edi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movq	%rax, %rdx
	xorl	%eax, %eax
	callq	_error
	movq	(%r14), %rdi
	callq	_free
	movl	$-1, %ebx
	jmp	LBB0_14
LBB0_13:
	xorl	%ebx, %ebx
	jmp	LBB0_14
LBB0_9:
	leaq	L_.str.3(%rip), %rdi
	callq	__
	movl	%eax, %edi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_error
	leaq	-52(%rbp), %rdi
	callq	_git_inflate_end
LBB0_3:
	movl	$-1, %ebx
	movq	-64(%rbp), %r15                 ## 8-byte Reload
LBB0_14:
	movq	-96(%rbp), %rsi
	movq	-112(%rbp), %rdi                ## 8-byte Reload
	callq	_munmap
LBB0_15:
	movq	%r15, %rsp
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_17
## %bb.16:
	movl	%ebx, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_17:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_HEADER_LEN,4,2             ## @MAX_HEADER_LEN
	.comm	_the_repository,4,2             ## @the_repository
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unable to mmap %s"

L_.str.1:                               ## @.str.1
	.asciz	"unable to unpack header of %s"

	.comm	_OBJ_BLOB,4,2                   ## @OBJ_BLOB
	.comm	_big_file_threshold,8,3         ## @big_file_threshold
L_.str.3:                               ## @.str.3
	.asciz	"unable to unpack contents of %s"

L_.str.4:                               ## @.str.4
	.asciz	"hash mismatch for %s (expected %s)"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_read_loose_object              ; -- Begin function read_loose_object
	.p2align	2
_read_loose_object:                     ; @read_loose_object
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	sub	sp, sp, #32
	mov	x21, x4
	mov	x24, x3
	mov	x23, x2
	mov	x22, x1
	mov	x20, x0
	mov	x27, sp
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _MAX_HEADER_LEN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_HEADER_LEN@GOTPAGEOFF]
Lloh5:
	ldr	w26, [x8]
	mov	x9, x26
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x26, #15
	and	x9, x9, #0x1fffffff0
	sub	x25, x8, x9
	mov	sp, x25
	str	xzr, [x4]
Lloh8:
	adrp	x8, _the_repository@GOTPAGE
Lloh9:
	ldr	x8, [x8, _the_repository@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	sub	x3, x29, #96
	mov	x1, x20
	mov	x2, #0
	bl	_map_loose_object_1
	cbz	x0, LBB0_6
; %bb.1:
	mov	x19, x0
	ldur	x2, [x29, #-96]
	sub	x0, x29, #100
	mov	x1, x19
	mov	x3, x25
	mov	x4, x26
	bl	_unpack_loose_header
	tbnz	x0, #63, LBB0_7
; %bb.2:
	mov	x0, x25
	mov	x1, x24
	bl	_parse_loose_header
	str	w0, [x23]
Lloh11:
	adrp	x8, _OBJ_BLOB@GOTPAGE
Lloh12:
	ldr	x8, [x8, _OBJ_BLOB@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	ldr	x2, [x24]
Lloh14:
	adrp	x9, _big_file_threshold@GOTPAGE
Lloh15:
	ldr	x9, [x9, _big_file_threshold@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	w0, w8
	sub	x0, x29, #100
	mov	x1, x25
	ccmp	x2, x9, #0, eq
	b.hi	LBB0_8
; %bb.3:
	mov	x3, x22
	bl	_unpack_loose_rest
	str	x0, [x21]
	cbz	x0, LBB0_10
; %bb.4:
	mov	x25, x0
	ldr	x24, [x24]
	ldr	w0, [x23]
	bl	_type_name
	mov	x3, x0
	mov	x0, x22
	mov	x1, x25
	mov	x2, x24
	bl	_check_object_signature
	cbz	x0, LBB0_9
; %bb.5:
Lloh17:
	adrp	x0, l_.str.4@PAGE
Lloh18:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	__
	mov	x23, x0
	mov	x0, x22
	bl	_oid_to_hex
	str	x0, [sp, #-16]!
	mov	x0, x23
	mov	x1, x20
	bl	_error
	add	sp, sp, #16
	ldr	x0, [x21]
	bl	_free
	b	LBB0_11
LBB0_6:
Lloh19:
	adrp	x0, l_.str@PAGE
Lloh20:
	add	x0, x0, l_.str@PAGEOFF
	bl	__
	mov	x1, x20
	bl	_error_errno
	mov	w20, #-1
	b	LBB0_13
LBB0_7:
Lloh21:
	adrp	x0, l_.str.1@PAGE
Lloh22:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	__
	mov	x1, x20
	bl	_error
	b	LBB0_11
LBB0_8:
	mov	x3, x20
	mov	x4, x22
	bl	_check_stream_oid
	tbnz	x0, #63, LBB0_11
LBB0_9:
	mov	w20, #0
	b	LBB0_12
LBB0_10:
Lloh23:
	adrp	x0, l_.str.3@PAGE
Lloh24:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	__
	mov	x1, x20
	bl	_error
	sub	x0, x29, #100
	bl	_git_inflate_end
LBB0_11:
	mov	w20, #-1
LBB0_12:
	ldur	x1, [x29, #-96]
	mov	x0, x19
	bl	_munmap
LBB0_13:
	mov	sp, x27
	ldur	x8, [x29, #-88]
Lloh25:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh26:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh27:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_15
; %bb.14:
	mov	x0, x20
	sub	sp, x29, #80
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_15:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_HEADER_LEN,4,2             ; @MAX_HEADER_LEN
	.comm	_the_repository,4,2             ; @the_repository
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unable to mmap %s"

l_.str.1:                               ; @.str.1
	.asciz	"unable to unpack header of %s"

	.comm	_OBJ_BLOB,4,2                   ; @OBJ_BLOB
	.comm	_big_file_threshold,8,3         ; @big_file_threshold
l_.str.3:                               ; @.str.3
	.asciz	"unable to unpack contents of %s"

l_.str.4:                               ; @.str.4
	.asciz	"hash mismatch for %s (expected %s)"

.subsections_via_symbols
