	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sel_mmap_policy_fault
_sel_mmap_policy_fault:                 ## @sel_mmap_policy_fault
	.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	_FAULT_FLAG_MKWRITE@GOTPCREL(%rip), %rax
	movq	_FAULT_FLAG_WRITE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	testl	%ecx, (%rsi)
	jne	LBB0_1
## %bb.2:
	movq	%rsi, %r14
	movq	(%rdi), %rax
	movq	8(%rsi), %rbx
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shlq	%cl, %rbx
	movq	(%rax), %r15
	movl	8(%r15), %edi
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_roundup
	cmpq	%rax, %rbx
	jae	LBB0_1
## %bb.3:
	addq	(%r15), %rbx
	movq	%rbx, %rdi
	callq	_vmalloc_to_page
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_get_page
	movq	%rbx, 16(%r14)
	xorl	%eax, %eax
	jmp	LBB0_4
LBB0_1:
	movq	_VM_FAULT_SIGBUS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_4:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FAULT_FLAG_MKWRITE,4,2         ## @FAULT_FLAG_MKWRITE
	.comm	_FAULT_FLAG_WRITE,4,2           ## @FAULT_FLAG_WRITE
	.comm	_VM_FAULT_SIGBUS,4,2            ## @VM_FAULT_SIGBUS
	.comm	_PAGE_SHIFT,8,3                 ## @PAGE_SHIFT
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.no_dead_strip	_sel_mmap_policy_fault
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sel_mmap_policy_fault
_sel_mmap_policy_fault:                 ; @sel_mmap_policy_fault
	.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
	ldr	w8, [x1]
Lloh0:
	adrp	x9, _FAULT_FLAG_MKWRITE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _FAULT_FLAG_MKWRITE@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
Lloh3:
	adrp	x10, _FAULT_FLAG_WRITE@GOTPAGE
Lloh4:
	ldr	x10, [x10, _FAULT_FLAG_WRITE@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.ne	LBB0_3
; %bb.1:
	mov	x19, x1
	ldr	x8, [x0]
	ldr	x20, [x8]
	ldr	x8, [x1, #8]
Lloh6:
	adrp	x9, _PAGE_SHIFT@GOTPAGE
Lloh7:
	ldr	x9, [x9, _PAGE_SHIFT@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	lsl	x21, x8, x9
	ldr	w0, [x20, #8]
Lloh9:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	bl	_roundup
	cmp	x21, x0
	b.hs	LBB0_3
; %bb.2:
	ldr	x8, [x20]
	add	x0, x8, x21
	bl	_vmalloc_to_page
	mov	x20, x0
	bl	_get_page
	mov	w0, #0
	str	x20, [x19, #16]
	b	LBB0_4
LBB0_3:
Lloh12:
	adrp	x8, _VM_FAULT_SIGBUS@GOTPAGE
Lloh13:
	ldr	x8, [x8, _VM_FAULT_SIGBUS@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
LBB0_4:
	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
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_FAULT_FLAG_MKWRITE,4,2         ; @FAULT_FLAG_MKWRITE
	.comm	_FAULT_FLAG_WRITE,4,2           ; @FAULT_FLAG_WRITE
	.comm	_VM_FAULT_SIGBUS,4,2            ; @VM_FAULT_SIGBUS
	.comm	_PAGE_SHIFT,8,3                 ; @PAGE_SHIFT
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.no_dead_strip	_sel_mmap_policy_fault
.subsections_via_symbols
