	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_glfwUpdateGamepadMappings      ## -- Begin function glfwUpdateGamepadMappings
	.p2align	4, 0x90
_glfwUpdateGamepadMappings:             ## @glfwUpdateGamepadMappings
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$1048, %rsp                     ## imm = 0x418
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	xorl	%edi, %edi
	testq	%r13, %r13
	setne	%dil
	callq	_assert
	movq	_GLFW_FALSE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	__GLFW_REQUIRE_INIT_OR_RETURN
	movb	(%r13), %al
	testb	%al, %al
	je	LBB0_9
## %bb.1:
	leaq	L_.str(%rip), %r14
	leaq	-1072(%rbp), %r15
	movq	__glfw@GOTPCREL(%rip), %r12
	jmp	LBB0_2
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	-1080(%rbp), %rcx
	movq	%rcx, (%rax)
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_2 Depth=1
	addq	%rbx, %r13
	movzbl	(%r13), %eax
	testb	%al, %al
	je	LBB0_9
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	leal	-48(%rax), %ecx
	cmpb	$10, %cl
	jb	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	addb	$-65, %al
	cmpb	$37, %al
	ja	LBB0_17
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movzbl	%al, %eax
	movabsq	$270582939711, %rcx             ## imm = 0x3F0000003F
	btq	%rax, %rcx
	jae	LBB0_17
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r13, %rdi
	movq	%r14, %rsi
	callq	_strcspn
	movq	%rax, %rbx
	cmpq	$1023, %rax                     ## imm = 0x3FF
	ja	LBB0_18
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	$0, -1080(%rbp)
	movq	%r15, %rdi
	movq	%r13, %rsi
	movq	%rbx, %rdx
	callq	_memcpy
	movb	$0, -1072(%rbp,%rbx)
	leaq	-1080(%rbp), %rdi
	movq	%r15, %rsi
	callq	_parseMapping
	testq	%rax, %rax
	je	LBB0_18
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	-1080(%rbp), %edi
	callq	_findMapping
	testq	%rax, %rax
	jne	LBB0_8
## %bb.16:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r12), %eax
	leal	1(%rax), %ecx
	movl	%ecx, (%r12)
	movq	16(%r12), %rdi
	leal	8(,%rax,8), %esi
	callq	_realloc
	movq	%rax, 16(%r12)
	movslq	(%r12), %rcx
	movq	-1080(%rbp), %rdx
	movq	%rdx, -8(%rax,%rcx,8)
	jmp	LBB0_18
LBB0_17:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	%r13, %rdi
	movq	%r14, %rsi
	callq	_strcspn
	movq	%rax, %rbx
	addq	%r13, %rbx
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_strspn
	movslq	%eax, %r13
	jmp	LBB0_18
LBB0_9:
	movq	_GLFW_JOYSTICK_LAST@GOTPCREL(%rip), %r14
	movl	(%r14), %eax
	testl	%eax, %eax
	js	LBB0_14
## %bb.10:
	movq	$-1, %r15
	xorl	%ebx, %ebx
	movq	__glfw@GOTPCREL(%rip), %r12
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_11 Depth=1
	movslq	%eax, %rcx
	incq	%r15
	addq	$16, %rbx
	cmpq	%rcx, %r15
	jge	LBB0_14
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r12), %r13
	cmpq	$0, 8(%r13,%rbx)
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	leaq	(%rbx,%r13), %rdi
	callq	_findValidMapping
	movl	%eax, (%r13,%rbx)
	movl	(%r14), %eax
	jmp	LBB0_13
LBB0_14:
	movq	_GLFW_TRUE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_15
## %bb.19:
	addq	$1048, %rsp                     ## imm = 0x418
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_GLFW_FALSE,4,2                 ## @GLFW_FALSE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"\r\n"

	.comm	__glfw,24,3                     ## @_glfw
	.comm	_GLFW_JOYSTICK_LAST,4,2         ## @GLFW_JOYSTICK_LAST
	.comm	_GLFW_TRUE,4,2                  ## @GLFW_TRUE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_glfwUpdateGamepadMappings      ; -- Begin function glfwUpdateGamepadMappings
	.p2align	2
_glfwUpdateGamepadMappings:             ; @glfwUpdateGamepadMappings
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w27, -72
	.cfi_offset w28, -80
	sub	sp, sp, #1040
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
	cmp	x0, #0
	cset	w0, ne
	bl	_assert
Lloh3:
	adrp	x8, _GLFW_FALSE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GLFW_FALSE@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	__GLFW_REQUIRE_INIT_OR_RETURN
	ldrb	w8, [x19]
	cbz	w8, LBB0_12
; %bb.1:
	add	x22, sp, #8
Lloh6:
	adrp	x23, __glfw@GOTPAGE
Lloh7:
	ldr	x23, [x23, __glfw@GOTPAGEOFF]
	mov	w24, #1
Lloh8:
	adrp	x20, l_.str@PAGE
Lloh9:
	add	x20, x20, l_.str@PAGEOFF
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	sub	w9, w8, #48
	and	w9, w9, #0xff
	cmp	w9, #10
	b.lo	LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	and	w8, w8, #0xff
	sub	w8, w8, #65
	cmp	w8, #37
	b.hi	LBB0_11
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	lsl	x8, x24, x8
	tst	x8, #0x3f0000003f
	b.eq	LBB0_11
LBB0_5:                                 ;   in Loop: Header=BB0_2 Depth=1
	mov	x0, x19
	mov	x1, x20
	bl	_strcspn
	mov	x21, x0
	cmp	x0, #1023
	b.hi	LBB0_10
; %bb.6:                                ;   in Loop: Header=BB0_2 Depth=1
	str	xzr, [sp]
	add	x0, sp, #8
	mov	x1, x19
	mov	x2, x21
	bl	_memcpy
	strb	wzr, [x22, x21]
	mov	x0, sp
	add	x1, sp, #8
	bl	_parseMapping
	cbz	x0, LBB0_10
; %bb.7:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	w0, [sp]
	bl	_findMapping
	cbz	x0, LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x8, [sp]
	str	x8, [x0]
	b	LBB0_10
LBB0_9:                                 ;   in Loop: Header=BB0_2 Depth=1
	ldr	w8, [x23]
	add	w8, w8, #1
	str	w8, [x23]
	ldr	x0, [x23, #16]
	lsl	w1, w8, #3
	bl	_realloc
	str	x0, [x23, #16]
	ldrsw	x8, [x23]
	add	x8, x0, x8, lsl #3
	ldr	x9, [sp]
	stur	x9, [x8, #-8]
LBB0_10:                                ;   in Loop: Header=BB0_2 Depth=1
	add	x19, x19, x21
	ldrb	w8, [x19]
	cbnz	w8, LBB0_2
	b	LBB0_12
LBB0_11:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x0, x19
	mov	x1, x20
	bl	_strcspn
	add	x19, x19, x0
	mov	x0, x19
	mov	x1, x20
	bl	_strspn
	add	x19, x19, w0, sxtw
	ldrb	w8, [x19]
	cbnz	w8, LBB0_2
LBB0_12:
Lloh10:
	adrp	x20, _GLFW_JOYSTICK_LAST@GOTPAGE
Lloh11:
	ldr	x20, [x20, _GLFW_JOYSTICK_LAST@GOTPAGEOFF]
	ldr	w8, [x20]
	tbnz	w8, #31, LBB0_17
; %bb.13:
	mov	x21, #0
	mov	x22, #-1
Lloh12:
	adrp	x23, __glfw@GOTPAGE
Lloh13:
	ldr	x23, [x23, __glfw@GOTPAGEOFF]
	b	LBB0_15
LBB0_14:                                ;   in Loop: Header=BB0_15 Depth=1
	add	x22, x22, #1
	add	x21, x21, #16
	cmp	x22, w8, sxtw
	b.ge	LBB0_17
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x23, #8]
	add	x19, x9, x21
	ldr	x9, [x19, #8]
	cbz	x9, LBB0_14
; %bb.16:                               ;   in Loop: Header=BB0_15 Depth=1
	mov	x0, x19
	bl	_findValidMapping
	str	w0, [x19]
	ldr	w8, [x20]
	b	LBB0_14
LBB0_17:
Lloh14:
	adrp	x8, _GLFW_TRUE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _GLFW_TRUE@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	ldur	x8, [x29, #-72]
Lloh17:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh18:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh19:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_19
; %bb.18:
	add	sp, sp, #1040
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_19:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_GLFW_FALSE,4,2                 ; @GLFW_FALSE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"\r\n"

	.comm	__glfw,24,3                     ; @_glfw
	.comm	_GLFW_JOYSTICK_LAST,4,2         ; @GLFW_JOYSTICK_LAST
	.comm	_GLFW_TRUE,4,2                  ; @GLFW_TRUE
.subsections_via_symbols
