	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function read_cols
_read_cols:                             ## @read_cols
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	_MATRIX_ROWS_PER_SIDE@GOTPCREL(%rip), %rax
	cmpq	%rdi, (%rax)
	jle	LBB0_5
## %bb.1:
	movq	$255, -16(%rbp)
	movq	_mcp23017_status@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rax
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	xorl	%edx, %edx
	jmp	LBB0_4
LBB0_5:
	movq	_GPIOB@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax), %ecx
	notl	%ecx
	andl	$63, %ecx
	jmp	LBB0_6
LBB0_3:
	movq	_I2C_GPIOB@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	_I2C_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-16(%rbp), %rdx
	movl	$1, %ecx
	movl	$10, %r8d
	callq	_i2c_readReg
	movq	%rax, (%rbx)
	movl	-16(%rbp), %edx
	notl	%edx
	andl	$63, %edx
LBB0_4:
	xorl	%ecx, %ecx
	testq	%rax, %rax
	cmoveq	%rdx, %rcx
LBB0_6:
	movq	%rcx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MATRIX_ROWS_PER_SIDE,8,3       ## @MATRIX_ROWS_PER_SIDE
	.comm	_mcp23017_status,8,3            ## @mcp23017_status
	.comm	_I2C_GPIOB,8,3                  ## @I2C_GPIOB
	.comm	_I2C_ADDR,4,2                   ## @I2C_ADDR
	.comm	_GPIOB,8,3                      ## @GPIOB
	.no_dead_strip	_read_cols
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function read_cols
_read_cols:                             ; @read_cols
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
Lloh0:
	adrp	x8, _MATRIX_ROWS_PER_SIDE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MATRIX_ROWS_PER_SIDE@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x8, x0
	b.le	LBB0_3
; %bb.1:
	mov	w8, #255
	str	x8, [sp, #8]
Lloh3:
	adrp	x19, _mcp23017_status@GOTPAGE
Lloh4:
	ldr	x19, [x19, _mcp23017_status@GOTPAGEOFF]
	ldr	x0, [x19]
	cbz	x0, LBB0_4
; %bb.2:
	mov	x8, #0
	b	LBB0_5
LBB0_3:
Lloh5:
	adrp	x8, _GPIOB@GOTPAGE
Lloh6:
	ldr	x8, [x8, _GPIOB@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	ldr	w8, [x8]
	mvn	w8, w8
	and	x0, x8, #0x3f
	b	LBB0_6
LBB0_4:
Lloh8:
	adrp	x8, _I2C_GPIOB@GOTPAGE
Lloh9:
	ldr	x8, [x8, _I2C_GPIOB@GOTPAGEOFF]
Lloh10:
	ldr	x1, [x8]
Lloh11:
	adrp	x8, _I2C_ADDR@GOTPAGE
Lloh12:
	ldr	x8, [x8, _I2C_ADDR@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	add	x2, sp, #8
	mov	w3, #1
	mov	w4, #10
	bl	_i2c_readReg
	str	x0, [x19]
	ldr	w8, [sp, #8]
	mvn	w8, w8
	and	x8, x8, #0x3f
LBB0_5:
	cmp	x0, #0
	csel	x0, x8, xzr, eq
LBB0_6:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_MATRIX_ROWS_PER_SIDE,8,3       ; @MATRIX_ROWS_PER_SIDE
	.comm	_mcp23017_status,8,3            ; @mcp23017_status
	.comm	_I2C_GPIOB,8,3                  ; @I2C_GPIOB
	.comm	_I2C_ADDR,4,2                   ; @I2C_ADDR
	.comm	_GPIOB,8,3                      ; @GPIOB
	.no_dead_strip	_read_cols
.subsections_via_symbols
