	.file	"extr_x86_mem.c_x86_mrsetvariable.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	x86_mrsetvariable, @function
x86_mrsetvariable:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	mov	r13, rsi
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	r14d, DWORD PTR [rdi]
	and	r14d, DWORD PTR MR686_FIXMTRR[rip]
	je	.L25
	mov	r14d, DWORD PTR MTRR_N16K[rip]
	add	r14d, DWORD PTR MTRR_N64K[rip]
	add	r14d, DWORD PTR MTRR_N4K[rip]
	movsx	rbx, r14d
	sal	rbx, 5
.L2:
	add	rbx, QWORD PTR 8[r12]
	cmp	r14d, DWORD PTR 4[r12]
	jge	.L3
	xor	ebp, ebp
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L31:
	mov	rdx, QWORD PTR 8[r13]
	cmp	QWORD PTR 8[rbx], rdx
	jne	.L5
	mov	rcx, QWORD PTR 16[r13]
	cmp	QWORD PTR 16[rbx], rcx
	je	.L28
.L5:
	mov	rsi, r13
	mov	rdi, rbx
	call	mroverlap@PLT
	test	rax, rax
	jne	.L29
.L9:
	add	r14d, 1
	add	rbx, 32
	cmp	DWORD PTR 4[r12], r14d
	jle	.L30
.L10:
	mov	eax, DWORD PTR [rbx]
	mov	edi, DWORD PTR MDF_ACTIVE[rip]
	test	eax, edi
	jne	.L31
	test	rbp, rbp
	cmove	rbp, rbx
	add	r14d, 1
	add	rbx, 32
	cmp	DWORD PTR 4[r12], r14d
	jg	.L10
.L30:
	test	rbp, rbp
	je	.L3
	mov	rdx, QWORD PTR 8[r13]
	mov	rcx, QWORD PTR 16[r13]
	mov	esi, DWORD PTR 0[r13]
	mov	edi, DWORD PTR MDF_ACTIVE[rip]
.L8:
	mov	QWORD PTR 8[rbp], rdx
	mov	QWORD PTR 16[rbp], rcx
	call	mrcopyflags@PLT
	mov	esi, DWORD PTR 24[rbp]
	mov	edi, DWORD PTR 24[r13]
	mov	edx, 4
	mov	DWORD PTR 0[rbp], eax
	call	bcopy@PLT
	xor	eax, eax
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L29:
	.cfi_restore_state
	mov	esi, DWORD PTR 0[r13]
	mov	edi, DWORD PTR [rbx]
	call	x86_mtrrconflict@PLT
	test	rax, rax
	je	.L9
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, DWORD PTR EINVAL[rip]
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L25:
	.cfi_restore_state
	xor	ebx, ebx
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L3:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, DWORD PTR ENOSPC[rip]
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
.L28:
	.cfi_restore_state
	test	DWORD PTR MDF_BUSY[rip], eax
	jne	.L32
	mov	esi, DWORD PTR 0[r13]
	test	DWORD PTR MDF_FORCE[rip], esi
	jne	.L12
	and	eax, DWORD PTR MDF_ATTRMASK[rip]
	cmp	eax, DWORD PTR MDF_UNKNOWN[rip]
	mov	rbp, rbx
	jne	.L8
	mov	eax, DWORD PTR EACCES[rip]
	jmp	.L1
.L32:
	mov	eax, DWORD PTR EBUSY[rip]
	jmp	.L1
.L12:
	mov	rbp, rbx
	jmp	.L8
	.cfi_endproc
.LFE0:
	.size	x86_mrsetvariable, .-x86_mrsetvariable
	.comm	MTRR_N64K,4,4
	.comm	MTRR_N4K,4,4
	.comm	MTRR_N16K,4,4
	.comm	MR686_FIXMTRR,4,4
	.comm	MDF_UNKNOWN,4,4
	.comm	MDF_FORCE,4,4
	.comm	MDF_BUSY,4,4
	.comm	MDF_ATTRMASK,4,4
	.comm	MDF_ACTIVE,4,4
	.comm	ENOSPC,4,4
	.comm	EINVAL,4,4
	.comm	EBUSY,4,4
	.comm	EACCES,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_x86_mem.c_x86_mrsetvariable.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	x86_mrsetvariable, %function
x86_mrsetvariable:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, .L32
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r3, [r3]
	ldr	r5, [r0]
	mov	r7, r1
	ands	r5, r5, r3
	moveq	r3, r5
	ldrne	r2, .L32+4
	ldrne	r1, .L32+8
	ldrne	r3, .L32+12
	ldrne	r5, [r1]
	ldrne	r2, [r2]
	ldrne	r3, [r3]
	addne	r5, r5, r2
	addne	r5, r5, r3
	lslne	r3, r5, #4
	ldmib	r0, {r2, r4}
	cmp	r5, r2
	mov	r9, r0
	add	r4, r4, r3
	bge	.L3
	mov	r6, #0
	ldr	r8, .L32+16
	b	.L10
.L29:
	ldr	r2, [r7, #4]
	ldr	r1, [r4, #4]
	cmp	r1, r2
	bne	.L5
	ldr	ip, [r7, #8]
	ldr	r1, [r4, #8]
	cmp	r1, ip
	beq	.L27
.L5:
	mov	r1, r7
	mov	r0, r4
	bl	mroverlap
	cmp	r0, #0
	bne	.L22
.L25:
	ldr	r2, [r9, #4]
	add	r5, r5, #1
	cmp	r2, r5
	add	r4, r4, #16
	ble	.L28
.L10:
	ldr	r3, [r4]
	ldr	r0, [r8]
	tst	r3, r0
	bne	.L29
	cmp	r6, #0
	add	r5, r5, #1
	moveq	r6, r4
	cmp	r2, r5
	add	r4, r4, #16
	bgt	.L10
.L28:
	cmp	r6, #0
	beq	.L3
	ldm	r7, {r1, r2, ip}
	ldr	r0, [r8]
.L8:
	stmib	r6, {r2, ip}
	bl	mrcopyflags
	mov	r2, #4
	str	r0, [r6]
	ldr	r1, [r6, #12]
	ldr	r0, [r7, #12]
	bl	bcopy
	mov	r0, #0
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L22:
	ldr	r1, [r7]
	ldr	r0, [r4]
	bl	x86_mtrrconflict
	cmp	r0, #0
	beq	.L25
	ldr	r3, .L32+20
	ldr	r0, [r3]
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L3:
	ldr	r3, .L32+24
	ldr	r0, [r3]
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L27:
	ldr	r1, .L32+28
	ldr	r1, [r1]
	tst	r3, r1
	bne	.L30
	ldr	lr, .L32+32
	ldr	r1, [r7]
	ldr	lr, [lr]
	tst	r1, lr
	bne	.L13
	ldr	r5, .L32+36
	ldr	lr, .L32+40
	ldr	r5, [r5]
	ldr	lr, [lr]
	and	r3, r3, r5
	cmp	r3, lr
	beq	.L31
.L13:
	mov	r6, r4
	b	.L8
.L30:
	ldr	r3, .L32+44
	ldr	r0, [r3]
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L31:
	ldr	r3, .L32+48
	ldr	r0, [r3]
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L33:
	.align	2
.L32:
	.word	MR686_FIXMTRR
	.word	MTRR_N16K
	.word	MTRR_N64K
	.word	MTRR_N4K
	.word	MDF_ACTIVE
	.word	EINVAL
	.word	ENOSPC
	.word	MDF_BUSY
	.word	MDF_FORCE
	.word	MDF_ATTRMASK
	.word	MDF_UNKNOWN
	.word	EBUSY
	.word	EACCES
	.size	x86_mrsetvariable, .-x86_mrsetvariable
	.comm	MTRR_N64K,4,4
	.comm	MTRR_N4K,4,4
	.comm	MTRR_N16K,4,4
	.comm	MR686_FIXMTRR,4,4
	.comm	MDF_UNKNOWN,4,4
	.comm	MDF_FORCE,4,4
	.comm	MDF_BUSY,4,4
	.comm	MDF_ATTRMASK,4,4
	.comm	MDF_ACTIVE,4,4
	.comm	ENOSPC,4,4
	.comm	EINVAL,4,4
	.comm	EBUSY,4,4
	.comm	EACCES,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
