	.file	"extr_ra_gl.c_gl_tex_create.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"after creating texture"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC1:
	.string	"Trying to create renderable texture with unsupported format.\n"
	.align 8
.LC2:
	.string	"Error: framebuffer completeness check failed (error=%d).\n"
	.section	.rodata.str1.1
.LC3:
	.string	"after creating framebuffer"
	.text
	.p2align 4
	.type	gl_tex_create, @function
gl_tex_create:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	mov	r13, rdi
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	mov	r12, rsi
	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	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	call	ra_gl_get@PLT
	xor	edi, edi
	mov	rbp, rax
	mov	rax, QWORD PTR 40[r12]
	mov	esi, DWORD PTR [rax]
	test	esi, esi
	sete	dil
	call	assert@PLT
	mov	rsi, r12
	mov	rdi, r13
	call	gl_tex_create_blank@PLT
	mov	QWORD PTR [rsp], rax
	test	rax, rax
	je	.L1
	mov	rbx, QWORD PTR 40[rax]
	mov	edi, 1
	lea	rsi, 4[rbx]
	mov	DWORD PTR [rbx], 1
	call	[QWORD PTR 88[rbp]]
	mov	esi, DWORD PTR 4[rbx]
	mov	edi, DWORD PTR 12[rbx]
	call	[QWORD PTR 40[rbp]]
	cmp	QWORD PTR 32[r12], 0
	mov	r15d, DWORD PTR GL_NEAREST[rip]
	je	.L4
	mov	r15d, DWORD PTR GL_LINEAR[rip]
.L4:
	cmp	QWORD PTR 24[r12], 0
	mov	r14d, DWORD PTR GL_CLAMP_TO_EDGE[rip]
	jne	.L21
.L6:
	mov	edi, DWORD PTR 12[rbx]
	mov	esi, DWORD PTR GL_TEXTURE_MIN_FILTER[rip]
	mov	edx, r15d
	call	[QWORD PTR 80[rbp]]
	mov	edi, DWORD PTR 12[rbx]
	mov	esi, DWORD PTR GL_TEXTURE_MAG_FILTER[rip]
	mov	edx, r15d
	call	[QWORD PTR 80[rbp]]
	mov	edi, DWORD PTR 12[rbx]
	mov	esi, DWORD PTR GL_TEXTURE_WRAP_S[rip]
	mov	edx, r14d
	call	[QWORD PTR 80[rbp]]
	cmp	DWORD PTR [r12], 1
	jle	.L7
	mov	edi, DWORD PTR 12[rbx]
	mov	esi, DWORD PTR GL_TEXTURE_WRAP_T[rip]
	mov	edx, r14d
	call	[QWORD PTR 80[rbp]]
	cmp	DWORD PTR [r12], 2
	jle	.L7
	mov	edi, DWORD PTR 12[rbx]
	mov	esi, DWORD PTR GL_TEXTURE_WRAP_R[rip]
	mov	edx, r14d
	call	[QWORD PTR 80[rbp]]
.L7:
	mov	edi, DWORD PTR GL_UNPACK_ALIGNMENT[rip]
	mov	esi, 1
	call	[QWORD PTR 48[rbp]]
	mov	eax, DWORD PTR [r12]
	cmp	eax, 2
	je	.L8
	cmp	eax, 3
	je	.L9
	cmp	eax, 1
	je	.L22
.L10:
	mov	edi, DWORD PTR GL_UNPACK_ALIGNMENT[rip]
	mov	esi, 4
	call	[QWORD PTR 48[rbp]]
	xor	esi, esi
	mov	edi, DWORD PTR 12[rbx]
	call	[QWORD PTR 40[rbp]]
	mov	esi, DWORD PTR 0[r13]
	lea	rdx, .LC0[rip]
	mov	rdi, rbp
	call	gl_check_error@PLT
	mov	rax, QWORD PTR [rsp]
	cmp	QWORD PTR 32[rax], 0
	je	.L23
.L11:
	mov	rax, QWORD PTR [rax]
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	je	.L24
	mov	edi, DWORD PTR 0[rbp]
	and	edi, DWORD PTR MPGL_CAP_FB[rip]
	call	assert@PLT
	lea	rsi, 8[rbx]
	mov	edi, 1
	call	[QWORD PTR 32[rbp]]
	mov	esi, DWORD PTR 8[rbx]
	mov	edi, DWORD PTR GL_FRAMEBUFFER[rip]
	call	[QWORD PTR 16[rbp]]
	mov	ecx, DWORD PTR 4[rbx]
	xor	r8d, r8d
	mov	edx, DWORD PTR GL_TEXTURE_2D[rip]
	mov	esi, DWORD PTR GL_COLOR_ATTACHMENT0[rip]
	mov	edi, DWORD PTR GL_FRAMEBUFFER[rip]
	call	[QWORD PTR 24[rbp]]
	mov	edi, DWORD PTR GL_FRAMEBUFFER[rip]
	call	[QWORD PTR 8[rbp]]
	xor	esi, esi
	mov	edi, DWORD PTR GL_FRAMEBUFFER[rip]
	mov	rbx, rax
	call	[QWORD PTR 16[rbp]]
	cmp	QWORD PTR GL_FRAMEBUFFER_COMPLETE[rip], rbx
	jne	.L25
	mov	esi, DWORD PTR 0[r13]
	lea	rdx, .LC3[rip]
	mov	rdi, rbp
	call	gl_check_error@PLT
	mov	rax, QWORD PTR [rsp]
.L1:
	mov	rcx, QWORD PTR 8[rsp]
	xor	rcx, QWORD PTR fs:40
	jne	.L26
	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
.L23:
	.cfi_restore_state
	cmp	QWORD PTR 24[rax], 0
	jne	.L11
	cmp	QWORD PTR 16[rax], 0
	jne	.L11
	cmp	QWORD PTR 8[rax], 0
	je	.L1
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L21:
	mov	r14d, DWORD PTR GL_REPEAT[rip]
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L9:
	mov	eax, DWORD PTR 4[r12]
	mov	edx, DWORD PTR 24[rbx]
	xor	esi, esi
	mov	edi, DWORD PTR 12[rbx]
	mov	ecx, DWORD PTR 16[r12]
	mov	r9d, DWORD PTR 8[r12]
	mov	r8d, DWORD PTR 12[r12]
	push	rax
	.cfi_def_cfa_offset 88
	mov	eax, DWORD PTR 16[rbx]
	push	rax
	.cfi_def_cfa_offset 96
	mov	eax, DWORD PTR 20[rbx]
	push	rax
	.cfi_def_cfa_offset 104
	push	0
	.cfi_def_cfa_offset 112
	call	[QWORD PTR 56[rbp]]
	add	rsp, 32
	.cfi_def_cfa_offset 80
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L8:
	mov	eax, DWORD PTR 4[r12]
	sub	rsp, 8
	.cfi_def_cfa_offset 88
	mov	edx, DWORD PTR 24[rbx]
	xor	r9d, r9d
	mov	edi, DWORD PTR 12[rbx]
	mov	ecx, DWORD PTR 16[r12]
	xor	esi, esi
	push	rax
	.cfi_def_cfa_offset 96
	mov	eax, DWORD PTR 16[rbx]
	mov	r8d, DWORD PTR 12[r12]
	push	rax
	.cfi_def_cfa_offset 104
	mov	eax, DWORD PTR 20[rbx]
	push	rax
	.cfi_def_cfa_offset 112
	call	[QWORD PTR 64[rbp]]
	add	rsp, 32
	.cfi_def_cfa_offset 80
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L22:
	mov	eax, DWORD PTR 4[r12]
	mov	edx, DWORD PTR 24[rbx]
	xor	r8d, r8d
	xor	esi, esi
	mov	r9d, DWORD PTR 20[rbx]
	mov	edi, DWORD PTR 12[rbx]
	push	rax
	.cfi_def_cfa_offset 88
	mov	eax, DWORD PTR 16[rbx]
	mov	ecx, DWORD PTR 16[r12]
	push	rax
	.cfi_def_cfa_offset 96
	call	[QWORD PTR 72[rbp]]
	pop	rdx
	.cfi_def_cfa_offset 88
	pop	rcx
	.cfi_def_cfa_offset 80
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L25:
	mov	edx, ebx
	lea	rsi, .LC2[rip]
	mov	rdi, r13
	xor	eax, eax
	call	MP_ERR@PLT
	mov	rsi, rsp
	mov	rdi, r13
	call	ra_tex_free@PLT
	xor	eax, eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L24:
	lea	rsi, .LC1[rip]
	mov	rdi, r13
	xor	eax, eax
	call	MP_ERR@PLT
	mov	rsi, rsp
	mov	rdi, r13
	call	ra_tex_free@PLT
	xor	eax, eax
	jmp	.L1
.L26:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	gl_tex_create, .-gl_tex_create
	.comm	MPGL_CAP_FB,4,4
	.comm	GL_UNPACK_ALIGNMENT,4,4
	.comm	GL_TEXTURE_WRAP_T,4,4
	.comm	GL_TEXTURE_WRAP_S,4,4
	.comm	GL_TEXTURE_WRAP_R,4,4
	.comm	GL_TEXTURE_MIN_FILTER,4,4
	.comm	GL_TEXTURE_MAG_FILTER,4,4
	.comm	GL_TEXTURE_2D,4,4
	.comm	GL_REPEAT,4,4
	.comm	GL_NEAREST,4,4
	.comm	GL_LINEAR,4,4
	.comm	GL_FRAMEBUFFER_COMPLETE,8,8
	.comm	GL_FRAMEBUFFER,4,4
	.comm	GL_COLOR_ATTACHMENT0,4,4
	.comm	GL_CLAMP_TO_EDGE,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_ra_gl.c_gl_tex_create.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"after creating texture\000"
	.align	2
.LC1:
	.ascii	"Trying to create renderable texture with unsupporte"
	.ascii	"d format.\012\000"
	.align	2
.LC2:
	.ascii	"Error: framebuffer completeness check failed (error"
	.ascii	"=%d).\012\000"
	.align	2
.LC3:
	.ascii	"after creating framebuffer\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	gl_tex_create, %function
gl_tex_create:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, lr}
	ldr	r3, .L29
	mov	r5, r1
	sub	sp, sp, #36
	ldr	r3, [r3]
	str	r3, [sp, #28]
	mov	r3,#0
	mov	r7, r0
	bl	ra_gl_get
	ldr	r3, [r5, #28]
	mov	r4, r0
	ldr	r0, [r3]
	clz	r0, r0
	lsr	r0, r0, #5
	bl	assert
	mov	r1, r5
	mov	r0, r7
	bl	gl_tex_create_blank
	cmp	r0, #0
	str	r0, [sp, #24]
	beq	.L1
	ldr	r6, [r0, #20]
	mov	r0, #1
	mov	r1, r6
	ldr	r3, [r4, #44]
	str	r0, [r1], #4
	blx	r3
	ldr	r1, [r6, #4]
	ldr	r3, [r4, #20]
	ldr	r0, [r6, #12]
	blx	r3
	ldr	r3, [r5, #24]
	ldr	r2, .L29+4
	cmp	r3, #0
	ldrne	r3, .L29+8
	ldreq	r3, .L29+12
	ldr	r1, [r2]
	ldr	r9, [r3]
	ldr	r3, [r5, #20]
	mov	r2, r9
	cmp	r3, #0
	ldrne	r3, .L29+16
	ldreq	r3, .L29+20
	ldr	r0, [r6, #12]
	ldr	r8, [r3]
	ldr	r3, [r4, #40]
	blx	r3
	ldr	r3, .L29+24
	mov	r2, r9
	ldr	r1, [r3]
	ldr	r0, [r6, #12]
	ldr	r3, [r4, #40]
	blx	r3
	ldr	r2, .L29+28
	ldr	r3, [r4, #40]
	ldr	r1, [r2]
	ldr	r0, [r6, #12]
	mov	r2, r8
	blx	r3
	ldr	r3, [r5]
	cmp	r3, #1
	ble	.L7
	ldr	r2, .L29+32
	ldr	r3, [r4, #40]
	ldr	r1, [r2]
	ldr	r0, [r6, #12]
	mov	r2, r8
	blx	r3
	ldr	r3, [r5]
	cmp	r3, #2
	ble	.L7
	ldr	r3, .L29+36
	mov	r2, r8
	ldr	r1, [r3]
	ldr	r0, [r6, #12]
	ldr	r3, [r4, #40]
	blx	r3
.L7:
	ldr	r8, .L29+40
	ldr	r3, [r4, #24]
	mov	r1, #1
	ldr	r0, [r8]
	blx	r3
	ldr	r3, [r5]
	cmp	r3, #2
	beq	.L8
	cmp	r3, #3
	beq	.L9
	cmp	r3, #1
	beq	.L24
.L10:
	mov	r1, #4
	ldr	r3, [r4, #24]
	ldr	r0, [r8]
	blx	r3
	ldr	r3, [r4, #20]
	mov	r1, #0
	ldr	r0, [r6, #12]
	blx	r3
	mov	r0, r4
	ldr	r2, .L29+44
	ldr	r1, [r7]
	bl	gl_check_error
	ldr	r0, [sp, #24]
	ldr	r3, [r0, #16]
	cmp	r3, #0
	beq	.L25
.L11:
	ldr	r3, [r0]
	ldr	r5, [r3]
	cmp	r5, #0
	beq	.L26
	mov	r5, #0
	ldr	r3, .L29+48
	ldr	r0, [r4]
	ldr	r3, [r3]
	ldr	r8, .L29+52
	and	r0, r0, r3
	bl	assert
	add	r1, r6, #8
	ldr	r3, [r4, #16]
	mov	r0, #1
	blx	r3
	ldr	r1, [r6, #8]
	ldr	r3, [r4, #8]
	ldr	r0, [r8]
	blx	r3
	ldr	r2, .L29+56
	ldr	r1, .L29+60
	ldr	r3, [r6, #4]
	str	r5, [sp]
	ldr	r2, [r2]
	ldr	r1, [r1]
	ldr	r6, [r4, #12]
	ldr	r0, [r8]
	blx	r6
	ldr	r3, [r4, #4]
	ldr	r0, [r8]
	blx	r3
	mov	r6, r0
	ldr	r3, [r4, #8]
	mov	r1, r5
	ldr	r0, [r8]
	blx	r3
	ldr	r3, .L29+64
	ldr	r3, [r3]
	cmp	r3, r6
	bne	.L27
	mov	r0, r4
	ldr	r1, [r7]
	ldr	r2, .L29+68
	bl	gl_check_error
	ldr	r0, [sp, #24]
.L1:
	ldr	r3, .L29
	ldr	r2, [r3]
	ldr	r3, [sp, #28]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L28
	add	sp, sp, #36
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, pc}
.L25:
	ldr	r3, [r0, #12]
	cmp	r3, #0
	bne	.L11
	ldr	r3, [r0, #8]
	cmp	r3, #0
	bne	.L11
	ldr	r3, [r0, #4]
	cmp	r3, #0
	beq	.L1
	b	.L11
.L9:
	mov	r1, #0
	ldr	r3, [r5, #4]
	ldr	r2, [r6, #24]
	ldr	r0, [r6, #12]
	str	r3, [sp, #20]
	ldr	r3, [r6, #16]
	str	r3, [sp, #16]
	ldr	r3, [r6, #20]
	ldr	ip, [r5, #8]
	str	r3, [sp, #12]
	ldr	r3, [r5, #12]
	str	r1, [sp, #8]
	stm	sp, {r3, ip}
	ldr	r3, [r5, #16]
	ldr	r5, [r4, #28]
	blx	r5
	b	.L10
.L8:
	mov	r1, #0
	ldr	r3, [r5, #4]
	ldr	r2, [r6, #24]
	ldr	r0, [r6, #12]
	str	r3, [sp, #16]
	ldr	r3, [r6, #16]
	str	r3, [sp, #12]
	ldr	ip, [r6, #20]
	ldr	r3, [r5, #12]
	stmib	sp, {r1, ip}
	str	r3, [sp]
	ldr	r3, [r5, #16]
	ldr	r5, [r4, #32]
	blx	r5
	b	.L10
.L24:
	mov	r1, #0
	ldr	r3, [r5, #4]
	ldr	r2, [r6, #24]
	ldr	r0, [r6, #12]
	str	r3, [sp, #12]
	ldr	ip, [r6, #16]
	ldr	r3, [r5, #16]
	str	ip, [sp, #8]
	ldr	ip, [r6, #20]
	stm	sp, {r1, ip}
	ldr	r5, [r4, #36]
	blx	r5
	b	.L10
.L27:
	mov	r2, r6
	ldr	r1, .L29+72
	mov	r0, r7
	bl	MP_ERR
	mov	r0, r7
	add	r1, sp, #24
	bl	ra_tex_free
	mov	r0, r5
	b	.L1
.L26:
	ldr	r1, .L29+76
	mov	r0, r7
	bl	MP_ERR
	mov	r0, r7
	add	r1, sp, #24
	bl	ra_tex_free
	mov	r0, r5
	b	.L1
.L28:
	bl	__stack_chk_fail
.L30:
	.align	2
.L29:
	.word	.LC4
	.word	GL_TEXTURE_MIN_FILTER
	.word	GL_LINEAR
	.word	GL_NEAREST
	.word	GL_REPEAT
	.word	GL_CLAMP_TO_EDGE
	.word	GL_TEXTURE_MAG_FILTER
	.word	GL_TEXTURE_WRAP_S
	.word	GL_TEXTURE_WRAP_T
	.word	GL_TEXTURE_WRAP_R
	.word	GL_UNPACK_ALIGNMENT
	.word	.LC0
	.word	MPGL_CAP_FB
	.word	GL_FRAMEBUFFER
	.word	GL_TEXTURE_2D
	.word	GL_COLOR_ATTACHMENT0
	.word	GL_FRAMEBUFFER_COMPLETE
	.word	.LC3
	.word	.LC2
	.word	.LC1
	.size	gl_tex_create, .-gl_tex_create
	.comm	MPGL_CAP_FB,4,4
	.comm	GL_UNPACK_ALIGNMENT,4,4
	.comm	GL_TEXTURE_WRAP_T,4,4
	.comm	GL_TEXTURE_WRAP_S,4,4
	.comm	GL_TEXTURE_WRAP_R,4,4
	.comm	GL_TEXTURE_MIN_FILTER,4,4
	.comm	GL_TEXTURE_MAG_FILTER,4,4
	.comm	GL_TEXTURE_2D,4,4
	.comm	GL_REPEAT,4,4
	.comm	GL_NEAREST,4,4
	.comm	GL_LINEAR,4,4
	.comm	GL_FRAMEBUFFER_COMPLETE,4,4
	.comm	GL_FRAMEBUFFER,4,4
	.comm	GL_COLOR_ATTACHMENT0,4,4
	.comm	GL_CLAMP_TO_EDGE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
