	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_spinup_ap                      ## -- Begin function spinup_ap
	.p2align	4, 0x90
_spinup_ap:                             ## @spinup_ap
	.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
	movl	%edx, %ebx
	movl	%esi, %r14d
	movq	%rdi, %r15
	movl	%ecx, -28(%rbp)
	xorl	%edi, %edi
	testl	%edx, %edx
	setne	%dil
	callq	_assert
	movq	_guest_ncpus@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	cmpl	%ebx, (%rax)
	setg	%dil
	callq	_assert
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_vcpu_reset
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_assert
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_fbsdrun_set_capabilities
	movq	_VM_CAP_UNRESTRICTED_GUEST@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	movl	%ebx, %esi
	movl	$1, %ecx
	callq	_vm_set_capability
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_assert
	leaq	-28(%rbp), %rdx
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_spinup_ap_realmode
	movl	-28(%rbp), %ecx
	movq	%r15, %rdi
	movl	%r14d, %esi
	movl	%ebx, %edx
	callq	_fbsdrun_addcpu
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_guest_ncpus,4,2                ## @guest_ncpus
	.comm	_VM_CAP_UNRESTRICTED_GUEST,4,2  ## @VM_CAP_UNRESTRICTED_GUEST
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_spinup_ap                      ; -- Begin function spinup_ap
	.p2align	2
_spinup_ap:                             ; @spinup_ap
	.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
	mov	x21, x0
	str	w3, [sp, #12]
	cmp	w2, #0
	cset	w0, ne
	bl	_assert
Lloh0:
	adrp	x8, _guest_ncpus@GOTPAGE
Lloh1:
	ldr	x8, [x8, _guest_ncpus@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w19
	cset	w0, gt
	bl	_assert
	mov	x0, x21
	mov	x1, x19
	bl	_vcpu_reset
	cmp	w0, #0
	cset	w0, eq
	bl	_assert
	mov	x0, x21
	mov	x1, x19
	bl	_fbsdrun_set_capabilities
Lloh3:
	adrp	x8, _VM_CAP_UNRESTRICTED_GUEST@GOTPAGE
Lloh4:
	ldr	x8, [x8, _VM_CAP_UNRESTRICTED_GUEST@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x21
	mov	x1, x19
	mov	w3, #1
	bl	_vm_set_capability
	cmp	w0, #0
	cset	w0, eq
	bl	_assert
	add	x2, sp, #12
	mov	x0, x21
	mov	x1, x19
	bl	_spinup_ap_realmode
	ldr	w3, [sp, #12]
	mov	x0, x21
	mov	x1, x20
	mov	x2, x19
	bl	_fbsdrun_addcpu
	mov	x0, x19
	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
	.cfi_endproc
                                        ; -- End function
	.comm	_guest_ncpus,4,2                ; @guest_ncpus
	.comm	_VM_CAP_UNRESTRICTED_GUEST,4,2  ; @VM_CAP_UNRESTRICTED_GUEST
.subsections_via_symbols
