	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function moea64_pte_replace_inval_native
_moea64_pte_replace_inval_native:       ## @moea64_pte_replace_inval_native
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %r14
	leaq	-32(%rbp), %rsi
	movq	%r14, %rdi
	callq	_moea64_pte_from_pvo
	movq	_moea64_eviction_lock@GOTPCREL(%rip), %rdi
	callq	_rw_rlock
	movl	(%r15), %edi
	movq	_LPTE_AVPN_MASK@GOTPCREL(%rip), %rbx
	andl	(%rbx), %edi
	callq	_be64toh
	movl	(%rbx), %ecx
	andl	-32(%rbp), %ecx
	cmpl	%ecx, %eax
	jne	LBB0_1
## %bb.2:
	xorl	%eax, %eax
	callq	_isync
	xorl	%eax, %eax
	callq	_critical_enter
	movl	(%r15), %eax
	movq	_LPTE_VALID@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	notl	%edi
	andl	%eax, %edi
	movq	_LPTE_LOCKED@GOTPCREL(%rip), %rax
	orl	(%rax), %edi
	callq	_be64toh
	movl	%eax, (%r15)
	xorl	%eax, %eax
	callq	_PTESYNC
	movl	(%r14), %edi
	callq	_TLBIE
	movl	4(%r15), %edi
	callq	_be64toh
	movl	%eax, %r14d
	xorl	%eax, %eax
	callq	_EIEIO
	movl	-28(%rbp), %edi
	callq	_htobe64
	movl	%eax, 4(%r15)
	xorl	%eax, %eax
	callq	_EIEIO
	movl	-32(%rbp), %edi
	callq	_htobe64
	movl	%eax, (%r15)
	xorl	%eax, %eax
	callq	_PTESYNC
	xorl	%eax, %eax
	callq	_critical_exit
	movq	_moea64_eviction_lock@GOTPCREL(%rip), %rdi
	callq	_rw_runlock
	movq	_LPTE_CHG@GOTPCREL(%rip), %rcx
	movq	_LPTE_REF@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	(%rcx), %eax
	andl	%r14d, %eax
	jmp	LBB0_3
LBB0_1:
	movq	_moea64_pte_overflow@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leal	-1(%rdi), %ecx
	movl	%ecx, (%rax)
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_STAT_MOEA64
	movq	_moea64_eviction_lock@GOTPCREL(%rip), %rdi
	callq	_rw_runlock
	movl	$-1, %eax
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_moea64_eviction_lock,4,2       ## @moea64_eviction_lock
	.comm	_LPTE_AVPN_MASK,4,2             ## @LPTE_AVPN_MASK
	.comm	_moea64_pte_overflow,4,2        ## @moea64_pte_overflow
	.comm	_LPTE_VALID,4,2                 ## @LPTE_VALID
	.comm	_LPTE_LOCKED,4,2                ## @LPTE_LOCKED
	.comm	_LPTE_CHG,4,2                   ## @LPTE_CHG
	.comm	_LPTE_REF,4,2                   ## @LPTE_REF
	.no_dead_strip	_moea64_pte_replace_inval_native
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function moea64_pte_replace_inval_native
_moea64_pte_replace_inval_native:       ; @moea64_pte_replace_inval_native
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x2
	mov	x20, x1
	add	x1, sp, #8
	mov	x0, x20
	bl	_moea64_pte_from_pvo
Lloh0:
	adrp	x0, _moea64_eviction_lock@GOTPAGE
Lloh1:
	ldr	x0, [x0, _moea64_eviction_lock@GOTPAGEOFF]
	bl	_rw_rlock
	ldr	w8, [x19]
Lloh2:
	adrp	x21, _LPTE_AVPN_MASK@GOTPAGE
Lloh3:
	ldr	x21, [x21, _LPTE_AVPN_MASK@GOTPAGEOFF]
	ldr	w9, [x21]
	and	w0, w9, w8
	bl	_be64toh
	ldr	w8, [sp, #8]
	ldr	w9, [x21]
	and	w8, w9, w8
	cmp	w0, w8
	b.ne	LBB0_2
; %bb.1:
	bl	_isync
	bl	_critical_enter
	ldr	w8, [x19]
Lloh4:
	adrp	x9, _LPTE_VALID@GOTPAGE
Lloh5:
	ldr	x9, [x9, _LPTE_VALID@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	bic	w8, w8, w9
Lloh7:
	adrp	x9, _LPTE_LOCKED@GOTPAGE
Lloh8:
	ldr	x9, [x9, _LPTE_LOCKED@GOTPAGEOFF]
Lloh9:
	ldr	w9, [x9]
	orr	w0, w8, w9
	bl	_be64toh
	str	w0, [x19]
	bl	_PTESYNC
	ldr	w0, [x20]
	bl	_TLBIE
	ldr	w0, [x19, #4]
	bl	_be64toh
	mov	x20, x0
	bl	_EIEIO
	ldr	w0, [sp, #12]
	bl	_htobe64
	str	w0, [x19, #4]
	bl	_EIEIO
	ldr	w0, [sp, #8]
	bl	_htobe64
	str	w0, [x19]
	bl	_PTESYNC
	bl	_critical_exit
Lloh10:
	adrp	x0, _moea64_eviction_lock@GOTPAGE
Lloh11:
	ldr	x0, [x0, _moea64_eviction_lock@GOTPAGEOFF]
	bl	_rw_runlock
Lloh12:
	adrp	x8, _LPTE_CHG@GOTPAGE
Lloh13:
	ldr	x8, [x8, _LPTE_CHG@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
Lloh15:
	adrp	x9, _LPTE_REF@GOTPAGE
Lloh16:
	ldr	x9, [x9, _LPTE_REF@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	orr	w8, w9, w8
	and	w0, w8, w20
	b	LBB0_3
LBB0_2:
Lloh18:
	adrp	x8, _moea64_pte_overflow@GOTPAGE
Lloh19:
	ldr	x8, [x8, _moea64_pte_overflow@GOTPAGEOFF]
	ldr	w0, [x8]
	sub	w9, w0, #1
	str	w9, [x8]
	bl	_STAT_MOEA64
Lloh20:
	adrp	x0, _moea64_eviction_lock@GOTPAGE
Lloh21:
	ldr	x0, [x0, _moea64_eviction_lock@GOTPAGEOFF]
	bl	_rw_runlock
	mov	w0, #-1
LBB0_3:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_moea64_eviction_lock,4,2       ; @moea64_eviction_lock
	.comm	_LPTE_AVPN_MASK,4,2             ; @LPTE_AVPN_MASK
	.comm	_moea64_pte_overflow,4,2        ; @moea64_pte_overflow
	.comm	_LPTE_VALID,4,2                 ; @LPTE_VALID
	.comm	_LPTE_LOCKED,4,2                ; @LPTE_LOCKED
	.comm	_LPTE_CHG,4,2                   ; @LPTE_CHG
	.comm	_LPTE_REF,4,2                   ; @LPTE_REF
	.no_dead_strip	_moea64_pte_replace_inval_native
.subsections_via_symbols
