Lines Matching refs:CPU
5 CPU Performance Scaling
12 The Concept of CPU Performance Scaling
19 can be retired by the CPU over a unit of time, but also the higher the clock
21 time (or the more power is drawn) by the CPU in the given P-state. Therefore
22 there is a natural tradeoff between the CPU capacity (the number of instructions
23 that can be executed over a unit of time) and the power drawn by the CPU.
29 instructions so quickly and maintaining the highest available CPU capacity for a
31 It also may not be physically possible to maintain maximum CPU capacity for too
37 Typically, they are used along with algorithms to estimate the required CPU
41 to as CPU performance scaling or CPU frequency scaling (because it involves
42 adjusting the CPU clock frequency).
45 CPU Performance Scaling in Linux
48 The Linux kernel supports CPU performance scaling by means of the ``CPUFreq``
49 (CPU Frequency scaling) subsystem that consists of three layers of code: the
53 interfaces for all platforms that support CPU performance scaling. It defines
56 Scaling governors implement algorithms to estimate the required CPU capacity.
62 access platform-specific hardware interfaces to change CPU P-states as requested
92 |struct cpufreq_policy| is also used when there is only one CPU in the given
96 every CPU in the system, including CPUs that are currently offline. If multiple
104 CPU Initialization
111 The scaling driver may be registered before or after CPU registration. If
118 In any case, the ``CPUFreq`` core is invoked to take note of any logical CPU it
119 has not seen so far as soon as it is ready to handle that CPU. [Note that the
120 logical CPU may be a physical single-core processor, or a single core in a
122 core. In what follows "CPU" always means "logical CPU" unless explicitly stated
127 for the given CPU and if so, it skips the policy object creation. Otherwise,
130 the given CPU is set to the new policy object's address in memory.
133 pointer of the new CPU passed to it as the argument. That callback is expected
134 to initialize the performance scaling hardware interface for the given CPU (or,
153 That callback it expected to register per-CPU utilization update callbacks for
154 all of the online CPUs belonging to the given policy with the CPU scheduler.
155 The utilization update callbacks will be invoked by the CPU scheduler on
157 scheduler tick or generally whenever the CPU utilization may change (from the
171 In turn, if a previously offline CPU is being brought back online, but some
174 necessary to restart the scaling governor so that it can take the new online CPU
182 to register per-CPU utilization update callbacks for each policy. These
183 callbacks are invoked by the CPU scheduler in the same way as for scaling
188 The policy objects created during CPU initialization and other data structures
191 when the last CPU belonging to the given policy in unregistered.
227 CPU frequencies, that limit will be reported through this attribute (if
283 the CPU is actually running at (due to hardware design and other
287 more precisely reflecting the current CPU frequency through this
288 attribute, but that still may not be the exact current CPU frequency as
378 to set the CPU frequency for the policy it is attached to by writing to the
384 This governor uses CPU utilization data available from the CPU scheduler. It
385 generally is regarded as a part of the CPU scheduler, so it can access the
389 invoke the scaling driver asynchronously when it decides that the CPU frequency
391 is capable of changing the CPU frequency from scheduler context).
393 The actions of this governor for a particular CPU depend on the scheduling class
394 invoking its utilization update callback for that CPU. If it is invoked by the
399 given CPU as the CPU utilization estimate (see the `Per-entity load tracking`_
401 CPU frequency to apply is computed in accordance with the formula
406 ``util``, and ``f_0`` is either the maximum possible CPU frequency for the given
407 policy (if the PELT number is frequency-invariant), or the current CPU frequency
411 CPU frequency for tasks that have been waiting on I/O most recently, called
429 tightly integrated with the CPU scheduler, its overhead in terms of CPU context
430 switches and similar is less significant, and it uses the scheduler's own CPU
437 This governor uses CPU load as a CPU frequency selection metric.
439 In order to estimate the current CPU load, it measures the time elapsed between
441 time in which the given CPU was not idle. The ratio of the non-idle (active)
442 time to the total CPU time is taken as an estimate of the load.
449 invoked asynchronously (via a workqueue) and CPU P-states are updated from
451 governor is minimum, but it causes additional CPU context switches to happen
452 relatively often and the CPU P-state updates triggered by it can be relatively
453 irregular. Also, it affects its own CPU load metric by running code that
454 reduces the CPU idle time (even though the CPU idle time is only reduced very
457 It generally selects CPU frequencies proportional to the estimated load, so that
483 If the estimated CPU load is above this value (in percent), the governor
486 CPU load.
489 If set to 1 (default 0), it will cause the CPU load estimation code to
490 treat the CPU time spent on executing tasks with "nice" levels greater
491 than 0 as CPU idle time.
500 the ``sampling_rate`` value if the CPU load goes above ``up_threshold``.
507 at the cost of additional energy spent on maintaining the maximum CPU
513 value is exceeded by the estimated CPU load) or sensitivity threshold
533 workload running on a CPU will change in response to frequency changes.
537 the CPU frequency, whereas workloads with the sensitivity of 100%
538 (CPU-bound) are expected to perform much better if the CPU frequency is
545 from running at higher CPU frequencies.
550 This governor uses CPU load as a CPU frequency selection metric.
552 It estimates the CPU load in the same way as the `ondemand`_ governor described
553 above, but the CPU frequency selection algorithm implemented by it is different.
559 (configurable) threshold has been exceeded by the estimated CPU load.
578 If the estimated CPU load is greater than this value, the frequency will
612 into a special state in which it can control the CPU frequency within certain
642 CPU performance on time scales below software resolution (e.g. below the