	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function aspm_calc_l1ss_info
_aspm_calc_l1ss_info:                   ## @aspm_calc_l1ss_info
	.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
	movl	4(%rsi), %eax
	movl	%eax, 16(%rdi)
	movl	4(%rdx), %eax
	movl	%eax, 12(%rdi)
	movq	$0, 4(%rdi)
	movq	_ASPM_STATE_L1_2_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rdi)
	je	LBB0_5
## %bb.1:
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movq	_PCI_L1SS_CAP_CM_RESTORE_TIME@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%rbx), %edi
	andl	%esi, %edi
	sarl	$8, %edi
	andl	(%rdx), %esi
	sarl	$8, %esi
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	callq	_max
                                        ## kill: def $eax killed $eax def $rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %r12d
	movq	_PCI_L1SS_CAP_P_PWR_ON_VALUE@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movl	%r13d, %r14d
	andl	%r12d, %r14d
	sarl	$19, %r14d
	movq	_PCI_L1SS_CAP_P_PWR_ON_SCALE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	%eax, %r12d
	sarl	$16, %r12d
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	(%rcx), %ebx
	andl	%ebx, %r13d
	sarl	$19, %r13d
	andl	%eax, %ebx
	sarl	$16, %ebx
	movl	24(%r15), %edi
	movl	%r12d, %esi
	movl	%r14d, %edx
	callq	_calc_l1ss_pwron
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movl	20(%r15), %edi
	movl	%ebx, %esi
	movl	%r13d, %edx
	callq	_calc_l1ss_pwron
	cmpq	%rax, -48(%rbp)                 ## 8-byte Folded Reload
	jle	LBB0_3
## %bb.2:
	leal	(,%r14,8), %eax
	orl	%r12d, %eax
	orl	%eax, 8(%r15)
	movl	24(%r15), %edi
	movl	%r12d, %esi
	movl	%r14d, %edx
	jmp	LBB0_4
LBB0_3:
	leal	(,%r13,8), %eax
	orl	%ebx, %eax
	orl	%eax, 8(%r15)
	movl	20(%r15), %edi
	movl	%ebx, %esi
	movl	%r13d, %edx
LBB0_4:
	callq	_calc_l1ss_pwron
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	leal	(%rbx,%rax), %edi
	addl	$6, %edi
	leaq	-56(%rbp), %rsi
	leaq	-52(%rbp), %rdx
	callq	_encode_l12_threshold
	shll	$8, %ebx
	movl	-56(%rbp), %eax
	shll	$29, %eax
	movl	-52(%rbp), %ecx
	shll	$16, %ecx
	orl	%eax, %ecx
	orl	%ebx, %ecx
	orl	%ecx, 4(%r15)
LBB0_5:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ASPM_STATE_L1_2_MASK,4,2       ## @ASPM_STATE_L1_2_MASK
	.comm	_PCI_L1SS_CAP_CM_RESTORE_TIME,4,2 ## @PCI_L1SS_CAP_CM_RESTORE_TIME
	.comm	_PCI_L1SS_CAP_P_PWR_ON_VALUE,4,2 ## @PCI_L1SS_CAP_P_PWR_ON_VALUE
	.comm	_PCI_L1SS_CAP_P_PWR_ON_SCALE,4,2 ## @PCI_L1SS_CAP_P_PWR_ON_SCALE
	.no_dead_strip	_aspm_calc_l1ss_info
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function aspm_calc_l1ss_info
_aspm_calc_l1ss_info:                   ; @aspm_calc_l1ss_info
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	ldr	w8, [x1, #4]
	ldr	w9, [x2, #4]
	stp	w9, w8, [x0, #12]
	stp	wzr, wzr, [x0, #4]
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _ASPM_STATE_L1_2_MASK@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ASPM_STATE_L1_2_MASK@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_5
; %bb.1:
	mov	x22, x2
	mov	x21, x1
	mov	x19, x0
	ldr	w8, [x1]
Lloh3:
	adrp	x9, _PCI_L1SS_CAP_CM_RESTORE_TIME@GOTPAGE
Lloh4:
	ldr	x9, [x9, _PCI_L1SS_CAP_CM_RESTORE_TIME@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	and	w8, w9, w8
	asr	w0, w8, #8
	ldr	w8, [x2]
	and	w8, w8, w9
	asr	w1, w8, #8
	bl	_max
	mov	x20, x0
	ldr	w8, [x21]
Lloh6:
	adrp	x9, _PCI_L1SS_CAP_P_PWR_ON_VALUE@GOTPAGE
Lloh7:
	ldr	x9, [x9, _PCI_L1SS_CAP_P_PWR_ON_VALUE@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	and	w10, w9, w8
	asr	w21, w10, #19
Lloh9:
	adrp	x10, _PCI_L1SS_CAP_P_PWR_ON_SCALE@GOTPAGE
Lloh10:
	ldr	x10, [x10, _PCI_L1SS_CAP_P_PWR_ON_SCALE@GOTPAGEOFF]
Lloh11:
	ldr	w10, [x10]
	and	w8, w10, w8
	asr	w23, w8, #16
	ldr	w8, [x22]
	and	w9, w8, w9
	asr	w22, w9, #19
	and	w8, w8, w10
	asr	w24, w8, #16
	ldr	w0, [x19, #24]
	mov	x1, x23
	mov	x2, x21
	bl	_calc_l1ss_pwron
	mov	x25, x0
	ldr	w0, [x19, #20]
	mov	x1, x24
	mov	x2, x22
	bl	_calc_l1ss_pwron
	cmp	x25, x0
	b.le	LBB0_3
; %bb.2:
	orr	w8, w23, w21, lsl #3
	ldr	w9, [x19, #8]
	orr	w8, w8, w9
	str	w8, [x19, #8]
	ldr	w0, [x19, #24]
	mov	x1, x23
	mov	x2, x21
	b	LBB0_4
LBB0_3:
	orr	w8, w24, w22, lsl #3
	ldr	w9, [x19, #8]
	orr	w8, w8, w9
	str	w8, [x19, #8]
	ldr	w0, [x19, #20]
	mov	x1, x24
	mov	x2, x22
LBB0_4:
	bl	_calc_l1ss_pwron
	add	w8, w20, w0
	add	w0, w8, #6
	add	x1, sp, #12
	add	x2, sp, #8
	bl	_encode_l12_threshold
	ldp	w9, w8, [sp, #8]
	lsl	w8, w8, #29
	orr	w8, w8, w20, lsl #8
	orr	w8, w8, w9, lsl #16
	ldr	w9, [x19, #4]
	orr	w8, w8, w9
	str	w8, [x19, #4]
LBB0_5:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ASPM_STATE_L1_2_MASK,4,2       ; @ASPM_STATE_L1_2_MASK
	.comm	_PCI_L1SS_CAP_CM_RESTORE_TIME,4,2 ; @PCI_L1SS_CAP_CM_RESTORE_TIME
	.comm	_PCI_L1SS_CAP_P_PWR_ON_VALUE,4,2 ; @PCI_L1SS_CAP_P_PWR_ON_VALUE
	.comm	_PCI_L1SS_CAP_P_PWR_ON_SCALE,4,2 ; @PCI_L1SS_CAP_P_PWR_ON_SCALE
	.no_dead_strip	_aspm_calc_l1ss_info
.subsections_via_symbols
