	.file	"extr_interrupts_and_traps.c_try_deliver_interrupt.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Re-enabling interrupts"
	.text
	.p2align 4
	.globl	try_deliver_interrupt
	.type	try_deliver_interrupt, @function
try_deliver_interrupt:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	mov	r12d, edx
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	ebp, esi
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	mov	rbx, rdi
	xor	edi, edi
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	cmp	DWORD PTR LGUEST_IRQS[rip], esi
	setbe	dil
	call	BUG_ON@PLT
	mov	rax, QWORD PTR 32[rbx]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR [rbx]
	cmp	rdx, QWORD PTR [rax]
	jl	.L2
	cmp	rdx, QWORD PTR 8[rax]
	jl	.L1
.L2:
	mov	rsi, QWORD PTR 16[rax]
	add	rsi, 4
	cmp	QWORD PTR 24[rbx], 0
	je	.L4
	mov	edi, DWORD PTR X86_EFLAGS_IF[rip]
	call	put_user@PLT
	test	rax, rax
	jne	.L15
.L5:
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, ebp
	add	edx, DWORD PTR FIRST_EXTERNAL_VECTOR[rip]
	mov	QWORD PTR 24[rbx], 0
	lea	r13, [rax+rdx*8]
	mov	edi, DWORD PTR 4[r13]
	mov	esi, DWORD PTR 0[r13]
	call	idt_present@PLT
	test	rax, rax
	jne	.L16
	mov	rdi, rbx
	call	write_timestamp@PLT
	test	r12d, r12d
	je	.L17
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L4:
	.cfi_restore_state
	xor	edi, edi
	call	get_user@PLT
	mov	rax, QWORD PTR [rbx]
	mov	edi, DWORD PTR X86_EFLAGS_IF[rip]
	mov	rsi, QWORD PTR 16[rax]
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	put_user@PLT
	.p2align 4,,10
	.p2align 3
.L17:
	.cfi_restore_state
	mov	rax, QWORD PTR [rbx]
	xor	edi, edi
	mov	rsi, QWORD PTR 16[rax]
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	put_user@PLT
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	lea	rsi, .LC0[rip]
	mov	rdi, rbx
	call	kill_guest@PLT
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L16:
	mov	esi, DWORD PTR 8[rbx]
	mov	edi, ebp
	call	clear_bit@PLT
	mov	esi, DWORD PTR 4[r13]
	mov	edx, DWORD PTR 0[r13]
	xor	ecx, ecx
	mov	rdi, rbx
	call	set_guest_interrupt@PLT
	mov	rdi, rbx
	call	write_timestamp@PLT
	test	r12d, r12d
	jne	.L1
	jmp	.L17
	.cfi_endproc
.LFE0:
	.size	try_deliver_interrupt, .-try_deliver_interrupt
	.comm	X86_EFLAGS_IF,4,4
	.comm	LGUEST_IRQS,4,4
	.comm	FIRST_EXTERNAL_VECTOR,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_interrupts_and_traps.c_try_deliver_interrupt.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Re-enabling interrupts\000"
	.text
	.align	2
	.global	try_deliver_interrupt
	.syntax unified
	.arm
	.fpu softvfp
	.type	try_deliver_interrupt, %function
try_deliver_interrupt:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	mov	r4, r0
	ldr	r3, .L16
	mov	r5, r1
	ldr	r0, [r3]
	mov	r6, r2
	cmp	r0, r1
	movhi	r0, #0
	movls	r0, #1
	bl	BUG_ON
	ldr	r2, [r4, #16]
	ldr	r3, [r4]
	ldr	r2, [r2]
	ldr	r1, [r3]
	cmp	r2, r1
	blt	.L2
	ldr	r1, [r3, #4]
	cmp	r2, r1
	poplt	{r4, r5, r6, r7, r8, r9, r10, pc}
.L2:
	ldr	r2, [r4, #12]
	ldr	r1, [r3, #8]
	cmp	r2, #0
	add	r1, r1, #4
	beq	.L4
	ldr	r3, .L16+4
	ldr	r0, [r3]
	bl	put_user
	cmp	r0, #0
	bne	.L14
.L5:
	mov	r10, #0
	ldr	r3, .L16+8
	ldr	r8, [r4, #8]
	ldr	r7, [r3]
	str	r10, [r4, #12]
	add	r7, r5, r7
	add	r9, r8, r7, lsl #3
	ldr	r0, [r9, #4]
	ldr	r1, [r8, r7, lsl #3]
	bl	idt_present
	cmp	r0, r10
	bne	.L15
.L7:
	mov	r0, r4
	bl	write_timestamp
	cmp	r6, #0
	popne	{r4, r5, r6, r7, r8, r9, r10, pc}
	ldr	r3, [r4]
	mov	r0, r6
	pop	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r1, [r3, #8]
	b	put_user
.L4:
	mov	r0, #0
	bl	get_user
	ldr	r2, [r4]
	ldr	r3, .L16+4
	ldr	r1, [r2, #8]
	ldr	r0, [r3]
	pop	{r4, r5, r6, r7, r8, r9, r10, lr}
	b	put_user
.L14:
	mov	r0, r4
	ldr	r1, .L16+12
	bl	kill_guest
	b	.L5
.L15:
	ldr	r1, [r4, #4]
	mov	r0, r5
	bl	clear_bit
	mov	r3, r10
	mov	r0, r4
	ldr	r2, [r8, r7, lsl #3]
	ldr	r1, [r9, #4]
	bl	set_guest_interrupt
	b	.L7
.L17:
	.align	2
.L16:
	.word	LGUEST_IRQS
	.word	X86_EFLAGS_IF
	.word	FIRST_EXTERNAL_VECTOR
	.word	.LC0
	.size	try_deliver_interrupt, .-try_deliver_interrupt
	.comm	X86_EFLAGS_IF,4,4
	.comm	LGUEST_IRQS,4,4
	.comm	FIRST_EXTERNAL_VECTOR,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
