	.file	"extr_x11_window.c__glfwPlatformCreateWindow.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	_glfwPlatformCreateWindow
	.type	_glfwPlatformCreateWindow, @function
_glfwPlatformCreateWindow:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	mov	r14, rsi
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	mov	r13, rcx
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rdx
	sub	rsp, 40
	.cfi_def_cfa_offset 80
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 24[rsp], rax
	xor	eax, eax
	mov	rax, QWORD PTR GLFW_NO_API[rip]
	cmp	QWORD PTR [rdx], rax
	je	.L2
	mov	rax, QWORD PTR 8[rdx]
	cmp	rax, QWORD PTR GLFW_NATIVE_CONTEXT_API[rip]
	je	.L20
	cmp	rax, QWORD PTR GLFW_EGL_CONTEXT_API[rip]
	je	.L21
	cmp	rax, QWORD PTR GLFW_OSMESA_CONTEXT_API[rip]
	je	.L22
.L9:
	mov	ecx, DWORD PTR 12[rsp]
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L20:
	xor	eax, eax
	call	_glfwInitGLX@PLT
	test	eax, eax
	je	.L18
	lea	rcx, 16[rsp]
	lea	r8, 12[rsp]
	mov	rdx, r13
	mov	rsi, rbp
	mov	rdi, r14
	call	_glfwChooseVisualGLX@PLT
	test	eax, eax
	je	.L18
.L6:
	mov	rax, QWORD PTR GLFW_NO_API[rip]
	cmp	QWORD PTR 0[rbp], rax
	je	.L2
	mov	rax, QWORD PTR GLFW_OSMESA_CONTEXT_API[rip]
	cmp	QWORD PTR 8[rbp], rax
	jne	.L9
.L2:
	mov	esi, DWORD PTR _glfw[rip+4]
	mov	edi, DWORD PTR _glfw[rip]
	call	DefaultVisual@PLT
	mov	esi, DWORD PTR _glfw[rip+4]
	mov	edi, DWORD PTR _glfw[rip]
	mov	QWORD PTR 16[rsp], rax
	call	DefaultDepth@PLT
	mov	DWORD PTR 12[rsp], eax
	mov	ecx, eax
.L10:
	mov	rdx, QWORD PTR 16[rsp]
	mov	rsi, r14
	mov	rdi, r12
	call	createNativeWindow@PLT
	test	eax, eax
	je	.L18
	mov	rax, QWORD PTR GLFW_NO_API[rip]
	cmp	QWORD PTR 0[rbp], rax
	je	.L12
	mov	rax, QWORD PTR 8[rbp]
	cmp	rax, QWORD PTR GLFW_NATIVE_CONTEXT_API[rip]
	je	.L23
	cmp	rax, QWORD PTR GLFW_EGL_CONTEXT_API[rip]
	je	.L24
	cmp	rax, QWORD PTR GLFW_OSMESA_CONTEXT_API[rip]
	je	.L25
.L12:
	cmp	QWORD PTR [r12], 0
	jne	.L26
.L15:
	mov	edi, DWORD PTR _glfw[rip]
	call	XFlush@PLT
	mov	eax, DWORD PTR GLFW_TRUE[rip]
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L21:
	xor	eax, eax
	call	_glfwInitEGL@PLT
	test	eax, eax
	je	.L18
	lea	rcx, 16[rsp]
	lea	r8, 12[rsp]
	mov	rdx, r13
	mov	rsi, rbp
	mov	rdi, r14
	call	_glfwChooseVisualEGL@PLT
	test	eax, eax
	jne	.L6
	.p2align 4,,10
	.p2align 3
.L18:
	mov	eax, DWORD PTR GLFW_FALSE[rip]
.L1:
	mov	rdx, QWORD PTR 24[rsp]
	xor	rdx, QWORD PTR fs:40
	jne	.L27
	add	rsp, 40
	.cfi_remember_state
	.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
.L26:
	.cfi_restore_state
	mov	rdi, r12
	call	_glfwPlatformShowWindow@PLT
	mov	rdi, r12
	call	updateWindowMode@PLT
	mov	rdi, r12
	call	acquireMonitor@PLT
	jmp	.L15
	.p2align 4,,10
	.p2align 3
.L22:
	xor	eax, eax
	call	_glfwInitOSMesa@PLT
	test	eax, eax
	jne	.L6
	jmp	.L18
	.p2align 4,,10
	.p2align 3
.L23:
	mov	rdx, r13
	mov	rsi, rbp
	mov	rdi, r12
	call	_glfwCreateContextGLX@PLT
	test	eax, eax
	jne	.L12
	jmp	.L18
	.p2align 4,,10
	.p2align 3
.L24:
	mov	rdx, r13
	mov	rsi, rbp
	mov	rdi, r12
	call	_glfwCreateContextEGL@PLT
	test	eax, eax
	jne	.L12
	jmp	.L18
	.p2align 4,,10
	.p2align 3
.L25:
	mov	rdx, r13
	mov	rsi, rbp
	mov	rdi, r12
	call	_glfwCreateContextOSMesa@PLT
	test	eax, eax
	jne	.L12
	jmp	.L18
.L27:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	_glfwPlatformCreateWindow, .-_glfwPlatformCreateWindow
	.comm	_glfw,8,8
	.comm	GLFW_TRUE,4,4
	.comm	GLFW_OSMESA_CONTEXT_API,8,8
	.comm	GLFW_NO_API,8,8
	.comm	GLFW_NATIVE_CONTEXT_API,8,8
	.comm	GLFW_FALSE,4,4
	.comm	GLFW_EGL_CONTEXT_API,8,8
	.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_x11_window.c__glfwPlatformCreateWindow.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	_glfwPlatformCreateWindow
	.syntax unified
	.arm
	.fpu softvfp
	.type	_glfwPlatformCreateWindow, %function
_glfwPlatformCreateWindow:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, lr}
	ldr	r8, .L31
	ldr	ip, [r2]
	mov	r4, r2
	ldr	r2, [r8]
	mov	r7, r3
	ldr	r3, .L31+4
	sub	sp, sp, #28
	cmp	ip, r2
	mov	r5, r0
	mov	r6, r1
	ldr	r3, [r3]
	str	r3, [sp, #20]
	mov	r3,#0
	beq	.L2
	ldr	r2, .L31+8
	ldr	r3, [r4, #4]
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L23
	ldr	r2, .L31+12
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L24
	ldr	r2, .L31+16
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L25
.L9:
	ldr	r3, [sp, #16]
	b	.L10
.L23:
	bl	_glfwInitGLX
	cmp	r0, #0
	beq	.L21
	add	r3, sp, #16
	str	r3, [sp]
	mov	r2, r7
	mov	r1, r4
	mov	r0, r6
	add	r3, sp, #12
	bl	_glfwChooseVisualGLX
	cmp	r0, #0
	beq	.L21
.L6:
	ldr	r2, [r4]
	ldr	r3, [r8]
	cmp	r2, r3
	beq	.L2
	ldr	r3, .L31+16
	ldr	r2, [r4, #4]
	ldr	r3, [r3]
	cmp	r2, r3
	bne	.L9
.L2:
	ldr	r9, .L31+20
	ldm	r9, {r0, r1}
	bl	DefaultVisual
	mov	r3, r0
	ldm	r9, {r0, r1}
	str	r3, [sp, #12]
	bl	DefaultDepth
	mov	r3, r0
	str	r0, [sp, #16]
.L10:
	mov	r1, r6
	mov	r0, r5
	ldr	r2, [sp, #12]
	bl	createNativeWindow
	cmp	r0, #0
	beq	.L21
	ldr	r3, [r8]
	ldr	r2, [r4]
	cmp	r2, r3
	beq	.L12
	ldr	r2, .L31+8
	ldr	r3, [r4, #4]
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L26
	ldr	r2, .L31+12
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L27
	ldr	r2, .L31+16
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L28
.L12:
	ldr	r3, [r5]
	cmp	r3, #0
	bne	.L29
.L15:
	ldr	r3, .L31+20
	ldr	r0, [r3]
	bl	XFlush
	ldr	r3, .L31+24
	ldr	r0, [r3]
	b	.L1
.L24:
	bl	_glfwInitEGL
	cmp	r0, #0
	beq	.L21
	add	r3, sp, #16
	str	r3, [sp]
	mov	r2, r7
	mov	r1, r4
	mov	r0, r6
	add	r3, sp, #12
	bl	_glfwChooseVisualEGL
	cmp	r0, #0
	bne	.L6
.L21:
	ldr	r3, .L31+28
	ldr	r0, [r3]
.L1:
	ldr	r3, .L31+4
	ldr	r2, [r3]
	ldr	r3, [sp, #20]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L30
	add	sp, sp, #28
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, pc}
.L29:
	mov	r0, r5
	bl	_glfwPlatformShowWindow
	mov	r0, r5
	bl	updateWindowMode
	mov	r0, r5
	bl	acquireMonitor
	b	.L15
.L25:
	bl	_glfwInitOSMesa
	cmp	r0, #0
	bne	.L6
	b	.L21
.L26:
	mov	r2, r7
	mov	r1, r4
	mov	r0, r5
	bl	_glfwCreateContextGLX
	cmp	r0, #0
	bne	.L12
	b	.L21
.L27:
	mov	r2, r7
	mov	r1, r4
	mov	r0, r5
	bl	_glfwCreateContextEGL
	cmp	r0, #0
	bne	.L12
	b	.L21
.L28:
	mov	r2, r7
	mov	r1, r4
	mov	r0, r5
	bl	_glfwCreateContextOSMesa
	cmp	r0, #0
	bne	.L12
	b	.L21
.L30:
	bl	__stack_chk_fail
.L32:
	.align	2
.L31:
	.word	GLFW_NO_API
	.word	.LC0
	.word	GLFW_NATIVE_CONTEXT_API
	.word	GLFW_EGL_CONTEXT_API
	.word	GLFW_OSMESA_CONTEXT_API
	.word	_glfw
	.word	GLFW_TRUE
	.word	GLFW_FALSE
	.size	_glfwPlatformCreateWindow, .-_glfwPlatformCreateWindow
	.comm	_glfw,8,4
	.comm	GLFW_TRUE,4,4
	.comm	GLFW_OSMESA_CONTEXT_API,4,4
	.comm	GLFW_NO_API,4,4
	.comm	GLFW_NATIVE_CONTEXT_API,4,4
	.comm	GLFW_FALSE,4,4
	.comm	GLFW_EGL_CONTEXT_API,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
