	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function p4tcc_get
_p4tcc_get:                             ## @p4tcc_get
	.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
	testq	%rsi, %rsi
	je	LBB0_1
## %bb.2:
	movq	%rsi, %rbx
	movl	%edi, %r14d
	callq	_device_get_softc
	cmpl	$0, (%rax)
	je	LBB0_3
## %bb.4:
	movq	_TCC_NUM_SETTINGS@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	jmp	LBB0_5
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_6
LBB0_3:
	movq	_MSR_THERM_CONTROL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_rdmsr
	movq	_TCC_REG_OFFSET@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %eax
	movq	_TCC_NUM_SETTINGS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r15d
	decl	%r15d
	andl	%eax, %r15d
LBB0_5:
	movq	_CPUFREQ_VAL_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$8, %edx
	callq	_memset
	movl	%r15d, %edi
	callq	_TCC_SPEED_PERCENT
	movl	%eax, 4(%rbx)
	movl	%r14d, (%rbx)
	xorl	%eax, %eax
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_MSR_THERM_CONTROL,4,2          ## @MSR_THERM_CONTROL
	.comm	_TCC_REG_OFFSET,4,2             ## @TCC_REG_OFFSET
	.comm	_TCC_NUM_SETTINGS,4,2           ## @TCC_NUM_SETTINGS
	.comm	_CPUFREQ_VAL_UNKNOWN,4,2        ## @CPUFREQ_VAL_UNKNOWN
	.no_dead_strip	_p4tcc_get
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function p4tcc_get
_p4tcc_get:                             ; @p4tcc_get
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	cbz	x1, LBB0_3
; %bb.1:
	mov	x19, x1
	mov	x20, x0
	bl	_device_get_softc
	ldr	w8, [x0]
	cbz	w8, LBB0_4
; %bb.2:
Lloh0:
	adrp	x8, _TCC_NUM_SETTINGS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TCC_NUM_SETTINGS@GOTPAGEOFF]
Lloh2:
	ldr	w21, [x8]
	b	LBB0_5
LBB0_3:
Lloh3:
	adrp	x8, _EINVAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	b	LBB0_6
LBB0_4:
Lloh6:
	adrp	x8, _MSR_THERM_CONTROL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MSR_THERM_CONTROL@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_rdmsr
Lloh9:
	adrp	x8, _TCC_REG_OFFSET@GOTPAGE
Lloh10:
	ldr	x8, [x8, _TCC_REG_OFFSET@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	asr	w8, w0, w8
Lloh12:
	adrp	x9, _TCC_NUM_SETTINGS@GOTPAGE
Lloh13:
	ldr	x9, [x9, _TCC_NUM_SETTINGS@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	sub	w9, w9, #1
	and	w21, w9, w8
LBB0_5:
Lloh15:
	adrp	x8, _CPUFREQ_VAL_UNKNOWN@GOTPAGE
Lloh16:
	ldr	x8, [x8, _CPUFREQ_VAL_UNKNOWN@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #8
	bl	_memset
	mov	x0, x21
	bl	_TCC_SPEED_PERCENT
	mov	x8, x0
	mov	w0, #0
	stp	w20, w8, [x19]
LBB0_6:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_MSR_THERM_CONTROL,4,2          ; @MSR_THERM_CONTROL
	.comm	_TCC_REG_OFFSET,4,2             ; @TCC_REG_OFFSET
	.comm	_TCC_NUM_SETTINGS,4,2           ; @TCC_NUM_SETTINGS
	.comm	_CPUFREQ_VAL_UNKNOWN,4,2        ; @CPUFREQ_VAL_UNKNOWN
	.no_dead_strip	_p4tcc_get
.subsections_via_symbols
