Content deleted Content added
Matthiaspaul (talk | contribs) +link |
m Undid revision 1293737941 by 177.22.176.151 (talk) random edit |
||
(40 intermediate revisions by 24 users not shown) | |||
Line 1:
{{Short description|Power management technique in computers}}
{{for|the CPU design principle|Frequency scaling}}
{{redirect|CPU throttling|other uses|Throttle (disambiguation)#Computing}}
{{Use dmy dates|date=January 2014}}
{{More citations needed|date=September 2021}}
'''Dynamic frequency scaling''' (also known as '''CPU throttling''') is a technique in [[computer architecture]] whereby the [[Clock rate|frequency]] of a microprocessor can be automatically adjusted "on the fly" depending on the actual needs, to [[Power management integrated circuit|conserve power]] and reduce the amount of heat generated by the chip. Dynamic frequency scaling helps preserve battery on mobile devices<ref>"[https://www.academia.edu/4186102/A_survey_of_techniques_for_improving_energy_efficiency_in_embedded_computing_systems A survey of techniques for improving energy efficiency in embedded computing systems]", IJCAET, 2014 </ref> and decrease cooling cost and noise on [[Quiet PC|quiet computing settings]], or can be useful as a security measure for overheated systems (e.g. after poor [[overclocking]]). Dynamic frequency scaling is used in all ranges of computing systems, ranging from mobile systems to data centers<ref>"[https://www.academia.edu/6982393/Power_Management_Techniques_for_Data_Centers_A_Survey Power Management Techniques for Data Centers: A Survey]", ORNL Technical Report, 2014 </ref> to reduce the power at the times of low workload. ▼
▲'''Dynamic frequency scaling''' (also known as '''CPU throttling''') is a [[power management]] technique in [[computer architecture]] whereby the [[Clock rate|frequency]] of a microprocessor can be automatically adjusted "on the fly" depending on the actual needs, to [[Power management integrated circuit|conserve power]] and reduce the amount of heat generated by the chip. Dynamic frequency scaling helps preserve battery on mobile devices
Dynamic frequency scaling almost always appear in conjunction with [[dynamic voltage scaling]], since higher frequencies require higher supply voltages for the digital circuit to yield correct results. The combined topic is known as '''dynamic voltage and frequency scaling''' ('''DVFS''').
The dynamic power (''[[switching power]]'') dissipated per unit of time by a chip is ''C·V<sup>2</sup>·A·f'', where C is the [[capacitance]] being switched per clock cycle, V is [[voltage]], A is the Activity Factor<ref name="ActivityFactor">{{cite journal | title = Timing-aware power-optimal ordering of signals | author = K. Moiseev, A. Kolodny and S. Wimer | work = ACM Transactions on Design Automation of Electronic Systems, Volume 13 Issue 4, September 2008}}</ref> indicating the average number of switching events undergone by the transistors in the chip (as a unitless quantity) and f is the switching frequency.<ref>{{Cite book|first=J. M.|last= Rabaey|title= Digital Integrated Circuits|publisher= Prentice Hall|year= 1996}}</ref>▼
== Operation ==
Voltage is therefore the main determinant of power usage and heating.<ref>{{cite web|url=https://software.intel.com/en-us/blogs/2014/02/19/why-has-cpu-frequency-ceased-to-grow|author= Victoria Zhislina|date=2014-02-19|title=Why has CPU frequency ceased to grow?|publisher=Intel}}</ref> The voltage required for stable operation is determined by the frequency at which the circuit is clocked, and can be reduced if the frequency is also reduced.<ref>https://www.usenix.org/legacy/events/hotpower/tech/full_papers/LeSueur.pdf</ref> Dynamic power alone does not account for the total power of the chip, however, as there is also static power, which is primarily because of various leakage currents. Due to static power consumption and asymptotic execution time it has been shown that the energy consumption of a piece of software shows convex energy behavior, i.e., there exists an optimal CPU frequency at which energy consumption is minimal.<ref>{{cite journal | author = K. De Vogeleer| title = The Energy/Frequency Convexity Rule: Modeling and Experimental Validation on Mobile Devices |year=2014 | arxiv = 1401.4655|display-authors=etal|bibcode=2014arXiv1401.4655D}}</ref>▼
{{see also|Processor power dissipation#Sources}}
[[Subthreshold leakage|Leakage current]] has become more and more important as transistor sizes have become smaller and threshold voltage levels lower. A decade ago, dynamic power accounted for approximately two-thirds of the total chip power. The power loss due to leakage currents in contemporary CPUs and SoCs tend to dominate the total power consumption. In the attempt to control the leakage power, [[High-κ dielectric|high-k metal-gates]] and power gating have been common methods.▼
▲The dynamic power (''[[switching power]]'') dissipated
▲Voltage is therefore the main determinant of power usage and heating.<ref>{{cite web|url=https://software.intel.com/en-us/blogs/2014/02/19/why-has-cpu-frequency-ceased-to-grow|author= Victoria Zhislina|date=2014-02-19|title=Why has CPU frequency ceased to grow?|publisher=Intel}}</ref> The voltage required for stable operation is determined by the frequency at which the circuit is clocked, and can be reduced if the frequency is also reduced.<ref>https://www.usenix.org/legacy/events/hotpower/tech/full_papers/LeSueur.pdf {{Bare URL PDF|date=March 2022}}</ref> Dynamic power alone does not account for the total power of the chip, however, as there is also static power, which is primarily because of various leakage currents. Due to static power consumption and asymptotic execution time it has been shown that the energy consumption
[[Dynamic voltage scaling]] is another related power conservation technique that is often used in conjunction with frequency scaling, as the frequency that a chip may run at is related to the operating voltage.▼
▲[[Subthreshold leakage|Leakage current]] has become more and more important as transistor sizes have become smaller and threshold voltage levels
▲
The efficiency of some electrical components, such as voltage regulators, decreases with increasing temperature, so the power usage may increase with temperature. Since increasing power use may increase the temperature, increases in voltage or frequency may increase system power demands even further than the CMOS formula indicates, and vice versa.<ref>{{cite web | url = http://www.silentpcreview.com/article821-page5.html | title = Asus EN9600GT Silent Edition Graphics Card | author = Mike Chin | page = 5 | work = Silent PC Review | accessdate = 21 April 2008}}</ref><ref name="SPCRNewLevels">{{cite web | url = http://www.silentpcreview.com/article814-page1.html | title = 80 Plus expands podium for Bronze, Silver & Gold | author = MIke Chin | work = Silent PC Review | accessdate = 21 April 2008 }}</ref>▼
▲The efficiency of some electrical components, such as voltage regulators, decreases with increasing temperature, so the power usage may increase with temperature. Since increasing power use may increase the temperature, increases in voltage or frequency may increase system power demands even further than the CMOS formula indicates, and vice versa.<ref>{{cite web | url = http://www.silentpcreview.com/article821-page5.html | title = Asus EN9600GT Silent Edition Graphics Card | author = Mike Chin | page = 5 | work = Silent PC Review |
== {{Anchor|ACPI|CPPC}} Standard interface ==
[[ACPI]] 1.0 (1996) defines a way for a CPU to go to idle "C states", but defines no frequency-scaling system.
ACPI 2.0 (2000) introduces a system of ''P states'' (power-performance states) that a processor can use to communicate its possible frequency–power settings to the OS. The operating system then sets the speed as needed by switching between these states. Throttling technology such as SpeedStep, PowerNow!/Cool'n'Quiet, and PowerSaver all work through P states. There is a limit of 16 states maximum.<ref>{{cite web
| url = http://www.acpi.info/DOWNLOADS/ACPIspec30.pdf
| title = Advanced Configuration and Power Interface Specification, Revision 3.0, Section 2.6 Device and Processor Performance State Definitions
| date = 2004-09-02
| access-date = 2015-08-19
| website = ACPI.info
| page = 23
| archive-date = November 28, 2015
| archive-url = https://web.archive.org/web/20151128143452/http://www.acpi.info/DOWNLOADS/ACPIspec30.pdf
| url-status = dead
}}</ref>
ACPI 5.0 (2011) introduces collaborative processor performance control (CPPC), exposing hundreds of performance levels to the OS for selection in the form of a "performance level" abstracted away from the frequency. This abstraction provides some leeway for the processor to adjust its workings in ways other than just the frequency.<ref>{{cite web |title=Collaborative Processor Performance Control (CPPC) — The Linux Kernel documentation |url=https://www.kernel.org/doc/html/latest/admin-guide/acpi/cppc_sysfs.html |website=www.kernel.org}}</ref><ref>{{cite web |title=8.4. Declaring Processors |url=https://uefi.org/htmlspecs/ACPI_Spec_6_4_html/08_Processor_Configuration_and_Control/declaring-processors.html#collaborative-processor-performance-control |website=ACPI Specification 6.4 documentation}}</ref><ref>{{cite web |title=Overview about power and performance tuning for the Windows Server |url=https://learn.microsoft.com/en-us/windows-server/administration/performance-tuning/hardware/power/power-performance-tuning |website=learn.microsoft.com |language=en-us |date=29 August 2022}}</ref>
== Autonomous frequency scaling ==
A number of modern CPUs can perform frequency scaling autonomously, using a performance level range and a "efficiency/performance preference" hint from the OS.
* Intel CPUs starting with [[Skylake (microarchitecture)|Skylake]] support ''hardware-managed P-states'' aka ''Speed Shift'', It based on CPPC protocol, and it using [[model-specific register]] as the control channel.<ref>{{man|8|x86_energy_perf_policy|Linux}}</ref><ref>{{cite web |title=intel_pstate CPU Performance Scaling Driver — The Linux Kernel documentation |url=https://www.kernel.org/doc/html/v4.19/admin-guide/pm/intel_pstate.html |website=www.kernel.org}}</ref>
* AMD CPUs starting with [[Zen 2]] supports a similar feature. It depends on CPPC being enabled. The preferred communication channel is a MSR (different from the Intel one) introduced in Zen 3; Zen 2 units use the ACPI AML method.<ref>{{cite web |title=amd-pstate CPU Performance Scaling Driver — The Linux Kernel documentation |url=https://docs.kernel.org/admin-guide/pm/amd-pstate.html |website=docs.kernel.org}}</ref>
==Performance impact==
Dynamic frequency scaling reduces the number of instructions a processor can issue in a given amount of time, thus reducing performance. Hence, it is generally used when the workload is not CPU-bound.
Dynamic frequency scaling by itself is rarely worthwhile as a way to conserve switching power. Saving the highest possible amount of power requires dynamic voltage scaling too, because of the V<sup>2</sup> component and the fact that modern CPUs are strongly optimized for low power idle states. In most constant-voltage cases, it is more efficient to run briefly at peak speed and stay in a deep idle state for longer time (called "[[Race to sleep|race to idle]]" or computational sprinting), than it is to run at a reduced clock rate for a long time and only stay briefly in a light idle state. However, reducing voltage along with clock rate can change those
A related-but-opposite technique is [[overclocking]], whereby processor performance is increased by ramping the processor's (dynamic) frequency beyond the manufacturer's design specifications.
Line 24 ⟶ 54:
One major difference between the two is that in modern PC systems overclocking is mostly done over the [[Front Side Bus]] (mainly because the multiplier is normally locked), but dynamic frequency scaling is done with the [[CPU multiplier|multiplier]]. Moreover, overclocking is often static, while dynamic frequency scaling is always dynamic. Software can often incorporate overclocked frequencies into the frequency scaling algorithm, if the chip degradation risks are allowable.
==Support across vendors==
=== Intel ===
[[Intel]]'s CPU throttling technology, [[SpeedStep]], is used in its mobile and desktop CPU lines.
=== AMD ===
[[AMD]] employs two different CPU throttling technologies. AMD's [[Cool'n'Quiet]] technology is used on its desktop and server processor lines. The aim of Cool'n'Quiet is not to save battery life, as it is not used in AMD's mobile processor line, but instead with the purpose of producing less heat, which in turn allows the system fan to spin down to slower speeds, resulting in cooler and quieter operation, hence the name of the technology. AMD's [[PowerNow!]] CPU throttling technology is used in its mobile processor line, though some supporting CPUs like the [[AMD K6-2]]+ can be found in desktops as well.
[[AMD PowerTune]] and [[AMD ZeroCore Power]] are dynamic frequency scaling technologies for [[Graphics processing unit|GPUs]].▼
=== VIA Technologies ===
[[VIA Technologies]] processors use a technology named [[LongHaul]] (PowerSaver), while [[Transmeta]]'s version was called [[LongRun]].
Line 35 ⟶ 71:
According to the [[Advanced Configuration and Power Interface|ACPI]] Specs, the C0 working state of a modern-day CPU can be divided into the so-called "P"-states (performance states) which allow clock rate reduction and "T"-states (throttling states) which will further throttle down a CPU (but not the actual clock rate) by inserting STPCLK (stop clock) signals and thus omitting duty cycles.
=== ARM ===
▲[[AMD PowerTune]] and [[AMD ZeroCore Power]] are dynamic frequency scaling technologies for [[Graphics processing unit|GPUs]].
Different ARM-based systems on chip provide CPU and GPU throttling.
== See also ==
* [[Dynamic voltage scaling]]
* [[Clock gating]]
* [[HLT (x86 instruction)]]
Power Saving Technologies:
* [[Cool'n'Quiet|AMD Cool'n'Quiet]] (desktop CPUs)
Line 56 ⟶ 94:
{{DEFAULTSORT:Dynamic Frequency Scaling}}
[[Category:Clock signal]]
[[Category:Energy conservation]]
|