	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sun4i_lradc_irq
_sun4i_lradc_irq:                       ## @sun4i_lradc_irq
	.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, %r13
	movq	_LRADC_INTS@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	addq	16(%rsi), %rdi
	callq	_readl
	movl	%eax, %ebx
	movq	_CHAN0_KEYUP_IRQ@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_2
## %bb.1:
	movl	24(%r13), %edi
	movq	(%r13), %rsi
	xorl	%edx, %edx
	callq	_input_report_key
	movq	$0, (%r13)
LBB0_2:
	movq	_CHAN0_KEYDOWN_IRQ@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_11
## %bb.3:
	cmpq	$0, (%r13)
	jne	LBB0_11
## %bb.4:
	movq	_LRADC_DATA0@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	16(%r13), %rdi
	callq	_readl
	cmpl	$0, 12(%r13)
	movl	%ebx, -48(%rbp)                 ## 4-byte Spill
	jle	LBB0_5
## %bb.6:
	andl	$63, %eax
	imull	8(%r13), %eax
	cltq
	imulq	$-2113396605, %rax, %rcx        ## imm = 0x82082083
	shrq	$32, %rcx
	addl	%ecx, %eax
	movl	%eax, %ecx
	shrl	$31, %ecx
	sarl	$5, %eax
	addl	%ecx, %eax
	movslq	%eax, %r12
	xorl	%ebx, %ebx
	movl	$-1, %r14d
	xorl	%r15d, %r15d
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_7 Depth=1
	incq	%r15
	movslq	12(%r13), %rax
	addq	$16, %rbx
	cmpq	%rax, %r15
	jge	LBB0_10
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	32(%r13), %rax
	movq	8(%rax,%rbx), %rdi
	subq	%r12, %rdi
	callq	_abs
	cmpl	%r14d, %eax
	jge	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	32(%r13), %rcx
	movl	(%rcx,%rbx), %ecx
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movl	%eax, %r14d
	jmp	LBB0_9
LBB0_5:
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
LBB0_10:
	movslq	-44(%rbp), %rsi                 ## 4-byte Folded Reload
	movq	%rsi, (%r13)
	movl	24(%r13), %edi
	movl	$1, %edx
	callq	_input_report_key
	movq	_LRADC_INTS@GOTPCREL(%rip), %r14
	movl	-48(%rbp), %ebx                 ## 4-byte Reload
LBB0_11:
	movl	24(%r13), %edi
	callq	_input_sync
	movq	(%r14), %rsi
	addq	16(%r13), %rsi
	movl	%ebx, %edi
	callq	_writel
	movq	_IRQ_HANDLED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LRADC_INTS,8,3                 ## @LRADC_INTS
	.comm	_CHAN0_KEYUP_IRQ,4,2            ## @CHAN0_KEYUP_IRQ
	.comm	_CHAN0_KEYDOWN_IRQ,4,2          ## @CHAN0_KEYDOWN_IRQ
	.comm	_LRADC_DATA0,8,3                ## @LRADC_DATA0
	.comm	_IRQ_HANDLED,4,2                ## @IRQ_HANDLED
	.no_dead_strip	_sun4i_lradc_irq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sun4i_lradc_irq
_sun4i_lradc_irq:                       ; @sun4i_lradc_irq
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x1
	ldr	x8, [x1, #16]
Lloh0:
	adrp	x21, _LRADC_INTS@GOTPAGE
Lloh1:
	ldr	x21, [x21, _LRADC_INTS@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x0, x9, x8
	bl	_readl
	mov	x20, x0
Lloh2:
	adrp	x8, _CHAN0_KEYUP_IRQ@GOTPAGE
Lloh3:
	ldr	x8, [x8, _CHAN0_KEYUP_IRQ@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_2
; %bb.1:
	ldr	w0, [x19, #24]
	ldr	x1, [x19]
	mov	w2, #0
	bl	_input_report_key
	str	xzr, [x19]
LBB0_2:
Lloh5:
	adrp	x8, _CHAN0_KEYDOWN_IRQ@GOTPAGE
Lloh6:
	ldr	x8, [x8, _CHAN0_KEYDOWN_IRQ@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_11
; %bb.3:
	ldr	x8, [x19]
	cbnz	x8, LBB0_11
; %bb.4:
	ldr	x8, [x19, #16]
Lloh8:
	adrp	x9, _LRADC_DATA0@GOTPAGE
Lloh9:
	ldr	x9, [x9, _LRADC_DATA0@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
	ldr	w8, [x19, #12]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.5:
	mov	x23, #0
	mov	x24, #0
	mov	w22, #0
	and	w8, w0, #0x3f
	ldr	w9, [x19, #8]
	mul	w8, w8, w9
	mov	w9, #8323
	movk	w9, #33288, lsl #16
	smull	x9, w8, w9
	lsr	x9, x9, #32
	add	w8, w9, w8
	asr	w9, w8, #5
	add	w8, w9, w8, lsr #31
	sxtw	x25, w8
	mov	w26, #-1
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	x24, x24, #1
	ldrsw	x8, [x19, #12]
	add	x23, x23, #16
	cmp	x24, x8
	b.ge	LBB0_10
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #32]
	add	x8, x8, x23
	ldr	x8, [x8, #8]
	sub	x0, x8, x25
	bl	_abs
	cmp	w0, w26
	b.ge	LBB0_6
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [x19, #32]
	ldr	w22, [x8, x23]
	mov	x26, x0
	b	LBB0_6
LBB0_9:
	mov	w22, #0
LBB0_10:
	sxtw	x1, w22
	str	x1, [x19]
	ldr	w0, [x19, #24]
	mov	w2, #1
	bl	_input_report_key
LBB0_11:
	ldr	w0, [x19, #24]
	bl	_input_sync
	ldr	x8, [x19, #16]
	ldr	x9, [x21]
	add	x1, x9, x8
	mov	x0, x20
	bl	_writel
Lloh11:
	adrp	x8, _IRQ_HANDLED@GOTPAGE
Lloh12:
	ldr	x8, [x8, _IRQ_HANDLED@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_LRADC_INTS,8,3                 ; @LRADC_INTS
	.comm	_CHAN0_KEYUP_IRQ,4,2            ; @CHAN0_KEYUP_IRQ
	.comm	_CHAN0_KEYDOWN_IRQ,4,2          ; @CHAN0_KEYDOWN_IRQ
	.comm	_LRADC_DATA0,8,3                ; @LRADC_DATA0
	.comm	_IRQ_HANDLED,4,2                ; @IRQ_HANDLED
	.no_dead_strip	_sun4i_lradc_irq
.subsections_via_symbols
