	.file	"extr_softcursor.c_soft_cursor.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	soft_cursor
	.type	soft_cursor, @function
soft_cursor:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	xor	eax, eax
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	mov	rbx, QWORD PTR FBINFO_STATE_RUNNING[rip]
	cmp	QWORD PTR [rdi], rbx
	jne	.L1
	mov	eax, DWORD PTR 24[rsi]
	mov	r14d, DWORD PTR 28[rsi]
	mov	r12, rdi
	mov	r8, rsi
	mov	r15, QWORD PTR 24[rdi]
	mov	r13d, DWORD PTR 16[rdi]
	lea	ecx, 7[rax]
	mov	ebx, DWORD PTR 20[rdi]
	sar	ecx, 3
	mov	edx, DWORD PTR [r15]
	mov	rbp, QWORD PTR 8[r15]
	imul	r14d, ecx
	mov	eax, r14d
	add	rax, 16
	cmp	rax, rdx
	je	.L3
	mov	rdi, rbp
	mov	DWORD PTR 4[rsp], ecx
	mov	QWORD PTR 8[rsp], rsi
	call	kfree@PLT
	lea	edi, 16[r14]
	mov	esi, DWORD PTR GFP_ATOMIC[rip]
	mov	DWORD PTR [r15], edi
	call	kmalloc@PLT
	mov	ecx, DWORD PTR 4[rsp]
	mov	r8, QWORD PTR 8[rsp]
	test	rax, rax
	mov	QWORD PTR 8[r15], rax
	mov	rbp, rax
	je	.L17
.L3:
	lea	eax, -1[r13+rcx]
	neg	r13d
	lea	rsi, 16[r12]
	mov	rdi, r12
	movdqu	xmm0, XMMWORD PTR 24[r8]
	and	r13d, eax
	mov	QWORD PTR 8[rsp], r8
	lea	r15, 64[rbp]
	mov	DWORD PTR 4[rsp], ecx
	movups	XMMWORD PTR 0[rbp], xmm0
	mov	eax, DWORD PTR 4[rbp]
	imul	eax, r13d
	lea	edx, -1[rbx+rax]
	neg	ebx
	and	edx, ebx
	call	fb_get_buffer_offset@PLT
	mov	r8, QWORD PTR 8[rsp]
	mov	ecx, DWORD PTR 4[rsp]
	mov	rbx, rax
	cmp	QWORD PTR 16[r8], 0
	je	.L4
	cmp	DWORD PTR [r8], 128
	je	.L18
	test	r14d, r14d
	je	.L7
	mov	r9, QWORD PTR 8[rbp]
	mov	rdi, QWORD PTR 8[r8]
	lea	esi, -1[r14]
	xor	eax, eax
	.p2align 4,,10
	.p2align 3
.L11:
	mov	edx, DWORD PTR [r9+rax*4]
	and	edx, DWORD PTR [rdi+rax*4]
	mov	DWORD PTR 64[rbp+rax*4], edx
	mov	rdx, rax
	add	rax, 1
	cmp	rsi, rdx
	jne	.L11
.L7:
	mov	r8d, DWORD PTR 4[rbp]
	mov	rdx, r15
	mov	esi, r13d
	mov	rdi, rbx
	call	fb_pad_aligned_buffer@PLT
	mov	rax, QWORD PTR 8[r12]
	mov	rsi, rbp
	mov	rdi, r12
	mov	QWORD PTR 8[rbp], rbx
	call	[QWORD PTR [rax]]
	xor	eax, eax
.L1:
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L18:
	.cfi_restore_state
	test	r14d, r14d
	je	.L7
	mov	r9, QWORD PTR 8[rbp]
	mov	rdi, QWORD PTR 8[r8]
	lea	esi, -1[r14]
	xor	eax, eax
	.p2align 4,,10
	.p2align 3
.L10:
	mov	edx, DWORD PTR [r9+rax*4]
	xor	edx, DWORD PTR [rdi+rax*4]
	mov	DWORD PTR 64[rbp+rax*4], edx
	mov	rdx, rax
	add	rax, 1
	cmp	rsi, rdx
	jne	.L10
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L4:
	mov	rsi, QWORD PTR 8[rbp]
	mov	edx, r14d
	mov	rdi, r15
	mov	DWORD PTR 4[rsp], ecx
	call	memcpy@PLT
	mov	ecx, DWORD PTR 4[rsp]
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L17:
	mov	eax, DWORD PTR ENOMEM[rip]
	mov	DWORD PTR [r15], 0
	neg	eax
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	soft_cursor, .-soft_cursor
	.comm	GFP_ATOMIC,4,4
	.comm	FBINFO_STATE_RUNNING,8,8
	.comm	ENOMEM,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_softcursor.c_soft_cursor.c"
	.text
	.align	2
	.global	soft_cursor
	.syntax unified
	.arm
	.fpu softvfp
	.type	soft_cursor, %function
soft_cursor:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, .L22
	ldr	r2, [r0]
	ldr	r3, [r3]
	cmp	r2, r3
	bne	.L12
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	ldr	r10, [r1, #12]
	ldr	r6, [r1, #16]
	add	r10, r10, #7
	asr	r10, r10, #3
	mul	r6, r10, r6
	ldr	r7, [r0, #16]
	add	r3, r6, #12
	sub	sp, sp, #20
	ldm	r7, {r2, r5}
	cmp	r3, r2
	mov	r4, r0
	mov	fp, r1
	ldr	r9, [r0, #8]
	ldr	r8, [r0, #12]
	str	r3, [sp, #12]
	beq	.L3
	mov	r0, r5
	bl	kfree
	ldr	r3, [sp, #12]
	ldr	r2, .L22+4
	mov	r0, r3
	ldr	r1, [r2]
	str	r3, [r7]
	bl	kmalloc
	cmp	r0, #0
	mov	r5, r0
	str	r0, [r7, #4]
	beq	.L20
.L3:
	add	r3, fp, #12
	ldm	r3, {r0, r1, r2}
	mov	r3, r1
	sub	r7, r9, #1
	add	r7, r7, r10
	rsb	r9, r9, #0
	sub	ip, r8, #1
	and	r7, r7, r9
	mla	r3, r7, r3, ip
	rsb	r8, r8, #0
	stm	r5, {r0, r1, r2}
	and	r2, r8, r3
	mov	r0, r4
	add	r1, r4, #8
	bl	fb_get_buffer_offset
	ldr	r3, [fp, #8]
	mov	r8, r0
	cmp	r3, #0
	add	r9, r5, #48
	beq	.L4
	ldr	r3, [fp]
	cmp	r3, #128
	beq	.L21
	cmp	r6, #0
	beq	.L7
	ldr	r3, [r5, #8]
	ldr	r1, [fp, #4]
	add	r6, r3, r6, lsl #2
	sub	r1, r1, #4
	sub	r6, r6, #4
	sub	r3, r3, #4
	add	r0, r5, #44
.L11:
	ldr	r2, [r3, #4]!
	ldr	ip, [r1, #4]!
	cmp	r3, r6
	and	r2, r2, ip
	str	r2, [r0, #4]!
	bne	.L11
.L7:
	ldr	r0, [r5, #4]
	mov	r3, r10
	mov	r2, r9
	mov	r1, r7
	str	r0, [sp]
	mov	r0, r8
	bl	fb_pad_aligned_buffer
	ldr	r3, [r4, #4]
	mov	r1, r5
	mov	r0, r4
	ldr	r3, [r3]
	str	r8, [r5, #8]
	blx	r3
	mov	r0, #0
.L1:
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L12:
	mov	r0, #0
	bx	lr
.L21:
	cmp	r6, #0
	beq	.L7
	ldr	r2, [r5, #8]
	ldr	r1, [fp, #4]
	add	r6, r2, r6, lsl #2
	sub	r1, r1, #4
	sub	r6, r6, #4
	sub	r2, r2, #4
	add	r0, r5, #44
.L10:
	ldr	r3, [r2, #4]!
	ldr	ip, [r1, #4]!
	cmp	r2, r6
	eor	r3, r3, ip
	str	r3, [r0, #4]!
	bne	.L10
	b	.L7
.L4:
	mov	r2, r6
	mov	r0, r9
	ldr	r1, [r5, #8]
	bl	memcpy
	b	.L7
.L20:
	ldr	r3, .L22+8
	str	r0, [r7]
	ldr	r0, [r3]
	rsb	r0, r0, #0
	b	.L1
.L23:
	.align	2
.L22:
	.word	FBINFO_STATE_RUNNING
	.word	GFP_ATOMIC
	.word	ENOMEM
	.size	soft_cursor, .-soft_cursor
	.comm	GFP_ATOMIC,4,4
	.comm	FBINFO_STATE_RUNNING,4,4
	.comm	ENOMEM,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
