	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function createSurface
_createSurface:                         ## @createSurface
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	_mir_buffer_usage_hardware@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	xorl	%eax, %eax
	callq	_findValidPixelFormat
	movq	_mir_pixel_format_invalid@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	movq	_GLFW_PLATFORM_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	__glfwInputError
	jmp	LBB0_5
LBB0_2:
	movq	__glfw@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	movl	4(%r15), %edx
	movl	8(%r15), %esi
	movq	%rax, %rcx
	callq	_mir_connection_create_spec_for_normal_surface
	movq	%rax, %rbx
	movq	%rax, %rdi
	movl	%r14d, %esi
	callq	_mir_surface_spec_set_buffer_usage
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_mir_surface_spec_set_name
	movq	%rbx, %rdi
	callq	_mir_surface_create_sync
	movl	%eax, (%r15)
	movq	%rbx, %rdi
	callq	_mir_surface_spec_release
	movl	(%r15), %edi
	callq	_mir_surface_is_valid
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	movl	(%r15), %edi
	movq	_addNewEvent@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdx
	callq	_mir_surface_set_event_handler
	movq	_GL_TRUE@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_4:
	movq	_GLFW_PLATFORM_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	(%r15), %edi
	callq	_mir_surface_get_error_message
	leaq	L_.str.2(%rip), %rsi
	movl	%ebx, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	__glfwInputError
LBB0_5:
	movq	_GL_FALSE@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_mir_buffer_usage_hardware,4,2  ## @mir_buffer_usage_hardware
	.comm	_mir_pixel_format_invalid,8,3   ## @mir_pixel_format_invalid
	.comm	_GLFW_PLATFORM_ERROR,4,2        ## @GLFW_PLATFORM_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Mir: Unable to find a correct pixel format"

	.comm	_GL_FALSE,4,2                   ## @GL_FALSE
	.comm	__glfw,4,2                      ## @_glfw
L_.str.1:                               ## @.str.1
	.asciz	"MirSurface"

L_.str.2:                               ## @.str.2
	.asciz	"Mir: Unable to create surface: %s"

	.comm	_addNewEvent,4,2                ## @addNewEvent
	.comm	_GL_TRUE,4,2                    ## @GL_TRUE
	.no_dead_strip	_createSurface
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function createSurface
_createSurface:                         ; @createSurface
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
Lloh0:
	adrp	x8, _mir_buffer_usage_hardware@GOTPAGE
Lloh1:
	ldr	x8, [x8, _mir_buffer_usage_hardware@GOTPAGEOFF]
Lloh2:
	ldr	w20, [x8]
	bl	_findValidPixelFormat
Lloh3:
	adrp	x8, _mir_pixel_format_invalid@GOTPAGE
Lloh4:
	ldr	x8, [x8, _mir_pixel_format_invalid@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_2
; %bb.1:
Lloh6:
	adrp	x8, _GLFW_PLATFORM_ERROR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _GLFW_PLATFORM_ERROR@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_5
LBB0_2:
	mov	x3, x0
Lloh11:
	adrp	x8, __glfw@GOTPAGE
Lloh12:
	ldr	x8, [x8, __glfw@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	ldp	w2, w1, [x19, #4]
	bl	_mir_connection_create_spec_for_normal_surface
	mov	x21, x0
	mov	x1, x20
	bl	_mir_surface_spec_set_buffer_usage
Lloh14:
	adrp	x1, l_.str.1@PAGE
Lloh15:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x21
	bl	_mir_surface_spec_set_name
	mov	x0, x21
	bl	_mir_surface_create_sync
	str	w0, [x19]
	mov	x0, x21
	bl	_mir_surface_spec_release
	ldr	w0, [x19]
	bl	_mir_surface_is_valid
	cbz	w0, LBB0_4
; %bb.3:
	ldr	w0, [x19]
Lloh16:
	adrp	x8, _addNewEvent@GOTPAGE
Lloh17:
	ldr	x8, [x8, _addNewEvent@GOTPAGEOFF]
Lloh18:
	ldr	w1, [x8]
	mov	x2, x19
	bl	_mir_surface_set_event_handler
Lloh19:
	adrp	x8, _GL_TRUE@GOTPAGE
Lloh20:
	ldr	x8, [x8, _GL_TRUE@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:
Lloh21:
	adrp	x8, _GLFW_PLATFORM_ERROR@GOTPAGE
Lloh22:
	ldr	x8, [x8, _GLFW_PLATFORM_ERROR@GOTPAGEOFF]
Lloh23:
	ldr	w20, [x8]
	ldr	w0, [x19]
	bl	_mir_surface_get_error_message
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh24:
	adrp	x1, l_.str.2@PAGE
Lloh25:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
LBB0_5:
	bl	__glfwInputError
Lloh26:
	adrp	x8, _GL_FALSE@GOTPAGE
Lloh27:
	ldr	x8, [x8, _GL_FALSE@GOTPAGEOFF]
LBB0_6:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_mir_buffer_usage_hardware,4,2  ; @mir_buffer_usage_hardware
	.comm	_mir_pixel_format_invalid,8,3   ; @mir_pixel_format_invalid
	.comm	_GLFW_PLATFORM_ERROR,4,2        ; @GLFW_PLATFORM_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Mir: Unable to find a correct pixel format"

	.comm	_GL_FALSE,4,2                   ; @GL_FALSE
	.comm	__glfw,4,2                      ; @_glfw
l_.str.1:                               ; @.str.1
	.asciz	"MirSurface"

l_.str.2:                               ; @.str.2
	.asciz	"Mir: Unable to create surface: %s"

	.comm	_addNewEvent,4,2                ; @addNewEvent
	.comm	_GL_TRUE,4,2                    ; @GL_TRUE
	.no_dead_strip	_createSurface
.subsections_via_symbols
