	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tsc_levels_changed
_tsc_levels_changed:                    ## @tsc_levels_changed
	.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
	testl	%esi, %esi
	je	LBB0_1
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_devclass_find
	movl	%eax, %edi
	xorl	%esi, %esi
	callq	_devclass_get_device
	testq	%rax, %rax
	je	LBB0_9
## %bb.2:
	movq	%rax, %rbx
	movl	$64, -28(%rbp)
	movq	_M_TEMP@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	_M_NOWAIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	$512, %edi                      ## imm = 0x200
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_8
## %bb.3:
	movq	%rax, %r14
	leaq	-28(%rbp), %rdx
	movq	%rbx, %rdi
	movq	%rax, %rsi
	callq	_CPUFREQ_LEVELS
	testl	%eax, %eax
	jne	LBB0_6
## %bb.4:
	cmpl	$0, -28(%rbp)
	je	LBB0_6
## %bb.5:
	imull	$1000000, (%r14), %esi          ## imm = 0xF4240
	movq	_rdtsc@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %edx
	callq	_set_cputicker
	jmp	LBB0_7
LBB0_9:
	leaq	L_str.3(%rip), %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_puts                           ## TAILCALL
LBB0_6:
	leaq	L_str(%rip), %rdi
	callq	_puts
LBB0_7:
	movl	(%r15), %esi
	movq	%r14, %rdi
	callq	_free
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cpufreq"

	.comm	_M_TEMP,4,2                     ## @M_TEMP
	.comm	_M_NOWAIT,4,2                   ## @M_NOWAIT
	.comm	_rdtsc,4,2                      ## @rdtsc
L_str:                                  ## @str
	.asciz	"tsc_levels_changed: no max freq found"

L_str.3:                                ## @str.3
	.asciz	"tsc_levels_changed() called but no cpufreq device?"

	.no_dead_strip	_tsc_levels_changed
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tsc_levels_changed
_tsc_levels_changed:                    ; @tsc_levels_changed
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	w1, LBB0_2
LBB0_1:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_2:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_devclass_find
	mov	w1, #0
	bl	_devclass_get_device
	cbz	x0, LBB0_6
; %bb.3:
	mov	x20, x0
	mov	w8, #64
	str	w8, [sp, #12]
Lloh2:
	adrp	x21, _M_TEMP@GOTPAGE
Lloh3:
	ldr	x21, [x21, _M_TEMP@GOTPAGEOFF]
	ldr	w1, [x21]
Lloh4:
	adrp	x8, _M_NOWAIT@GOTPAGE
Lloh5:
	ldr	x8, [x8, _M_NOWAIT@GOTPAGEOFF]
Lloh6:
	ldr	w2, [x8]
	mov	w0, #512
	bl	_malloc
	cbz	x0, LBB0_1
; %bb.4:
	mov	x19, x0
	add	x2, sp, #12
	mov	x0, x20
	mov	x1, x19
	bl	_CPUFREQ_LEVELS
	ldr	w8, [sp, #12]
	cmp	w0, #0
	ccmp	w8, #0, #4, eq
	b.ne	LBB0_7
; %bb.5:
Lloh7:
	adrp	x0, l_str@PAGE
Lloh8:
	add	x0, x0, l_str@PAGEOFF
	bl	_puts
	b	LBB0_8
LBB0_6:
Lloh9:
	adrp	x0, l_str.3@PAGE
Lloh10:
	add	x0, x0, l_str.3@PAGEOFF
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	b	_puts
LBB0_7:
	ldr	w8, [x19]
	mov	w9, #16960
	movk	w9, #15, lsl #16
	mul	w1, w8, w9
Lloh11:
	adrp	x8, _rdtsc@GOTPAGE
Lloh12:
	ldr	x8, [x8, _rdtsc@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	mov	w2, #1
	bl	_set_cputicker
LBB0_8:
	ldr	w1, [x21]
	mov	x0, x19
	bl	_free
	b	LBB0_1
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cpufreq"

	.comm	_M_TEMP,4,2                     ; @M_TEMP
	.comm	_M_NOWAIT,4,2                   ; @M_NOWAIT
	.comm	_rdtsc,4,2                      ; @rdtsc
l_str:                                  ; @str
	.asciz	"tsc_levels_changed: no max freq found"

l_str.3:                                ; @str.3
	.asciz	"tsc_levels_changed() called but no cpufreq device?"

	.no_dead_strip	_tsc_levels_changed
.subsections_via_symbols
