	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function __arm_lpae_unmap
___arm_lpae_unmap:                      ## @__arm_lpae_unmap
	.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	%r9, -64(%rbp)                  ## 8-byte Spill
	movl	%r8d, %r15d
	movq	%rcx, %r14
	movq	%rdx, %rbx
	movq	%rsi, %r12
	movq	%rdi, %r13
	movq	_ARM_LPAE_MAX_LEVELS@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	%r8d, (%rax)
	sete	%dil
	callq	_WARN_ON
	testq	%rax, %rax
	je	LBB0_1
LBB0_12:
	xorl	%r14d, %r14d
LBB0_13:
	movq	%r14, %rax
LBB0_14:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	%r12, -72(%rbp)                 ## 8-byte Spill
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movq	%r13, %rdx
	callq	_ARM_LPAE_LVL_IDX
	movslq	%eax, %r14
	movq	%r12, -64(%rbp)                 ## 8-byte Spill
	movl	(%r12,%r14,4), %edi
	callq	_READ_ONCE
	movl	%eax, %r12d
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_WARN_ON
	testq	%rax, %rax
	jne	LBB0_12
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r13, %rbx
	movl	%r15d, %edi
	movq	%r13, %rsi
	callq	_ARM_LPAE_BLOCK_SIZE
	cmpq	-48(%rbp), %rax                 ## 8-byte Folded Reload
	je	LBB0_4
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	(%rbx), %edx
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_iopte_leaf
	testq	%rax, %rax
	jne	LBB0_10
## %bb.11:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	%r12d, %edi
	movq	%rbx, %rsi
	callq	_iopte_deref
	movq	%rax, %r12
	incl	%r15d
	xorl	%edi, %edi
	movq	_ARM_LPAE_MAX_LEVELS@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r15d
	sete	%dil
	callq	_WARN_ON
	testq	%rax, %rax
	movq	%rbx, %r13
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	je	LBB0_2
	jmp	LBB0_12
LBB0_4:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	leaq	(%rax,%r14,4), %rdi
	leaq	4(%rbx), %r13
	xorl	%esi, %esi
	movq	%r13, %rdx
	callq	___arm_lpae_set_pte
	movl	(%rbx), %edx
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_iopte_leaf
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movq	_IO_PGTABLE_QUIRK_NON_STRICT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r13)
	je	LBB0_8
## %bb.7:
	xorl	%eax, %eax
	callq	_smp_wmb
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	jmp	LBB0_13
LBB0_10:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	leaq	(%rax,%r14,4), %rax
	incl	%r15d
	movq	%rax, (%rsp)
	movq	%rbx, %rdi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	%r12d, %r8d
	movl	%r15d, %r9d
	callq	_arm_lpae_split_blk_unmap
	jmp	LBB0_14
LBB0_5:
	movq	%rbx, %rdi
	callq	_ARM_LPAE_GRANULE
	movq	%rbx, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdx
	movl	%eax, %ecx
	callq	_io_pgtable_tlb_flush_walk
	movl	%r12d, %edi
	movq	%rbx, %rsi
	callq	_iopte_deref
	incl	%r15d
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movq	%rax, %rdx
	callq	___arm_lpae_free_pgtable
	jmp	LBB0_13
LBB0_8:
	movq	%rbx, %rdi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rcx
	callq	_io_pgtable_tlb_add_page
	jmp	LBB0_13
	.cfi_endproc
                                        ## -- End function
	.comm	_ARM_LPAE_MAX_LEVELS,4,2        ## @ARM_LPAE_MAX_LEVELS
	.comm	_IO_PGTABLE_QUIRK_NON_STRICT,4,2 ## @IO_PGTABLE_QUIRK_NON_STRICT
	.no_dead_strip	___arm_lpae_unmap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function __arm_lpae_unmap
___arm_lpae_unmap:                      ; @__arm_lpae_unmap
	.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	x24, x5
	mov	x22, x4
	mov	x19, x3
	mov	x21, x2
	mov	x23, x1
	mov	x20, x0
Lloh0:
	adrp	x27, _ARM_LPAE_MAX_LEVELS@GOTPAGE
Lloh1:
	ldr	x27, [x27, _ARM_LPAE_MAX_LEVELS@GOTPAGEOFF]
	ldr	w8, [x27]
	cmp	w8, w4
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	cset	w0, eq
	bl	_WARN_ON
	cbnz	x0, LBB0_6
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x0, x21
	mov	x1, x22
	mov	x2, x20
	bl	_ARM_LPAE_LVL_IDX
	mov	x26, x0
	ldr	w0, [x24, w0, sxtw #2]
	bl	_READ_ONCE
	mov	x25, x0
	cmp	w0, #0
	cset	w0, eq
	bl	_WARN_ON
	cbnz	x0, LBB0_6
; %bb.3:                                ;   in Loop: Header=BB0_1 Depth=1
	sxtw	x26, w26
	mov	x0, x22
	mov	x1, x20
	bl	_ARM_LPAE_BLOCK_SIZE
	cmp	x0, x19
	b.eq	LBB0_8
; %bb.4:                                ;   in Loop: Header=BB0_1 Depth=1
	ldr	w2, [x20]
	mov	x0, x25
	mov	x1, x22
	bl	_iopte_leaf
	cbnz	x0, LBB0_11
; %bb.5:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x0, x25
	mov	x1, x20
	bl	_iopte_deref
	mov	x24, x0
	add	w22, w22, #1
	ldr	w8, [x27]
	cmp	w22, w8
	b	LBB0_1
LBB0_6:
	mov	x19, #0
LBB0_7:
	mov	x0, x19
	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_8:
	add	x0, x24, x26, lsl #2
	add	x24, x20, #4
	mov	w1, #0
	mov	x2, x24
	bl	___arm_lpae_set_pte
	ldr	w2, [x20]
	mov	x0, x25
	mov	x1, x22
	bl	_iopte_leaf
	cbz	x0, LBB0_12
; %bb.9:
	ldr	w8, [x24]
Lloh2:
	adrp	x9, _IO_PGTABLE_QUIRK_NON_STRICT@GOTPAGE
Lloh3:
	ldr	x9, [x9, _IO_PGTABLE_QUIRK_NON_STRICT@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_13
; %bb.10:
	bl	_smp_wmb
	b	LBB0_7
LBB0_11:
	add	x6, x24, x26, lsl #2
	add	w5, w22, #1
	mov	x0, x20
	mov	x1, x23
	mov	x2, x21
	mov	x3, x19
	mov	x4, x25
	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
	b	_arm_lpae_split_blk_unmap
LBB0_12:
	mov	x0, x20
	bl	_ARM_LPAE_GRANULE
	mov	x3, x0
	mov	x0, x20
	mov	x1, x21
	mov	x2, x19
	bl	_io_pgtable_tlb_flush_walk
	mov	x0, x25
	mov	x1, x20
	bl	_iopte_deref
	mov	x2, x0
	add	w1, w22, #1
	mov	x0, x20
	bl	___arm_lpae_free_pgtable
	b	LBB0_7
LBB0_13:
	mov	x0, x20
	mov	x1, x23
	mov	x2, x21
	mov	x3, x19
	bl	_io_pgtable_tlb_add_page
	b	LBB0_7
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_ARM_LPAE_MAX_LEVELS,4,2        ; @ARM_LPAE_MAX_LEVELS
	.comm	_IO_PGTABLE_QUIRK_NON_STRICT,4,2 ; @IO_PGTABLE_QUIRK_NON_STRICT
	.no_dead_strip	___arm_lpae_unmap
.subsections_via_symbols
