	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pages_commit_impl
_pages_commit_impl:                     ## @pages_commit_impl
	.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
	movl	%edx, %r15d
	movq	%rsi, %r14
	movq	%rdi, %r12
	callq	_PAGE_ADDR2BASE
	xorl	%edi, %edi
	cmpq	%r12, %rax
	sete	%dil
	callq	_assert
	movq	%r14, %rdi
	callq	_PAGE_CEILING
	xorl	%edi, %edi
	cmpq	%r14, %rax
	sete	%dil
	callq	_assert
	movq	_os_overcommits@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jne	LBB0_7
## %bb.1:
	testl	%r15d, %r15d
	jne	LBB0_2
## %bb.3:
	movq	_PAGES_PROT_DECOMMIT@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_2:
	movq	_PAGES_PROT_COMMIT@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %edx
	movq	_mmap_flags@GOTPCREL(%rip), %rax
	movq	_MAP_FIXED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	movq	%r14, %rsi
	movl	$-1, %r8d
	xorl	%r9d, %r9d
	callq	_mmap
	movq	_MAP_FAILED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_7
## %bb.5:
	cmpq	%r12, %rax
	je	LBB0_8
## %bb.6:
	movq	%rax, %rdi
	movq	%r14, %rsi
	callq	_os_pages_unmap
LBB0_7:
	movl	$1, %ebx
LBB0_8:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_os_overcommits,8,3             ## @os_overcommits
	.comm	_PAGES_PROT_COMMIT,4,2          ## @PAGES_PROT_COMMIT
	.comm	_PAGES_PROT_DECOMMIT,4,2        ## @PAGES_PROT_DECOMMIT
	.comm	_mmap_flags,4,2                 ## @mmap_flags
	.comm	_MAP_FIXED,4,2                  ## @MAP_FIXED
	.comm	_MAP_FAILED,8,3                 ## @MAP_FAILED
	.comm	_MEM_COMMIT,4,2                 ## @MEM_COMMIT
	.comm	_MEM_DECOMMIT,4,2               ## @MEM_DECOMMIT
	.comm	_PAGE_READWRITE,4,2             ## @PAGE_READWRITE
	.no_dead_strip	_pages_commit_impl
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pages_commit_impl
_pages_commit_impl:                     ; @pages_commit_impl
	.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
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	bl	_PAGE_ADDR2BASE
	cmp	x0, x20
	cset	w0, eq
	bl	_assert
	mov	x0, x19
	bl	_PAGE_CEILING
	cmp	x0, x19
	cset	w0, eq
	bl	_assert
Lloh0:
	adrp	x8, _os_overcommits@GOTPAGE
Lloh1:
	ldr	x8, [x8, _os_overcommits@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cbz	x8, LBB0_3
LBB0_1:
	mov	w0, #1
LBB0_2:
	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_3:
Lloh3:
	adrp	x8, _PAGES_PROT_COMMIT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PAGES_PROT_COMMIT@GOTPAGEOFF]
Lloh5:
	adrp	x9, _PAGES_PROT_DECOMMIT@GOTPAGE
Lloh6:
	ldr	x9, [x9, _PAGES_PROT_DECOMMIT@GOTPAGEOFF]
	cmp	w21, #0
	csel	x8, x9, x8, eq
Lloh7:
	adrp	x9, _mmap_flags@GOTPAGE
Lloh8:
	ldr	x9, [x9, _mmap_flags@GOTPAGEOFF]
	ldr	w2, [x8]
Lloh9:
	ldr	w8, [x9]
Lloh10:
	adrp	x9, _MAP_FIXED@GOTPAGE
Lloh11:
	ldr	x9, [x9, _MAP_FIXED@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	orr	w3, w9, w8
	mov	x0, x20
	mov	x1, x19
	mov	w4, #-1
	mov	w5, #0
	bl	_mmap
Lloh13:
	adrp	x8, _MAP_FAILED@GOTPAGE
Lloh14:
	ldr	x8, [x8, _MAP_FAILED@GOTPAGEOFF]
Lloh15:
	ldr	x8, [x8]
	cmp	x0, x8
	b.eq	LBB0_1
; %bb.4:
	cmp	x0, x20
	b.eq	LBB0_6
; %bb.5:
	mov	x1, x19
	bl	_os_pages_unmap
	b	LBB0_1
LBB0_6:
	mov	w0, #0
	b	LBB0_2
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_os_overcommits,8,3             ; @os_overcommits
	.comm	_PAGES_PROT_COMMIT,4,2          ; @PAGES_PROT_COMMIT
	.comm	_PAGES_PROT_DECOMMIT,4,2        ; @PAGES_PROT_DECOMMIT
	.comm	_mmap_flags,4,2                 ; @mmap_flags
	.comm	_MAP_FIXED,4,2                  ; @MAP_FIXED
	.comm	_MAP_FAILED,8,3                 ; @MAP_FAILED
	.comm	_MEM_COMMIT,4,2                 ; @MEM_COMMIT
	.comm	_MEM_DECOMMIT,4,2               ; @MEM_DECOMMIT
	.comm	_PAGE_READWRITE,4,2             ; @PAGE_READWRITE
	.no_dead_strip	_pages_commit_impl
.subsections_via_symbols
