	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cmd64x_test_irq
_cmd64x_test_irq:                       ## @cmd64x_test_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	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movl	16(%rdi), %edi
	callq	_to_pci_dev
	cmpq	$0, 8(%r14)
	movq	_ARTTIM23@GOTPCREL(%rip), %rcx
	cmoveq	_CFR@GOTPCREL(%rip), %rcx
	movq	_ARTTIM23_INTR_CH1@GOTPCREL(%rip), %rdx
	cmoveq	_CFR_INTR_CH0@GOTPCREL(%rip), %rdx
	movl	(%rcx), %esi
	movl	(%rdx), %ebx
	movl	$0, -20(%rbp)
	leaq	-20(%rbp), %rdx
	movq	%rax, %rdi
	callq	_pci_read_config_byte
	movl	(%r14), %esi
	movl	-20(%rbp), %edx
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %ecx
	callq	_pr_debug
	xorl	%eax, %eax
	andl	-20(%rbp), %ebx
	setne	%al
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ARTTIM23,4,2                   ## @ARTTIM23
	.comm	_CFR,4,2                        ## @CFR
	.comm	_ARTTIM23_INTR_CH1,4,2          ## @ARTTIM23_INTR_CH1
	.comm	_CFR_INTR_CH0,4,2               ## @CFR_INTR_CH0
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: irq_stat: 0x%02x irq_mask: 0x%02x\n"

	.no_dead_strip	_cmd64x_test_irq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cmd64x_test_irq
_cmd64x_test_irq:                       ; @cmd64x_test_irq
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
	ldr	w0, [x0, #16]
	bl	_to_pci_dev
	ldr	x8, [x19, #8]
Lloh0:
	adrp	x9, _ARTTIM23@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ARTTIM23@GOTPAGEOFF]
Lloh2:
	adrp	x10, _CFR@GOTPAGE
Lloh3:
	ldr	x10, [x10, _CFR@GOTPAGEOFF]
	cmp	x8, #0
	csel	x8, x10, x9, eq
Lloh4:
	adrp	x9, _ARTTIM23_INTR_CH1@GOTPAGE
Lloh5:
	ldr	x9, [x9, _ARTTIM23_INTR_CH1@GOTPAGEOFF]
	ldr	w1, [x8]
Lloh6:
	adrp	x8, _CFR_INTR_CH0@GOTPAGE
Lloh7:
	ldr	x8, [x8, _CFR_INTR_CH0@GOTPAGEOFF]
	csel	x8, x8, x9, eq
	ldr	w20, [x8]
	str	wzr, [sp, #12]
	add	x2, sp, #12
	bl	_pci_read_config_byte
	ldr	w1, [x19]
	ldr	w2, [sp, #12]
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	mov	x3, x20
	bl	_pr_debug
	ldr	w8, [sp, #12]
	tst	w8, w20
	cset	w0, ne
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_ARTTIM23,4,2                   ; @ARTTIM23
	.comm	_CFR,4,2                        ; @CFR
	.comm	_ARTTIM23_INTR_CH1,4,2          ; @ARTTIM23_INTR_CH1
	.comm	_CFR_INTR_CH0,4,2               ; @CFR_INTR_CH0
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: irq_stat: 0x%02x irq_mask: 0x%02x\n"

	.no_dead_strip	_cmd64x_test_irq
.subsections_via_symbols
