	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function xinput_joypad_rumble
_xinput_joypad_rumble:                  ## @xinput_joypad_rumble
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdx, %r14
	movl	%esi, %ebx
	callq	_pad_index_to_xuser_index
	cmpl	$-1, %eax
	je	LBB0_1
## %bb.2:
	movq	_RETRO_RUMBLE_STRONG@GOTPCREL(%rip), %rcx
	cmpl	%ebx, (%rcx)
	jne	LBB0_4
## %bb.3:
	movq	_g_xinput_rumble_states@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movslq	%eax, %rsi
	movq	%rsi, %rdx
	shlq	$4, %rdx
	movq	%r14, 8(%rcx,%rdx)
	jmp	LBB0_7
LBB0_1:
	xorl	%eax, %eax
	jmp	LBB0_8
LBB0_4:
	movq	_RETRO_RUMBLE_WEAK@GOTPCREL(%rip), %rcx
	cmpl	%ebx, (%rcx)
	jne	LBB0_5
## %bb.6:
	movq	_g_xinput_rumble_states@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movslq	%eax, %rsi
	movq	%rsi, %rdx
	shlq	$4, %rdx
	movq	%r14, (%rcx,%rdx)
	jmp	LBB0_7
LBB0_5:
	movslq	%eax, %rsi
LBB0_7:
	movq	_g_xinput_rumble_states@GOTPCREL(%rip), %rcx
	shlq	$4, %rsi
	addq	(%rcx), %rsi
	movl	%eax, %edi
	callq	_g_XInputSetState
	movq	%rax, %rcx
	xorl	%eax, %eax
	testq	%rcx, %rcx
	sete	%al
LBB0_8:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RETRO_RUMBLE_STRONG,4,2        ## @RETRO_RUMBLE_STRONG
	.comm	_g_xinput_rumble_states,8,3     ## @g_xinput_rumble_states
	.comm	_RETRO_RUMBLE_WEAK,4,2          ## @RETRO_RUMBLE_WEAK
	.comm	_dinput_joypad,8,3              ## @dinput_joypad
	.no_dead_strip	_xinput_joypad_rumble
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function xinput_joypad_rumble
_xinput_joypad_rumble:                  ; @xinput_joypad_rumble
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x2
	mov	x20, x1
	bl	_pad_index_to_xuser_index
                                        ; kill: def $w0 killed $w0 def $x0
	cmn	w0, #1
	b.eq	LBB0_3
; %bb.1:
Lloh0:
	adrp	x8, _RETRO_RUMBLE_STRONG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RETRO_RUMBLE_STRONG@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x8]
Lloh3:
	adrp	x8, _g_xinput_rumble_states@GOTPAGE
Lloh4:
	ldr	x8, [x8, _g_xinput_rumble_states@GOTPAGEOFF]
	cmp	w9, w20
	b.ne	LBB0_4
; %bb.2:
	ldr	x10, [x8]
	sxtw	x9, w0
	add	x10, x10, w0, sxtw #4
	str	x19, [x10, #8]
	b	LBB0_7
LBB0_3:
	mov	w0, #0
	b	LBB0_8
LBB0_4:
Lloh5:
	adrp	x9, _RETRO_RUMBLE_WEAK@GOTPAGE
Lloh6:
	ldr	x9, [x9, _RETRO_RUMBLE_WEAK@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	cmp	w9, w20
	b.ne	LBB0_6
; %bb.5:
	ldr	x10, [x8]
	mov	x11, x0
	sxtw	x9, w11
	sbfiz	x11, x11, #4, #32
	str	x19, [x10, x11]
	b	LBB0_7
LBB0_6:
	mov	x9, x0
	sxtw	x9, w9
LBB0_7:
	ldr	x8, [x8]
	add	x1, x8, x9, lsl #4
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_g_XInputSetState
	cmp	x0, #0
	cset	w0, eq
LBB0_8:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_RETRO_RUMBLE_STRONG,4,2        ; @RETRO_RUMBLE_STRONG
	.comm	_g_xinput_rumble_states,8,3     ; @g_xinput_rumble_states
	.comm	_RETRO_RUMBLE_WEAK,4,2          ; @RETRO_RUMBLE_WEAK
	.comm	_dinput_joypad,8,3              ; @dinput_joypad
	.no_dead_strip	_xinput_joypad_rumble
.subsections_via_symbols
