	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function emem_seek
_emem_seek:                             ## @emem_seek
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	8(%rdi), %rbx
	cmpl	$130, %edx
	je	LBB0_5
## %bb.1:
	cmpl	$129, %edx
	je	LBB0_6
## %bb.2:
	cmpl	$128, %edx
	jne	LBB0_10
## %bb.3:
	movslq	%esi, %rax
	movq	(%rbx), %rcx
	movq	16(%rbx), %rdx
	cmpq	%rax, %rcx
	cmovael	%esi, %ecx
	xorl	%eax, %eax
	testl	%ecx, %ecx
	cmovgl	%ecx, %eax
	movl	12(%rbx), %ecx
	addl	%eax, %ecx
	movl	%ecx, 8(%rbx)
	cmpq	%rax, %rdx
	jae	LBB0_8
## %bb.4:
	movq	%rax, 16(%rbx)
	jmp	LBB0_8
LBB0_5:
	addl	8(%rbx), %esi
	subl	12(%rbx), %esi
	jmp	LBB0_7
LBB0_6:
	addl	16(%rbx), %esi
LBB0_7:
	movl	$128, %edx
	callq	*(%rdi)
LBB0_8:
	movl	8(%rbx), %eax
	subl	12(%rbx), %eax
	jmp	LBB0_9
LBB0_10:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_errno@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movl	$-1, %eax
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_errno,4,2                      ## @errno
	.no_dead_strip	_emem_seek
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function emem_seek
_emem_seek:                             ; @emem_seek
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	ldr	x19, [x0, #8]
	cmp	w2, #130
	b.eq	LBB0_5
; %bb.1:
	cmp	w2, #129
	b.eq	LBB0_6
; %bb.2:
	cmp	w2, #128
	b.ne	LBB0_9
; %bb.3:
	ldr	x8, [x19]
	cmp	x8, w1, sxtw
	csel	w8, w8, w1, lo
	cmp	w8, #0
	csel	w8, w8, wzr, gt
	ldr	w9, [x19, #12]
	add	w9, w8, w9
	str	w9, [x19, #8]
	ldr	x9, [x19, #16]
	cmp	x9, x8
	b.hs	LBB0_8
; %bb.4:
	str	x8, [x19, #16]
	b	LBB0_8
LBB0_5:
	ldr	x8, [x0]
	ldp	w9, w10, [x19, #8]
	add	w9, w9, w1
	sub	w1, w9, w10
	b	LBB0_7
LBB0_6:
	ldr	x8, [x0]
	ldr	w9, [x19, #16]
	add	w1, w9, w1
LBB0_7:
	mov	w2, #128
	blr	x8
LBB0_8:
	ldp	w8, w9, [x19, #8]
	sub	w0, w8, w9
	b	LBB0_10
LBB0_9:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _errno@GOTPAGE
Lloh4:
	ldr	x9, [x9, _errno@GOTPAGEOFF]
Lloh5:
	str	w8, [x9]
	mov	w0, #-1
LBB0_10:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotStr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_errno,4,2                      ; @errno
	.no_dead_strip	_emem_seek
.subsections_via_symbols
