	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pic32_irq_domain_map
_pic32_irq_domain_map:                  ## @pic32_irq_domain_map
	.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	%rdx, %r15
	movl	%esi, %r12d
	movq	%rdi, %rbx
	movq	(%rdi), %r13
	callq	_irq_map_generic_chip
	movl	%eax, %r14d
	testl	%eax, %eax
	jne	LBB0_4
## %bb.1:
	movq	(%r13), %rax
	movq	_IRQ_TYPE_SENSE_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, (%rax,%r15,4)
	je	LBB0_3
## %bb.2:
	movq	%rbx, %rdi
	movl	%r12d, %esi
	callq	_irq_domain_get_irq_data
	movq	%rax, %rbx
	movq	(%r13), %rax
	movl	(%rax,%r15,4), %esi
	movq	%rbx, %rdi
	callq	_irqd_set_trigger_type
	movq	(%r13), %rax
	movl	(%rax,%r15,4), %esi
	movq	%rbx, %rdi
	callq	_irq_setup_alt_chip
LBB0_3:
	movq	%r15, %rdi
	callq	_IRQ_REG_MASK
	movq	_REG_IEC_OFFSET@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_PIC32_CLR
	movl	%eax, %r12d
	movq	_REG_IFS_OFFSET@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_PIC32_CLR
	movl	%eax, %ebx
	movq	_evic_base@GOTPCREL(%rip), %r13
	addl	(%r13), %r12d
	movl	%r12d, %esi
	callq	_writel
	addl	(%r13), %ebx
	movl	%ebx, %esi
	callq	_writel
	movl	$2, %edi
	xorl	%esi, %esi
	callq	_PIC32_INT_PRI
	movq	%r15, %rdi
	movl	%eax, %esi
	callq	_pic32_set_irq_priority
LBB0_4:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IRQ_TYPE_SENSE_MASK,4,2        ## @IRQ_TYPE_SENSE_MASK
	.comm	_REG_IEC_OFFSET,8,3             ## @REG_IEC_OFFSET
	.comm	_REG_IFS_OFFSET,8,3             ## @REG_IFS_OFFSET
	.comm	_evic_base,4,2                  ## @evic_base
	.no_dead_strip	_pic32_irq_domain_map
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pic32_irq_domain_map
_pic32_irq_domain_map:                  ; @pic32_irq_domain_map
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x2
	mov	x21, x1
	mov	x22, x0
	ldr	x23, [x0]
	bl	_irq_map_generic_chip
	mov	x20, x0
	cbnz	w0, LBB0_4
; %bb.1:
	ldr	x8, [x23]
	ldr	w8, [x8, x19, lsl #2]
Lloh0:
	adrp	x9, _IRQ_TYPE_SENSE_MASK@GOTPAGE
Lloh1:
	ldr	x9, [x9, _IRQ_TYPE_SENSE_MASK@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.2:
	mov	x0, x22
	mov	x1, x21
	bl	_irq_domain_get_irq_data
	mov	x21, x0
	ldr	x8, [x23]
	lsl	x22, x19, #2
	ldr	w1, [x8, x22]
	bl	_irqd_set_trigger_type
	ldr	x8, [x23]
	ldr	w1, [x8, x22]
	mov	x0, x21
	bl	_irq_setup_alt_chip
LBB0_3:
	mov	x0, x19
	bl	_IRQ_REG_MASK
Lloh3:
	adrp	x8, _REG_IEC_OFFSET@GOTPAGE
Lloh4:
	ldr	x8, [x8, _REG_IEC_OFFSET@GOTPAGEOFF]
Lloh5:
	ldr	x0, [x8]
	bl	_PIC32_CLR
	mov	x21, x0
Lloh6:
	adrp	x8, _REG_IFS_OFFSET@GOTPAGE
Lloh7:
	ldr	x8, [x8, _REG_IFS_OFFSET@GOTPAGEOFF]
Lloh8:
	ldr	x0, [x8]
	bl	_PIC32_CLR
	mov	x22, x0
Lloh9:
	adrp	x23, _evic_base@GOTPAGE
Lloh10:
	ldr	x23, [x23, _evic_base@GOTPAGEOFF]
	ldr	w8, [x23]
	add	w1, w8, w21
	bl	_writel
	ldr	w8, [x23]
	add	w1, w8, w22
	bl	_writel
	mov	w0, #2
	mov	w1, #0
	bl	_PIC32_INT_PRI
	mov	x1, x0
	mov	x0, x19
	bl	_pic32_set_irq_priority
LBB0_4:
	mov	x0, x20
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_IRQ_TYPE_SENSE_MASK,4,2        ; @IRQ_TYPE_SENSE_MASK
	.comm	_REG_IEC_OFFSET,8,3             ; @REG_IEC_OFFSET
	.comm	_REG_IFS_OFFSET,8,3             ; @REG_IFS_OFFSET
	.comm	_evic_base,4,2                  ; @evic_base
	.no_dead_strip	_pic32_irq_domain_map
.subsections_via_symbols
