	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_riscv_cpu_intr                 ## -- Begin function riscv_cpu_intr
	.p2align	4, 0x90
_riscv_cpu_intr:                        ## @riscv_cpu_intr
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	xorl	%eax, %eax
	callq	_critical_enter
	movq	_EXCP_INTR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	andl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
	callq	_KASSERT
	movq	_EXCP_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	andl	(%r14), %ebx
	leal	-128(%rbx), %eax
	cmpl	$3, %eax
	jae	LBB0_1
## %bb.3:
	movq	_isrcs@GOTPCREL(%rip), %rax
	leaq	(,%rbx,4), %rdi
	addq	(%rax), %rdi
	movq	%r14, %rsi
	callq	_intr_isrc_dispatch
	testl	%eax, %eax
	je	LBB0_5
## %bb.4:
	leaq	L_.str.1(%rip), %rdi
	movl	%ebx, %esi
	callq	_printf
	jmp	LBB0_5
LBB0_1:
	cmpl	$131, %ebx
	jne	LBB0_5
## %bb.2:
	movq	%r14, %rdi
	callq	_intr_irq_handler
LBB0_5:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_critical_exit                  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_EXCP_INTR,4,2                  ## @EXCP_INTR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"riscv_cpu_intr: wrong frame passed"

	.comm	_EXCP_MASK,4,2                  ## @EXCP_MASK
	.comm	_isrcs,8,3                      ## @isrcs
L_.str.1:                               ## @.str.1
	.asciz	"stray interrupt %d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_riscv_cpu_intr                 ; -- Begin function riscv_cpu_intr
	.p2align	2
_riscv_cpu_intr:                        ; @riscv_cpu_intr
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	bl	_critical_enter
	ldr	w8, [x19]
Lloh0:
	adrp	x9, _EXCP_INTR@GOTPAGE
Lloh1:
	ldr	x9, [x9, _EXCP_INTR@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	and	w0, w9, w8
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_KASSERT
	ldr	w8, [x19]
Lloh5:
	adrp	x9, _EXCP_MASK@GOTPAGE
Lloh6:
	ldr	x9, [x9, _EXCP_MASK@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	and	w20, w9, w8
	sub	w8, w20, #128
	cmp	w8, #3
	b.hs	LBB0_3
; %bb.1:
Lloh8:
	adrp	x8, _isrcs@GOTPAGE
Lloh9:
	ldr	x8, [x8, _isrcs@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	add	x0, x8, x20, lsl #2
	mov	x1, x19
	bl	_intr_isrc_dispatch
	cbz	w0, LBB0_5
; %bb.2:
Lloh11:
	adrp	x0, l_.str.1@PAGE
Lloh12:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x20
	bl	_printf
	b	LBB0_5
LBB0_3:
	cmp	w20, #131
	b.ne	LBB0_5
; %bb.4:
	mov	x0, x19
	bl	_intr_irq_handler
LBB0_5:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_critical_exit
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_EXCP_INTR,4,2                  ; @EXCP_INTR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"riscv_cpu_intr: wrong frame passed"

	.comm	_EXCP_MASK,4,2                  ; @EXCP_MASK
	.comm	_isrcs,8,3                      ; @isrcs
l_.str.1:                               ; @.str.1
	.asciz	"stray interrupt %d\n"

.subsections_via_symbols
