	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_biosmptable_detect             ## -- Begin function biosmptable_detect
	.p2align	4, 0x90
_biosmptable_detect:                    ## @biosmptable_detect
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_memopen
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	xorl	%eax, %eax
	callq	_biosmptable_find_mpfps
	movq	%rax, %r14
	testq	%rax, %rax
	je	LBB0_13
## %bb.3:
	movl	$2, %ebx
	cmpq	$0, (%r14)
	je	LBB0_4
LBB0_13:
	xorl	%eax, %eax
	callq	_memclose
	testq	%r14, %r14
	je	LBB0_18
LBB0_17:
	movq	%r14, %rdi
	callq	_free
	jmp	LBB0_18
LBB0_1:
	movl	$-1, %ebx
LBB0_18:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movl	12(%r14), %edi
	callq	_PTOV
	movl	%eax, %edi
	callq	_biosmptable_check_mpcth
	movl	$0, %ebx
	testq	%rax, %rax
	je	LBB0_13
## %bb.5:
	movq	%rax, %r15
	movl	8(%rax), %eax
	testl	%eax, %eax
	movq	%r15, -48(%rbp)                 ## 8-byte Spill
	jle	LBB0_6
## %bb.7:
	addq	$16, %r15
	leaq	LJTI0_0(%rip), %r13
	xorl	%r12d, %r12d
	xorl	%ebx, %ebx
	jmp	LBB0_8
LBB0_11:                                ##   in Loop: Header=BB0_8 Depth=1
	leaq	4(%r15), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movsbl	8(%r15), %esi
	movq	_PROCENTRY_FLAG_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	4(%r15), %eax
	leaq	L_.str.1(%rip), %rdx
	leaq	L_.str.2(%rip), %rax
	cmoveq	%rax, %rdx
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_warnx
	movq	_PROCENTRY_FLAG_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	4(%r15), %eax
	cmpl	$1, %eax
	sbbl	$-1, %ebx
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	8(%rax), %eax
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_8 Depth=1
	incl	%r12d
	cmpl	%eax, %r12d
	jge	LBB0_15
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movsbl	(%r15), %ecx
	cmpl	$4, %ecx
	ja	LBB0_14
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movslq	(%r13,%rcx,4), %rcx
	addq	%r13, %rcx
	jmpq	*%rcx
LBB0_10:                                ##   in Loop: Header=BB0_8 Depth=1
	addq	$4, %r15
	jmp	LBB0_12
LBB0_6:
	xorl	%ebx, %ebx
	jmp	LBB0_15
LBB0_14:
	movsbl	%cl, %esi
	leaq	L_.str.3(%rip), %rdi
	xorl	%eax, %eax
	callq	_warnx
LBB0_15:
	xorl	%eax, %eax
	callq	_memclose
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_free
	testq	%r14, %r14
	jne	LBB0_17
	jmp	LBB0_18
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_11, LBB0_11-LJTI0_0
.set L0_0_set_10, LBB0_10-LJTI0_0
LJTI0_0:
	.long	L0_0_set_11
	.long	L0_0_set_10
	.long	L0_0_set_10
	.long	L0_0_set_10
	.long	L0_0_set_10
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"MPTable: Found CPU APIC ID %d %s"

	.comm	_PROCENTRY_FLAG_EN,4,2          ## @PROCENTRY_FLAG_EN
L_.str.1:                               ## @.str.1
	.asciz	"enabled"

L_.str.2:                               ## @.str.2
	.asciz	"disabled"

L_.str.3:                               ## @.str.3
	.asciz	"unknown mptable entry type (%d)"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_biosmptable_detect             ; -- Begin function biosmptable_detect
	.p2align	2
_biosmptable_detect:                    ; @biosmptable_detect
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	bl	_memopen
	cbz	w0, LBB0_4
; %bb.1:
	bl	_biosmptable_find_mpfps
	mov	x19, x0
	cbz	x0, LBB0_13
; %bb.2:
	ldr	x8, [x19]
	cbz	x8, LBB0_5
; %bb.3:
	mov	w20, #2
	bl	_memclose
	cbnz	x19, LBB0_14
	b	LBB0_15
LBB0_4:
	mov	w20, #-1
	b	LBB0_15
LBB0_5:
	ldr	w0, [x19, #12]
	bl	_PTOV
	bl	_biosmptable_check_mpcth
	cbz	x0, LBB0_13
; %bb.6:
	mov	x21, x0
	ldr	w8, [x0, #8]
	cmp	w8, #1
	b.lt	LBB0_16
; %bb.7:
	mov	w23, #0
	mov	w20, #0
	add	x24, x21, #16
Lloh0:
	adrp	x25, lJTI0_0@PAGE
Lloh1:
	add	x25, x25, lJTI0_0@PAGEOFF
Lloh2:
	adrp	x26, _PROCENTRY_FLAG_EN@GOTPAGE
Lloh3:
	ldr	x26, [x26, _PROCENTRY_FLAG_EN@GOTPAGEOFF]
Lloh4:
	adrp	x27, l_.str.1@PAGE
Lloh5:
	add	x27, x27, l_.str.1@PAGEOFF
Lloh6:
	adrp	x28, l_.str.2@PAGE
Lloh7:
	add	x28, x28, l_.str.2@PAGEOFF
Lloh8:
	adrp	x22, l_.str@PAGE
Lloh9:
	add	x22, x22, l_.str@PAGEOFF
	b	LBB0_10
LBB0_8:                                 ;   in Loop: Header=BB0_10 Depth=1
	ldr	w8, [x24, #4]!
	ldrsb	w1, [x24, #4]
	ldr	w9, [x26]
	tst	w9, w8
	csel	x8, x28, x27, eq
	str	x8, [sp]
	mov	x0, x22
	bl	_warnx
	ldr	w8, [x24]
	ldr	w9, [x26]
	tst	w9, w8
	cinc	w20, w20, ne
	ldr	w8, [x21, #8]
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=1
	add	w23, w23, #1
	cmp	w23, w8
	b.ge	LBB0_18
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	ldrsb	w9, [x24]
	cmp	w9, #4
	b.hi	LBB0_17
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	adr	x10, LBB0_8
	ldrb	w11, [x25, x9]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_12:                                ;   in Loop: Header=BB0_10 Depth=1
	add	x24, x24, #4
	b	LBB0_9
LBB0_13:
	mov	w20, #0
	bl	_memclose
	cbz	x19, LBB0_15
LBB0_14:
	mov	x0, x19
	bl	_free
LBB0_15:
	mov	x0, x20
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_16:
	mov	w20, #0
	b	LBB0_18
LBB0_17:
	and	w8, w9, #0xff
	sxtb	w1, w8
Lloh10:
	adrp	x0, l_.str.3@PAGE
Lloh11:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_warnx
LBB0_18:
	bl	_memclose
	mov	x0, x21
	bl	_free
	cbnz	x19, LBB0_14
	b	LBB0_15
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh10, Lloh11
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_8-LBB0_8)>>2
	.byte	(LBB0_12-LBB0_8)>>2
	.byte	(LBB0_12-LBB0_8)>>2
	.byte	(LBB0_12-LBB0_8)>>2
	.byte	(LBB0_12-LBB0_8)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"MPTable: Found CPU APIC ID %d %s"

	.comm	_PROCENTRY_FLAG_EN,4,2          ; @PROCENTRY_FLAG_EN
l_.str.1:                               ; @.str.1
	.asciz	"enabled"

l_.str.2:                               ; @.str.2
	.asciz	"disabled"

l_.str.3:                               ; @.str.3
	.asciz	"unknown mptable entry type (%d)"

.subsections_via_symbols
