	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dmz_recover_mblocks
_dmz_recover_mblocks:                   ## @dmz_recover_mblocks
	.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
	movl	%esi, %r13d
	movq	%rdi, %r12
	movq	16(%rdi), %rdi
	leaq	L_.str(%rip), %rsi
	movl	%r13d, %edx
	callq	_dmz_dev_warn
	testl	%r13d, %r13d
	je	LBB0_1
## %bb.2:
	movq	8(%r12), %rax
	movl	(%r12), %edx
	movq	16(%r12), %rcx
	movb	(%rcx), %cl
	shll	%cl, %edx
	movslq	%edx, %rcx
	addq	16(%rax), %rcx
	movq	%rcx, 40(%rax)
	jmp	LBB0_3
LBB0_1:
	movl	24(%r12), %esi
	movq	%r12, %rdi
	callq	_dmz_start_block
	movq	8(%r12), %rcx
	movq	%rax, 16(%rcx)
LBB0_3:
	movq	_GFP_NOIO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_alloc_page
	testq	%rax, %rax
	je	LBB0_9
## %bb.4:
	movq	%rax, %r15
	cmpl	$1, 4(%r12)
	jle	LBB0_5
## %bb.12:
	movl	%r13d, %eax
	xorl	$1, %eax
	movl	%eax, %eax
	movl	%r13d, -44(%rbp)                ## 4-byte Spill
	movl	%r13d, %ecx
	movl	$1, %r13d
	leaq	(%rax,%rax,2), %r14
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	leaq	(%rcx,%rcx,2), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movq	_REQ_OP_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	8(%r12), %rax
	movq	16(%rax,%r14,8), %rdx
	addq	%r13, %rdx
	movq	%r12, %rdi
	movq	%r15, %rcx
	callq	_dmz_rdwr_block
	testl	%eax, %eax
	jne	LBB0_17
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	_REQ_OP_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	8(%r12), %rax
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	16(%rax,%rcx,8), %rdx
	addq	%r13, %rdx
	movq	%r12, %rdi
	movq	%r15, %rcx
	callq	_dmz_rdwr_block
	testl	%eax, %eax
	jne	LBB0_17
## %bb.10:                              ##   in Loop: Header=BB0_13 Depth=1
	incq	%r13
	movslq	4(%r12), %rax
	cmpq	%rax, %r13
	jl	LBB0_13
## %bb.11:
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	jmp	LBB0_6
LBB0_9:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_19
LBB0_5:
	movl	%r13d, %ecx
LBB0_6:
	movq	8(%r12), %rax
	leaq	(%rcx,%rcx,2), %r14
	cmpq	$0, (%rax,%r14,8)
	jne	LBB0_16
## %bb.7:
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_dmz_alloc_mblock
	movq	8(%r12), %rcx
	movq	%rax, (%rcx,%r14,8)
	testq	%rax, %rax
	je	LBB0_8
## %bb.15:
	movl	(%rax), %eax
	movl	%eax, 8(%rcx,%r14,8)
LBB0_16:
	movq	%r12, %rdi
	movl	%r13d, %esi
	callq	_dmz_write_sb
LBB0_17:
	movl	%eax, %ebx
LBB0_18:
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	___free_pages
LBB0_19:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_18
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Metadata set %u invalid: recovering"

	.comm	_GFP_NOIO,4,2                   ## @GFP_NOIO
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_REQ_OP_READ,4,2                ## @REQ_OP_READ
	.comm	_REQ_OP_WRITE,4,2               ## @REQ_OP_WRITE
	.no_dead_strip	_dmz_recover_mblocks
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dmz_recover_mblocks
_dmz_recover_mblocks:                   ; @dmz_recover_mblocks
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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, x1
	mov	x20, x0
	ldr	x0, [x0, #16]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x19
	bl	_dmz_dev_warn
	cbz	w19, LBB0_2
; %bb.1:
	ldp	x8, x9, [x20, #8]
	ldr	x10, [x8, #16]
	ldr	w11, [x20]
	ldr	w9, [x9]
	lsl	w9, w11, w9
	add	x9, x10, w9, sxtw
	str	x9, [x8, #40]
	b	LBB0_3
LBB0_2:
	ldr	w1, [x20, #24]
	mov	x0, x20
	bl	_dmz_start_block
	ldr	x8, [x20, #8]
	str	x0, [x8, #16]
LBB0_3:
Lloh2:
	adrp	x8, _GFP_NOIO@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GFP_NOIO@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	bl	_alloc_page
	cbz	x0, LBB0_9
; %bb.4:
	mov	x21, x0
	ldr	w8, [x20, #4]
	cmp	w8, #1
	b.le	LBB0_10
; %bb.5:
	eor	w24, w19, #0x1
	mov	w25, #1
Lloh5:
	adrp	x26, _REQ_OP_READ@GOTPAGE
Lloh6:
	ldr	x26, [x26, _REQ_OP_READ@GOTPAGEOFF]
	mov	w27, #24
Lloh7:
	adrp	x28, _REQ_OP_WRITE@GOTPAGE
Lloh8:
	ldr	x28, [x28, _REQ_OP_WRITE@GOTPAGEOFF]
	mov	w23, w19
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x26]
	ldr	x8, [x20, #8]
	madd	x8, x24, x27, x8
	ldr	x8, [x8, #16]
	add	x2, x25, x8
	mov	x0, x20
	mov	x3, x21
	bl	_dmz_rdwr_block
	cbnz	w0, LBB0_15
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w1, [x28]
	ldr	x8, [x20, #8]
	madd	x8, x23, x27, x8
	ldr	x8, [x8, #16]
	add	x2, x25, x8
	mov	x0, x20
	mov	x3, x21
	bl	_dmz_rdwr_block
	cbnz	w0, LBB0_15
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x25, x25, #1
	ldrsw	x8, [x20, #4]
	cmp	x25, x8
	b.lt	LBB0_6
	b	LBB0_11
LBB0_9:
Lloh9:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_17
LBB0_10:
	mov	w23, w19
LBB0_11:
	ldr	x8, [x20, #8]
	mov	w9, #24
	mul	x9, x23, x9
	ldr	x8, [x8, x9]
	cbnz	x8, LBB0_14
; %bb.12:
	mov	x0, x20
	mov	w1, #0
	bl	_dmz_alloc_mblock
	ldr	x8, [x20, #8]
	mov	w9, #24
	mul	x9, x23, x9
	str	x0, [x8, x9]
	cbz	x0, LBB0_18
; %bb.13:
	ldr	w9, [x0]
	mov	w10, #24
	madd	x8, x23, x10, x8
	str	w9, [x8, #8]
LBB0_14:
	mov	x0, x20
	mov	x1, x19
	bl	_dmz_write_sb
LBB0_15:
	mov	x22, x0
LBB0_16:
	mov	x0, x21
	mov	w1, #0
	bl	___free_pages
LBB0_17:
	mov	x0, x22
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_18:
Lloh12:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_16
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Metadata set %u invalid: recovering"

	.comm	_GFP_NOIO,4,2                   ; @GFP_NOIO
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_REQ_OP_READ,4,2                ; @REQ_OP_READ
	.comm	_REQ_OP_WRITE,4,2               ; @REQ_OP_WRITE
	.no_dead_strip	_dmz_recover_mblocks
.subsections_via_symbols
