	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fpuinit_bsp1
_fpuinit_bsp1:                          ## @fpuinit_bsp1
	.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	%rbx
	subq	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	_use_xsave@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_9
## %bb.1:
	leaq	-48(%rbp), %rdx
	movl	$13, %edi
	xorl	%esi, %esi
	callq	_cpuid_count
	movq	_XFEATURE_ENABLED_X87@GOTPCREL(%rip), %r14
	movq	_XFEATURE_ENABLED_SSE@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	orl	(%r14), %eax
	movq	_xsave_mask@GOTPCREL(%rip), %r15
	movl	%eax, (%r15)
	movl	-48(%rbp), %esi
	movl	%esi, %ecx
	notl	%ecx
	testl	%ecx, %eax
	je	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rdi
	callq	_panic
LBB0_3:
	leaq	L_.str.1(%rip), %rdi
	leaq	-52(%rbp), %rsi
	callq	_TUNABLE_ULONG_FETCH
	movl	(%rbx), %eax
	orl	(%r14), %eax
	orl	-52(%rbp), %eax
	movl	%eax, -52(%rbp)
	andl	(%r15), %eax
	movl	%eax, (%r15)
	movq	_XFEATURE_AVX512@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%eax, %edx
	notl	%edx
	testl	%edx, %ecx
	je	LBB0_5
## %bb.4:
	notl	%ecx
	andl	%ecx, %eax
	movl	%eax, (%r15)
LBB0_5:
	movq	_XFEATURE_MPX@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%eax, %edx
	notl	%edx
	testl	%edx, %ecx
	je	LBB0_7
## %bb.6:
	notl	%ecx
	andl	%ecx, %eax
	movl	%eax, (%r15)
LBB0_7:
	leaq	-48(%rbp), %rdx
	movl	$13, %edi
	movl	$1, %esi
	callq	_cpuid_count
	movq	_CPUID_EXTSTATE_XSAVEOPT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -48(%rbp)
	je	LBB0_9
## %bb.8:
	xorl	%eax, %eax
	callq	_disable_wp
	movq	_ctx_switch_xsave@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	orl	$16, 12(%rcx)
	movl	%eax, %edi
	callq	_restore_wp
LBB0_9:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_11
## %bb.10:
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_use_xsave,4,2                  ## @use_xsave
	.comm	_XFEATURE_ENABLED_X87,4,2       ## @XFEATURE_ENABLED_X87
	.comm	_XFEATURE_ENABLED_SSE,4,2       ## @XFEATURE_ENABLED_SSE
	.comm	_xsave_mask,4,2                 ## @xsave_mask
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"CPU0 does not support X87 or SSE: %x"

L_.str.1:                               ## @.str.1
	.asciz	"hw.xsave_mask"

	.comm	_XFEATURE_AVX512,4,2            ## @XFEATURE_AVX512
	.comm	_XFEATURE_MPX,4,2               ## @XFEATURE_MPX
	.comm	_CPUID_EXTSTATE_XSAVEOPT,4,2    ## @CPUID_EXTSTATE_XSAVEOPT
	.comm	_ctx_switch_xsave,8,3           ## @ctx_switch_xsave
	.no_dead_strip	_fpuinit_bsp1
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fpuinit_bsp1
_fpuinit_bsp1:                          ; @fpuinit_bsp1
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
Lloh3:
	adrp	x8, _use_xsave@GOTPAGE
Lloh4:
	ldr	x8, [x8, _use_xsave@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cbz	w8, LBB0_9
; %bb.1:
	add	x2, sp, #8
	mov	w0, #13
	mov	w1, #0
	bl	_cpuid_count
Lloh6:
	adrp	x20, _XFEATURE_ENABLED_X87@GOTPAGE
Lloh7:
	ldr	x20, [x20, _XFEATURE_ENABLED_X87@GOTPAGEOFF]
	ldr	w8, [x20]
Lloh8:
	adrp	x21, _XFEATURE_ENABLED_SSE@GOTPAGE
Lloh9:
	ldr	x21, [x21, _XFEATURE_ENABLED_SSE@GOTPAGEOFF]
	ldr	w9, [x21]
	orr	w8, w9, w8
Lloh10:
	adrp	x19, _xsave_mask@GOTPAGE
Lloh11:
	ldr	x19, [x19, _xsave_mask@GOTPAGEOFF]
	str	w8, [x19]
	ldr	w1, [sp, #8]
	bics	wzr, w8, w1
	b.eq	LBB0_3
; %bb.2:
Lloh12:
	adrp	x0, l_.str@PAGE
Lloh13:
	add	x0, x0, l_.str@PAGEOFF
	bl	_panic
LBB0_3:
Lloh14:
	adrp	x0, l_.str.1@PAGE
Lloh15:
	add	x0, x0, l_.str.1@PAGEOFF
	add	x1, sp, #4
	bl	_TUNABLE_ULONG_FETCH
	ldr	w8, [x20]
	ldr	w9, [x21]
	orr	w8, w9, w8
	ldr	w9, [sp, #4]
	orr	w8, w8, w9
	str	w8, [sp, #4]
	ldr	w9, [x19]
	and	w8, w9, w8
	str	w8, [x19]
Lloh16:
	adrp	x9, _XFEATURE_AVX512@GOTPAGE
Lloh17:
	ldr	x9, [x9, _XFEATURE_AVX512@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	bics	wzr, w9, w8
	b.eq	LBB0_5
; %bb.4:
	bic	w8, w8, w9
	str	w8, [x19]
LBB0_5:
Lloh19:
	adrp	x9, _XFEATURE_MPX@GOTPAGE
Lloh20:
	ldr	x9, [x9, _XFEATURE_MPX@GOTPAGEOFF]
Lloh21:
	ldr	w9, [x9]
	bics	wzr, w9, w8
	b.eq	LBB0_7
; %bb.6:
	bic	w8, w8, w9
	str	w8, [x19]
LBB0_7:
	add	x2, sp, #8
	mov	w0, #13
	mov	w1, #1
	bl	_cpuid_count
	ldr	w8, [sp, #8]
Lloh22:
	adrp	x9, _CPUID_EXTSTATE_XSAVEOPT@GOTPAGE
Lloh23:
	ldr	x9, [x9, _CPUID_EXTSTATE_XSAVEOPT@GOTPAGEOFF]
Lloh24:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_9
; %bb.8:
	bl	_disable_wp
Lloh25:
	adrp	x8, _ctx_switch_xsave@GOTPAGE
Lloh26:
	ldr	x8, [x8, _ctx_switch_xsave@GOTPAGEOFF]
Lloh27:
	ldr	x8, [x8]
	ldr	w9, [x8, #12]
	orr	w9, w9, #0x10
	str	w9, [x8, #12]
	bl	_restore_wp
LBB0_9:
	ldr	x8, [sp, #24]
Lloh28:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh29:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh30:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_11
; %bb.10:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_11:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.cfi_endproc
                                        ; -- End function
	.comm	_use_xsave,4,2                  ; @use_xsave
	.comm	_XFEATURE_ENABLED_X87,4,2       ; @XFEATURE_ENABLED_X87
	.comm	_XFEATURE_ENABLED_SSE,4,2       ; @XFEATURE_ENABLED_SSE
	.comm	_xsave_mask,4,2                 ; @xsave_mask
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"CPU0 does not support X87 or SSE: %x"

l_.str.1:                               ; @.str.1
	.asciz	"hw.xsave_mask"

	.comm	_XFEATURE_AVX512,4,2            ; @XFEATURE_AVX512
	.comm	_XFEATURE_MPX,4,2               ; @XFEATURE_MPX
	.comm	_CPUID_EXTSTATE_XSAVEOPT,4,2    ; @CPUID_EXTSTATE_XSAVEOPT
	.comm	_ctx_switch_xsave,8,3           ; @ctx_switch_xsave
	.no_dead_strip	_fpuinit_bsp1
.subsections_via_symbols
