	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_serial_transaction             ## -- Begin function serial_transaction
	.p2align	4, 0x90
_serial_transaction:                    ## @serial_transaction
	.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	_isLeftHand@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	movq	_ROWS_PER_HAND@GOTPCREL(%rip), %r14
	movslq	(%r14), %rbx
	xorl	%eax, %eax
	callq	_serial_update_buffers
	movq	%rax, %rcx
	movl	$1, %eax
	testq	%rcx, %rcx
	jne	LBB0_4
## %bb.1:
	cmpl	$0, (%r14)
	movl	$0, %eax
	jle	LBB0_4
## %bb.2:
	testq	%r15, %r15
	movq	_serial_slave_buffer@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	_matrix@GOTPCREL(%rip), %rax
	cmoveq	%r15, %rbx
	shlq	$2, %rbx
	addq	(%rax), %rbx
	xorl	%eax, %eax
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rcx,%rdx,4), %esi
	movl	%esi, (%rbx,%rdx,4)
	incq	%rdx
	movslq	(%r14), %rsi
	cmpq	%rsi, %rdx
	jl	LBB0_3
LBB0_4:
                                        ## kill: def $eax killed $eax killed $rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_isLeftHand,8,3                 ## @isLeftHand
	.comm	_ROWS_PER_HAND,4,2              ## @ROWS_PER_HAND
	.comm	_serial_slave_buffer,8,3        ## @serial_slave_buffer
	.comm	_matrix,8,3                     ## @matrix
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_serial_transaction             ; -- Begin function serial_transaction
	.p2align	2
_serial_transaction:                    ; @serial_transaction
	.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, _isLeftHand@GOTPAGE
Lloh1:
	ldr	x8, [x8, _isLeftHand@GOTPAGEOFF]
Lloh2:
	ldr	x20, [x8]
Lloh3:
	adrp	x19, _ROWS_PER_HAND@GOTPAGE
Lloh4:
	ldr	x19, [x19, _ROWS_PER_HAND@GOTPAGEOFF]
	ldrsw	x21, [x19]
	bl	_serial_update_buffers
	cbz	x0, LBB0_2
; %bb.1:
	mov	w0, #1
	b	LBB0_6
LBB0_2:
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.3:
	mov	x8, #0
Lloh5:
	adrp	x9, _serial_slave_buffer@GOTPAGE
Lloh6:
	ldr	x9, [x9, _serial_slave_buffer@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
Lloh8:
	adrp	x10, _matrix@GOTPAGE
Lloh9:
	ldr	x10, [x10, _matrix@GOTPAGEOFF]
Lloh10:
	ldr	x10, [x10]
	cmp	x20, #0
	csel	x11, xzr, x21, eq
	add	x10, x10, x11, lsl #2
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	lsl	x11, x8, #2
	ldr	w12, [x9, x11]
	str	w12, [x10, x11]
	add	x8, x8, #1
	ldrsw	x11, [x19]
	cmp	x8, x11
	b.lt	LBB0_4
LBB0_5:
	mov	w0, #0
LBB0_6:
	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 AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_isLeftHand,8,3                 ; @isLeftHand
	.comm	_ROWS_PER_HAND,4,2              ; @ROWS_PER_HAND
	.comm	_serial_slave_buffer,8,3        ; @serial_slave_buffer
	.comm	_matrix,8,3                     ; @matrix
.subsections_via_symbols
