	.file	"extr_gl_raster_font.c_gl_raster_font_render_line.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	gl_raster_font_render_line, @function
gl_raster_font_render_line:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	r15
	push	r14
	push	r13
	push	r12
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	mov	r12, rdi
	push	rbx
	sub	rsp, 120
	.cfi_offset 3, -56
	mov	rax, QWORD PTR 32[rbp]
	mov	QWORD PTR -104[rbp], rsi
	mov	esi, DWORD PTR MAX_MSG_LEN_CHUNK[rip]
	mov	rbx, rsp
	mov	QWORD PTR -144[rbp], rax
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -56[rbp], rax
	xor	eax, eax
	lea	eax, [rsi+rsi*2]
	sal	eax, 2
	cdqe
	lea	rdi, 15[0+rax*4]
	sal	rax, 2
	mov	r8, rdi
	and	r8, -4096
	sub	rbx, r8
	mov	r8, rbx
	cmp	rsp, r8
	je	.L3
.L43:
	sub	rsp, 4096
	or	QWORD PTR 4088[rsp], 0
	cmp	rsp, r8
	jne	.L43
.L3:
	and	eax, 4095
	sub	rsp, rax
	test	rax, rax
	jne	.L44
.L4:
	mov	r8, rdi
	mov	rbx, rsp
	mov	rax, rdi
	mov	QWORD PTR -112[rbp], rsp
	and	r8, -4096
	and	rax, -16
	sub	rbx, r8
	mov	r8, rbx
	cmp	rsp, r8
	je	.L6
.L45:
	sub	rsp, 4096
	or	QWORD PTR 4088[rsp], 0
	cmp	rsp, r8
	jne	.L45
.L6:
	and	eax, 4095
	sub	rsp, rax
	test	rax, rax
	jne	.L46
.L7:
	lea	eax, [rsi+rsi*2]
	mov	rbx, rsp
	mov	QWORD PTR -120[rbp], rsp
	sal	eax, 3
	cdqe
	sal	rax, 2
	mov	rsi, rax
	and	rsi, -4096
	sub	rbx, rsi
	mov	rsi, rbx
	cmp	rsp, rsi
	je	.L9
.L47:
	sub	rsp, 4096
	or	QWORD PTR 4088[rsp], 0
	cmp	rsp, rsi
	jne	.L47
.L9:
	and	eax, 4095
	sub	rsp, rax
	test	rax, rax
	je	.L10
	or	QWORD PTR -8[rsp+rax], 0
.L10:
	mov	rax, rdi
	mov	rsi, rsp
	and	rdi, -4096
	mov	QWORD PTR -128[rbp], rsp
	sub	rsi, rdi
	and	rax, -16
	cmp	rsp, rsi
	je	.L12
.L48:
	sub	rsp, 4096
	or	QWORD PTR 4088[rsp], 0
	cmp	rsp, rsi
	jne	.L48
.L12:
	and	eax, 4095
	sub	rsp, rax
	test	rax, rax
	je	.L13
	or	QWORD PTR -8[rsp+rax], 0
.L13:
	mov	rbx, QWORD PTR 32[r12]
	mov	r13d, edx
	mov	DWORD PTR -152[rbp], ecx
	mov	DWORD PTR -148[rbp], edx
	add	r13, QWORD PTR -104[rbp]
	mov	edi, DWORD PTR [rbx]
	mov	QWORD PTR -136[rbp], rsp
	imul	edi, r9d
	call	roundf@PLT
	mov	edi, DWORD PTR 16[rbp]
	imul	edi, DWORD PTR 4[rbx]
	call	roundf@PLT
	mov	eax, DWORD PTR 24[rbp]
	add	eax, -128
	cmp	eax, 1
	ja	.L14
	mov	ecx, DWORD PTR -152[rbp]
	mov	edx, DWORD PTR -148[rbp]
	mov	rdi, r12
	mov	rsi, QWORD PTR -104[rbp]
	call	gl_get_message_width@PLT
.L14:
	lea	r15, -96[rbp]
	lea	r14, -104[rbp]
	cmp	r13, QWORD PTR -104[rbp]
	jbe	.L1
	.p2align 4,,10
	.p2align 3
.L15:
	xor	ebx, ebx
.L18:
	cmp	ebx, DWORD PTR MAX_MSG_LEN_CHUNK[rip]
	jnb	.L19
.L50:
	cmp	QWORD PTR -104[rbp], r13
	jnb	.L19
	mov	rdi, r14
	call	utf8_walk@PLT
	mov	edi, DWORD PTR 16[r12]
	movsx	esi, al
	mov	rax, QWORD PTR 24[r12]
	call	[QWORD PTR [rax]]
	test	rax, rax
	je	.L49
.L17:
	xor	esi, esi
	xor	edi, edi
	mov	edx, 1
	add	ebx, 1
	call	gl_raster_font_emit@PLT
	mov	edx, 1
	mov	esi, 1
	mov	edi, 1
	call	gl_raster_font_emit@PLT
	xor	edx, edx
	xor	esi, esi
	mov	edi, 2
	call	gl_raster_font_emit@PLT
	xor	edx, edx
	mov	esi, 1
	mov	edi, 3
	call	gl_raster_font_emit@PLT
	xor	edx, edx
	xor	esi, esi
	mov	edi, 4
	call	gl_raster_font_emit@PLT
	mov	edx, 1
	mov	esi, 1
	mov	edi, 5
	call	gl_raster_font_emit@PLT
	cmp	ebx, DWORD PTR MAX_MSG_LEN_CHUNK[rip]
	jb	.L50
.L19:
	mov	rax, QWORD PTR -112[rbp]
	lea	edx, [rbx+rbx*2]
	mov	rdi, QWORD PTR 8[r12]
	add	edx, edx
	mov	QWORD PTR -96[rbp], rax
	mov	rax, QWORD PTR -120[rbp]
	mov	DWORD PTR -72[rbp], edx
	mov	QWORD PTR -88[rbp], rax
	mov	rax, QWORD PTR -128[rbp]
	mov	QWORD PTR -80[rbp], rax
	mov	rax, QWORD PTR -136[rbp]
	mov	QWORD PTR -64[rbp], rax
	test	rdi, rdi
	je	.L21
	mov	rsi, r15
	call	video_coord_array_append@PLT
.L22:
	cmp	QWORD PTR -104[rbp], r13
	jb	.L15
.L1:
	mov	rax, QWORD PTR -56[rbp]
	xor	rax, QWORD PTR fs:40
	jne	.L51
	lea	rsp, -40[rbp]
	pop	rbx
	pop	r12
	pop	r13
	pop	r14
	pop	r15
	pop	rbp
	.cfi_remember_state
	.cfi_def_cfa 7, 8
	ret
.L44:
	.cfi_restore_state
	or	QWORD PTR -8[rsp+rax], 0
	jmp	.L4
.L46:
	or	QWORD PTR -8[rsp+rax], 0
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L49:
	mov	rax, QWORD PTR 24[r12]
	mov	edi, DWORD PTR 16[r12]
	mov	esi, 63
	call	[QWORD PTR [rax]]
	test	rax, rax
	je	.L18
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L21:
	mov	rdx, QWORD PTR -144[rbp]
	mov	rsi, r15
	mov	rdi, r12
	call	gl_raster_font_draw_vertices@PLT
	jmp	.L22
.L51:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	gl_raster_font_render_line, .-gl_raster_font_render_line
	.comm	MAX_MSG_LEN_CHUNK,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_gl_raster_font.c_gl_raster_font_render_line.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	gl_raster_font_render_line, %function
gl_raster_font_render_line:
	@ args = 20, pretend = 0, frame = 40
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	add	fp, sp, #32
	sub	sp, sp, #44
	mov	ip, sp
	ldr	r7, .L21
	mov	r4, r2
	ldr	r2, [r7]
	ldr	r10, [r0, #20]
	add	r2, r2, r2, lsl #1
	sub	ip, ip, r2, lsl #4
	mov	sp, ip
	mov	lr, sp
	sub	lr, lr, r2, lsl #4
	str	sp, [fp, #-68]
	mov	sp, lr
	sub	lr, lr, r2, lsl #5
	mov	r8, sp
	mov	sp, lr
	mov	r9, sp
	sub	r2, r9, r2, lsl #4
	mov	sp, r2
	str	r3, [fp, #-76]
	ldr	r3, .L21+4
	ldr	ip, [fp, #8]
	mov	r5, r0
	ldr	r0, [r10]
	str	r1, [fp, #-64]
	ldr	r3, [r3]
	str	r3, [fp, #-40]
	mov	r3,#0
	ldr	r3, [fp, #20]
	mul	r0, ip, r0
	add	r6, r1, r4
	str	r3, [fp, #-72]
	bl	roundf
	ldr	r0, [r10, #4]
	ldr	r3, [fp, #12]
	mov	r10, sp
	mul	r3, r0, r3
	mov	r0, r3
	bl	roundf
	ldr	r3, [fp, #16]
	sub	r2, r3, #128
	cmp	r2, #1
	bhi	.L2
	mov	r2, r4
	mov	r0, r5
	ldr	r3, [fp, #-76]
	ldr	r1, [fp, #-64]
	bl	gl_get_message_width
.L2:
	ldr	r3, [fp, #-64]
	cmp	r6, r3
	bls	.L1
.L3:
	mov	r4, #0
.L6:
	ldr	r3, [r7]
	cmp	r4, r3
	bcs	.L7
.L19:
	ldr	r3, [fp, #-64]
	cmp	r3, r6
	bcs	.L7
	sub	r0, fp, #64
	bl	utf8_walk
	ldr	r3, [r5, #16]
	and	r1, r0, #255
	ldr	r3, [r3]
	ldr	r0, [r5, #12]
	blx	r3
	cmp	r0, #0
	beq	.L18
.L5:
	mov	r1, #0
	mov	r2, #1
	mov	r0, r1
	bl	gl_raster_font_emit
	mov	r2, #1
	mov	r1, r2
	mov	r0, r2
	bl	gl_raster_font_emit
	mov	r2, #0
	mov	r0, #2
	mov	r1, r2
	bl	gl_raster_font_emit
	mov	r2, #0
	mov	r1, #1
	mov	r0, #3
	bl	gl_raster_font_emit
	mov	r2, #0
	mov	r0, #4
	mov	r1, r2
	bl	gl_raster_font_emit
	mov	r2, #1
	mov	r0, #5
	mov	r1, r2
	bl	gl_raster_font_emit
	ldr	r3, [r7]
	add	r4, r4, #1
	cmp	r4, r3
	bcc	.L19
.L7:
	ldr	r0, [r5, #8]
	ldr	r3, [fp, #-68]
	add	r4, r4, r4, lsl #1
	lsl	r2, r4, #1
	cmp	r0, #0
	str	r2, [fp, #-48]
	str	r3, [fp, #-60]
	str	r8, [fp, #-56]
	str	r9, [fp, #-52]
	str	r10, [fp, #-44]
	beq	.L9
	sub	r1, fp, #60
	bl	video_coord_array_append
.L10:
	ldr	r3, [fp, #-64]
	cmp	r3, r6
	bcc	.L3
.L1:
	ldr	r3, .L21+4
	ldr	r2, [r3]
	ldr	r3, [fp, #-40]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L20
	sub	sp, fp, #32
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L18:
	ldr	r3, [r5, #16]
	mov	r1, #63
	ldr	r3, [r3]
	ldr	r0, [r5, #12]
	blx	r3
	cmp	r0, #0
	beq	.L6
	b	.L5
.L9:
	mov	r0, r5
	ldr	r2, [fp, #-72]
	sub	r1, fp, #60
	bl	gl_raster_font_draw_vertices
	b	.L10
.L20:
	bl	__stack_chk_fail
.L22:
	.align	2
.L21:
	.word	MAX_MSG_LEN_CHUNK
	.word	.LC0
	.size	gl_raster_font_render_line, .-gl_raster_font_render_line
	.comm	MAX_MSG_LEN_CHUNK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
