	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_msi_init                       ## -- Begin function msi_init
	.p2align	4, 0x90
_msi_init:                              ## @msi_init
	.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	_cpu_vendor_id@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cmpl	$128, %eax
	je	LBB0_5
## %bb.1:
	cmpl	$130, %eax
	je	LBB0_5
## %bb.2:
	cmpl	$129, %eax
	jne	LBB0_9
## %bb.3:
	movq	_cpu_id@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	callq	_CPUID_TO_FAMILY
	cmpl	$6, %eax
	jne	LBB0_9
## %bb.4:
	movl	(%rbx), %edi
	callq	_CPUID_TO_MODEL
	cmpl	$15, %eax
	jl	LBB0_9
LBB0_5:
	movq	_num_msi_irqs@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	je	LBB0_9
## %bb.6:
	movq	_num_io_irqs@GOTPCREL(%rip), %r14
	movq	(%r14), %rcx
	movq	_first_msi_irq@GOTPCREL(%rip), %rbx
	movq	%rcx, (%rbx)
	movq	_UINT_MAX@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	subq	%rcx, %rdx
	cmpq	%rdx, %rax
	jle	LBB0_8
## %bb.7:
	leaq	L_.str(%rip), %rdi
	callq	_panic
	movq	(%rbx), %rcx
	movq	_num_msi_irqs@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
LBB0_8:
	addq	%rcx, %rax
	movq	%rax, (%r14)
	movq	_msi_enabled@GOTPCREL(%rip), %rax
	movl	$1, (%rax)
	movq	_msi_pic@GOTPCREL(%rip), %rdi
	callq	_intr_register_pic
	movq	_MTX_DEF@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_msi_lock@GOTPCREL(%rip), %rdi
	leaq	L_.str.1(%rip), %rsi
	xorl	%edx, %edx
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_mtx_init                       ## TAILCALL
LBB0_9:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_cpu_vendor_id,4,2              ## @cpu_vendor_id
	.comm	_cpu_id,4,2                     ## @cpu_id
	.comm	_num_msi_irqs,8,3               ## @num_msi_irqs
	.comm	_num_io_irqs,8,3                ## @num_io_irqs
	.comm	_first_msi_irq,8,3              ## @first_msi_irq
	.comm	_UINT_MAX,8,3                   ## @UINT_MAX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"num_msi_irqs too high"

	.comm	_msi_enabled,4,2                ## @msi_enabled
	.comm	_msi_pic,4,2                    ## @msi_pic
	.comm	_msi_lock,4,2                   ## @msi_lock
L_.str.1:                               ## @.str.1
	.asciz	"msi"

	.comm	_MTX_DEF,4,2                    ## @MTX_DEF
	.comm	_msix_disable_migration,4,2     ## @msix_disable_migration
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_msi_init                       ; -- Begin function msi_init
	.p2align	2
_msi_init:                              ; @msi_init
	.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
Lloh0:
	adrp	x8, _cpu_vendor_id@GOTPAGE
Lloh1:
	ldr	x8, [x8, _cpu_vendor_id@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, #128
	b.eq	LBB0_6
; %bb.1:
	cmp	w8, #130
	b.eq	LBB0_6
; %bb.2:
	cmp	w8, #129
	b.ne	LBB0_5
; %bb.3:
Lloh3:
	adrp	x19, _cpu_id@GOTPAGE
Lloh4:
	ldr	x19, [x19, _cpu_id@GOTPAGEOFF]
	ldr	w0, [x19]
	bl	_CPUID_TO_FAMILY
	cmp	w0, #6
	b.ne	LBB0_5
; %bb.4:
	ldr	w0, [x19]
	bl	_CPUID_TO_MODEL
Lloh5:
	adrp	x8, _num_msi_irqs@GOTPAGE
Lloh6:
	ldr	x8, [x8, _num_msi_irqs@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	cmp	w0, #15
	ccmp	x8, #0, #4, ge
	b.ne	LBB0_7
LBB0_5:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_6:
Lloh8:
	adrp	x8, _num_msi_irqs@GOTPAGE
Lloh9:
	ldr	x8, [x8, _num_msi_irqs@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	cbz	x8, LBB0_5
LBB0_7:
Lloh11:
	adrp	x19, _num_io_irqs@GOTPAGE
Lloh12:
	ldr	x19, [x19, _num_io_irqs@GOTPAGEOFF]
	ldr	x9, [x19]
Lloh13:
	adrp	x20, _first_msi_irq@GOTPAGE
Lloh14:
	ldr	x20, [x20, _first_msi_irq@GOTPAGEOFF]
	str	x9, [x20]
Lloh15:
	adrp	x10, _UINT_MAX@GOTPAGE
Lloh16:
	ldr	x10, [x10, _UINT_MAX@GOTPAGEOFF]
Lloh17:
	ldr	x10, [x10]
	sub	x10, x10, x9
	cmp	x8, x10
	b.le	LBB0_9
; %bb.8:
Lloh18:
	adrp	x0, l_.str@PAGE
Lloh19:
	add	x0, x0, l_.str@PAGEOFF
	bl	_panic
	ldr	x9, [x20]
Lloh20:
	adrp	x8, _num_msi_irqs@GOTPAGE
Lloh21:
	ldr	x8, [x8, _num_msi_irqs@GOTPAGEOFF]
Lloh22:
	ldr	x8, [x8]
LBB0_9:
	add	x8, x8, x9
	str	x8, [x19]
Lloh23:
	adrp	x8, _msi_enabled@GOTPAGE
Lloh24:
	ldr	x8, [x8, _msi_enabled@GOTPAGEOFF]
	mov	w9, #1
Lloh25:
	str	w9, [x8]
Lloh26:
	adrp	x0, _msi_pic@GOTPAGE
Lloh27:
	ldr	x0, [x0, _msi_pic@GOTPAGEOFF]
	bl	_intr_register_pic
Lloh28:
	adrp	x8, _MTX_DEF@GOTPAGE
Lloh29:
	ldr	x8, [x8, _MTX_DEF@GOTPAGEOFF]
Lloh30:
	ldr	w3, [x8]
Lloh31:
	adrp	x0, _msi_lock@GOTPAGE
Lloh32:
	ldr	x0, [x0, _msi_lock@GOTPAGEOFF]
Lloh33:
	adrp	x1, l_.str.1@PAGE
Lloh34:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, #0
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_mtx_init
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGotStr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_cpu_vendor_id,4,2              ; @cpu_vendor_id
	.comm	_cpu_id,4,2                     ; @cpu_id
	.comm	_num_msi_irqs,8,3               ; @num_msi_irqs
	.comm	_num_io_irqs,8,3                ; @num_io_irqs
	.comm	_first_msi_irq,8,3              ; @first_msi_irq
	.comm	_UINT_MAX,8,3                   ; @UINT_MAX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"num_msi_irqs too high"

	.comm	_msi_enabled,4,2                ; @msi_enabled
	.comm	_msi_pic,4,2                    ; @msi_pic
	.comm	_msi_lock,4,2                   ; @msi_lock
l_.str.1:                               ; @.str.1
	.asciz	"msi"

	.comm	_MTX_DEF,4,2                    ; @MTX_DEF
	.comm	_msix_disable_migration,4,2     ; @msix_disable_migration
.subsections_via_symbols
