	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vm_phys_alloc_freelist_pages   ## -- Begin function vm_phys_alloc_freelist_pages
	.p2align	4, 0x90
_vm_phys_alloc_freelist_pages:          ## @vm_phys_alloc_freelist_pages
	.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
	movl	%ecx, %r14d
	movl	%edx, %ebx
	movl	%esi, %r12d
	testl	%edi, %edi
	setns	%al
	movq	_vm_ndomains@GOTPCREL(%rip), %rcx
	cmpl	%edi, (%rcx)
	setg	%cl
	andb	%al, %cl
	movzbl	%cl, %eax
	movslq	%edi, %r15
	movl	%eax, %edi
	movq	%r15, %rsi
	callq	_KASSERT
	movq	_VM_NFREELIST@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	%r12d, (%rax)
	setg	%dil
	movslq	%r12d, %r13
	movq	%r13, %rsi
	callq	_KASSERT
	movq	_VM_NFREEPOOL@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	%ebx, (%rax)
	setg	%dil
	movl	%ebx, -56(%rbp)                 ## 4-byte Spill
	movslq	%ebx, %rbx
	movq	%rbx, %rsi
	callq	_KASSERT
	movq	_VM_NFREEORDER@GOTPCREL(%rip), %r12
	xorl	%edi, %edi
	cmpl	%r14d, (%r12)
	setg	%dil
	movslq	%r14d, %rsi
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	callq	_KASSERT
	movq	_vm_freelist_to_flind@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax,%r13,4), %r13d
	testl	%r13d, %r13d
	js	LBB0_15
## %bb.1:
	movl	%r15d, %edi
	callq	_VM_DOMAIN
	movl	%eax, %edi
	callq	_vm_domain_free_assert_locked
	movq	_vm_phys_free_queues@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax,%r15,8), %rax
	movq	(%rax,%r13,8), %rax
	movq	(%rax,%rbx,8), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movl	(%r12), %eax
	cmpl	%r14d, %eax
	movq	%r15, %rcx
	jle	LBB0_6
## %bb.2:
	movq	%r13, -72(%rbp)                 ## 8-byte Spill
	movl	%r14d, %r15d
	movq	%rcx, -80(%rbp)                 ## 8-byte Spill
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	leaq	(%rax,%r14,4), %rbx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	callq	_TAILQ_FIRST
	testq	%rax, %rax
	jne	LBB0_17
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	incq	%r14
	movslq	(%r12), %rax
	addq	$4, %rbx
	cmpq	%rax, %r14
	jl	LBB0_3
## %bb.5:
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movl	%r15d, %r14d
	movq	-72(%rbp), %r13                 ## 8-byte Reload
LBB0_6:
	cmpl	%r14d, %eax
	jle	LBB0_15
## %bb.7:
	movslq	%eax, %rdx
	movq	_VM_NFREEPOOL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	xorl	%r12d, %r12d
	movl	%r14d, -52(%rbp)                ## 4-byte Spill
	jmp	LBB0_9
LBB0_15:
	xorl	%r12d, %r12d
	jmp	LBB0_19
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_9 Depth=1
	cmpq	-64(%rbp), %rdx                 ## 8-byte Folded Reload
	jle	LBB0_19
LBB0_9:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_11 Depth 2
	decq	%rdx
	testl	%eax, %eax
	jle	LBB0_8
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_11:                                ##   Parent Loop BB0_9 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	_vm_phys_free_queues@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rcx, %r14
	movq	(%rax,%rcx,8), %rax
	movq	%r13, %rbx
	movq	(%rax,%r13,8), %rax
	movq	(%rax,%r15,8), %r13
	movq	%rdx, %r12
	leaq	(,%rdx,4), %rdi
	addq	%r13, %rdi
	callq	_TAILQ_FIRST
	testq	%rax, %rax
	jne	LBB0_16
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=2
	incq	%r15
	movq	_VM_NFREEPOOL@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	cmpq	%rax, %r15
	movq	%r14, %rcx
	movq	%rbx, %r13
	movq	%r12, %rdx
	jl	LBB0_11
## %bb.13:                              ##   in Loop: Header=BB0_9 Depth=1
	xorl	%r12d, %r12d
	jmp	LBB0_8
LBB0_16:
	movq	%r13, %rdi
	movq	%rax, %rsi
	movq	%r12, %rbx
	movl	%ebx, %edx
	movq	%rax, %r12
	callq	_vm_freelist_rem
	movl	-56(%rbp), %edi                 ## 4-byte Reload
	movq	%r12, %rsi
	movl	%ebx, %edx
	callq	_vm_phys_set_pool
	movq	%r12, %rdi
	movl	%ebx, %esi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	movl	-52(%rbp), %ecx                 ## 4-byte Reload
	jmp	LBB0_18
LBB0_17:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movq	%rax, %r12
	movq	%rax, %rsi
	movl	%r14d, %edx
	callq	_vm_freelist_rem
	movq	%r12, %rdi
	movl	%r14d, %esi
	movq	%rbx, %rdx
	movl	%r15d, %ecx
LBB0_18:
	movl	$1, %r8d
	callq	_vm_phys_split_pages
LBB0_19:
	movq	%r12, %rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_vm_ndomains,4,2                ## @vm_ndomains
	.comm	_VM_NFREELIST,4,2               ## @VM_NFREELIST
	.comm	_VM_NFREEPOOL,4,2               ## @VM_NFREEPOOL
	.comm	_VM_NFREEORDER,4,2              ## @VM_NFREEORDER
	.comm	_vm_freelist_to_flind,8,3       ## @vm_freelist_to_flind
	.comm	_vm_phys_free_queues,8,3        ## @vm_phys_free_queues
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vm_phys_alloc_freelist_pages   ; -- Begin function vm_phys_alloc_freelist_pages
	.p2align	2
_vm_phys_alloc_freelist_pages:          ; @vm_phys_alloc_freelist_pages
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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	x19, x3
	mov	x20, x2
	mov	x25, x1
	mov	x22, x0
	cmp	w0, #0
Lloh0:
	adrp	x8, _vm_ndomains@GOTPAGE
Lloh1:
	ldr	x8, [x8, _vm_ndomains@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ccmp	w8, w0, #4, ge
	cset	w0, gt
	sxtw	x21, w22
	mov	x1, x21
	bl	_KASSERT
Lloh3:
	adrp	x8, _VM_NFREELIST@GOTPAGE
Lloh4:
	ldr	x8, [x8, _VM_NFREELIST@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w8, w25
	cset	w0, gt
	sxtw	x1, w25
	bl	_KASSERT
Lloh6:
	adrp	x27, _VM_NFREEPOOL@GOTPAGE
Lloh7:
	ldr	x27, [x27, _VM_NFREEPOOL@GOTPAGEOFF]
	ldr	w8, [x27]
	cmp	w8, w20
	cset	w0, gt
	str	x20, [sp, #24]                  ; 8-byte Folded Spill
	sxtw	x24, w20
	mov	x1, x24
	bl	_KASSERT
Lloh8:
	adrp	x20, _VM_NFREEORDER@GOTPAGE
Lloh9:
	ldr	x20, [x20, _VM_NFREEORDER@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, w19
	cset	w0, gt
	sxtw	x23, w19
	mov	x1, x23
	bl	_KASSERT
Lloh10:
	adrp	x8, _vm_freelist_to_flind@GOTPAGE
Lloh11:
	ldr	x8, [x8, _vm_freelist_to_flind@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
	ldr	w28, [x8, w25, sxtw #2]
	tbnz	w28, #31, LBB0_8
; %bb.1:
	mov	x0, x22
	bl	_VM_DOMAIN
	bl	_vm_domain_free_assert_locked
Lloh13:
	adrp	x22, _vm_phys_free_queues@GOTPAGE
Lloh14:
	ldr	x22, [x22, _vm_phys_free_queues@GOTPAGEOFF]
	ldr	x8, [x22]
	ldr	x8, [x8, x21, lsl #3]
	ldr	x8, [x8, x28, lsl #3]
	ldr	x9, [x8, x24, lsl #3]
	ldr	w8, [x20]
	cmp	w8, w19
	b.le	LBB0_6
; %bb.2:
	mov	x24, #0
	mov	w8, w19
	stp	x8, x9, [sp, #8]                ; 16-byte Folded Spill
	add	x26, x9, x23, lsl #2
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x26
	bl	_TAILQ_FIRST
	cbnz	x0, LBB0_15
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldrsw	x8, [x20]
	add	x24, x24, #1
	add	x26, x26, #4
	add	x9, x23, x24
	cmp	x9, x8
	b.lt	LBB0_3
; %bb.5:
                                        ; kill: def $w8 killed $w8 killed $x8 def $x8
	ldr	x9, [sp, #16]                   ; 8-byte Folded Reload
LBB0_6:
	cmp	w8, w19
	b.le	LBB0_8
; %bb.7:
	str	x9, [sp, #16]                   ; 8-byte Folded Spill
	sxtw	x24, w8
	ldr	w8, [x27]
	b	LBB0_10
LBB0_8:
	mov	x25, #0
	b	LBB0_17
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=1
	mov	x25, #0
	cmp	x24, x23
	b.le	LBB0_17
LBB0_10:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_12 Depth 2
	sub	x24, x24, #1
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	mov	x20, #0
LBB0_12:                                ;   Parent Loop BB0_10 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [x22]
	ldr	x8, [x8, x21, lsl #3]
	ldr	x8, [x8, x28, lsl #3]
	ldr	x26, [x8, x20, lsl #3]
	add	x0, x26, x24, lsl #2
	bl	_TAILQ_FIRST
	cbnz	x0, LBB0_14
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=2
	add	x20, x20, #1
	ldrsw	x8, [x27]
	cmp	x20, x8
	b.lt	LBB0_12
	b	LBB0_9
LBB0_14:
	mov	x25, x0
	mov	x0, x26
	mov	x1, x25
	mov	x2, x24
	bl	_vm_freelist_rem
	ldr	x0, [sp, #24]                   ; 8-byte Folded Reload
                                        ; kill: def $w0 killed $w0 killed $x0
	mov	x1, x25
	mov	x2, x24
	bl	_vm_phys_set_pool
	mov	x0, x25
	mov	x1, x24
	ldr	x2, [sp, #16]                   ; 8-byte Folded Reload
	mov	x3, x19
	b	LBB0_16
LBB0_15:
	mov	x25, x0
	add	w19, w19, w24
	ldr	x20, [sp, #16]                  ; 8-byte Folded Reload
	mov	x0, x20
	mov	x1, x25
	mov	x2, x19
	bl	_vm_freelist_rem
	mov	x0, x25
	mov	x1, x19
	mov	x2, x20
	ldr	x3, [sp, #8]                    ; 8-byte Folded Reload
                                        ; kill: def $w3 killed $w3 killed $x3
LBB0_16:
	mov	w4, #1
	bl	_vm_phys_split_pages
LBB0_17:
	mov	x0, x25
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_vm_ndomains,4,2                ; @vm_ndomains
	.comm	_VM_NFREELIST,4,2               ; @VM_NFREELIST
	.comm	_VM_NFREEPOOL,4,2               ; @VM_NFREEPOOL
	.comm	_VM_NFREEORDER,4,2              ; @VM_NFREEORDER
	.comm	_vm_freelist_to_flind,8,3       ; @vm_freelist_to_flind
	.comm	_vm_phys_free_queues,8,3        ; @vm_phys_free_queues
.subsections_via_symbols
