	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function power_saving_thread
_power_saving_thread:                   ## @power_saving_thread
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movl	$1, -48(%rbp)
	movq	_current@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SCHED_RR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-48(%rbp), %rdx
	callq	_sched_setscheduler
	xorl	%eax, %eax
	callq	_kthread_should_stop
	testl	%eax, %eax
	je	LBB0_1
LBB0_15:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_exit_round_robin
	xorl	%eax, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	_HZ@GOTPCREL(%rip), %r15
	movq	_jiffies@GOTPCREL(%rip), %r12
	movq	_tsc_marked_unstable@GOTPCREL(%rip), %r13
	leaq	-52(%rbp), %r14
	xorl	%eax, %eax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	_TS_POLLING@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	xorl	%eax, %eax
	callq	_current_thread_info
	orl	%ebx, (%rax)
	movq	_HZ@GOTPCREL(%rip), %r15
LBB0_14:                                ##   in Loop: Header=BB0_2 Depth=1
	xorl	%eax, %eax
	callq	_kthread_should_stop
	testl	%eax, %eax
	jne	LBB0_15
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_5 Depth 2
	xorl	%eax, %eax
	callq	_try_to_freeze
	movq	_round_robin_time@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	movslq	(%r15), %rcx
	imulq	%rax, %rcx
	addq	-72(%rbp), %rcx                 ## 8-byte Folded Reload
	movq	(%r12), %rbx
	cmpq	%rbx, %rcx
	jge	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_round_robin_cpu
	movq	%rbx, -72(%rbp)                 ## 8-byte Spill
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_TS_POLLING@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	notl	%ebx
	xorl	%eax, %eax
	callq	_current_thread_info
	andl	%ebx, (%rax)
	xorl	%eax, %eax
	callq	_smp_mb
	movl	$100, %eax
	movq	_idle_pct@GOTPCREL(%rip), %rcx
	subl	(%rcx), %eax
	imull	(%r15), %eax
	cltq
	imulq	$1374389535, %rax, %rax         ## imm = 0x51EB851F
	movq	%rax, %rcx
	shrq	$63, %rcx
	sarq	$37, %rax
	addl	%ecx, %eax
	movslq	%eax, %r15
	addq	(%r12), %r15
	movq	_tsc_detected_unstable@GOTPCREL(%rip), %rbx
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_5 Depth=2
	xorl	%eax, %eax
	callq	_start_critical_timings
	movq	_CLOCK_EVT_NOTIFY_BROADCAST_EXIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_clockevents_notify
	xorl	%eax, %eax
	callq	_local_irq_enable
	cmpq	%r15, (%r12)
	jg	LBB0_12
LBB0_5:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	xorl	%eax, %eax
	callq	_need_resched
	testl	%eax, %eax
	jne	LBB0_13
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=2
	cmpq	$0, (%rbx)
	je	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=2
	cmpl	$0, (%r13)
	jne	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=2
	leaq	L_.str(%rip), %rdi
	callq	_mark_tsc_unstable
	movl	$1, (%r13)
LBB0_9:                                 ##   in Loop: Header=BB0_5 Depth=2
	xorl	%eax, %eax
	callq	_local_irq_disable
	xorl	%eax, %eax
	callq	_smp_processor_id
	movl	%eax, -52(%rbp)
	movq	_CLOCK_EVT_NOTIFY_BROADCAST_ENTER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_clockevents_notify
	xorl	%eax, %eax
	callq	_stop_critical_timings
	xorl	%eax, %eax
	callq	_current_thread_info
	leaq	4(%rax), %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	___monitor
	xorl	%eax, %eax
	callq	_smp_mb
	xorl	%eax, %eax
	callq	_need_resched
	testl	%eax, %eax
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_5 Depth=2
	movq	_power_saving_mwait_eax@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %esi
	callq	___mwait
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	_TS_POLLING@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	xorl	%eax, %eax
	callq	_current_thread_info
	orl	%ebx, (%rax)
	movq	_idle_pct@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_HZ@GOTPCREL(%rip), %r15
	imull	(%r15), %eax
	cltq
	imulq	$1374389535, %rax, %rdi         ## imm = 0x51EB851F
	movq	%rdi, %rax
	shrq	$63, %rax
	sarq	$37, %rdi
	addl	%eax, %edi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_schedule_timeout_killable
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_current,4,2                    ## @current
	.comm	_SCHED_RR,4,2                   ## @SCHED_RR
	.comm	_round_robin_time,4,2           ## @round_robin_time
	.comm	_HZ,4,2                         ## @HZ
	.comm	_jiffies,8,3                    ## @jiffies
	.comm	_TS_POLLING,4,2                 ## @TS_POLLING
	.comm	_idle_pct,4,2                   ## @idle_pct
	.comm	_tsc_detected_unstable,8,3      ## @tsc_detected_unstable
	.comm	_tsc_marked_unstable,4,2        ## @tsc_marked_unstable
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"TSC halts in idle"

	.comm	_CLOCK_EVT_NOTIFY_BROADCAST_ENTER,4,2 ## @CLOCK_EVT_NOTIFY_BROADCAST_ENTER
	.comm	_power_saving_mwait_eax,4,2     ## @power_saving_mwait_eax
	.comm	_CLOCK_EVT_NOTIFY_BROADCAST_EXIT,4,2 ## @CLOCK_EVT_NOTIFY_BROADCAST_EXIT
	.no_dead_strip	_power_saving_thread
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function power_saving_thread
_power_saving_thread:                   ; @power_saving_thread
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	str	x0, [sp]                        ; 8-byte Folded Spill
	mov	w21, #1
	str	w21, [sp, #24]
Lloh0:
	adrp	x8, _current@GOTPAGE
Lloh1:
	ldr	x8, [x8, _current@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x8, _SCHED_RR@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SCHED_RR@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x2, sp, #24
	bl	_sched_setscheduler
	bl	_kthread_should_stop
	cbnz	w0, LBB0_13
; %bb.1:
	str	xzr, [sp, #8]                   ; 8-byte Folded Spill
Lloh6:
	adrp	x26, _HZ@GOTPAGE
Lloh7:
	ldr	x26, [x26, _HZ@GOTPAGEOFF]
Lloh8:
	adrp	x24, _jiffies@GOTPAGE
Lloh9:
	ldr	x24, [x24, _jiffies@GOTPAGEOFF]
Lloh10:
	adrp	x28, _tsc_detected_unstable@GOTPAGE
Lloh11:
	ldr	x28, [x28, _tsc_detected_unstable@GOTPAGEOFF]
Lloh12:
	adrp	x19, _tsc_marked_unstable@GOTPAGE
Lloh13:
	ldr	x19, [x19, _tsc_marked_unstable@GOTPAGEOFF]
Lloh14:
	adrp	x27, _CLOCK_EVT_NOTIFY_BROADCAST_ENTER@GOTPAGE
Lloh15:
	ldr	x27, [x27, _CLOCK_EVT_NOTIFY_BROADCAST_ENTER@GOTPAGEOFF]
Lloh16:
	adrp	x22, _power_saving_mwait_eax@GOTPAGE
Lloh17:
	ldr	x22, [x22, _power_saving_mwait_eax@GOTPAGEOFF]
Lloh18:
	adrp	x20, l_.str@PAGE
Lloh19:
	add	x20, x20, l_.str@PAGEOFF
Lloh20:
	adrp	x25, _CLOCK_EVT_NOTIFY_BROADCAST_EXIT@GOTPAGE
Lloh21:
	ldr	x25, [x25, _CLOCK_EVT_NOTIFY_BROADCAST_EXIT@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
Lloh22:
	adrp	x8, _TS_POLLING@GOTPAGE
Lloh23:
	ldr	x8, [x8, _TS_POLLING@GOTPAGEOFF]
Lloh24:
	ldr	w23, [x8]
	bl	_current_thread_info
	ldr	w8, [x0]
	orr	w8, w8, w23
	str	w8, [x0]
Lloh25:
	adrp	x26, _HZ@GOTPAGE
Lloh26:
	ldr	x26, [x26, _HZ@GOTPAGEOFF]
	bl	_kthread_should_stop
	cbnz	w0, LBB0_13
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_8 Depth 2
	bl	_try_to_freeze
Lloh27:
	adrp	x8, _round_robin_time@GOTPAGE
Lloh28:
	ldr	x8, [x8, _round_robin_time@GOTPAGEOFF]
Lloh29:
	ldrsw	x8, [x8]
	ldrsw	x9, [x26]
	ldr	x10, [sp, #8]                   ; 8-byte Folded Reload
	madd	x8, x9, x8, x10
	ldr	x23, [x24]
	cmp	x8, x23
	b.ge	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x0, [sp]                        ; 8-byte Folded Reload
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_round_robin_cpu
	str	x23, [sp, #8]                   ; 8-byte Folded Spill
LBB0_5:                                 ;   in Loop: Header=BB0_3 Depth=1
Lloh30:
	adrp	x8, _TS_POLLING@GOTPAGE
Lloh31:
	ldr	x8, [x8, _TS_POLLING@GOTPAGEOFF]
Lloh32:
	ldr	w23, [x8]
	bl	_current_thread_info
	ldr	w8, [x0]
	bic	w8, w8, w23
	str	w8, [x0]
	bl	_smp_mb
	ldr	x8, [x24]
	ldr	w9, [x26]
Lloh33:
	adrp	x10, _idle_pct@GOTPAGE
Lloh34:
	ldr	x10, [x10, _idle_pct@GOTPAGEOFF]
Lloh35:
	ldr	w10, [x10]
	mov	w11, #100
	sub	w10, w11, w10
	mul	w9, w10, w9
	mov	w10, #34079
	movk	w10, #20971, lsl #16
	smull	x9, w9, w10
	lsr	x10, x9, #63
	asr	x9, x9, #37
	add	w9, w9, w10
	add	x23, x8, w9, sxtw
	b	LBB0_8
LBB0_6:                                 ;   in Loop: Header=BB0_8 Depth=2
	bl	_local_irq_disable
	bl	_smp_processor_id
	str	w0, [sp, #20]
	ldr	w0, [x27]
	add	x1, sp, #20
	bl	_clockevents_notify
	bl	_stop_critical_timings
	bl	_current_thread_info
	add	x0, x0, #4
	mov	w1, #0
	mov	w2, #0
	bl	___monitor
	bl	_smp_mb
	bl	_need_resched
	cbz	w0, LBB0_11
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=2
	bl	_start_critical_timings
	ldr	w0, [x25]
	add	x1, sp, #20
	bl	_clockevents_notify
	bl	_local_irq_enable
	ldr	x8, [x24]
	cmp	x8, x23
	b.gt	LBB0_12
LBB0_8:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	bl	_need_resched
	cbnz	w0, LBB0_2
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=2
	ldr	x8, [x28]
	ldr	w9, [x19]
	cmp	x8, #0
	ccmp	w9, #0, #0, ne
	b.ne	LBB0_6
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=2
	mov	x0, x20
	bl	_mark_tsc_unstable
	str	w21, [x19]
	b	LBB0_6
LBB0_11:                                ;   in Loop: Header=BB0_8 Depth=2
	ldr	w0, [x22]
	mov	w1, #1
	bl	___mwait
	b	LBB0_7
LBB0_12:                                ;   in Loop: Header=BB0_3 Depth=1
Lloh36:
	adrp	x8, _TS_POLLING@GOTPAGE
Lloh37:
	ldr	x8, [x8, _TS_POLLING@GOTPAGEOFF]
Lloh38:
	ldr	w23, [x8]
	bl	_current_thread_info
	ldr	w8, [x0]
	orr	w8, w8, w23
	str	w8, [x0]
Lloh39:
	adrp	x26, _HZ@GOTPAGE
Lloh40:
	ldr	x26, [x26, _HZ@GOTPAGEOFF]
	ldr	w8, [x26]
Lloh41:
	adrp	x9, _idle_pct@GOTPAGE
Lloh42:
	ldr	x9, [x9, _idle_pct@GOTPAGEOFF]
Lloh43:
	ldr	w9, [x9]
	mul	w8, w9, w8
	mov	w9, #34079
	movk	w9, #20971, lsl #16
	smull	x8, w8, w9
	lsr	x9, x8, #63
	asr	x8, x8, #37
	add	w0, w8, w9
	bl	_schedule_timeout_killable
	bl	_kthread_should_stop
	cbz	w0, LBB0_3
LBB0_13:
	ldr	x0, [sp]                        ; 8-byte Folded Reload
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_exit_round_robin
	mov	w0, #0
	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
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.comm	_current,4,2                    ; @current
	.comm	_SCHED_RR,4,2                   ; @SCHED_RR
	.comm	_round_robin_time,4,2           ; @round_robin_time
	.comm	_HZ,4,2                         ; @HZ
	.comm	_jiffies,8,3                    ; @jiffies
	.comm	_TS_POLLING,4,2                 ; @TS_POLLING
	.comm	_idle_pct,4,2                   ; @idle_pct
	.comm	_tsc_detected_unstable,8,3      ; @tsc_detected_unstable
	.comm	_tsc_marked_unstable,4,2        ; @tsc_marked_unstable
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"TSC halts in idle"

	.comm	_CLOCK_EVT_NOTIFY_BROADCAST_ENTER,4,2 ; @CLOCK_EVT_NOTIFY_BROADCAST_ENTER
	.comm	_power_saving_mwait_eax,4,2     ; @power_saving_mwait_eax
	.comm	_CLOCK_EVT_NOTIFY_BROADCAST_EXIT,4,2 ; @CLOCK_EVT_NOTIFY_BROADCAST_EXIT
	.no_dead_strip	_power_saving_thread
.subsections_via_symbols
