	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function read_cols_on_row
_read_cols_on_row:                      ## @read_cols_on_row
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	(%rdi,%rsi,8), %rax
	movq	$0, (%rdi,%rsi,8)
	cmpq	$8, %rsi
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	jne	LBB0_4
## %bb.1:
	movq	_tp_pins@GOTPCREL(%rip), %rax
	movq	%rax, %r13
	movq	(%rax), %rax
	movq	(%rax), %rbx
	movq	%rbx, %rdi
	shrq	$4, %rdi
	callq	__SFR_IO8
	movq	%rax, %r12
	andl	$15, %ebx
	movq	%rbx, %rdi
	callq	__BV
	movq	_ROW_SHIFTER@GOTPCREL(%rip), %rdx
	movl	$0, %ecx
	testq	%r12, %rax
	jne	LBB0_3
## %bb.2:
	movq	(%rdx), %rcx
LBB0_3:
	orq	%rcx, (%r14,%r15,8)
	movq	(%r13), %rax
	movq	8(%rax), %rbx
	movq	%rbx, %rdi
	shrq	$4, %rdi
	movq	%rdx, %r13
	callq	__SFR_IO8
	movq	%rax, %r12
	andl	$15, %ebx
	movq	%rbx, %rdi
	callq	__BV
	movq	(%r13), %rcx
	addq	%rcx, %rcx
	testq	%r12, %rax
	movl	$0, %r13d
	cmovneq	%r13, %rcx
	orq	%rcx, (%r14,%r15,8)
	movq	_tp_pins@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	16(%rax), %rbx
	movq	%rbx, %rdi
	shrq	$4, %rdi
	callq	__SFR_IO8
	movq	%rax, %r12
	andl	$15, %ebx
	movq	%rbx, %rdi
	callq	__BV
	movq	_ROW_SHIFTER@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	shlq	$2, %rcx
	testq	%r12, %rax
	cmovneq	%r13, %rcx
	orq	(%r14,%r15,8), %rcx
	movq	%rcx, (%r14,%r15,8)
	jmp	LBB0_10
LBB0_4:
	movq	%r15, %rdi
	callq	_select_row
	movl	$5, %edi
	callq	__delay_us
	movq	_MATRIX_COLS@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_9
## %bb.5:
	xorl	%r12d, %r12d
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_6 Depth=1
	orq	%rdx, (%r14,%r15,8)
	incq	%r12
	movq	_MATRIX_COLS@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r12
	jae	LBB0_9
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	_col_pins@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax,%r12,8), %rbx
	movq	%rbx, %rdi
	shrq	$4, %rdi
	callq	__SFR_IO8
	movq	%rax, %r13
	andl	$15, %ebx
	movq	%rbx, %rdi
	callq	__BV
	movq	_ROW_SHIFTER@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
	movl	%r12d, %ecx
	shlq	%cl, %rdx
	testq	%r13, %rax
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	xorl	%edx, %edx
	jmp	LBB0_8
LBB0_9:
	movq	%r15, %rdi
	callq	_unselect_row
	movq	(%r14,%r15,8), %rcx
LBB0_10:
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	xorl	%eax, %eax
	cmpq	%rcx, %rdx
	setne	%al
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_tp_pins,8,3                    ## @tp_pins
	.comm	_ROW_SHIFTER,8,3                ## @ROW_SHIFTER
	.comm	_MATRIX_COLS,8,3                ## @MATRIX_COLS
	.comm	_col_pins,8,3                   ## @col_pins
	.no_dead_strip	_read_cols_on_row
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function read_cols_on_row
_read_cols_on_row:                      ; @read_cols_on_row
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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 w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
	lsl	x23, x1, #3
	ldr	x22, [x0, x23]
	str	xzr, [x0, x23]
	cmp	x1, #8
	b.ne	LBB0_2
; %bb.1:
Lloh0:
	adrp	x21, _tp_pins@GOTPAGE
Lloh1:
	ldr	x21, [x21, _tp_pins@GOTPAGEOFF]
	ldr	x8, [x21]
	ldr	x24, [x8]
	lsr	x0, x24, #4
	bl	__SFR_IO8
	mov	x20, x0
	and	x0, x24, #0xf
	bl	__BV
Lloh2:
	adrp	x24, _ROW_SHIFTER@GOTPAGE
Lloh3:
	ldr	x24, [x24, _ROW_SHIFTER@GOTPAGEOFF]
	ldr	x8, [x24]
	tst	x0, x20
	csel	x8, x8, xzr, eq
	ldr	x9, [x19, x23]
	orr	x8, x8, x9
	str	x8, [x19, x23]
	ldr	x8, [x21]
	ldr	x25, [x8, #8]
	lsr	x0, x25, #4
	bl	__SFR_IO8
	mov	x20, x0
	and	x0, x25, #0xf
	bl	__BV
	ldr	x8, [x24]
	lsl	x8, x8, #1
	tst	x0, x20
	csel	x8, x8, xzr, eq
	ldr	x9, [x19, x23]
	orr	x8, x8, x9
	str	x8, [x19, x23]
	ldr	x8, [x21]
	ldr	x21, [x8, #16]
	lsr	x0, x21, #4
	bl	__SFR_IO8
	mov	x20, x0
	and	x0, x21, #0xf
	bl	__BV
	ldr	x8, [x24]
	lsl	x8, x8, #2
	tst	x0, x20
	csel	x8, x8, xzr, eq
	ldr	x9, [x19, x23]
	orr	x8, x8, x9
	str	x8, [x19, x23]
	b	LBB0_6
LBB0_2:
	mov	x20, x1
	mov	x0, x1
	bl	_select_row
	mov	w0, #5
	bl	__delay_us
Lloh4:
	adrp	x24, _MATRIX_COLS@GOTPAGE
Lloh5:
	ldr	x24, [x24, _MATRIX_COLS@GOTPAGEOFF]
	ldr	x8, [x24]
	cbz	x8, LBB0_5
; %bb.3:
	mov	x25, #0
Lloh6:
	adrp	x26, _col_pins@GOTPAGE
Lloh7:
	ldr	x26, [x26, _col_pins@GOTPAGEOFF]
Lloh8:
	adrp	x27, _ROW_SHIFTER@GOTPAGE
Lloh9:
	ldr	x27, [x27, _ROW_SHIFTER@GOTPAGEOFF]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x26]
	ldr	x28, [x8, x25, lsl #3]
	lsr	x0, x28, #4
	bl	__SFR_IO8
	mov	x21, x0
	and	x0, x28, #0xf
	bl	__BV
	ldr	x8, [x27]
	lsl	x8, x8, x25
	tst	x0, x21
	csel	x8, x8, xzr, eq
	ldr	x9, [x19, x23]
	orr	x8, x8, x9
	str	x8, [x19, x23]
	add	x25, x25, #1
	ldr	x8, [x24]
	cmp	x25, x8
	b.lo	LBB0_4
LBB0_5:
	mov	x0, x20
	bl	_unselect_row
	ldr	x8, [x19, x20, lsl #3]
LBB0_6:
	cmp	x22, x8
	cset	w0, ne
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_tp_pins,8,3                    ; @tp_pins
	.comm	_ROW_SHIFTER,8,3                ; @ROW_SHIFTER
	.comm	_MATRIX_COLS,8,3                ; @MATRIX_COLS
	.comm	_col_pins,8,3                   ; @col_pins
	.no_dead_strip	_read_cols_on_row
.subsections_via_symbols
