	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function g2d_irq_handler
_g2d_irq_handler:                       ## @g2d_irq_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, %rbx
	movq	_G2D_INTC_PEND@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	addq	16(%rsi), %rdi
	callq	_readl_relaxed
	movl	%eax, %r14d
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movq	(%r15), %rsi
	addq	16(%rbx), %rsi
	movl	%r14d, %edi
	callq	_writel_relaxed
LBB0_2:
	movq	_G2D_INTP_GCMD_FIN@GOTPCREL(%rip), %rax
	testl	%r14d, (%rax)
	je	LBB0_5
## %bb.3:
	movq	_G2D_DMA_STATUS@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	16(%rbx), %rdi
	callq	_readl_relaxed
	movq	_G2D_DMA_LIST_DONE_COUNT@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	movq	_G2D_DMA_LIST_DONE_COUNT_OFFSET@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %eax
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_g2d_finish_event
	movq	_G2D_DMA_HOLD_CMD@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	16(%rbx), %rsi
	xorl	%edi, %edi
	callq	_writel_relaxed
	movq	_G2D_INTP_ACMD_FIN@GOTPCREL(%rip), %rax
	testl	%r14d, (%rax)
	jne	LBB0_5
## %bb.4:
	movq	_G2D_DMA_CONTINUE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_G2D_DMA_COMMAND@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	16(%rbx), %rsi
	callq	_writel_relaxed
LBB0_5:
	movq	_G2D_INTP_ACMD_FIN@GOTPCREL(%rip), %rax
	testl	%r14d, (%rax)
	je	LBB0_7
## %bb.6:
	movq	_G2D_BIT_ENGINE_BUSY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	8(%rbx), %rsi
	callq	_clear_bit
	movl	4(%rbx), %edi
	movq	%rbx, %rsi
	callq	_queue_work
LBB0_7:
	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	_G2D_INTC_PEND,8,3              ## @G2D_INTC_PEND
	.comm	_G2D_INTP_GCMD_FIN,4,2          ## @G2D_INTP_GCMD_FIN
	.comm	_G2D_DMA_STATUS,8,3             ## @G2D_DMA_STATUS
	.comm	_G2D_DMA_LIST_DONE_COUNT,4,2    ## @G2D_DMA_LIST_DONE_COUNT
	.comm	_G2D_DMA_LIST_DONE_COUNT_OFFSET,4,2 ## @G2D_DMA_LIST_DONE_COUNT_OFFSET
	.comm	_G2D_DMA_HOLD_CMD,8,3           ## @G2D_DMA_HOLD_CMD
	.comm	_G2D_INTP_ACMD_FIN,4,2          ## @G2D_INTP_ACMD_FIN
	.comm	_G2D_DMA_CONTINUE,4,2           ## @G2D_DMA_CONTINUE
	.comm	_G2D_DMA_COMMAND,8,3            ## @G2D_DMA_COMMAND
	.comm	_G2D_BIT_ENGINE_BUSY,4,2        ## @G2D_BIT_ENGINE_BUSY
	.comm	_IRQ_HANDLED,4,2                ## @IRQ_HANDLED
	.no_dead_strip	_g2d_irq_handler
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function g2d_irq_handler
_g2d_irq_handler:                       ; @g2d_irq_handler
	.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
	ldr	x8, [x1, #16]
Lloh0:
	adrp	x21, _G2D_INTC_PEND@GOTPAGE
Lloh1:
	ldr	x21, [x21, _G2D_INTC_PEND@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x0, x9, x8
	bl	_readl_relaxed
	mov	x20, x0
	cbz	w0, LBB0_2
; %bb.1:
	ldr	x8, [x19, #16]
	ldr	x9, [x21]
	add	x1, x9, x8
	mov	x0, x20
	bl	_writel_relaxed
LBB0_2:
Lloh2:
	adrp	x8, _G2D_INTP_GCMD_FIN@GOTPAGE
Lloh3:
	ldr	x8, [x8, _G2D_INTP_GCMD_FIN@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x21, _G2D_INTP_ACMD_FIN@GOTPAGE
Lloh6:
	ldr	x21, [x21, _G2D_INTP_ACMD_FIN@GOTPAGEOFF]
	tst	w8, w20
	b.eq	LBB0_5
; %bb.3:
	ldr	x8, [x19, #16]
Lloh7:
	adrp	x9, _G2D_DMA_STATUS@GOTPAGE
Lloh8:
	ldr	x9, [x9, _G2D_DMA_STATUS@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl_relaxed
Lloh10:
	adrp	x8, _G2D_DMA_LIST_DONE_COUNT@GOTPAGE
Lloh11:
	ldr	x8, [x8, _G2D_DMA_LIST_DONE_COUNT@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	and	w8, w8, w0
Lloh13:
	adrp	x9, _G2D_DMA_LIST_DONE_COUNT_OFFSET@GOTPAGE
Lloh14:
	ldr	x9, [x9, _G2D_DMA_LIST_DONE_COUNT_OFFSET@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	asr	w1, w8, w9
	mov	x0, x19
	bl	_g2d_finish_event
	ldr	x8, [x19, #16]
Lloh16:
	adrp	x9, _G2D_DMA_HOLD_CMD@GOTPAGE
Lloh17:
	ldr	x9, [x9, _G2D_DMA_HOLD_CMD@GOTPAGEOFF]
Lloh18:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	w0, #0
	bl	_writel_relaxed
	ldr	w8, [x21]
	tst	w8, w20
	b.ne	LBB0_5
; %bb.4:
Lloh19:
	adrp	x8, _G2D_DMA_CONTINUE@GOTPAGE
Lloh20:
	ldr	x8, [x8, _G2D_DMA_CONTINUE@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
	ldr	x8, [x19, #16]
Lloh22:
	adrp	x9, _G2D_DMA_COMMAND@GOTPAGE
Lloh23:
	ldr	x9, [x9, _G2D_DMA_COMMAND@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	add	x1, x9, x8
	bl	_writel_relaxed
LBB0_5:
	ldr	w8, [x21]
	tst	w8, w20
	b.eq	LBB0_7
; %bb.6:
Lloh25:
	adrp	x8, _G2D_BIT_ENGINE_BUSY@GOTPAGE
Lloh26:
	ldr	x8, [x8, _G2D_BIT_ENGINE_BUSY@GOTPAGEOFF]
Lloh27:
	ldr	w0, [x8]
	add	x1, x19, #8
	bl	_clear_bit
	ldr	w0, [x19, #4]
	mov	x1, x19
	bl	_queue_work
LBB0_7:
Lloh28:
	adrp	x8, _IRQ_HANDLED@GOTPAGE
Lloh29:
	ldr	x8, [x8, _IRQ_HANDLED@GOTPAGEOFF]
Lloh30:
	ldr	w0, [x8]
	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	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.cfi_endproc
                                        ; -- End function
	.comm	_G2D_INTC_PEND,8,3              ; @G2D_INTC_PEND
	.comm	_G2D_INTP_GCMD_FIN,4,2          ; @G2D_INTP_GCMD_FIN
	.comm	_G2D_DMA_STATUS,8,3             ; @G2D_DMA_STATUS
	.comm	_G2D_DMA_LIST_DONE_COUNT,4,2    ; @G2D_DMA_LIST_DONE_COUNT
	.comm	_G2D_DMA_LIST_DONE_COUNT_OFFSET,4,2 ; @G2D_DMA_LIST_DONE_COUNT_OFFSET
	.comm	_G2D_DMA_HOLD_CMD,8,3           ; @G2D_DMA_HOLD_CMD
	.comm	_G2D_INTP_ACMD_FIN,4,2          ; @G2D_INTP_ACMD_FIN
	.comm	_G2D_DMA_CONTINUE,4,2           ; @G2D_DMA_CONTINUE
	.comm	_G2D_DMA_COMMAND,8,3            ; @G2D_DMA_COMMAND
	.comm	_G2D_BIT_ENGINE_BUSY,4,2        ; @G2D_BIT_ENGINE_BUSY
	.comm	_IRQ_HANDLED,4,2                ; @IRQ_HANDLED
	.no_dead_strip	_g2d_irq_handler
.subsections_via_symbols
