	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function calculate_cfg_state
_calculate_cfg_state:                   ## @calculate_cfg_state
	.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
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %r14d
	movq	_SPA_CFG_DR@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	_SPRN_LPCR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_mfspr
	movl	%eax, %ebx
	movq	_LPCR_TC@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	je	LBB0_2
## %bb.1:
	movq	_SPA_CFG_TC@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_2:
	orl	%r15d, %ebx
	xorl	%eax, %eax
	callq	_radix_enabled
	testq	%rax, %rax
	jne	LBB0_3
## %bb.4:
	movq	_SPA_CFG_XLAT_hpt@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_3:
	movq	_SPA_CFG_XLAT_ror@GOTPCREL(%rip), %rax
LBB0_5:
	orl	(%rax), %ebx
	movq	_SPA_CFG_HV@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	testl	%r14d, %r14d
	je	LBB0_7
## %bb.6:
	xorl	%eax, %eax
	callq	_mfmsr
	movq	_MSR_SF@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_9
LBB0_8:
	movq	_SPA_CFG_SF@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
LBB0_9:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_SPA_CFG_PR@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	movq	_current@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_TIF_32BIT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_test_tsk_thread_flag
	testl	%eax, %eax
	jne	LBB0_9
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_SPA_CFG_DR,4,2                 ## @SPA_CFG_DR
	.comm	_SPRN_LPCR,4,2                  ## @SPRN_LPCR
	.comm	_LPCR_TC,4,2                    ## @LPCR_TC
	.comm	_SPA_CFG_TC,4,2                 ## @SPA_CFG_TC
	.comm	_SPA_CFG_XLAT_ror,4,2           ## @SPA_CFG_XLAT_ror
	.comm	_SPA_CFG_XLAT_hpt,4,2           ## @SPA_CFG_XLAT_hpt
	.comm	_SPA_CFG_HV,4,2                 ## @SPA_CFG_HV
	.comm	_MSR_SF,4,2                     ## @MSR_SF
	.comm	_SPA_CFG_SF,4,2                 ## @SPA_CFG_SF
	.comm	_SPA_CFG_PR,4,2                 ## @SPA_CFG_PR
	.comm	_current,4,2                    ## @current
	.comm	_TIF_32BIT,4,2                  ## @TIF_32BIT
	.no_dead_strip	_calculate_cfg_state
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function calculate_cfg_state
_calculate_cfg_state:                   ; @calculate_cfg_state
	.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
	mov	x20, x0
Lloh0:
	adrp	x8, _SPA_CFG_DR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SPA_CFG_DR@GOTPAGEOFF]
Lloh2:
	ldr	w19, [x8]
Lloh3:
	adrp	x8, _SPRN_LPCR@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SPRN_LPCR@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_mfspr
Lloh6:
	adrp	x8, _LPCR_TC@GOTPAGE
Lloh7:
	ldr	x8, [x8, _LPCR_TC@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
Lloh9:
	adrp	x9, _SPA_CFG_TC@GOTPAGE
Lloh10:
	ldr	x9, [x9, _SPA_CFG_TC@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	tst	w8, w0
	csel	w8, wzr, w9, eq
	orr	w19, w8, w19
	bl	_radix_enabled
Lloh12:
	adrp	x8, _SPA_CFG_XLAT_hpt@GOTPAGE
Lloh13:
	ldr	x8, [x8, _SPA_CFG_XLAT_hpt@GOTPAGEOFF]
Lloh14:
	adrp	x9, _SPA_CFG_XLAT_ror@GOTPAGE
Lloh15:
	ldr	x9, [x9, _SPA_CFG_XLAT_ror@GOTPAGEOFF]
	cmp	x0, #0
	csel	x8, x8, x9, eq
	ldr	w8, [x8]
	orr	w8, w19, w8
Lloh16:
	adrp	x9, _SPA_CFG_HV@GOTPAGE
Lloh17:
	ldr	x9, [x9, _SPA_CFG_HV@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	orr	w19, w8, w9
	cbz	w20, LBB0_4
; %bb.1:
	bl	_mfmsr
Lloh19:
	adrp	x8, _MSR_SF@GOTPAGE
Lloh20:
	ldr	x8, [x8, _MSR_SF@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_3
LBB0_2:
Lloh22:
	adrp	x8, _SPA_CFG_SF@GOTPAGE
Lloh23:
	ldr	x8, [x8, _SPA_CFG_SF@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	orr	w19, w8, w19
LBB0_3:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_4:
Lloh25:
	adrp	x8, _SPA_CFG_PR@GOTPAGE
Lloh26:
	ldr	x8, [x8, _SPA_CFG_PR@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
	orr	w19, w8, w19
Lloh28:
	adrp	x8, _current@GOTPAGE
Lloh29:
	ldr	x8, [x8, _current@GOTPAGEOFF]
Lloh30:
	ldr	w0, [x8]
Lloh31:
	adrp	x8, _TIF_32BIT@GOTPAGE
Lloh32:
	ldr	x8, [x8, _TIF_32BIT@GOTPAGEOFF]
Lloh33:
	ldr	w1, [x8]
	bl	_test_tsk_thread_flag
	cbnz	w0, LBB0_3
	b	LBB0_2
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_SPA_CFG_DR,4,2                 ; @SPA_CFG_DR
	.comm	_SPRN_LPCR,4,2                  ; @SPRN_LPCR
	.comm	_LPCR_TC,4,2                    ; @LPCR_TC
	.comm	_SPA_CFG_TC,4,2                 ; @SPA_CFG_TC
	.comm	_SPA_CFG_XLAT_ror,4,2           ; @SPA_CFG_XLAT_ror
	.comm	_SPA_CFG_XLAT_hpt,4,2           ; @SPA_CFG_XLAT_hpt
	.comm	_SPA_CFG_HV,4,2                 ; @SPA_CFG_HV
	.comm	_MSR_SF,4,2                     ; @MSR_SF
	.comm	_SPA_CFG_SF,4,2                 ; @SPA_CFG_SF
	.comm	_SPA_CFG_PR,4,2                 ; @SPA_CFG_PR
	.comm	_current,4,2                    ; @current
	.comm	_TIF_32BIT,4,2                  ; @TIF_32BIT
	.no_dead_strip	_calculate_cfg_state
.subsections_via_symbols
