	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gen8_update_reg_state_unlocked
_gen8_update_reg_state_unlocked:        ## @gen8_update_reg_state_unlocked
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r14
	movq	%rdx, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	%rsi, -96(%rbp)                 ## 8-byte Spill
	movq	8(%rsi), %rax
	movq	(%rax), %rax
	movq	(%rax), %rbx
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movq	8(%rax), %rsi
	movq	_EU_PERF_CNTL0@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -80(%rbp)
	movq	_EU_PERF_CNTL1@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -76(%rbp)
	movq	_EU_PERF_CNTL2@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -72(%rbp)
	movq	_EU_PERF_CNTL3@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -68(%rbp)
	movq	_EU_PERF_CNTL4@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -64(%rbp)
	movq	_EU_PERF_CNTL5@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -60(%rbp)
	movq	_EU_PERF_CNTL6@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -56(%rbp)
	movq	_GEN8_OACTXCONTROL@GOTPCREL(%rip), %rdx
	movl	(%rdi), %eax
	movq	_GEN8_OA_TIMER_PERIOD_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %eax
	movl	(%rdx), %edx
	xorl	%ecx, %ecx
	cmpq	$0, 8(%rdi)
	je	LBB0_2
## %bb.1:
	movq	_GEN8_OA_TIMER_ENABLE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
LBB0_2:
	orl	%eax, %ecx
	movq	_GEN8_OA_COUNTER_RESUME@GOTPCREL(%rip), %rax
	orl	(%rax), %ecx
	movq	%r13, %rdi
	callq	_CTX_REG
	leaq	-80(%rbp), %rdi
	callq	_ARRAY_SIZE
	testl	%eax, %eax
	jle	LBB0_5
## %bb.3:
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	-80(%rbp,%r15,4), %r12d
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_oa_config_flex_reg
	movq	%r13, %rdi
	movq	%rbx, %rsi
	movl	%r12d, %edx
	movl	%eax, %ecx
	callq	_CTX_REG
	incq	%r15
	leaq	-80(%rbp), %rdi
	callq	_ARRAY_SIZE
	cltq
	addq	$2, %rbx
	cmpq	%rax, %r15
	jl	LBB0_4
LBB0_5:
	movq	_CTX_R_PWR_CLK_STATE@GOTPCREL(%rip), %rax
	movq	(%rax), %r14
	movq	_GEN8_R_PWR_CLK_STATE@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movq	-96(%rbp), %rsi                 ## 8-byte Reload
	callq	_intel_sseu_make_rpcs
	movq	%r13, %rdi
	movq	%r14, %rsi
	movl	%ebx, %edx
	movl	%eax, %ecx
	callq	_CTX_REG
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_7
## %bb.6:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_EU_PERF_CNTL0,4,2              ## @EU_PERF_CNTL0
	.comm	_EU_PERF_CNTL1,4,2              ## @EU_PERF_CNTL1
	.comm	_EU_PERF_CNTL2,4,2              ## @EU_PERF_CNTL2
	.comm	_EU_PERF_CNTL3,4,2              ## @EU_PERF_CNTL3
	.comm	_EU_PERF_CNTL4,4,2              ## @EU_PERF_CNTL4
	.comm	_EU_PERF_CNTL5,4,2              ## @EU_PERF_CNTL5
	.comm	_EU_PERF_CNTL6,4,2              ## @EU_PERF_CNTL6
	.comm	_GEN8_OACTXCONTROL,4,2          ## @GEN8_OACTXCONTROL
	.comm	_GEN8_OA_TIMER_PERIOD_SHIFT,4,2 ## @GEN8_OA_TIMER_PERIOD_SHIFT
	.comm	_GEN8_OA_TIMER_ENABLE,4,2       ## @GEN8_OA_TIMER_ENABLE
	.comm	_GEN8_OA_COUNTER_RESUME,4,2     ## @GEN8_OA_COUNTER_RESUME
	.comm	_CTX_R_PWR_CLK_STATE,8,3        ## @CTX_R_PWR_CLK_STATE
	.comm	_GEN8_R_PWR_CLK_STATE,4,2       ## @GEN8_R_PWR_CLK_STATE
	.no_dead_strip	_gen8_update_reg_state_unlocked
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gen8_update_reg_state_unlocked
_gen8_update_reg_state_unlocked:        ; @gen8_update_reg_state_unlocked
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	mov	x21, x3
	mov	x19, x2
	mov	x20, x1
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
	ldr	x8, [x1, #8]
	ldr	x22, [x8]
	ldp	x23, x1, [x22]
Lloh3:
	adrp	x8, _EU_PERF_CNTL0@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EU_PERF_CNTL0@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _EU_PERF_CNTL1@GOTPAGE
Lloh7:
	ldr	x9, [x9, _EU_PERF_CNTL1@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #12]
Lloh9:
	adrp	x8, _EU_PERF_CNTL2@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EU_PERF_CNTL2@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
Lloh12:
	adrp	x9, _EU_PERF_CNTL3@GOTPAGE
Lloh13:
	ldr	x9, [x9, _EU_PERF_CNTL3@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
Lloh15:
	adrp	x10, _EU_PERF_CNTL4@GOTPAGE
Lloh16:
	ldr	x10, [x10, _EU_PERF_CNTL4@GOTPAGEOFF]
	stp	w8, w9, [sp, #20]
Lloh17:
	ldr	w8, [x10]
Lloh18:
	adrp	x9, _EU_PERF_CNTL5@GOTPAGE
Lloh19:
	ldr	x9, [x9, _EU_PERF_CNTL5@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
	stp	w8, w9, [sp, #28]
Lloh21:
	adrp	x8, _EU_PERF_CNTL6@GOTPAGE
Lloh22:
	ldr	x8, [x8, _EU_PERF_CNTL6@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
Lloh24:
	adrp	x9, _GEN8_OACTXCONTROL@GOTPAGE
Lloh25:
	ldr	x9, [x9, _GEN8_OACTXCONTROL@GOTPAGEOFF]
	str	w8, [sp, #36]
	ldr	w8, [x0]
Lloh26:
	adrp	x10, _GEN8_OA_TIMER_PERIOD_SHIFT@GOTPAGE
Lloh27:
	ldr	x10, [x10, _GEN8_OA_TIMER_PERIOD_SHIFT@GOTPAGEOFF]
Lloh28:
	ldr	w10, [x10]
	lsl	w8, w8, w10
	ldr	x10, [x0, #8]
Lloh29:
	adrp	x11, _GEN8_OA_TIMER_ENABLE@GOTPAGE
Lloh30:
	ldr	x11, [x11, _GEN8_OA_TIMER_ENABLE@GOTPAGEOFF]
Lloh31:
	ldr	w11, [x11]
	cmp	x10, #0
	csel	w10, wzr, w11, eq
	orr	w8, w10, w8
Lloh32:
	adrp	x10, _GEN8_OA_COUNTER_RESUME@GOTPAGE
Lloh33:
	ldr	x10, [x10, _GEN8_OA_COUNTER_RESUME@GOTPAGEOFF]
Lloh34:
	ldr	w10, [x10]
	orr	w3, w8, w10
Lloh35:
	ldr	w2, [x9]
	mov	x0, x19
	bl	_CTX_REG
	add	x25, sp, #12
	add	x0, sp, #12
	bl	_ARRAY_SIZE
	cmp	w0, #1
	b.lt	LBB0_3
; %bb.1:
	mov	x26, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w24, [x25, x26, lsl #2]
	mov	x0, x21
	mov	x1, x24
	bl	_oa_config_flex_reg
	mov	x3, x0
	mov	x0, x19
	mov	x1, x23
	mov	x2, x24
	bl	_CTX_REG
	add	x26, x26, #1
	add	x0, sp, #12
	bl	_ARRAY_SIZE
	add	x23, x23, #2
	cmp	x26, w0, sxtw
	b.lt	LBB0_2
LBB0_3:
Lloh36:
	adrp	x8, _CTX_R_PWR_CLK_STATE@GOTPAGE
Lloh37:
	ldr	x8, [x8, _CTX_R_PWR_CLK_STATE@GOTPAGEOFF]
Lloh38:
	ldr	x21, [x8]
Lloh39:
	adrp	x8, _GEN8_R_PWR_CLK_STATE@GOTPAGE
Lloh40:
	ldr	x8, [x8, _GEN8_R_PWR_CLK_STATE@GOTPAGEOFF]
Lloh41:
	ldr	w23, [x8]
	mov	x0, x22
	mov	x1, x20
	bl	_intel_sseu_make_rpcs
	mov	x3, x0
	mov	x0, x19
	mov	x1, x21
	mov	x2, x23
	bl	_CTX_REG
	ldr	x8, [sp, #40]
Lloh42:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh43:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh44:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_5
; %bb.4:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_5:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh35
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.comm	_EU_PERF_CNTL0,4,2              ; @EU_PERF_CNTL0
	.comm	_EU_PERF_CNTL1,4,2              ; @EU_PERF_CNTL1
	.comm	_EU_PERF_CNTL2,4,2              ; @EU_PERF_CNTL2
	.comm	_EU_PERF_CNTL3,4,2              ; @EU_PERF_CNTL3
	.comm	_EU_PERF_CNTL4,4,2              ; @EU_PERF_CNTL4
	.comm	_EU_PERF_CNTL5,4,2              ; @EU_PERF_CNTL5
	.comm	_EU_PERF_CNTL6,4,2              ; @EU_PERF_CNTL6
	.comm	_GEN8_OACTXCONTROL,4,2          ; @GEN8_OACTXCONTROL
	.comm	_GEN8_OA_TIMER_PERIOD_SHIFT,4,2 ; @GEN8_OA_TIMER_PERIOD_SHIFT
	.comm	_GEN8_OA_TIMER_ENABLE,4,2       ; @GEN8_OA_TIMER_ENABLE
	.comm	_GEN8_OA_COUNTER_RESUME,4,2     ; @GEN8_OA_COUNTER_RESUME
	.comm	_CTX_R_PWR_CLK_STATE,8,3        ; @CTX_R_PWR_CLK_STATE
	.comm	_GEN8_R_PWR_CLK_STATE,4,2       ; @GEN8_R_PWR_CLK_STATE
	.no_dead_strip	_gen8_update_reg_state_unlocked
.subsections_via_symbols
