	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_matrix_scan_user               ## -- Begin function matrix_scan_user
	.p2align	4, 0x90
_matrix_scan_user:                      ## @matrix_scan_user
	.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	_layer_state@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_biton32
	cmpl	%eax, _matrix_scan_user.old_layer(%rip)
	je	LBB0_7
## %bb.1:
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_2
## %bb.3:
	cmpl	$1, %ebx
	jne	LBB0_6
## %bb.4:
	xorl	%r14d, %r14d
	movl	$18, %edi
	jmp	LBB0_5
LBB0_2:
	movl	$255, %r14d
	movl	$1, %edi
LBB0_5:
	callq	_rgblight_mode
	movl	%r14d, %edi
	movl	$255, %esi
	movl	$255, %edx
	callq	_rgblight_setrgb
LBB0_6:
	movl	%ebx, _matrix_scan_user.old_layer(%rip)
LBB0_7:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__DATA,__data
	.p2align	2                               ## @matrix_scan_user.old_layer
_matrix_scan_user.old_layer:
	.long	255                             ## 0xff

	.comm	_layer_state,4,2                ## @layer_state
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_matrix_scan_user               ; -- Begin function matrix_scan_user
	.p2align	2
_matrix_scan_user:                      ; @matrix_scan_user
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
Lloh0:
	adrp	x8, _layer_state@GOTPAGE
Lloh1:
	ldr	x8, [x8, _layer_state@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_biton32
	adrp	x21, _matrix_scan_user.old_layer@PAGE
	ldr	w8, [x21, _matrix_scan_user.old_layer@PAGEOFF]
	cmp	w8, w0
	b.eq	LBB0_7
; %bb.1:
	mov	x19, x0
	cbz	w0, LBB0_4
; %bb.2:
	cmp	w19, #1
	b.ne	LBB0_6
; %bb.3:
	mov	w20, #0
	mov	w0, #18
	b	LBB0_5
LBB0_4:
	mov	w20, #255
	mov	w0, #1
LBB0_5:
	bl	_rgblight_mode
	mov	x0, x20
	mov	w1, #255
	mov	w2, #255
	bl	_rgblight_setrgb
LBB0_6:
	str	w19, [x21, _matrix_scan_user.old_layer@PAGEOFF]
LBB0_7:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.section	__DATA,__data
	.p2align	2                               ; @matrix_scan_user.old_layer
_matrix_scan_user.old_layer:
	.long	255                             ; 0xff

	.comm	_layer_state,4,2                ; @layer_state
.subsections_via_symbols
