	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function PxeSeek
_PxeSeek:                               ## @PxeSeek
	.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, -64(%rbp)
	movq	__OpenFile@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_EBADF@GOTPCREL(%rip), %rbx
	cmpq	%rdi, %rax
	jne	LBB0_15
## %bb.1:
	movq	_NO_FILE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_15
## %bb.2:
	movq	%rsi, %r12
	cmpq	$0, (%rsi)
	movq	_EINVAL@GOTPCREL(%rip), %rbx
	jne	LBB0_15
## %bb.3:
	movq	_SeekAbsolute@GOTPCREL(%rip), %rax
	cmpq	%rdx, (%rax)
	jne	LBB0_15
## %bb.4:
	movq	__CachedFile@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jne	LBB0_8
## %bb.5:
	movq	8(%r12), %rax
	movq	__FilePosition@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jge	LBB0_8
## %bb.6:
	callq	_PxeClose
	movq	_ESUCCESS@GOTPCREL(%rip), %r14
	movq	_EIO@GOTPCREL(%rip), %rbx
	cmpq	(%r14), %rax
	jne	LBB0_15
## %bb.7:
	movq	__OpenFileName@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_OpenReadOnly@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-64(%rbp), %rdx
	callq	_PxeOpen
	cmpq	(%r14), %rax
	jne	LBB0_15
LBB0_8:
	leaq	-56(%rbp), %rdi
	movl	$16, %esi
	callq	_RtlZeroMemory
	movq	__Packet@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movzwl	%ax, %ecx
	shrl	$4, %eax
	andl	$61440, %eax                    ## imm = 0xF000
	movl	%eax, -48(%rbp)
	movl	%ecx, -44(%rbp)
	movq	8(%r12), %rax
	movq	__CachedLength@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rax
	jle	LBB0_14
## %bb.9:
	leaq	-56(%rbp), %r14
	movq	_EIO@GOTPCREL(%rip), %rbx
	movq	__PacketPosition@GOTPCREL(%rip), %r13
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_10 Depth=1
	movq	(%r15), %rcx
	movq	%rcx, (%r13)
	addq	-56(%rbp), %rcx
	movq	%rcx, (%r15)
	movq	8(%r12), %rax
	cmpq	%rcx, %rax
	jle	LBB0_14
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movq	_PXENV_TFTP_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_CallPxe
	testl	%eax, %eax
	je	LBB0_15
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	movq	__CachedFile@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	testq	%rdi, %rdi
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_10 Depth=1
	addq	(%r15), %rdi
	movq	__Packet@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	-56(%rbp), %rdx
	callq	_RtlCopyMemory
	jmp	LBB0_13
LBB0_14:
	movq	__FilePosition@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	movq	_ESUCCESS@GOTPCREL(%rip), %rbx
LBB0_15:
	movq	(%rbx), %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	__OpenFile,8,3                  ## @_OpenFile
	.comm	_NO_FILE,8,3                    ## @NO_FILE
	.comm	_EBADF,8,3                      ## @EBADF
	.comm	_SeekAbsolute,8,3               ## @SeekAbsolute
	.comm	_EINVAL,8,3                     ## @EINVAL
	.comm	__CachedFile,8,3                ## @_CachedFile
	.comm	__FilePosition,8,3              ## @_FilePosition
	.comm	_ESUCCESS,8,3                   ## @ESUCCESS
	.comm	_EIO,8,3                        ## @EIO
	.comm	__OpenFileName,4,2              ## @_OpenFileName
	.comm	_OpenReadOnly,4,2               ## @OpenReadOnly
	.comm	__Packet,8,3                    ## @_Packet
	.comm	__CachedLength,8,3              ## @_CachedLength
	.comm	_PXENV_TFTP_READ,4,2            ## @PXENV_TFTP_READ
	.comm	__PacketPosition,8,3            ## @_PacketPosition
	.no_dead_strip	_PxeSeek
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function PxeSeek
_PxeSeek:                               ; @PxeSeek
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	str	x0, [sp, #24]
Lloh0:
	adrp	x8, __OpenFile@GOTPAGE
Lloh1:
	ldr	x8, [x8, __OpenFile@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
Lloh3:
	adrp	x9, _NO_FILE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _NO_FILE@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x0
	ccmp	x8, x9, #4, eq
	b.ne	LBB0_2
; %bb.1:
Lloh6:
	adrp	x22, _EBADF@GOTPAGE
Lloh7:
	ldr	x22, [x22, _EBADF@GOTPAGEOFF]
	b	LBB0_15
LBB0_2:
	mov	x19, x1
	ldr	x8, [x1]
Lloh8:
	adrp	x22, _EINVAL@GOTPAGE
Lloh9:
	ldr	x22, [x22, _EINVAL@GOTPAGEOFF]
	cbnz	x8, LBB0_15
; %bb.3:
Lloh10:
	adrp	x8, _SeekAbsolute@GOTPAGE
Lloh11:
	ldr	x8, [x8, _SeekAbsolute@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
	cmp	x8, x2
	b.ne	LBB0_15
; %bb.4:
Lloh13:
	adrp	x21, __CachedFile@GOTPAGE
Lloh14:
	ldr	x21, [x21, __CachedFile@GOTPAGEOFF]
	ldr	x8, [x21]
Lloh15:
	adrp	x20, __FilePosition@GOTPAGE
Lloh16:
	ldr	x20, [x20, __FilePosition@GOTPAGEOFF]
	cbnz	x8, LBB0_8
; %bb.5:
	ldr	x8, [x19, #8]
	ldr	x9, [x20]
	cmp	x8, x9
	b.ge	LBB0_8
; %bb.6:
	bl	_PxeClose
Lloh17:
	adrp	x22, _ESUCCESS@GOTPAGE
Lloh18:
	ldr	x22, [x22, _ESUCCESS@GOTPAGEOFF]
	ldr	x8, [x22]
	cmp	x0, x8
	b.ne	LBB0_16
; %bb.7:
Lloh19:
	adrp	x8, __OpenFileName@GOTPAGE
Lloh20:
	ldr	x8, [x8, __OpenFileName@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
Lloh22:
	adrp	x8, _OpenReadOnly@GOTPAGE
Lloh23:
	ldr	x8, [x8, _OpenReadOnly@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
	add	x2, sp, #24
	bl	_PxeOpen
	ldr	x8, [x22]
	cmp	x0, x8
	b.ne	LBB0_16
LBB0_8:
	add	x0, sp, #8
	mov	w1, #16
	bl	_RtlZeroMemory
Lloh25:
	adrp	x23, __Packet@GOTPAGE
Lloh26:
	ldr	x23, [x23, __Packet@GOTPAGEOFF]
	ldr	w8, [x23]
	lsr	w9, w8, #4
	and	w9, w9, #0xf000
	and	w8, w8, #0xffff
	stp	w9, w8, [sp, #16]
	ldr	x8, [x19, #8]
Lloh27:
	adrp	x24, __CachedLength@GOTPAGE
Lloh28:
	ldr	x24, [x24, __CachedLength@GOTPAGEOFF]
	ldr	x9, [x24]
	cmp	x8, x9
	b.le	LBB0_14
; %bb.9:
Lloh29:
	adrp	x25, _PXENV_TFTP_READ@GOTPAGE
Lloh30:
	ldr	x25, [x25, _PXENV_TFTP_READ@GOTPAGEOFF]
Lloh31:
	adrp	x22, _EIO@GOTPAGE
Lloh32:
	ldr	x22, [x22, _EIO@GOTPAGEOFF]
Lloh33:
	adrp	x26, __PacketPosition@GOTPAGE
Lloh34:
	ldr	x26, [x26, __PacketPosition@GOTPAGEOFF]
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	ldr	x9, [x24]
	str	x9, [x26]
	ldr	x10, [sp, #8]
	ldr	x8, [x19, #8]
	add	x9, x10, x9
	cmp	x8, x9
	str	x9, [x24]
	b.le	LBB0_14
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x25]
	add	x1, sp, #8
	bl	_CallPxe
	cbz	w0, LBB0_15
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	x8, [x21]
	cbz	x8, LBB0_10
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	x9, [x24]
	add	x0, x9, x8
	ldr	x1, [x23]
	ldr	x2, [sp, #8]
	bl	_RtlCopyMemory
	b	LBB0_10
LBB0_14:
	str	x8, [x20]
Lloh35:
	adrp	x22, _ESUCCESS@GOTPAGE
Lloh36:
	ldr	x22, [x22, _ESUCCESS@GOTPAGEOFF]
LBB0_15:
	ldr	x0, [x22]
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_16:
Lloh37:
	adrp	x22, _EIO@GOTPAGE
Lloh38:
	ldr	x22, [x22, _EIO@GOTPAGEOFF]
	b	LBB0_15
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.comm	__OpenFile,8,3                  ; @_OpenFile
	.comm	_NO_FILE,8,3                    ; @NO_FILE
	.comm	_EBADF,8,3                      ; @EBADF
	.comm	_SeekAbsolute,8,3               ; @SeekAbsolute
	.comm	_EINVAL,8,3                     ; @EINVAL
	.comm	__CachedFile,8,3                ; @_CachedFile
	.comm	__FilePosition,8,3              ; @_FilePosition
	.comm	_ESUCCESS,8,3                   ; @ESUCCESS
	.comm	_EIO,8,3                        ; @EIO
	.comm	__OpenFileName,4,2              ; @_OpenFileName
	.comm	_OpenReadOnly,4,2               ; @OpenReadOnly
	.comm	__Packet,8,3                    ; @_Packet
	.comm	__CachedLength,8,3              ; @_CachedLength
	.comm	_PXENV_TFTP_READ,4,2            ; @PXENV_TFTP_READ
	.comm	__PacketPosition,8,3            ; @_PacketPosition
	.no_dead_strip	_PxeSeek
.subsections_via_symbols
