	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pl310_set_way_sizes
_pl310_set_way_sizes:                   ## @pl310_set_way_sizes
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	_PL310_AUX_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_pl310_read4
	movq	_AUX_CTRL_WAY_SIZE_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	andl	%eax, %edx
	movq	_AUX_CTRL_WAY_SIZE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %edx
	addb	$13, %dl
	movl	$1, %esi
	movl	%edx, %ecx
	shll	%cl, %esi
	movq	_g_way_size@GOTPCREL(%rip), %rcx
	movl	%esi, (%rcx)
	movq	_AUX_CTRL_ASSOCIATIVITY_SHIFT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	xorl	%esi, %esi
	btl	%ecx, %eax
	setb	%sil
	leal	8(,%rsi,8), %eax
	movq	_g_ways_assoc@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movl	$-1, %esi
	movl	%eax, %ecx
	shll	%cl, %esi
	notl	%esi
	movl	%edx, %ecx
	shll	%cl, %eax
	movq	_g_l2cache_way_mask@GOTPCREL(%rip), %rcx
	movl	%esi, (%rcx)
	movq	_g_l2cache_size@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PL310_AUX_CTRL,4,2             ## @PL310_AUX_CTRL
	.comm	_AUX_CTRL_WAY_SIZE_MASK,4,2     ## @AUX_CTRL_WAY_SIZE_MASK
	.comm	_AUX_CTRL_WAY_SIZE_SHIFT,4,2    ## @AUX_CTRL_WAY_SIZE_SHIFT
	.comm	_g_way_size,4,2                 ## @g_way_size
	.comm	_AUX_CTRL_ASSOCIATIVITY_SHIFT,4,2 ## @AUX_CTRL_ASSOCIATIVITY_SHIFT
	.comm	_g_ways_assoc,4,2               ## @g_ways_assoc
	.comm	_g_l2cache_way_mask,4,2         ## @g_l2cache_way_mask
	.comm	_g_l2cache_size,4,2             ## @g_l2cache_size
	.no_dead_strip	_pl310_set_way_sizes
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pl310_set_way_sizes
_pl310_set_way_sizes:                   ; @pl310_set_way_sizes
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh0:
	adrp	x8, _PL310_AUX_CTRL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PL310_AUX_CTRL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_pl310_read4
Lloh3:
	adrp	x8, _AUX_CTRL_WAY_SIZE_MASK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AUX_CTRL_WAY_SIZE_MASK@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _AUX_CTRL_WAY_SIZE_SHIFT@GOTPAGE
Lloh7:
	ldr	x9, [x9, _AUX_CTRL_WAY_SIZE_SHIFT@GOTPAGEOFF]
	and	w8, w8, w0
Lloh8:
	ldr	w9, [x9]
	asr	w8, w8, w9
	add	w8, w8, #13
	mov	w9, #1
	lsl	w9, w9, w8
Lloh9:
	adrp	x10, _g_way_size@GOTPAGE
Lloh10:
	ldr	x10, [x10, _g_way_size@GOTPAGEOFF]
Lloh11:
	str	w9, [x10]
Lloh12:
	adrp	x9, _AUX_CTRL_ASSOCIATIVITY_SHIFT@GOTPAGE
Lloh13:
	ldr	x9, [x9, _AUX_CTRL_ASSOCIATIVITY_SHIFT@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	lsr	w9, w0, w9
	tst	w9, #0x1
	mov	w9, #16
	mov	w10, #8
Lloh15:
	adrp	x11, _g_ways_assoc@GOTPAGE
Lloh16:
	ldr	x11, [x11, _g_ways_assoc@GOTPAGEOFF]
	csel	w9, w10, w9, eq
Lloh17:
	str	w9, [x11]
	mov	w10, #-1
	lsl	w10, w10, w9
Lloh18:
	adrp	x11, _g_l2cache_way_mask@GOTPAGE
Lloh19:
	ldr	x11, [x11, _g_l2cache_way_mask@GOTPAGEOFF]
	mvn	w10, w10
Lloh20:
	str	w10, [x11]
	lsl	w8, w9, w8
Lloh21:
	adrp	x9, _g_l2cache_size@GOTPAGE
Lloh22:
	ldr	x9, [x9, _g_l2cache_size@GOTPAGEOFF]
Lloh23:
	str	w8, [x9]
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotStr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotStr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotStr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotStr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_PL310_AUX_CTRL,4,2             ; @PL310_AUX_CTRL
	.comm	_AUX_CTRL_WAY_SIZE_MASK,4,2     ; @AUX_CTRL_WAY_SIZE_MASK
	.comm	_AUX_CTRL_WAY_SIZE_SHIFT,4,2    ; @AUX_CTRL_WAY_SIZE_SHIFT
	.comm	_g_way_size,4,2                 ; @g_way_size
	.comm	_AUX_CTRL_ASSOCIATIVITY_SHIFT,4,2 ; @AUX_CTRL_ASSOCIATIVITY_SHIFT
	.comm	_g_ways_assoc,4,2               ; @g_ways_assoc
	.comm	_g_l2cache_way_mask,4,2         ; @g_l2cache_way_mask
	.comm	_g_l2cache_size,4,2             ; @g_l2cache_size
	.no_dead_strip	_pl310_set_way_sizes
.subsections_via_symbols
