	.file	"extr_emptystr_hittest.c_key.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	key, @function
key:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	cmp	QWORD PTR 16[rdi], 0
	jne	.L14
	cmp	QWORD PTR [rdi], 0
	jne	.L14
	mov	eax, DWORD PTR 8[rdi]
	cmp	eax, 130
	je	.L5
	jg	.L6
	mov	r12d, 1
	cmp	eax, 128
	je	.L1
	cmp	eax, 129
	jne	.L14
	mov	edi, DWORD PTR attrstr[rip]
	mov	esi, DWORD PTR caretPos[rip]
	call	uiAttributedStringByteIndexToGrapheme@PLT
	mov	edi, DWORD PTR attrstr[rip]
	mov	rbx, rax
	call	uiAttributedStringNumGraphemes@PLT
	cmp	rax, rbx
	je	.L14
	mov	edi, DWORD PTR attrstr[rip]
	lea	rsi, 1[rbx]
	call	uiAttributedStringGraphemeToByteIndex@PLT
	mov	DWORD PTR caretPos[rip], eax
	xor	eax, eax
	call	redraw@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L14:
	xor	r12d, r12d
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L6:
	.cfi_restore_state
	xor	r12d, r12d
	cmp	eax, 131
	sete	r12b
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L5:
	.cfi_restore_state
	mov	esi, DWORD PTR caretPos[rip]
	mov	edi, DWORD PTR attrstr[rip]
	call	uiAttributedStringByteIndexToGrapheme@PLT
	test	rax, rax
	je	.L14
	mov	edi, DWORD PTR attrstr[rip]
	lea	rsi, -1[rax]
	mov	r12d, 1
	call	uiAttributedStringGraphemeToByteIndex@PLT
	mov	DWORD PTR caretPos[rip], eax
	xor	eax, eax
	call	redraw@PLT
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	key, .-key
	.comm	caretPos,4,4
	.comm	attrstr,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_emptystr_hittest.c_key.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	key, %function
key:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r2, [r0, #8]
	cmp	r2, #0
	bne	.L14
	mov	r3, r0
	ldr	r0, [r0]
	cmp	r0, #0
	bne	.L14
	ldr	r3, [r3, #4]
	push	{r4, r5, r6, lr}
	sub	r3, r3, #128
	cmp	r3, #3
	ldrls	pc, [pc, r3, asl #2]
	b	.L1
.L6:
	.word	.L9
	.word	.L8
	.word	.L7
	.word	.L9
.L14:
	mov	r0, #0
	bx	lr
.L9:
	mov	r0, #1
.L1:
	pop	{r4, r5, r6, pc}
.L7:
	ldr	r4, .L18
	ldr	r5, .L18+4
	ldr	r1, [r4]
	ldr	r0, [r5]
	bl	uiAttributedStringByteIndexToGrapheme
	cmp	r0, #0
	beq	.L4
	sub	r1, r0, #1
	ldr	r0, [r5]
	bl	uiAttributedStringGraphemeToByteIndex
	str	r0, [r4]
	bl	redraw
	mov	r0, #1
	pop	{r4, r5, r6, pc}
.L8:
	ldr	r5, .L18+4
	ldr	r6, .L18
	ldr	r0, [r5]
	ldr	r1, [r6]
	bl	uiAttributedStringByteIndexToGrapheme
	mov	r4, r0
	ldr	r0, [r5]
	bl	uiAttributedStringNumGraphemes
	cmp	r0, r4
	beq	.L4
	add	r1, r4, #1
	ldr	r0, [r5]
	bl	uiAttributedStringGraphemeToByteIndex
	str	r0, [r6]
	bl	redraw
	mov	r0, #1
	pop	{r4, r5, r6, pc}
.L4:
	mov	r0, #0
	pop	{r4, r5, r6, pc}
.L19:
	.align	2
.L18:
	.word	caretPos
	.word	attrstr
	.size	key, .-key
	.comm	caretPos,4,4
	.comm	attrstr,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
