	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bcm_intc_map_intr
_bcm_intc_map_intr:                     ## @bcm_intc_map_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	(%rsi), %rax
	movq	_INTR_MAP_DATA_FDT@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_4
## %bb.1:
	movq	%rdx, %r14
	cmpl	$2, %eax
	je	LBB0_5
## %bb.2:
	cmpl	$1, %eax
	jne	LBB0_15
## %bb.3:
	movq	8(%rsi), %rax
	movq	(%rax), %rbx
LBB0_11:
	movq	_BCM_INTC_NIRQS@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rbx
	jae	LBB0_15
## %bb.12:
	callq	_device_get_softc
	shlq	$2, %rbx
	addq	(%rax), %rbx
	movq	%rbx, (%r14)
	xorl	%eax, %eax
	jmp	LBB0_17
LBB0_4:
	movq	_ENOTSUP@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_5:
	movq	8(%rsi), %rax
	movq	(%rax), %rdx
	testq	%rdx, %rdx
	je	LBB0_9
## %bb.6:
	cmpq	$1, %rdx
	je	LBB0_10
## %bb.7:
	cmpq	$2, %rdx
	jne	LBB0_13
## %bb.8:
	movq	8(%rax), %rcx
	movq	_BANK2_START@GOTPCREL(%rip), %rax
	movslq	(%rax), %rbx
	addq	%rcx, %rbx
	movq	_BANK2_END@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rbx
	jbe	LBB0_11
	jmp	LBB0_14
LBB0_9:
	movq	8(%rax), %rcx
	movq	_BANK1_START@GOTPCREL(%rip), %rax
	movq	%rcx, %rbx
	cmpq	(%rax), %rcx
	jb	LBB0_11
	jmp	LBB0_14
LBB0_10:
	movq	8(%rax), %rcx
	movq	_BANK1_START@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	addq	%rcx, %rbx
	movq	_BANK1_END@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rbx
	ja	LBB0_14
	jmp	LBB0_11
LBB0_13:
	movq	8(%rax), %rcx
LBB0_14:
	leaq	L_.str(%rip), %rsi
	callq	_device_printf
LBB0_15:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_16:
	movl	(%rax), %eax
LBB0_17:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_INTR_MAP_DATA_FDT,8,3          ## @INTR_MAP_DATA_FDT
	.comm	_ENOTSUP,4,2                    ## @ENOTSUP
	.comm	_BANK1_START,8,3                ## @BANK1_START
	.comm	_BANK1_END,8,3                  ## @BANK1_END
	.comm	_BANK2_START,4,2                ## @BANK2_START
	.comm	_BANK2_END,8,3                  ## @BANK2_END
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid IRQ config: bank=%d, irq=%d\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_BCM_INTC_NIRQS,8,3             ## @BCM_INTC_NIRQS
	.no_dead_strip	_bcm_intc_map_intr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bcm_intc_map_intr
_bcm_intc_map_intr:                     ; @bcm_intc_map_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
	ldr	x8, [x1]
Lloh0:
	adrp	x9, _INTR_MAP_DATA_FDT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _INTR_MAP_DATA_FDT@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_6
; %bb.1:
	mov	x19, x2
	cmp	w8, #2
	b.eq	LBB0_7
; %bb.2:
	cmp	w8, #1
	b.ne	LBB0_15
; %bb.3:
	ldr	x8, [x1, #8]
	ldr	x20, [x8]
LBB0_4:
Lloh3:
	adrp	x8, _BCM_INTC_NIRQS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _BCM_INTC_NIRQS@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x20, x8
	b.hs	LBB0_15
; %bb.5:
	bl	_device_get_softc
	mov	x8, x0
	mov	w0, #0
	ldr	x8, [x8]
	add	x8, x8, x20, lsl #2
	str	x8, [x19]
	b	LBB0_17
LBB0_6:
Lloh6:
	adrp	x8, _ENOTSUP@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOTSUP@GOTPAGEOFF]
	b	LBB0_16
LBB0_7:
	ldr	x8, [x1, #8]
	ldr	x2, [x8]
	cbz	x2, LBB0_11
; %bb.8:
	cmp	x2, #1
	b.eq	LBB0_12
; %bb.9:
	cmp	x2, #2
	b.ne	LBB0_13
; %bb.10:
	ldr	x3, [x8, #8]
Lloh8:
	adrp	x8, _BANK2_START@GOTPAGE
Lloh9:
	ldr	x8, [x8, _BANK2_START@GOTPAGEOFF]
Lloh10:
	ldrsw	x8, [x8]
Lloh11:
	adrp	x9, _BANK2_END@GOTPAGE
Lloh12:
	ldr	x9, [x9, _BANK2_END@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	add	x20, x3, x8
	cmp	x20, x9
	b.ls	LBB0_4
	b	LBB0_14
LBB0_11:
	ldr	x3, [x8, #8]
Lloh14:
	adrp	x8, _BANK1_START@GOTPAGE
Lloh15:
	ldr	x8, [x8, _BANK1_START@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	mov	x20, x3
	cmp	x3, x8
	b.lo	LBB0_4
	b	LBB0_14
LBB0_12:
	ldr	x3, [x8, #8]
Lloh17:
	adrp	x8, _BANK1_START@GOTPAGE
Lloh18:
	ldr	x8, [x8, _BANK1_START@GOTPAGEOFF]
Lloh19:
	ldr	x8, [x8]
Lloh20:
	adrp	x9, _BANK1_END@GOTPAGE
Lloh21:
	ldr	x9, [x9, _BANK1_END@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
	add	x20, x8, x3
	cmp	x20, x9
	b.hi	LBB0_14
	b	LBB0_4
LBB0_13:
	ldr	x3, [x8, #8]
LBB0_14:
Lloh23:
	adrp	x1, l_.str@PAGE
Lloh24:
	add	x1, x1, l_.str@PAGEOFF
	bl	_device_printf
LBB0_15:
Lloh25:
	adrp	x8, _EINVAL@GOTPAGE
Lloh26:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_16:
	ldr	w0, [x8]
LBB0_17:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_INTR_MAP_DATA_FDT,8,3          ; @INTR_MAP_DATA_FDT
	.comm	_ENOTSUP,4,2                    ; @ENOTSUP
	.comm	_BANK1_START,8,3                ; @BANK1_START
	.comm	_BANK1_END,8,3                  ; @BANK1_END
	.comm	_BANK2_START,4,2                ; @BANK2_START
	.comm	_BANK2_END,8,3                  ; @BANK2_END
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid IRQ config: bank=%d, irq=%d\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_BCM_INTC_NIRQS,8,3             ; @BCM_INTC_NIRQS
	.no_dead_strip	_bcm_intc_map_intr
.subsections_via_symbols
