	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nested_svm_vmexit
_nested_svm_vmexit:                     ## @nested_svm_vmexit
	.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
	movq	%rdi, %r14
	movq	32(%rdi), %r15
	movq	16(%rdi), %rbx
	movl	24(%rdi), %esi
	movq	_KM_USER0@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_nested_svm_map
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r12
	movq	%r14, %rdi
	callq	_disable_gif
	movl	136(%rbx), %eax
	movl	%eax, 136(%r12)
	movl	132(%rbx), %eax
	movl	%eax, 132(%r12)
	movups	116(%rbx), %xmm0
	movups	%xmm0, 116(%r12)
	movq	_npt_enabled@GOTPCREL(%rip), %r13
	cmpq	$0, (%r13)
	je	LBB0_4
## %bb.3:
	movl	100(%rbx), %eax
	movl	%eax, 100(%r12)
LBB0_4:
	movl	144(%rbx), %eax
	movl	%eax, 144(%r12)
	movl	112(%rbx), %eax
	movl	%eax, 112(%r12)
	movl	88(%rbx), %eax
	movl	%eax, 88(%r12)
	movl	92(%rbx), %eax
	movl	%eax, 92(%r12)
	movl	96(%rbx), %eax
	movl	%eax, 96(%r12)
	movl	140(%rbx), %eax
	movl	%eax, 140(%r12)
	movups	72(%rbx), %xmm0
	movups	%xmm0, 72(%r12)
	movl	8(%rbx), %eax
	movl	%eax, 8(%r12)
	movl	60(%rbx), %ecx
	movl	%ecx, 60(%r12)
	movl	56(%rbx), %ecx
	movl	%ecx, 56(%r12)
	movups	40(%rbx), %xmm0
	movups	%xmm0, 40(%r12)
	movl	(%rbx), %ecx
	movl	%ecx, (%r12)
	movq	32(%rbx), %rcx
	movq	%rcx, 32(%r12)
	movl	4(%rbx), %ecx
	movq	_SVM_EVTINJ_VALID@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_6
## %bb.5:
	movl	%ecx, (%r12)
	movq	16(%rbx), %rcx
	movq	%rcx, 32(%r12)
LBB0_6:
	movl	$0, 4(%r12)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 16(%r12)
	movq	_HF_VINTR_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, (%r14)
	jne	LBB0_8
## %bb.7:
	movq	_V_INTR_MASKING_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	notl	%ecx
	andl	%ecx, %eax
	movl	%eax, 8(%r12)
LBB0_8:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_copy_vmcb_control_area
	cmpl	$1, 8(%r14)
	jne	LBB0_10
## %bb.9:
	leaq	L_.str(%rip), %rdi
	callq	_nsvm_printk
LBB0_10:
	movq	%r14, %rdi
	callq	_kvm_clear_exception_queue
	movq	%r14, %rdi
	callq	_kvm_clear_interrupt_queue
	movl	136(%r15), %eax
	movq	16(%r14), %rcx
	movl	%eax, 136(%rcx)
	movl	132(%r15), %eax
	movl	%eax, 132(%rcx)
	movl	128(%r15), %eax
	movl	%eax, 128(%rcx)
	movups	112(%r15), %xmm0
	movups	%xmm0, 112(%rcx)
	movl	108(%r15), %esi
	movq	%r14, %rdi
	callq	_svm_set_efer
	movq	_X86_CR0_PE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	orl	64(%r15), %esi
	movq	%r14, %rdi
	callq	_svm_set_cr0
	movl	104(%r15), %esi
	movq	%r14, %rdi
	callq	_svm_set_cr4
	cmpq	$0, (%r13)
	movl	100(%r15), %esi
	je	LBB0_12
## %bb.11:
	movq	16(%r14), %rdi
	movl	%esi, 100(%rdi)
	movl	100(%r15), %eax
	movl	%eax, 4(%r14)
	jmp	LBB0_13
LBB0_1:
	movl	$1, %eax
	jmp	LBB0_14
LBB0_12:
	movq	%r14, %rdi
	callq	_kvm_set_cr3
	movq	16(%r14), %rdi
LBB0_13:
	movq	_KM_USER0@GOTPCREL(%rip), %rbx
	movq	_VMCB_CR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_mark_dirty
	movq	_VCPU_REGS_RAX@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	96(%r15), %edx
	movq	%r14, %rdi
	callq	_kvm_register_write
	movq	_VCPU_REGS_RSP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	92(%r15), %edx
	movq	%r14, %rdi
	callq	_kvm_register_write
	movq	_VCPU_REGS_RIP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	88(%r15), %edx
	movq	%r14, %rdi
	callq	_kvm_register_write
	movq	16(%r14), %rdi
	movl	$0, (%rdi)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 72(%rdi)
	movl	$0, 24(%r14)
	callq	_mark_all_dirty
	movl	(%rbx), %esi
	movq	%r12, %rdi
	callq	_nested_svm_unmap
	movq	%r14, %rdi
	callq	_kvm_mmu_reset_context
	movq	%r14, %rdi
	callq	_kvm_mmu_load
	xorl	%eax, %eax
LBB0_14:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_KM_USER0,4,2                   ## @KM_USER0
	.comm	_npt_enabled,8,3                ## @npt_enabled
	.comm	_SVM_EVTINJ_VALID,4,2           ## @SVM_EVTINJ_VALID
	.comm	_HF_VINTR_MASK,4,2              ## @HF_VINTR_MASK
	.comm	_V_INTR_MASKING_MASK,4,2        ## @V_INTR_MASKING_MASK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"WARNING: Pending Exception\n"

	.comm	_X86_CR0_PE,4,2                 ## @X86_CR0_PE
	.comm	_VMCB_CR,4,2                    ## @VMCB_CR
	.comm	_VCPU_REGS_RAX,4,2              ## @VCPU_REGS_RAX
	.comm	_VCPU_REGS_RSP,4,2              ## @VCPU_REGS_RSP
	.comm	_VCPU_REGS_RIP,4,2              ## @VCPU_REGS_RIP
	.no_dead_strip	_nested_svm_vmexit
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nested_svm_vmexit
_nested_svm_vmexit:                     ; @nested_svm_vmexit
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	ldr	x21, [x0, #32]
	ldr	x22, [x0, #16]
	ldr	w1, [x0, #24]
Lloh0:
	adrp	x23, _KM_USER0@GOTPAGE
Lloh1:
	ldr	x23, [x23, _KM_USER0@GOTPAGEOFF]
	ldr	w2, [x23]
	bl	_nested_svm_map
	cbz	x0, LBB0_11
; %bb.1:
	mov	x20, x0
	mov	x0, x19
	bl	_disable_gif
	ldur	d0, [x22, #132]
	stur	d0, [x20, #132]
	ldur	q0, [x22, #116]
	stur	q0, [x20, #116]
Lloh2:
	adrp	x24, _npt_enabled@GOTPAGE
Lloh3:
	ldr	x24, [x24, _npt_enabled@GOTPAGEOFF]
	ldr	x8, [x24]
	cbz	x8, LBB0_3
; %bb.2:
	ldr	w8, [x22, #100]
	str	w8, [x20, #100]
LBB0_3:
	ldr	w8, [x22, #144]
	str	w8, [x20, #144]
	ldr	w8, [x22, #112]
	str	w8, [x20, #112]
	ldr	d0, [x22, #88]
	str	d0, [x20, #88]
	ldr	w8, [x22, #96]
	str	w8, [x20, #96]
	ldr	w8, [x22, #140]
	str	w8, [x20, #140]
	ldur	q0, [x22, #72]
	stur	q0, [x20, #72]
	ldr	w8, [x22, #8]
	str	w8, [x20, #8]
	ldr	d0, [x22, #56]
	str	d0, [x20, #56]
	ldur	q0, [x22, #40]
	stur	q0, [x20, #40]
	ldp	w10, w9, [x22]
	str	w10, [x20]
	ldr	x10, [x22, #32]
	str	x10, [x20, #32]
Lloh4:
	adrp	x10, _SVM_EVTINJ_VALID@GOTPAGE
Lloh5:
	ldr	x10, [x10, _SVM_EVTINJ_VALID@GOTPAGEOFF]
Lloh6:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_5
; %bb.4:
	str	w9, [x20]
	ldr	x9, [x22, #16]
	str	x9, [x20, #32]
LBB0_5:
	str	wzr, [x20, #4]
	stp	xzr, xzr, [x20, #16]
	ldr	w9, [x19]
Lloh7:
	adrp	x10, _HF_VINTR_MASK@GOTPAGE
Lloh8:
	ldr	x10, [x10, _HF_VINTR_MASK@GOTPAGEOFF]
Lloh9:
	ldr	w10, [x10]
	tst	w10, w9
	b.ne	LBB0_7
; %bb.6:
Lloh10:
	adrp	x9, _V_INTR_MASKING_MASK@GOTPAGE
Lloh11:
	ldr	x9, [x9, _V_INTR_MASKING_MASK@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	bic	w8, w8, w9
	str	w8, [x20, #8]
LBB0_7:
	mov	x0, x22
	mov	x1, x21
	bl	_copy_vmcb_control_area
	ldr	w8, [x19, #8]
	cmp	w8, #1
	b.ne	LBB0_9
; %bb.8:
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
	bl	_nsvm_printk
LBB0_9:
	mov	x0, x19
	bl	_kvm_clear_exception_queue
	mov	x0, x19
	bl	_kvm_clear_interrupt_queue
	ldr	w8, [x21, #136]
	ldr	x9, [x19, #16]
	str	w8, [x9, #136]
	ldr	d0, [x21, #128]
	str	d0, [x9, #128]
	ldr	q0, [x21, #112]
	str	q0, [x9, #112]
	ldr	w1, [x21, #108]
	mov	x0, x19
	bl	_svm_set_efer
	ldr	w8, [x21, #64]
Lloh15:
	adrp	x9, _X86_CR0_PE@GOTPAGE
Lloh16:
	ldr	x9, [x9, _X86_CR0_PE@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	orr	w1, w9, w8
	mov	x0, x19
	bl	_svm_set_cr0
	ldr	w1, [x21, #104]
	mov	x0, x19
	bl	_svm_set_cr4
	ldr	x8, [x24]
	ldr	w1, [x21, #100]
	cbz	x8, LBB0_12
; %bb.10:
	ldr	x0, [x19, #16]
	str	w1, [x0, #100]
	ldr	w8, [x21, #100]
	str	w8, [x19, #4]
	b	LBB0_13
LBB0_11:
	mov	w0, #1
	b	LBB0_14
LBB0_12:
	mov	x0, x19
	bl	_kvm_set_cr3
	ldr	x0, [x19, #16]
LBB0_13:
Lloh18:
	adrp	x8, _VMCB_CR@GOTPAGE
Lloh19:
	ldr	x8, [x8, _VMCB_CR@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	bl	_mark_dirty
Lloh21:
	adrp	x8, _VCPU_REGS_RAX@GOTPAGE
Lloh22:
	ldr	x8, [x8, _VCPU_REGS_RAX@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	ldr	w2, [x21, #96]
	mov	x0, x19
	bl	_kvm_register_write
Lloh24:
	adrp	x8, _VCPU_REGS_RSP@GOTPAGE
Lloh25:
	ldr	x8, [x8, _VCPU_REGS_RSP@GOTPAGEOFF]
Lloh26:
	ldr	w1, [x8]
	ldr	w2, [x21, #92]
	mov	x0, x19
	bl	_kvm_register_write
Lloh27:
	adrp	x8, _VCPU_REGS_RIP@GOTPAGE
Lloh28:
	ldr	x8, [x8, _VCPU_REGS_RIP@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	ldr	w2, [x21, #88]
	mov	x0, x19
	bl	_kvm_register_write
	ldr	x0, [x19, #16]
	str	wzr, [x0]
	stp	xzr, xzr, [x0, #72]
	str	wzr, [x19, #24]
	bl	_mark_all_dirty
	ldr	w1, [x23]
	mov	x0, x20
	bl	_nested_svm_unmap
	mov	x0, x19
	bl	_kvm_mmu_reset_context
	mov	x0, x19
	bl	_kvm_mmu_load
	mov	w0, #0
LBB0_14:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_KM_USER0,4,2                   ; @KM_USER0
	.comm	_npt_enabled,8,3                ; @npt_enabled
	.comm	_SVM_EVTINJ_VALID,4,2           ; @SVM_EVTINJ_VALID
	.comm	_HF_VINTR_MASK,4,2              ; @HF_VINTR_MASK
	.comm	_V_INTR_MASKING_MASK,4,2        ; @V_INTR_MASKING_MASK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"WARNING: Pending Exception\n"

	.comm	_X86_CR0_PE,4,2                 ; @X86_CR0_PE
	.comm	_VMCB_CR,4,2                    ; @VMCB_CR
	.comm	_VCPU_REGS_RAX,4,2              ; @VCPU_REGS_RAX
	.comm	_VCPU_REGS_RSP,4,2              ; @VCPU_REGS_RSP
	.comm	_VCPU_REGS_RIP,4,2              ; @VCPU_REGS_RIP
	.no_dead_strip	_nested_svm_vmexit
.subsections_via_symbols
