	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function si1145_measure
_si1145_measure:                        ## @si1145_measure
	.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	%rsi, %r15
	movq	%rdi, %rbx
	callq	_iio_priv
	movq	%rax, %r14
	movl	12(%r15), %edi
	callq	_BIT
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_si1145_set_chlist
	testl	%eax, %eax
	js	LBB0_6
## %bb.1:
	movq	(%r15), %rax
	movq	_IIO_PROXIMITY@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.3:
	movq	_SI1145_CMD_PS_FORCE@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_2:
	movq	_SI1145_CMD_ALS_FORCE@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_si1145_command
	testl	%eax, %eax
	jns	LBB0_7
## %bb.5:
	movq	_EOVERFLOW@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	addl	%eax, %ecx
	jne	LBB0_6
LBB0_7:
	movl	(%r14), %edi
	movl	8(%r15), %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_i2c_smbus_read_word_data       ## TAILCALL
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IIO_PROXIMITY,8,3              ## @IIO_PROXIMITY
	.comm	_SI1145_CMD_PS_FORCE,4,2        ## @SI1145_CMD_PS_FORCE
	.comm	_SI1145_CMD_ALS_FORCE,4,2       ## @SI1145_CMD_ALS_FORCE
	.comm	_EOVERFLOW,4,2                  ## @EOVERFLOW
	.no_dead_strip	_si1145_measure
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function si1145_measure
_si1145_measure:                        ; @si1145_measure
	.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
	mov	x19, x1
	mov	x21, x0
	bl	_iio_priv
	mov	x20, x0
	ldr	w0, [x19, #12]
	bl	_BIT
	mov	x1, x0
	mov	x0, x21
	bl	_si1145_set_chlist
	tbnz	w0, #31, LBB0_4
; %bb.1:
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _IIO_PROXIMITY@GOTPAGE
Lloh1:
	ldr	x9, [x9, _IIO_PROXIMITY@GOTPAGEOFF]
Lloh2:
	adrp	x10, _SI1145_CMD_PS_FORCE@GOTPAGE
Lloh3:
	ldr	x10, [x10, _SI1145_CMD_PS_FORCE@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
Lloh5:
	adrp	x11, _SI1145_CMD_ALS_FORCE@GOTPAGE
Lloh6:
	ldr	x11, [x11, _SI1145_CMD_ALS_FORCE@GOTPAGEOFF]
	cmp	x8, x9
	csel	x8, x10, x11, eq
	ldr	w1, [x8]
	mov	x0, x20
	bl	_si1145_command
	tbz	w0, #31, LBB0_3
; %bb.2:
Lloh7:
	adrp	x8, _EOVERFLOW@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EOVERFLOW@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	cmn	w0, w8
	b.ne	LBB0_4
LBB0_3:
	ldr	w0, [x20]
	ldr	w1, [x19, #8]
	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
	b	_i2c_smbus_read_word_data
LBB0_4:
	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	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_IIO_PROXIMITY,8,3              ; @IIO_PROXIMITY
	.comm	_SI1145_CMD_PS_FORCE,4,2        ; @SI1145_CMD_PS_FORCE
	.comm	_SI1145_CMD_ALS_FORCE,4,2       ; @SI1145_CMD_ALS_FORCE
	.comm	_EOVERFLOW,4,2                  ; @EOVERFLOW
	.no_dead_strip	_si1145_measure
.subsections_via_symbols
