	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_libpe_load_section             ## -- Begin function libpe_load_section
	.p2align	4, 0x90
_libpe_load_section:                    ## @libpe_load_section
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	testq	%rdi, %rdi
	setne	%al
	testq	%rsi, %rsi
	setne	%cl
	andb	%al, %cl
	movzbl	%cl, %edi
	callq	_assert
	movq	_LIBPE_F_LOAD_SECTION@GOTPCREL(%rip), %r13
	movl	(%r13), %eax
	xorl	%edi, %edi
	andl	(%rbx), %eax
	sete	%dil
	callq	_assert
	movq	8(%rbx), %rsi
	testq	%rsi, %rsi
	je	LBB0_1
## %bb.2:
	movq	_LIBPE_F_SPECIAL_FILE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r14)
	jne	LBB0_5
## %bb.3:
	movl	4(%r14), %edi
	movl	16(%rbx), %esi
	movq	_SEEK_SET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_lseek
	testq	%rax, %rax
	js	LBB0_15
## %bb.4:
	movq	8(%rbx), %rsi
LBB0_5:
	movq	%rbx, %rdi
	callq	_libpe_alloc_buffer
	movl	$-1, %r15d
	testq	%rax, %rax
	je	LBB0_14
## %bb.6:
	movl	4(%r14), %edi
	movq	(%rax), %rsi
	movq	8(%rbx), %rdx
	callq	_read
	cmpq	8(%rbx), %rax
	jne	LBB0_7
## %bb.8:
	cmpl	$-1, 4(%rbx)
	je	LBB0_9
LBB0_13:
	movl	(%r13), %eax
	orl	%eax, (%rbx)
	xorl	%r15d, %r15d
	jmp	LBB0_14
LBB0_1:
	xorl	%r15d, %r15d
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_libpe_alloc_buffer
	movl	(%r13), %eax
	orl	%eax, (%rbx)
	jmp	LBB0_14
LBB0_15:
	movq	_EIO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_errno@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movl	$-1, %r15d
	jmp	LBB0_14
LBB0_9:
	movl	4(%r14), %edi
	leaq	-44(%rbp), %rsi
	movl	$4, %edx
	callq	_read
	cmpq	$4, %rax
	jne	LBB0_7
## %bb.10:
	leaq	-44(%rbp), %rdi
	callq	_le32dec
	cmpq	$5, %rax
	jb	LBB0_13
## %bb.11:
	movq	%rax, %r12
	addq	$-4, %r12
	movq	%rbx, %rdi
	movq	%r12, %rsi
	callq	_libpe_alloc_buffer
	testq	%rax, %rax
	je	LBB0_14
## %bb.12:
	movl	4(%r14), %edi
	movq	(%rax), %rsi
	movq	%r12, %rdx
	callq	_read
	cmpq	%r12, %rax
	je	LBB0_13
LBB0_7:
	movq	_EIO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_errno@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
LBB0_14:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LIBPE_F_LOAD_SECTION,4,2       ## @LIBPE_F_LOAD_SECTION
	.comm	_LIBPE_F_SPECIAL_FILE,4,2       ## @LIBPE_F_SPECIAL_FILE
	.comm	_SEEK_SET,4,2                   ## @SEEK_SET
	.comm	_EIO,4,2                        ## @EIO
	.comm	_errno,4,2                      ## @errno
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_libpe_load_section             ; -- Begin function libpe_load_section
	.p2align	2
_libpe_load_section:                    ; @libpe_load_section
	.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	x19, x1
	mov	x20, x0
	cmp	x0, #0
	ccmp	x1, #0, #4, ne
	cset	w0, ne
	bl	_assert
	ldr	w8, [x19]
Lloh0:
	adrp	x22, _LIBPE_F_LOAD_SECTION@GOTPAGE
Lloh1:
	ldr	x22, [x22, _LIBPE_F_LOAD_SECTION@GOTPAGEOFF]
	ldr	w9, [x22]
	tst	w9, w8
	cset	w0, eq
	bl	_assert
	ldr	x1, [x19, #8]
	cbz	x1, LBB0_13
; %bb.1:
	ldr	w8, [x20]
Lloh2:
	adrp	x9, _LIBPE_F_SPECIAL_FILE@GOTPAGE
Lloh3:
	ldr	x9, [x9, _LIBPE_F_SPECIAL_FILE@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_4
; %bb.2:
	ldr	w0, [x20, #4]
	ldr	w1, [x19, #16]
Lloh5:
	adrp	x8, _SEEK_SET@GOTPAGE
Lloh6:
	ldr	x8, [x8, _SEEK_SET@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	bl	_lseek
	tbnz	x0, #63, LBB0_11
; %bb.3:
	ldr	x1, [x19, #8]
LBB0_4:
	mov	x0, x19
	bl	_libpe_alloc_buffer
	cbz	x0, LBB0_12
; %bb.5:
	ldr	w8, [x20, #4]
	ldr	x1, [x0]
	ldr	x2, [x19, #8]
	mov	x0, x8
	bl	_read
	ldr	x8, [x19, #8]
	cmp	x0, x8
	b.ne	LBB0_11
; %bb.6:
	ldr	w8, [x19, #4]
	cmn	w8, #1
	b.ne	LBB0_14
; %bb.7:
	ldr	w0, [x20, #4]
	add	x1, sp, #12
	mov	w2, #4
	bl	_read
	cmp	x0, #4
	b.ne	LBB0_11
; %bb.8:
	add	x0, sp, #12
	bl	_le32dec
	cmp	x0, #5
	b.lo	LBB0_14
; %bb.9:
	sub	x21, x0, #4
	mov	x0, x19
	mov	x1, x21
	bl	_libpe_alloc_buffer
	cbz	x0, LBB0_12
; %bb.10:
	ldr	w8, [x20, #4]
	ldr	x1, [x0]
	mov	x0, x8
	mov	x2, x21
	bl	_read
	cmp	x0, x21
	b.eq	LBB0_14
LBB0_11:
Lloh8:
	adrp	x8, _EIO@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
Lloh11:
	adrp	x9, _errno@GOTPAGE
Lloh12:
	ldr	x9, [x9, _errno@GOTPAGEOFF]
Lloh13:
	str	w8, [x9]
LBB0_12:
	mov	w0, #-1
	b	LBB0_15
LBB0_13:
	mov	x0, x19
	bl	_libpe_alloc_buffer
LBB0_14:
	mov	w0, #0
	ldr	w8, [x22]
	ldr	w9, [x19]
	orr	w8, w9, w8
	str	w8, [x19]
LBB0_15:
	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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotStr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_LIBPE_F_LOAD_SECTION,4,2       ; @LIBPE_F_LOAD_SECTION
	.comm	_LIBPE_F_SPECIAL_FILE,4,2       ; @LIBPE_F_SPECIAL_FILE
	.comm	_SEEK_SET,4,2                   ; @SEEK_SET
	.comm	_EIO,4,2                        ; @EIO
	.comm	_errno,4,2                      ; @errno
.subsections_via_symbols
