	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vm_set_register                ## -- Begin function vm_set_register
	.p2align	4, 0x90
_vm_set_register:                       ## @vm_set_register
	.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
	testl	%esi, %esi
	js	LBB0_2
## %bb.1:
	movl	%esi, %ebx
	movq	%rdi, %r15
	cmpl	%esi, (%rdi)
	jle	LBB0_2
## %bb.3:
	movl	%edx, %r12d
	movq	_VM_REG_LAST@GOTPCREL(%rip), %rax
	cmpl	%edx, (%rax)
	jle	LBB0_2
## %bb.4:
	movl	%ecx, %r14d
	movl	16(%r15), %edi
	movl	%ebx, %esi
	movl	%r12d, %edx
	callq	_VMSETREG
	testl	%eax, %eax
	jne	LBB0_7
## %bb.5:
	movq	_VM_REG_GUEST_RIP@GOTPCREL(%rip), %rcx
	cmpl	%r12d, (%rcx)
	jne	LBB0_7
## %bb.6:
	leaq	L_.str(%rip), %rdx
	movq	%r15, %rdi
	movl	%ebx, %esi
	movl	%r14d, %ecx
	callq	_VCPU_CTR1
	movq	8(%r15), %rax
	movl	%ebx, %ecx
	movl	%r14d, (%rax,%rcx,4)
	xorl	%eax, %eax
	jmp	LBB0_7
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_7:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_VM_REG_LAST,4,2                ## @VM_REG_LAST
	.comm	_VM_REG_GUEST_RIP,4,2           ## @VM_REG_GUEST_RIP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Setting nextrip to %#lx"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vm_set_register                ; -- Begin function vm_set_register
	.p2align	2
_vm_set_register:                       ; @vm_set_register
	.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
	tbnz	w1, #31, LBB0_6
; %bb.1:
	mov	x20, x1
	mov	x21, x0
	ldr	w8, [x0]
	cmp	w8, w1
	b.le	LBB0_6
; %bb.2:
	mov	x22, x2
Lloh0:
	adrp	x8, _VM_REG_LAST@GOTPAGE
Lloh1:
	ldr	x8, [x8, _VM_REG_LAST@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w2
	b.le	LBB0_6
; %bb.3:
	mov	x19, x3
	ldr	w0, [x21, #16]
	mov	x1, x20
	mov	x2, x22
	bl	_VMSETREG
	cbnz	w0, LBB0_7
; %bb.4:
Lloh3:
	adrp	x8, _VM_REG_GUEST_RIP@GOTPAGE
Lloh4:
	ldr	x8, [x8, _VM_REG_GUEST_RIP@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w8, w22
	b.ne	LBB0_7
; %bb.5:
Lloh6:
	adrp	x2, l_.str@PAGE
Lloh7:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x21
	mov	x1, x20
	mov	x3, x19
	bl	_VCPU_CTR1
	mov	w0, #0
	ldr	x8, [x21, #8]
	str	w19, [x8, w20, uxtw #2]
	b	LBB0_7
LBB0_6:
Lloh8:
	adrp	x8, _EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
LBB0_7:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_VM_REG_LAST,4,2                ; @VM_REG_LAST
	.comm	_VM_REG_GUEST_RIP,4,2           ; @VM_REG_GUEST_RIP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Setting nextrip to %#lx"

.subsections_via_symbols
