	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function apds9960_interrupt_handler
_apds9960_interrupt_handler:            ## @apds9960_interrupt_handler
	.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, %r14
	movq	%rsi, %rdi
	callq	_iio_priv
	movq	%rax, %rbx
	movl	(%rax), %edi
	movq	_APDS9960_REG_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-28(%rbp), %rdx
	callq	_regmap_read
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movl	-28(%rbp), %eax
	movq	_APDS9960_REG_STATUS_ALS_INT@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_5
## %bb.3:
	cmpq	$0, 16(%rbx)
	je	LBB0_5
## %bb.4:
	movq	_IIO_INTENSITY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_IIO_EV_TYPE_THRESH@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_IIO_EV_DIR_EITHER@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%esi, %esi
	callq	_IIO_UNMOD_EVENT_CODE
	movl	%eax, %r15d
	movq	%r14, %rdi
	callq	_iio_get_time_ns
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_iio_push_event
	movl	(%rbx), %edi
	movq	_APDS9960_REG_CICLEAR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edx
	callq	_regmap_write
	movl	-28(%rbp), %eax
LBB0_5:
	movq	_APDS9960_REG_STATUS_PS_INT@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_8
## %bb.6:
	cmpq	$0, 8(%rbx)
	je	LBB0_8
## %bb.7:
	movq	_IIO_PROXIMITY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_IIO_EV_TYPE_THRESH@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_IIO_EV_DIR_EITHER@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%esi, %esi
	callq	_IIO_UNMOD_EVENT_CODE
	movl	%eax, %r15d
	movq	%r14, %rdi
	callq	_iio_get_time_ns
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_iio_push_event
	movl	(%rbx), %edi
	movq	_APDS9960_REG_PICLEAR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$1, %edx
	callq	_regmap_write
	movl	-28(%rbp), %eax
LBB0_8:
	movq	_APDS9960_REG_STATUS_GINT@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_10
## %bb.9:
	movq	%rbx, %rdi
	callq	_apds9960_read_gesture_fifo
	jmp	LBB0_10
LBB0_1:
	movq	24(%rbx), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
LBB0_10:
	movq	_IRQ_HANDLED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_APDS9960_REG_STATUS,4,2        ## @APDS9960_REG_STATUS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"irq status reg read failed\n"

	.comm	_IRQ_HANDLED,4,2                ## @IRQ_HANDLED
	.comm	_APDS9960_REG_STATUS_ALS_INT,4,2 ## @APDS9960_REG_STATUS_ALS_INT
	.comm	_IIO_INTENSITY,4,2              ## @IIO_INTENSITY
	.comm	_IIO_EV_TYPE_THRESH,4,2         ## @IIO_EV_TYPE_THRESH
	.comm	_IIO_EV_DIR_EITHER,4,2          ## @IIO_EV_DIR_EITHER
	.comm	_APDS9960_REG_CICLEAR,4,2       ## @APDS9960_REG_CICLEAR
	.comm	_APDS9960_REG_STATUS_PS_INT,4,2 ## @APDS9960_REG_STATUS_PS_INT
	.comm	_IIO_PROXIMITY,4,2              ## @IIO_PROXIMITY
	.comm	_APDS9960_REG_PICLEAR,4,2       ## @APDS9960_REG_PICLEAR
	.comm	_APDS9960_REG_STATUS_GINT,4,2   ## @APDS9960_REG_STATUS_GINT
	.no_dead_strip	_apds9960_interrupt_handler
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function apds9960_interrupt_handler
_apds9960_interrupt_handler:            ; @apds9960_interrupt_handler
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x20, x1
	mov	x0, x1
	bl	_iio_priv
	mov	x19, x0
	ldr	w0, [x0]
Lloh0:
	adrp	x8, _APDS9960_REG_STATUS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _APDS9960_REG_STATUS@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x2, sp, #12
	bl	_regmap_read
	tbnz	w0, #31, LBB0_9
; %bb.1:
	ldr	w8, [sp, #12]
Lloh3:
	adrp	x9, _APDS9960_REG_STATUS_ALS_INT@GOTPAGE
Lloh4:
	ldr	x9, [x9, _APDS9960_REG_STATUS_ALS_INT@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.2:
	ldr	x9, [x19, #16]
	cbz	x9, LBB0_4
; %bb.3:
Lloh6:
	adrp	x8, _IIO_INTENSITY@GOTPAGE
Lloh7:
	ldr	x8, [x8, _IIO_INTENSITY@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
Lloh9:
	adrp	x8, _IIO_EV_TYPE_THRESH@GOTPAGE
Lloh10:
	ldr	x8, [x8, _IIO_EV_TYPE_THRESH@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
Lloh12:
	adrp	x8, _IIO_EV_DIR_EITHER@GOTPAGE
Lloh13:
	ldr	x8, [x8, _IIO_EV_DIR_EITHER@GOTPAGEOFF]
Lloh14:
	ldr	w3, [x8]
	mov	w1, #0
	bl	_IIO_UNMOD_EVENT_CODE
	mov	x21, x0
	mov	x0, x20
	bl	_iio_get_time_ns
	mov	x2, x0
	mov	x0, x20
	mov	x1, x21
	bl	_iio_push_event
	ldr	w0, [x19]
Lloh15:
	adrp	x8, _APDS9960_REG_CICLEAR@GOTPAGE
Lloh16:
	ldr	x8, [x8, _APDS9960_REG_CICLEAR@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	w2, #1
	bl	_regmap_write
	ldr	w8, [sp, #12]
LBB0_4:
Lloh18:
	adrp	x9, _APDS9960_REG_STATUS_PS_INT@GOTPAGE
Lloh19:
	ldr	x9, [x9, _APDS9960_REG_STATUS_PS_INT@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.5:
	ldr	x9, [x19, #8]
	cbz	x9, LBB0_7
; %bb.6:
Lloh21:
	adrp	x8, _IIO_PROXIMITY@GOTPAGE
Lloh22:
	ldr	x8, [x8, _IIO_PROXIMITY@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
Lloh24:
	adrp	x8, _IIO_EV_TYPE_THRESH@GOTPAGE
Lloh25:
	ldr	x8, [x8, _IIO_EV_TYPE_THRESH@GOTPAGEOFF]
Lloh26:
	ldr	w2, [x8]
Lloh27:
	adrp	x8, _IIO_EV_DIR_EITHER@GOTPAGE
Lloh28:
	ldr	x8, [x8, _IIO_EV_DIR_EITHER@GOTPAGEOFF]
Lloh29:
	ldr	w3, [x8]
	mov	w1, #0
	bl	_IIO_UNMOD_EVENT_CODE
	mov	x21, x0
	mov	x0, x20
	bl	_iio_get_time_ns
	mov	x2, x0
	mov	x0, x20
	mov	x1, x21
	bl	_iio_push_event
	ldr	w0, [x19]
Lloh30:
	adrp	x8, _APDS9960_REG_PICLEAR@GOTPAGE
Lloh31:
	ldr	x8, [x8, _APDS9960_REG_PICLEAR@GOTPAGEOFF]
Lloh32:
	ldr	w1, [x8]
	mov	w2, #1
	bl	_regmap_write
	ldr	w8, [sp, #12]
LBB0_7:
Lloh33:
	adrp	x9, _APDS9960_REG_STATUS_GINT@GOTPAGE
Lloh34:
	ldr	x9, [x9, _APDS9960_REG_STATUS_GINT@GOTPAGEOFF]
Lloh35:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_10
; %bb.8:
	mov	x0, x19
	bl	_apds9960_read_gesture_fifo
	b	LBB0_10
LBB0_9:
	ldr	x0, [x19, #24]
Lloh36:
	adrp	x1, l_.str@PAGE
Lloh37:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
LBB0_10:
Lloh38:
	adrp	x8, _IRQ_HANDLED@GOTPAGE
Lloh39:
	ldr	x8, [x8, _IRQ_HANDLED@GOTPAGEOFF]
Lloh40:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.cfi_endproc
                                        ; -- End function
	.comm	_APDS9960_REG_STATUS,4,2        ; @APDS9960_REG_STATUS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"irq status reg read failed\n"

	.comm	_IRQ_HANDLED,4,2                ; @IRQ_HANDLED
	.comm	_APDS9960_REG_STATUS_ALS_INT,4,2 ; @APDS9960_REG_STATUS_ALS_INT
	.comm	_IIO_INTENSITY,4,2              ; @IIO_INTENSITY
	.comm	_IIO_EV_TYPE_THRESH,4,2         ; @IIO_EV_TYPE_THRESH
	.comm	_IIO_EV_DIR_EITHER,4,2          ; @IIO_EV_DIR_EITHER
	.comm	_APDS9960_REG_CICLEAR,4,2       ; @APDS9960_REG_CICLEAR
	.comm	_APDS9960_REG_STATUS_PS_INT,4,2 ; @APDS9960_REG_STATUS_PS_INT
	.comm	_IIO_PROXIMITY,4,2              ; @IIO_PROXIMITY
	.comm	_APDS9960_REG_PICLEAR,4,2       ; @APDS9960_REG_PICLEAR
	.comm	_APDS9960_REG_STATUS_GINT,4,2   ; @APDS9960_REG_STATUS_GINT
	.no_dead_strip	_apds9960_interrupt_handler
.subsections_via_symbols
