	.file	"extr_vmx.c_vmx_set_rflags.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	vmx_set_rflags
	.type	vmx_set_rflags, @function
vmx_set_rflags:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	mov	r12, rsi
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	call	vmx_get_rflags@PLT
	mov	edi, DWORD PTR VCPU_EXREG_RFLAGS[rip]
	mov	rsi, rbp
	mov	rbx, rax
	call	__set_bit@PLT
	mov	rdi, rbp
	call	to_vmx@PLT
	mov	rdi, rbp
	mov	QWORD PTR [rax], r12
	call	to_vmx@PLT
	cmp	QWORD PTR 24[rax], 0
	jne	.L9
.L2:
	mov	edi, DWORD PTR GUEST_RFLAGS[rip]
	mov	rsi, r12
	call	vmcs_writel@PLT
	mov	rdi, rbp
	call	to_vmx@PLT
	xor	rbx, QWORD PTR [rax]
	test	QWORD PTR X86_EFLAGS_VM[rip], rbx
	jne	.L10
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L9:
	.cfi_restore_state
	mov	rdi, rbp
	call	to_vmx@PLT
	mov	QWORD PTR 16[rax], r12
	mov	rax, QWORD PTR X86_EFLAGS_IOPL[rip]
	or	rax, QWORD PTR X86_EFLAGS_VM[rip]
	or	r12, rax
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L10:
	mov	rdi, rbp
	call	to_vmx@PLT
	mov	rdi, rbp
	mov	rbx, rax
	call	emulation_required@PLT
	mov	DWORD PTR 8[rbx], eax
	pop	rbx
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	vmx_set_rflags, .-vmx_set_rflags
	.comm	X86_EFLAGS_VM,8,8
	.comm	X86_EFLAGS_IOPL,8,8
	.comm	VCPU_EXREG_RFLAGS,4,4
	.comm	GUEST_RFLAGS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_vmx.c_vmx_set_rflags.c"
	.text
	.align	2
	.global	vmx_set_rflags
	.syntax unified
	.arm
	.fpu softvfp
	.type	vmx_set_rflags, %function
vmx_set_rflags:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r4, r0
	mov	r6, r1
	bl	vmx_get_rflags
	ldr	r3, .L12
	mov	r1, r4
	mov	r5, r0
	ldr	r0, [r3]
	bl	__set_bit
	mov	r0, r4
	bl	to_vmx
	mov	r3, r0
	mov	r0, r4
	str	r6, [r3]
	bl	to_vmx
	ldr	r3, [r0, #12]
	cmp	r3, #0
	bne	.L9
	ldr	r7, .L12+4
.L2:
	ldr	r3, .L12+8
	mov	r1, r6
	ldr	r0, [r3]
	bl	vmcs_writel
	mov	r0, r4
	bl	to_vmx
	ldr	r2, [r0]
	ldr	r3, [r7]
	eor	r5, r5, r2
	tst	r5, r3
	popeq	{r4, r5, r6, r7, r8, pc}
	mov	r0, r4
	bl	to_vmx
	mov	r3, r0
	mov	r0, r4
	mov	r4, r3
	bl	emulation_required
	str	r0, [r4, #4]
	pop	{r4, r5, r6, r7, r8, pc}
.L9:
	mov	r0, r4
	bl	to_vmx
	ldr	r7, .L12+4
	ldr	r3, .L12+12
	ldr	r2, [r7]
	ldr	r3, [r3]
	str	r6, [r0, #8]
	orr	r3, r3, r2
	orr	r6, r6, r3
	b	.L2
.L13:
	.align	2
.L12:
	.word	VCPU_EXREG_RFLAGS
	.word	X86_EFLAGS_VM
	.word	GUEST_RFLAGS
	.word	X86_EFLAGS_IOPL
	.size	vmx_set_rflags, .-vmx_set_rflags
	.comm	X86_EFLAGS_VM,4,4
	.comm	X86_EFLAGS_IOPL,4,4
	.comm	VCPU_EXREG_RFLAGS,4,4
	.comm	GUEST_RFLAGS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
