	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function __card_freeblock
___card_freeblock:                      ## @__card_freeblock
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_EXI_CHANNEL_0@GOTPCREL(%rip), %rax
	cmpq	%rdi, (%rax)
	ja	LBB0_2
## %bb.1:
	movq	%rdi, %rbx
	movq	_EXI_CHANNEL_2@GOTPCREL(%rip), %rax
	cmpq	%rdi, (%rax)
	jbe	LBB0_2
## %bb.4:
	movq	_cardmap@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	movq	%rbx, %rax
	shlq	$4, %rax
	cmpl	$0, 8(%r15,%rax)
	je	LBB0_2
## %bb.5:
	movl	%edx, %r14d
	movq	%rsi, %r12
	addq	%rax, %r15
	movq	%r15, %rdi
	callq	___card_getbatblock
	movq	(%rax), %rcx
	movq	_CARD_SYSAREA@GOTPCREL(%rip), %r8
	movq	(%r8), %rdi
	subq	%rdi, %r12
	movq	(%rcx,%r12,8), %rdx
	cmpq	$65535, %rdx                    ## imm = 0xFFFF
	jne	LBB0_6
LBB0_11:
	movq	%rbx, %rdi
	movq	%rax, %rsi
	movl	%r14d, %edx
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	___card_updatefat               ## TAILCALL
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	%rdi, %rdx
	jb	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	cmpq	(%r15), %rdx
	jae	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	%rdx, %rsi
	subq	%rdi, %rsi
	movq	(%rcx,%rsi,8), %rdx
	movq	$0, (%rcx,%rsi,8)
	incl	8(%rax)
	cmpq	$65535, %rdx                    ## imm = 0xFFFF
	je	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_6 Depth=1
	movq	(%r8), %rdi
	jmp	LBB0_6
LBB0_2:
	movq	_CARD_ERROR_NOCARD@GOTPCREL(%rip), %rax
LBB0_3:
	movq	(%rax), %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	movq	_CARD_ERROR_BROKEN@GOTPCREL(%rip), %rax
	jmp	LBB0_3
	.cfi_endproc
                                        ## -- End function
	.comm	_EXI_CHANNEL_0,8,3              ## @EXI_CHANNEL_0
	.comm	_EXI_CHANNEL_2,8,3              ## @EXI_CHANNEL_2
	.comm	_CARD_ERROR_NOCARD,8,3          ## @CARD_ERROR_NOCARD
	.comm	_cardmap,8,3                    ## @cardmap
	.comm	_CARD_SYSAREA,8,3               ## @CARD_SYSAREA
	.comm	_CARD_ERROR_BROKEN,8,3          ## @CARD_ERROR_BROKEN
	.no_dead_strip	___card_freeblock
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function __card_freeblock
___card_freeblock:                      ; @__card_freeblock
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
Lloh0:
	adrp	x8, _EXI_CHANNEL_0@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EXI_CHANNEL_0@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
Lloh3:
	adrp	x9, _EXI_CHANNEL_2@GOTPAGE
Lloh4:
	ldr	x9, [x9, _EXI_CHANNEL_2@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x0
	ccmp	x9, x0, #0, ls
	b.ls	LBB0_4
; %bb.1:
	mov	x20, x0
Lloh6:
	adrp	x8, _cardmap@GOTPAGE
Lloh7:
	ldr	x8, [x8, _cardmap@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	add	x21, x8, x0, lsl #4
	ldr	w8, [x21, #8]
	cbz	w8, LBB0_4
; %bb.2:
	mov	x19, x2
	mov	x22, x1
	mov	x0, x21
	bl	___card_getbatblock
	mov	x1, x0
	ldr	x8, [x0]
Lloh9:
	adrp	x9, _CARD_SYSAREA@GOTPAGE
Lloh10:
	ldr	x9, [x9, _CARD_SYSAREA@GOTPAGEOFF]
	ldr	x11, [x9]
	sub	x10, x22, x11
	ldr	x10, [x8, x10, lsl #3]
	mov	w12, #65535
	cmp	x10, x12
	b.ne	LBB0_6
LBB0_3:
	mov	x0, x20
	mov	x2, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	___card_updatefat
LBB0_4:
Lloh11:
	adrp	x8, _CARD_ERROR_NOCARD@GOTPAGE
Lloh12:
	ldr	x8, [x8, _CARD_ERROR_NOCARD@GOTPAGEOFF]
LBB0_5:
	ldr	x0, [x8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_6:
	cmp	x10, x11
	b.lo	LBB0_11
; %bb.7:
	mov	w12, #65535
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x13, [x21]
	cmp	x10, x13
	b.hs	LBB0_11
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	sub	x10, x10, x11
	lsl	x11, x10, #3
	ldr	x10, [x8, x11]
	str	xzr, [x8, x11]
	ldr	w11, [x1, #8]
	add	w11, w11, #1
	str	w11, [x1, #8]
	cmp	x10, x12
	b.eq	LBB0_3
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	ldr	x11, [x9]
	cmp	x10, x11
	b.hs	LBB0_8
LBB0_11:
Lloh13:
	adrp	x8, _CARD_ERROR_BROKEN@GOTPAGE
Lloh14:
	ldr	x8, [x8, _CARD_ERROR_BROKEN@GOTPAGEOFF]
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_EXI_CHANNEL_0,8,3              ; @EXI_CHANNEL_0
	.comm	_EXI_CHANNEL_2,8,3              ; @EXI_CHANNEL_2
	.comm	_CARD_ERROR_NOCARD,8,3          ; @CARD_ERROR_NOCARD
	.comm	_cardmap,8,3                    ; @cardmap
	.comm	_CARD_SYSAREA,8,3               ; @CARD_SYSAREA
	.comm	_CARD_ERROR_BROKEN,8,3          ; @CARD_ERROR_BROKEN
	.no_dead_strip	___card_freeblock
.subsections_via_symbols
