	.file	"extr_lsm_sorted.c_multiCursorDoCompare.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	multiCursorDoCompare, @function
multiCursorDoCompare:
.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
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	movsx	rbp, esi
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	rbx, rdi
	sub	rsp, 48
	.cfi_def_cfa_offset 96
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 40[rsp], rax
	xor	eax, eax
	cmp	edx, 1
	sbb	r12d, r12d
	xor	edi, edi
	and	r12d, 2
	sub	r12d, 1
	cmp	QWORD PTR [rbx], 0
	je	.L3
	xor	edi, edi
	cmp	DWORD PTR 8[rbx], ebp
	setg	dil
.L3:
	call	assert@PLT
	mov	eax, DWORD PTR 8[rbx]
	mov	edx, eax
	shr	edx, 31
	add	edx, eax
	sar	edx
	cmp	edx, ebp
	jg	.L4
	mov	r13d, ebp
	sub	r13d, edx
	add	r13d, r13d
	lea	r14d, 1[r13]
.L5:
	lea	rcx, 24[rsp]
	lea	rdx, 12[rsp]
	mov	esi, r13d
	mov	rdi, rbx
	lea	r8, 8[rsp]
	call	multiCursorGetKey@PLT
	lea	rdx, 20[rsp]
	mov	esi, r14d
	mov	rdi, rbx
	lea	rcx, 32[rsp]
	lea	r8, 16[rsp]
	call	multiCursorGetKey@PLT
	mov	rdx, QWORD PTR 24[rsp]
	test	rdx, rdx
	je	.L11
	mov	r9, QWORD PTR 32[rsp]
	test	r9, r9
	je	.L6
	sub	rsp, 8
	.cfi_def_cfa_offset 104
	mov	rdi, rbx
	mov	eax, DWORD PTR 24[rsp]
	push	rax
	.cfi_def_cfa_offset 112
	mov	r8d, DWORD PTR 36[rsp]
	mov	ecx, DWORD PTR 24[rsp]
	mov	esi, DWORD PTR 28[rsp]
	call	sortedDbKeyCompare@PLT
	imul	r12d, eax
	pop	rax
	.cfi_def_cfa_offset 104
	pop	rdx
	.cfi_def_cfa_offset 96
	test	r12d, r12d
	jne	.L7
	mov	eax, DWORD PTR LSM_INSERT[rip]
	or	eax, DWORD PTR LSM_POINT_DELETE[rip]
	test	DWORD PTR 12[rsp], eax
	sete	dl
	test	DWORD PTR 20[rsp], eax
	sete	al
	cmp	dl, al
	cmova	r13d, r14d
	.p2align 4,,10
	.p2align 3
.L6:
	mov	rax, QWORD PTR [rbx]
	mov	DWORD PTR [rax+rbp*4], r13d
	mov	rax, QWORD PTR 40[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L19
	add	rsp, 48
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	pop	rbx
	.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
.L4:
	.cfi_restore_state
	mov	rdx, QWORD PTR [rbx]
	lea	eax, [rbp+rbp]
	cdqe
	mov	r13d, DWORD PTR [rdx+rax*4]
	mov	r14d, DWORD PTR 4[rdx+rax*4]
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L11:
	mov	r13d, r14d
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L7:
	cmovns	r13d, r14d
	jmp	.L6
.L19:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	multiCursorDoCompare, .-multiCursorDoCompare
	.comm	LSM_POINT_DELETE,4,4
	.comm	LSM_INSERT,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_lsm_sorted.c_multiCursorDoCompare.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	multiCursorDoCompare, %function
multiCursorDoCompare:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r5, r0
	ldr	r0, [r0]
	cmp	r2, #0
	ldr	r3, .L19
	mvnne	r7, #0
	moveq	r7, #1
	sub	sp, sp, #48
	cmp	r0, #0
	mov	r6, r1
	ldr	r3, [r3]
	str	r3, [sp, #44]
	mov	r3,#0
	beq	.L3
	ldr	r0, [r5, #4]
	cmp	r0, r1
	movle	r0, #0
	movgt	r0, #1
.L3:
	bl	assert
	ldr	r4, [r5, #4]
	mov	r0, r5
	add	r4, r4, r4, lsr #31
	cmp	r6, r4, asr #1
	ldrlt	r3, [r5]
	asr	r4, r4, #1
	subge	r4, r6, r4
	ldrlt	r4, [r3, r6, lsl #3]
	addlt	r2, r3, r6, lsl #3
	lslge	r4, r4, #1
	add	r3, sp, #24
	ldrlt	r8, [r2, #4]
	mov	r1, r4
	str	r3, [sp]
	add	r2, sp, #28
	add	r3, sp, #20
	addge	r8, r4, #1
	bl	multiCursorGetKey
	add	r3, sp, #36
	str	r3, [sp]
	add	r2, sp, #40
	mov	r1, r8
	mov	r0, r5
	add	r3, sp, #32
	bl	multiCursorGetKey
	ldr	r2, [sp, #20]
	cmp	r2, #0
	beq	.L11
	ldr	r3, [sp, #32]
	cmp	r3, #0
	beq	.L6
	ldr	r0, [sp, #36]
	ldr	r1, [sp, #40]
	str	r3, [sp, #4]
	str	r0, [sp, #8]
	str	r1, [sp]
	mov	r0, r5
	ldr	r3, [sp, #24]
	ldr	r1, [sp, #28]
	bl	sortedDbKeyCompare
	mul	r7, r0, r7
	cmp	r7, #0
	bne	.L7
	ldr	r2, .L19+4
	ldr	r3, .L19+8
	ldr	r1, [r2]
	ldr	r3, [r3]
	ldr	r2, [sp, #28]
	orr	r3, r3, r1
	ldr	r1, [sp, #40]
	tst	r3, r2
	moveq	r2, #1
	movne	r2, #0
	tst	r3, r1
	moveq	r3, #1
	movne	r3, #0
	cmp	r2, r3
	movhi	r4, r8
.L6:
	ldr	r3, [r5]
	str	r4, [r3, r6, lsl #2]
	ldr	r3, .L19
	ldr	r2, [r3]
	ldr	r3, [sp, #44]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L18
	add	sp, sp, #48
	@ sp needed
	pop	{r4, r5, r6, r7, r8, pc}
.L7:
	blt	.L6
.L11:
	mov	r4, r8
	b	.L6
.L18:
	bl	__stack_chk_fail
.L20:
	.align	2
.L19:
	.word	.LC0
	.word	LSM_POINT_DELETE
	.word	LSM_INSERT
	.size	multiCursorDoCompare, .-multiCursorDoCompare
	.comm	LSM_POINT_DELETE,4,4
	.comm	LSM_INSERT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
