	.file	"extr_fontstash.h_fons__allocFont.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	fons__allocFont, @function
fons__allocFont:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	mov	rbx, rdi
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	mov	esi, DWORD PTR 4[rdi]
	cmp	DWORD PTR [rdi], esi
	jl	.L7
	test	esi, esi
	jne	.L19
	mov	esi, 64
	mov	eax, 8
.L5:
	mov	DWORD PTR 4[rbx], eax
	mov	rdi, QWORD PTR 8[rbx]
	call	realloc@PLT
	mov	QWORD PTR 8[rbx], rax
	test	rax, rax
	je	.L20
.L7:
	mov	edi, 24
	call	malloc@PLT
	mov	rbp, rax
	test	rax, rax
	jne	.L21
.L3:
	mov	rdi, rbp
	call	fons__freeFont@PLT
	mov	eax, DWORD PTR FONS_INVALID[rip]
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L19:
	.cfi_restore_state
	lea	eax, [rsi+rsi]
	sal	esi, 4
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L21:
	mov	edx, 24
	xor	esi, esi
	mov	rdi, rax
	call	memset@PLT
	mov	eax, DWORD PTR FONS_INIT_GLYPHS[rip]
	lea	edi, 0[0+rax*4]
	call	malloc@PLT
	mov	QWORD PTR 16[rbp], rax
	test	rax, rax
	je	.L3
	mov	eax, DWORD PTR FONS_INIT_GLYPHS[rip]
	mov	rdx, QWORD PTR 8[rbx]
	mov	QWORD PTR 8[rbp], 0
	mov	DWORD PTR 0[rbp], eax
	mov	eax, DWORD PTR [rbx]
	lea	ecx, 1[rax]
	mov	DWORD PTR [rbx], ecx
	movsx	rcx, eax
	mov	QWORD PTR [rdx+rcx*8], rbp
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
.L20:
	.cfi_restore_state
	mov	eax, -1
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	fons__allocFont, .-fons__allocFont
	.comm	FONS_INVALID,4,4
	.comm	FONS_INIT_GLYPHS,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_fontstash.h_fons__allocFont.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	fons__allocFont, %function
fons__allocFont:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r1, [r0, #4]
	ldr	r3, [r0]
	push	{r4, r5, r6, r7, r8, lr}
	cmp	r3, r1
	mov	r5, r0
	blt	.L7
	cmp	r1, #0
	moveq	r3, #8
	lslne	r3, r1, #1
	moveq	r1, #32
	lslne	r1, r1, #3
	str	r3, [r0, #4]
	ldr	r0, [r0, #8]
	bl	realloc
	cmp	r0, #0
	str	r0, [r5, #8]
	beq	.L19
.L7:
	mov	r0, #12
	bl	malloc
	subs	r4, r0, #0
	beq	.L3
	mov	r6, #0
	ldr	r3, .L20
	str	r6, [r4]
	ldr	r7, [r3]
	str	r6, [r4, #4]
	lsl	r0, r7, #2
	str	r6, [r4, #8]
	bl	malloc
	cmp	r0, r6
	str	r0, [r4, #8]
	beq	.L3
	ldr	r0, [r5]
	ldr	r3, [r5, #8]
	add	r2, r0, #1
	str	r7, [r4]
	str	r6, [r4, #4]
	str	r2, [r5]
	str	r4, [r3, r0, lsl #2]
	pop	{r4, r5, r6, r7, r8, pc}
.L3:
	mov	r0, r4
	bl	fons__freeFont
	ldr	r3, .L20+4
	ldr	r0, [r3]
	pop	{r4, r5, r6, r7, r8, pc}
.L19:
	mvn	r0, #0
	pop	{r4, r5, r6, r7, r8, pc}
.L21:
	.align	2
.L20:
	.word	FONS_INIT_GLYPHS
	.word	FONS_INVALID
	.size	fons__allocFont, .-fons__allocFont
	.comm	FONS_INVALID,4,4
	.comm	FONS_INIT_GLYPHS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
