	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function kmem_malloc_domain
_kmem_malloc_domain:                    ## @kmem_malloc_domain
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movl	%edi, %ebx
	movq	_vm_dom@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	%edi, %rcx
	shlq	$4, %rcx
	movq	(%rax,%rcx), %r14
	movl	%esi, %edi
	callq	_round_page
	movl	%eax, %r13d
	movq	_M_BESTFIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	%r15d, %edx
	leaq	-44(%rbp), %rcx
	movq	%r14, %rdi
	movl	%r13d, %esi
	callq	_vmem_alloc
	xorl	%r12d, %r12d
	testq	%rax, %rax
	jne	LBB0_4
## %bb.1:
	movq	_kernel_object@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-44(%rbp), %edx
	movl	%ebx, %edi
	movl	%r13d, %ecx
	movl	%r15d, %r8d
	callq	_kmem_back_domain
	movq	_KERN_SUCCESS@GOTPCREL(%rip), %rcx
	movl	-44(%rbp), %esi
	cmpl	(%rcx), %eax
	jne	LBB0_3
## %bb.2:
	movl	%esi, %r12d
	jmp	LBB0_4
LBB0_3:
	movq	%r14, %rdi
	movl	%r13d, %edx
	callq	_vmem_free
LBB0_4:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_vm_dom,8,3                     ## @vm_dom
	.comm	_M_BESTFIT,4,2                  ## @M_BESTFIT
	.comm	_kernel_object,4,2              ## @kernel_object
	.comm	_KERN_SUCCESS,4,2               ## @KERN_SUCCESS
	.comm	_M_EXEC,4,2                     ## @M_EXEC
	.no_dead_strip	_kmem_malloc_domain
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function kmem_malloc_domain
_kmem_malloc_domain:                    ; @kmem_malloc_domain
	.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	x21, x2
	mov	x22, x0
Lloh0:
	adrp	x8, _vm_dom@GOTPAGE
Lloh1:
	ldr	x8, [x8, _vm_dom@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	sbfiz	x9, x22, #4, #32
	ldr	x19, [x8, x9]
	mov	x0, x1
	bl	_round_page
	mov	x20, x0
Lloh3:
	adrp	x8, _M_BESTFIT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _M_BESTFIT@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	orr	w2, w8, w21
	add	x3, sp, #12
	mov	x0, x19
	mov	x1, x20
	bl	_vmem_alloc
	cbnz	x0, LBB0_3
; %bb.1:
Lloh6:
	adrp	x8, _kernel_object@GOTPAGE
Lloh7:
	ldr	x8, [x8, _kernel_object@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	ldr	w2, [sp, #12]
	mov	x0, x22
	mov	x3, x20
	mov	x4, x21
	bl	_kmem_back_domain
Lloh9:
	adrp	x8, _KERN_SUCCESS@GOTPAGE
Lloh10:
	ldr	x8, [x8, _KERN_SUCCESS@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldr	w1, [sp, #12]
	cmp	w0, w8
	b.eq	LBB0_4
; %bb.2:
	mov	x0, x19
	mov	x2, x20
	bl	_vmem_free
LBB0_3:
	mov	w1, #0
LBB0_4:
	mov	x0, x1
	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 AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_vm_dom,8,3                     ; @vm_dom
	.comm	_M_BESTFIT,4,2                  ; @M_BESTFIT
	.comm	_kernel_object,4,2              ; @kernel_object
	.comm	_KERN_SUCCESS,4,2               ; @KERN_SUCCESS
	.comm	_M_EXEC,4,2                     ; @M_EXEC
	.no_dead_strip	_kmem_malloc_domain
.subsections_via_symbols
