	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function input_autoconfigure_joypad_try_from_conf
_input_autoconfigure_joypad_try_from_conf: ## @input_autoconfigure_joypad_try_from_conf
	.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	$312, %rsp                      ## imm = 0x138
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movl	$0, -340(%rbp)
	movb	$0, -336(%rbp)
	movb	$0, -304(%rbp)
	leaq	L_.str(%rip), %rsi
	leaq	-304(%rbp), %rdx
	movl	$256, %ecx                      ## imm = 0x100
	callq	_config_get_array
	leaq	L_.str.1(%rip), %rsi
	leaq	-336(%rbp), %rdx
	movq	%rbx, %rdi
	movl	$32, %ecx
	callq	_config_get_array
	leaq	L_.str.2(%rip), %rsi
	leaq	-340(%rbp), %r12
	movq	%rbx, %rdi
	movq	%r12, %rdx
	callq	_config_get_int
	xorl	%r15d, %r15d
	movl	$0, %r13d
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movl	-340(%rbp), %r13d
LBB0_2:
	leaq	L_.str.3(%rip), %rsi
	movq	%rbx, %rdi
	movq	%r12, %rdx
	callq	_config_get_int
	cmpl	%r13d, (%r14)
	jne	LBB0_6
## %bb.3:
	movq	_BLISSBOX_VID@GOTPCREL(%rip), %rdx
	xorl	%ecx, %ecx
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movl	-340(%rbp), %ecx
LBB0_5:
	cmpl	(%rdx), %r13d
	sete	%dil
	movq	_BLISSBOX_PID@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	cmovel	%edx, %ecx
	movl	4(%r14), %esi
	cmpl	%ecx, %esi
	setne	%cl
	testl	%r13d, %r13d
	sete	%bl
	testl	%esi, %esi
	sete	%al
	orb	%bl, %al
	orb	%dil, %al
	orb	%cl, %al
	notb	%al
	cmpl	%edx, %esi
	setne	%cl
	andb	%al, %cl
	movzbl	%cl, %eax
	leal	(%rax,%rax,2), %r15d
LBB0_6:
	movq	8(%r14), %rdi
	callq	_string_is_empty
	testl	%eax, %eax
	jne	LBB0_9
## %bb.7:
	leaq	-304(%rbp), %rdi
	callq	_string_is_empty
	testl	%eax, %eax
	jne	LBB0_9
## %bb.8:
	movq	8(%r14), %rsi
	leaq	-304(%rbp), %rdi
	callq	_string_is_equal
	leal	2(%r15), %ecx
	testq	%rax, %rax
	cmovel	%r15d, %ecx
	movl	%ecx, %r15d
LBB0_9:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_11
## %bb.10:
	movl	%r15d, %eax
	addq	$312, %rsp                      ## imm = 0x138
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"input_device"

L_.str.1:                               ## @.str.1
	.asciz	"input_driver"

L_.str.2:                               ## @.str.2
	.asciz	"input_vendor_id"

L_.str.3:                               ## @.str.3
	.asciz	"input_product_id"

	.comm	_BLISSBOX_VID,4,2               ## @BLISSBOX_VID
	.comm	_BLISSBOX_PID,4,2               ## @BLISSBOX_PID
	.no_dead_strip	_input_autoconfigure_joypad_try_from_conf
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function input_autoconfigure_joypad_try_from_conf
_input_autoconfigure_joypad_try_from_conf: ; @input_autoconfigure_joypad_try_from_conf
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #352
	.cfi_def_cfa_offset 352
	stp	x22, x21, [sp, #304]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #320]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #336]            ; 16-byte Folded Spill
	add	x29, sp, #336
	.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, x1
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-40]
	str	wzr, [sp, #4]
	strb	wzr, [sp, #8]
	strb	wzr, [sp, #40]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	add	x2, sp, #40
	mov	w3, #256
	bl	_config_get_array
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x2, sp, #8
	mov	x0, x20
	mov	w3, #32
	bl	_config_get_array
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	add	x2, sp, #4
	mov	x0, x20
	bl	_config_get_int
	ldr	w8, [sp, #4]
	cmp	x0, #0
	csel	w21, wzr, w8, eq
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	add	x2, sp, #4
	mov	x0, x20
	bl	_config_get_int
	mov	w20, #0
	ldr	w8, [x19]
	cmp	w8, w21
	b.ne	LBB0_2
; %bb.1:
Lloh11:
	adrp	x8, _BLISSBOX_VID@GOTPAGE
Lloh12:
	ldr	x8, [x8, _BLISSBOX_VID@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
Lloh14:
	adrp	x9, _BLISSBOX_PID@GOTPAGE
Lloh15:
	ldr	x9, [x9, _BLISSBOX_PID@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	ldr	w10, [sp, #4]
	cmp	x0, #0
	csel	w10, wzr, w10, eq
	cmp	w21, w8
	csel	w10, w9, w10, eq
	ldr	w11, [x19, #4]
	cmp	w11, w9
	ccmp	w21, w8, #4, ne
	ccmp	w21, #0, #4, ne
	ccmp	w11, w10, #0, ne
	ccmp	w11, #0, #4, eq
	mov	w8, #3
	csel	w20, wzr, w8, eq
LBB0_2:
	ldr	x0, [x19, #8]
	bl	_string_is_empty
	cbnz	w0, LBB0_5
; %bb.3:
	add	x0, sp, #40
	bl	_string_is_empty
	cbnz	w0, LBB0_5
; %bb.4:
	ldr	x1, [x19, #8]
	add	x0, sp, #40
	bl	_string_is_equal
	add	w8, w20, #2
	cmp	x0, #0
	csel	w20, w20, w8, eq
LBB0_5:
	ldur	x8, [x29, #-40]
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_7
; %bb.6:
	mov	x0, x20
	ldp	x29, x30, [sp, #336]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #320]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #304]            ; 16-byte Folded Reload
	add	sp, sp, #352
	ret
LBB0_7:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"input_device"

l_.str.1:                               ; @.str.1
	.asciz	"input_driver"

l_.str.2:                               ; @.str.2
	.asciz	"input_vendor_id"

l_.str.3:                               ; @.str.3
	.asciz	"input_product_id"

	.comm	_BLISSBOX_VID,4,2               ; @BLISSBOX_VID
	.comm	_BLISSBOX_PID,4,2               ; @BLISSBOX_PID
	.no_dead_strip	_input_autoconfigure_joypad_try_from_conf
.subsections_via_symbols
