	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__FAT_seek_r                    ## -- Begin function _FAT_seek_r
	.p2align	4, 0x90
__FAT_seek_r:                           ## @_FAT_seek_r
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	testq	%rsi, %rsi
	je	LBB0_6
## %bb.1:
	movq	%rsi, %r14
	cmpl	$0, (%rsi)
	je	LBB0_6
## %bb.2:
	movl	%ecx, %ebx
	movl	%edx, %r15d
	movq	56(%r14), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	leaq	16(%rax), %rdi
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	callq	__FAT_lock
	movl	%r15d, %r12d
	cmpl	$128, %ebx
	je	LBB0_9
## %bb.3:
	cmpl	$130, %ebx
	je	LBB0_7
## %bb.4:
	cmpl	$129, %ebx
	jne	LBB0_17
## %bb.5:
	movl	$16, %eax
	jmp	LBB0_8
LBB0_6:
	movq	_EBADF@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_7:
	movl	$8, %eax
LBB0_8:
	movl	(%r14,%rax), %r12d
	addl	%r15d, %r12d
LBB0_9:
	testl	%r15d, %r15d
	jle	LBB0_12
## %bb.10:
	testl	%r12d, %r12d
	jns	LBB0_12
## %bb.11:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	__FAT_unlock
	movq	_EOVERFLOW@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_12:
	testl	%r12d, %r12d
	js	LBB0_17
## %bb.13:
	movl	%r12d, %ecx
	cmpq	%rcx, 16(%r14)
	jl	LBB0_46
## %bb.14:
	movq	24(%r14), %rdx
	movq	_CLUSTER_FREE@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdx
	je	LBB0_46
## %bb.15:
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	movq	(%r8), %rsi
	movq	%rsi, %rax
	shrq	$32, %rax
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	je	LBB0_21
## %bb.16:
	movq	%rcx, %rax
	xorl	%edx, %edx
	idivq	%rsi
	movq	%rdx, %rdi
	movq	%rax, %rbx
	jmp	LBB0_22
LBB0_17:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	__FAT_unlock
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_18:
	movq	(%rax), %rax
	movq	%rax, (%r13)
LBB0_19:
	movl	$-1, %r12d
LBB0_20:
	movl	%r12d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_21:
	movl	%ecx, %eax
	xorl	%edx, %edx
	divl	%esi
	movl	%edx, %edi
	movl	%eax, %ebx
LBB0_22:
	movq	8(%r14), %rax
	cmpq	%rcx, %rax
	jg	LBB0_27
## %bb.23:
	movq	%rax, %rdx
	orq	%rsi, %rdx
	shrq	$32, %rdx
	je	LBB0_25
## %bb.24:
	cqto
	idivq	%rsi
	jmp	LBB0_26
LBB0_25:
                                        ## kill: def $eax killed $eax killed $rax
	xorl	%edx, %edx
	divl	%esi
                                        ## kill: def $eax killed $eax def $rax
LBB0_26:
	movq	48(%r14), %rdx
	xorl	%esi, %esi
	cmpq	24(%r8), %rdx
	movq	32(%r14), %rdx
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	sete	%sil
	subl	%eax, %ebx
	addl	%esi, %ebx
LBB0_27:
	movq	8(%r8), %rsi
	movq	%rdi, %rax
	orq	%rsi, %rax
	shrq	$32, %rax
	je	LBB0_29
## %bb.28:
	movq	%rdi, %rax
	cqto
	idivq	%rsi
	jmp	LBB0_30
LBB0_29:
	movl	%edi, %eax
	xorl	%edx, %edx
	divl	%esi
                                        ## kill: def $eax killed $eax def $rax
LBB0_30:
	movq	%rax, 48(%r14)
	movq	%rsi, %rax
	shrq	$32, %rax
	movq	%rcx, -80(%rbp)                 ## 8-byte Spill
	je	LBB0_32
## %bb.31:
	movq	%rcx, %rax
	xorl	%edx, %edx
	idivq	%rsi
	jmp	LBB0_33
LBB0_32:
	movl	%ecx, %eax
	xorl	%edx, %edx
	divl	%esi
                                        ## kill: def $edx killed $edx def $rdx
LBB0_33:
	movq	%rdx, 40(%r14)
	movq	%r8, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	callq	__FAT_fat_nextCluster
	testl	%ebx, %ebx
	setg	%cl
	movq	%r13, -72(%rbp)                 ## 8-byte Spill
	jle	LBB0_38
## %bb.34:
	movq	_CLUSTER_FREE@GOTPCREL(%rip), %r15
	.p2align	4, 0x90
LBB0_35:                                ## =>This Inner Loop Header: Depth=1
	cmpq	(%r15), %rax
	je	LBB0_38
## %bb.36:                              ##   in Loop: Header=BB0_35 Depth=1
	movq	_CLUSTER_EOF@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rax
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	je	LBB0_39
## %bb.37:                              ##   in Loop: Header=BB0_35 Depth=1
	movq	%rax, %rsi
	movl	%ebx, %r13d
	leal	-1(%r13), %ebx
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	callq	__FAT_fat_nextCluster
	cmpl	$2, %r13d
	setge	%cl
	jge	LBB0_35
LBB0_38:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
LBB0_39:
	testb	%cl, %cl
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	je	LBB0_45
## %bb.40:
	cmpl	$1, %ebx
	jne	LBB0_43
## %bb.41:
	cmpq	%rcx, 16(%r14)
	jne	LBB0_43
## %bb.42:
	cmpq	$0, 48(%r14)
	je	LBB0_44
LBB0_43:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	__FAT_unlock
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	jmp	LBB0_19
LBB0_44:
	movq	24(%rdi), %rax
	movq	%rax, 48(%r14)
	movq	$0, 40(%r14)
LBB0_45:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	%rax, 32(%r14)
LBB0_46:
	movq	%rcx, 8(%r14)
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	__FAT_unlock
	jmp	LBB0_20
	.cfi_endproc
                                        ## -- End function
	.comm	_EBADF,8,3                      ## @EBADF
	.comm	_EINVAL,8,3                     ## @EINVAL
	.comm	_EOVERFLOW,8,3                  ## @EOVERFLOW
	.comm	_CLUSTER_FREE,8,3               ## @CLUSTER_FREE
	.comm	_CLUSTER_EOF,8,3                ## @CLUSTER_EOF
	.comm	_FILE_MAX_SIZE,8,3              ## @FILE_MAX_SIZE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__FAT_seek_r                    ; -- Begin function _FAT_seek_r
	.p2align	2
__FAT_seek_r:                           ; @_FAT_seek_r
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
	cbz	x1, LBB0_6
; %bb.1:
	mov	x21, x1
	ldr	w8, [x1]
	cbz	w8, LBB0_6
; %bb.2:
	mov	x25, x3
	mov	x24, x2
	ldr	x23, [x21, #56]
	add	x20, x23, #16
	mov	x0, x20
	bl	__FAT_lock
	mov	x22, x24
	cmp	w25, #128
	b.eq	LBB0_9
; %bb.3:
	cmp	w25, #130
	b.eq	LBB0_7
; %bb.4:
	cmp	w25, #129
	b.ne	LBB0_27
; %bb.5:
	mov	w8, #16
	b	LBB0_8
LBB0_6:
Lloh0:
	adrp	x8, _EBADF@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EBADF@GOTPAGEOFF]
	b	LBB0_28
LBB0_7:
	mov	w8, #8
LBB0_8:
	ldr	w8, [x21, x8]
	add	w22, w8, w24
LBB0_9:
	cmp	w24, #1
	b.lt	LBB0_12
; %bb.10:
	tbz	w22, #31, LBB0_12
; %bb.11:
	mov	x0, x20
	bl	__FAT_unlock
Lloh2:
	adrp	x8, _EOVERFLOW@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EOVERFLOW@GOTPAGEOFF]
	b	LBB0_28
LBB0_12:
	tbnz	w22, #31, LBB0_27
; %bb.13:
	mov	w26, w22
	ldr	x8, [x21, #16]
	cmp	x8, x26
	b.lt	LBB0_32
; %bb.14:
	ldr	x24, [x21, #24]
Lloh4:
	adrp	x27, _CLUSTER_FREE@GOTPAGE
Lloh5:
	ldr	x27, [x27, _CLUSTER_FREE@GOTPAGEOFF]
	ldr	x8, [x27]
	cmp	x24, x8
	b.eq	LBB0_32
; %bb.15:
	ldr	x8, [x23]
	ldr	x10, [x21, #8]
	sdiv	x9, x26, x8
	cmp	x10, x26
	b.le	LBB0_17
; %bb.16:
	mov	x25, x9
	b	LBB0_18
LBB0_17:
	sdiv	x10, x10, x8
	ldr	x11, [x21, #48]
	ldr	x12, [x23, #24]
	sub	w10, w9, w10
	cmp	x11, x12
	cinc	w25, w10, eq
	ldr	x24, [x21, #32]
LBB0_18:
	msub	x8, x9, x8, x26
	ldr	x9, [x23, #8]
	sdiv	x10, x26, x9
	msub	x10, x10, x9, x26
	sdiv	x8, x8, x9
	stp	x10, x8, [x21, #40]
	mov	x0, x23
	mov	x1, x24
	bl	__FAT_fat_nextCluster
	cmp	w25, #0
	cset	w8, gt
	cmp	w25, #1
	str	x26, [sp, #8]                   ; 8-byte Folded Spill
	b.lt	LBB0_23
; %bb.19:
	ldr	x9, [x27]
	cmp	x0, x9
	b.eq	LBB0_23
; %bb.20:
Lloh6:
	adrp	x28, _CLUSTER_EOF@GOTPAGE
Lloh7:
	ldr	x28, [x28, _CLUSTER_EOF@GOTPAGEOFF]
	ldr	x9, [x28]
	cmp	x0, x9
	b.eq	LBB0_23
LBB0_21:                                ; =>This Inner Loop Header: Depth=1
	mov	x24, x0
	mov	x26, x25
	mov	x0, x23
	mov	x1, x24
	bl	__FAT_fat_nextCluster
	subs	w25, w25, #1
	cset	w8, gt
	cmp	w26, #2
	b.lt	LBB0_23
; %bb.22:                               ;   in Loop: Header=BB0_21 Depth=1
	ldr	x9, [x27]
	ldr	x10, [x28]
	cmp	x0, x9
	ccmp	x0, x10, #4, ne
	b.ne	LBB0_21
LBB0_23:
	ldr	x26, [sp, #8]                   ; 8-byte Folded Reload
	cbz	w8, LBB0_31
; %bb.24:
	cmp	w25, #1
	b.ne	LBB0_27
; %bb.25:
	ldr	x8, [x21, #16]
	cmp	x8, x26
	b.ne	LBB0_27
; %bb.26:
	ldr	x8, [x21, #48]
	cbz	x8, LBB0_30
LBB0_27:
	mov	x0, x20
	bl	__FAT_unlock
Lloh8:
	adrp	x8, _EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_28:
	ldr	x8, [x8]
	str	x8, [x19]
	mov	w22, #-1
LBB0_29:
	mov	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
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_30:
	ldr	x8, [x23, #24]
	stp	xzr, x8, [x21, #40]
LBB0_31:
	str	x24, [x21, #32]
LBB0_32:
	str	x26, [x21, #8]
	mov	x0, x20
	bl	__FAT_unlock
	b	LBB0_29
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_EBADF,8,3                      ; @EBADF
	.comm	_EINVAL,8,3                     ; @EINVAL
	.comm	_EOVERFLOW,8,3                  ; @EOVERFLOW
	.comm	_CLUSTER_FREE,8,3               ; @CLUSTER_FREE
	.comm	_CLUSTER_EOF,8,3                ; @CLUSTER_EOF
	.comm	_FILE_MAX_SIZE,8,3              ; @FILE_MAX_SIZE
.subsections_via_symbols
