Power management with dynamic frequency adjustments

Information

  • Patent Grant
  • 8775843
  • Patent Number
    8,775,843
  • Date Filed
    Monday, February 4, 2013
    12 years ago
  • Date Issued
    Tuesday, July 8, 2014
    10 years ago
Abstract
A central processing unit (CPU) can specify an initial (e.g., baseline) frequency for a clock signal used by a device to perform a task. The CPU is then placed in a reduced power mode. The device performs the task after the CPU is placed in the reduced power mode until a triggering event causes the device to send an interrupt to the CPU. In response to the interrupt, the CPU awakens to dynamically adjust the clock frequency. If the clock frequency is reset to the baseline value, then the CPU is again placed in the reduced power mode.
Description
FIELD

Embodiments according to the present invention generally relate to power management in limited-powered devices.


BACKGROUND

Power consumption is of particular concern to limited-power devices (e.g., battery-powered devices) such as laptop and notebook computer systems, cell phones, personal digital assistants (PDAs), portable media players, remote control units, hand-held devices including video game players, and the like. These devices are limited in size and weight and generally portable, and therefore they typically use smaller and lighter batteries of limited capacity. However, these types of devices may be used for a variety of computationally intensive and therefore power-hungry applications such as three-dimensional (3D) rendering and video encoding and decoding. As a result, such devices can usually be used only for relatively short periods of time before their batteries need to be recharged.


SUMMARY

Embodiments according to the present invention provide methods and systems for conserving power in limited-powered devices. In one embodiment, a central processing unit (CPU, e.g., a microprocessor) identifies a type of task to be performed and a device to perform that task. Based on the type of task and also on the device identified, the CPU selects an initial (or baseline) frequency for a clock signal to be used by the device(s) to perform the task. A baseline frequency can be predefined for each type of task, based on the known workload associated with each type of task. As such, the baseline frequency can be looked up by the CPU knowing the task to be performed.


The baseline frequency is a function of task and which device is used for the task. For example, a single task may be executed by two different devices. A different baseline frequency may be specified for each device. The discussion below describes the singular case but can be readily extended to cases involving multiple devices.


After selecting a device and setting the initial clock frequency, the CPU can enter a “reduced power mode.” In general, the CPU's power is reduced to less than its normal power level. More specifically, the CPU may be “power gated” (e.g., turned off until it is needed). The selected device continues to execute the task using the baseline frequency after the CPU enters the reduced power mode.


If the clock frequency needs to be increased from the baseline frequency because the device is experiencing an increase in workload, the CPU can be awakened using an interrupt or the like. Once awakened, the CPU can dynamically adjust the frequency of the clock signal to track the actual workload of the device.


Before the CPU is awakened, the device can monitor its workload by monitoring relevant indicators. For example, buffer capacity can be monitored and the CPU awakened if remaining capacity falls below a predefined threshold. Once awakened, the CPU can measure, for example, the amount of time that the device is idle by counting the number of idle clock cycles. If the device's “idle time” decreases below a certain threshold, then the frequency of the clock signal can be increased adaptively; and if the idle time increases above that threshold (or a different threshold), then the frequency of the clock signal can be decreased adaptively. The clock frequency can be dynamically adjusted in this manner until it returns to the baseline frequency. Once the clock frequency is reduced back to its baseline frequency, the CPU can be returned to the reduced power mode.


In summary, once the baseline frequency is initially set by the CPU, the CPU can be powered down or turned off to save power. With the CPU in the reduced power mode, idle time is not monitored and clock frequency is not adjusted by the CPU. The CPU can be subsequently awakened in response to a triggering event that indicates that the frequency of the clock signal needs to be increased above the baseline. The CPU remains awake while the clock frequency is above the baseline, and idle time is monitored so that further adjustments to the clock frequency can be made if necessary. Once the workload decreases to a point where the clock frequency can be reset to the baseline frequency, the CPU can again be powered down or turned off and perhaps subsequently reawakened to repeat the process just described.


Thus, power is conserved on at least two fronts. First, power consumption is reduced because the CPU is not running continuously at full power—once the CPU selects a device and a baseline frequency, it can be powered down or turned off until it is needed. Second, the frequency of the clock signal used by the device is adjusted up and down depending on workload—because power usage is a function of clock frequency, the capability to scale frequency to workload means that power is used more efficiently. By intelligently selecting an appropriate baseline frequency and then adjusting it as needed, and by selectively running the CPU in the manner just described, a net savings in power is realized.


These and other objects and advantages of the various embodiments of the present invention will be recognized by those of ordinary skill in the art after reading the following detailed description of the embodiments that are illustrated in the various drawing figures.





BRIEF DESCRIPTION OF THE DRAWINGS

The present invention is illustrated by way of example, and not by way of limitation, in the figures of the accompanying drawings and in which like reference numerals refer to similar elements.



FIG. 1 is a block diagram showing an example of a computing system platform upon which embodiments according to the present invention may be implemented.



FIGS. 2A and 2B are a block diagrams showing embodiments of power management systems in accordance with the present invention.



FIG. 3 is a block diagram representing a clock signal frequency adjustment loop in one embodiment in accordance with the present invention.



FIG. 4 is a diagram showing clock signal frequency and workload versus time in one embodiment in accordance with the present invention.



FIG. 5 is a flowchart of a computer-implemented power management method in one embodiment in accordance with the present invention.





DETAILED DESCRIPTION

Reference will now be made in detail to embodiments in accordance with the present invention, examples of which are illustrated in the accompanying drawings. While the invention will be described in conjunction with these embodiments, it will be understood that they are not intended to limit the invention to these embodiments. On the contrary, the invention is intended to cover alternatives, modifications and equivalents, which may be included within the spirit and scope of the invention as defined by the appended claims. Furthermore, in the following detailed description of embodiments of the present invention, numerous specific details are set forth in order to provide a thorough understanding of the present invention. However, it will be recognized by one of ordinary skill in the art that the present invention may be practiced without these specific details. In other instances, well-known methods, procedures, components, and circuits have not been described in detail as not to unnecessarily obscure aspects of the embodiments in accordance with the present invention.


Some portions of the detailed descriptions, which follow, are presented in terms of procedures, steps, logic blocks, processing, and other symbolic representations of operations on data bits within a computer memory. These descriptions and representations are the means used by those skilled in the data processing arts to most effectively convey the substance of their work to others skilled in the art. A procedure, computer executed step, logic block, process, etc., is here, and generally, conceived to be a self-consistent sequence of steps or instructions leading to a desired result. The steps are those requiring physical manipulations of physical quantities. Usually, though not necessarily, these quantities take the form of electrical or magnetic signals capable of being stored, transferred, combined, compared, and otherwise manipulated in a computer system. It has proven convenient at times, principally for reasons of common usage, to refer to these signals as bits, values, elements, symbols, characters, terms, numbers, or the like.


It should be borne in mind, however, that all of these and similar terms are to be associated with the appropriate physical quantities and are merely convenient labels applied to these quantities. Unless specifically stated otherwise as apparent from the following discussions, it is appreciated that throughout the present invention, discussions utilizing terms such as “performing,” “adjusting,” “setting,” “specifying,” “selecting,” “entering,” “interrupting,” “awakening,” “monitoring,” “sending,” “predicting,” “increasing,” “decreasing,” “power gating,” “operating,” “returning,” “monitoring,” “comparing,” “measuring” or the like, refer to the actions and processes of a computer system, or similar electronic computing device, that manipulates and transforms data represented as physical (electronic) quantities within the computer system's registers and memories into other data similarly represented as physical quantities within the computer system memories or registers or other such information storage, transmission or display devices.


Embodiments described herein may be discussed in the general context of computer-executable instructions residing on some form of computer-usable medium, such as program modules, executed by one or more computers or other devices. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform particular tasks or implement particular abstract data types. The functionality of the program modules may be combined or distributed as desired in various embodiments.


By way of example, and not limitation, computer-usable media may comprise computer storage media and communication media. Computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer-readable instructions, data structures, program modules or other data. Computer storage media includes, but is not limited to, random access memory (RAM), read only memory (ROM), electrically erasable programmable ROM (EEPROM), flash memory or other memory technology, compact disk ROM (CD-ROM), digital versatile disks (DVDs) or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to store the desired information.


Communication media can embody computer-readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media. The term “modulated data signal” means a signal that has one or more of its characteristics set or changed in such a manner as to encode information in the signal. By way of example, and not limitation, communication media includes wired media such as a wired network or direct-wired connection, and wireless media such as acoustic, radio frequency (RF), infrared and other wireless media. Combinations of any of the above should also be included within the scope of computer-readable media.



FIG. 1 is a block diagram showing an example of a computing system platform 100 upon which embodiments according to the present invention may be implemented. Embodiments in accordance with the present invention may be implemented on platforms that include functionality, components and devices other than those included in the system 100.


In the FIG. 1 embodiment, the system 100, which may be a battery-operated and/or portable device, includes a central processing unit (CPU) or microprocessor 102, a memory controller 104, a main memory 106, and audio/video processor (AVP) 108 (e.g., a multimedia player or decoder), a graphics (3D) processor 110, and an encoder 112. These elements are interconnected using one or more buses, exemplified by bus 114, such as an AMBA (Advanced Microprocessor Bus Architecture) High Speed Bus (AHB) and an AMBA Peripheral Bus (APB). Each of these elements, including the buses, may be driven using a different clock, although it is possible for different devices to be driven by the same clock. That is, a clock domain may include one or more devices.


In one embodiment, the system 100 is implemented as a system-on-a-chip (SOC). In such an embodiment, all of the blocks in the system 100, including memory, are inside the SOC.


Generally speaking, embodiments in accordance with the present invention can be implemented with multi-processor systems and/or multi-device SOCs.


In the present embodiment, the CPU 102 implements a power management technique that may be referred to as dynamic frequency scaling (DFS). In general, DFS provides a mechanism for adjusting the frequencies of the clock signals used by the devices in the system 100. Supply voltage may also be adjusted when frequency is adjusted—for example, if clock frequency is decreased, then supply voltage may be decreased as well. In general, lowering clock frequency and voltage saves power but can reduce performance. DFS may also be implemented for the CPU 102—the clock frequency used by the CPU 102 may be adjusted up or down to conserve power, depending on the workload of the CPU.


DFS may be implemented using a centralized module that is constantly running. DFS is fundamentally run from the CPU 102 and by itself is consuming power. As will be described, DFS can be disabled under certain conditions. The CPU 102 may be running only for DFS. If so, and if DFS is disabled, then the CPU 102 can be placed in a “reduced power mode”—it may be powered down or turned off. In one embodiment, the CPU is “power gated.” Power gating is a term of art and refers to a technique in which a device (e.g., the CPU 102) is temporarily turned off and then reactivated when it is needed. According to embodiments of the present invention, even if the CPU 102 is powered down or turned off, the activity of each of the devices in the system 100 is monitored. If device activity increases to a certain level, then the CPU 102 is awakened and the device is subject to DFS. These features are described in further detail in conjunction with the figures to follow.



FIG. 2A is a block diagram showing elements of a power management system 200 in one embodiment in accordance with the present invention. The system 200 includes a device 214, which may be one of the devices mentioned in connection with FIG. 1. The device 214 executes one or more software applications that in turn execute one or more tasks.


The device 214 uses a clock signal generated by a clock generator 218. The frequency of the clock signal generated by the clock generator 218 is dynamic—it can be changed (increased or decreased) over time. In the example of FIG. 2A, the frequency of the clock signal is controlled by a dynamic frequency counter or controller (DFC) 216.



FIG. 2A shows only a single device 214. However, as shown in FIG. 2B, there may be multiple devices (device 1214, . . . , device N 254), such as the devices mentioned above in conjunction with FIG. 1, and each of those devices may be inside an SOC as shown in FIG. 1. Each device 1, . . . , N can have its own processor and its own idle monitor 1212, . . . , N 252, respectively, which may be a hardware element or may be running in software, either on the device itself or on the CPU 102. Also, each device 1, . . . , N can generate its own “starvation” and “busyness” triggers, which are described below.


Furthermore, in one embodiment, each device can receive a different clock signal from the clock generator 218—in general, each device 1, . . . , N can have its own clock, and a different clock frequency can be specified for each device. Different tasks can be executed on different devices, with some tasks limited to a subset of all of the devices. Also, a single task may be executed by two different devices.


Thus, the activity (e.g., amount of idle time) for each device 1, . . . , N can be individually monitored using the idle monitors 1, . . . , N, respectively. As will be seen from the discussion below, the clock frequency used by each device 1, . . . , N can be individually adjusted for DFS. Furthermore, as will be seen from the discussion below, DFS can be conditionally disabled.


For reasons of clarity, the following discussion refers to a single device 214. However, the discussion can be readily extended to multiple devices, perhaps operating in parallel, and perhaps operating on the same task or on different tasks.


With reference to FIG. 2A, an initial (baseline) frequency is specified by the CPU 102, depending on the type of task or use case to be executed by the device 214 at any time. The baseline frequency is a function of task and which device is used for the task. If multiple devices are performing the same task, a different baseline frequency may be specified for each device.


Significantly, after setting the baseline frequency initially, the CPU 102 can enter a reduced power mode until it is interrupted or otherwise needed (e.g., to adjust the frequency of the clock signal, as will be described). In the reduced power mode, the CPU 102 can be powered down or turned off. In one embodiment, the CPU 102 is power gated. In essence, the CPU 102 can be switched off while other devices continue to be powered. For example, the CPU 102 may have its own power domain and hence may be powered by an external power supply.


Thus, once the CPU 102 specifies an initial (or baseline) clock frequency for the device 214 based on the identified task, it enters an inactive (e.g., “sleep”) mode. The device 214 executes the task using the baseline frequency after the CPU 102 enters the reduced power mode.


If the baseline frequency needs to be increased because the performance level associated with the baseline frequency is not adequate to perform the task in a manner required or desired, the CPU 102 can be awakened using an interrupt that is issued by the device 214 in response to a triggering event. Triggering events are generally categorized herein as “starvation” triggers and “busyness” triggers. Triggering events may also be referred to as real-time events.


An example of a starvation trigger is buffer fullness. In general, a certain amount of buffer capacity (e.g., a certain number of buffers) is associated with the device 214. It is generally desirable to fill the buffers to a certain level but not completely, so that the buffers do not overflow yet the device 214 will not be starved for data when data is needed. This is particularly true for tasks that involve decoding or processing audio and/or video data for real-time rendering. In one embodiment, the device 214 sends an interrupt to the CPU 102 if a measure of buffer capacity fails to satisfy a predefined threshold. For example, if remaining buffer capacity falls below the predefined threshold, then an interrupt is generated. In response to the interrupt, the CPU 102 awakens so that it can specify a new (higher) frequency for the clock generator 218, thereby increasing the performance of the device 214. Different devices may have different thresholds—each device can have its own threshold for detecting real time starvation. Also, the buffer capacity threshold may depend on the type of task—for a given device, different thresholds may be set for different tasks.


An example of a busyness trigger is a predicted change in workload for the device 214. For example, the device 214 may be executing a particular task when the device driver identifies a pending task that is more computationally intensive then the currently executing task. In one embodiment, the device 214 sends an interrupt to the CPU 102 if the device predicts an increase in its workload. In response to the interrupt, the CPU 102 awakens so that it can specify a new (higher) frequency for the clock generator 218.


Once awakened, the CPU 102 stays awake so that it can continue to dynamically adjust the frequency of the clock signal according to the time-dependent workload of the device 214. Based on the measured idleness of the device, the frequency may be increased or decreased. Supply voltage may also be adjusted when frequency is adjusted—for example, if clock frequency is decreased, then supply voltage may be decreased as well. If the clock frequency is subsequently reset to the baseline frequency, then the CPU 102 can re-enter the reduced power mode.


The embodiment of FIG. 2A includes an idle monitor 212, which may be implemented in hardware and/or software. In general, the idle monitor 212 measures the amount of time that the device 214 is idle. A similar idle monitor may be associated with each device and bus in the system 100. In one embodiment, the idle monitor 212 counts the number of clock cycles that the device 214 is idle during each sample interval. In one embodiment, an average count is determined for a moving window of time. That is, the number of idle clock cycles is counted over a first sample interval, a second sample interval, and so on, up to N consecutive sample intervals. The counts for the set of 1 to N sample intervals are then averaged to determine the amount of idle time for a first window of time. The count for the first sample interval is removed from the set and replaced with the count for the (N+1)th sample interval, and the counts for the set of 2 to (N+1) sample intervals are averaged to determine the amount of idle time for a second window of time, and so on.


In one embodiment, the length of the sample intervals depends on clock frequency—if clock frequency is reduced, the length of the sample intervals is increased. Extending the length of the sample intervals reduces power consumption.


For a given workload, the amount of idle time is a function of clock frequency—increasing the clock frequency increases idle time, and decreasing the clock frequency decreases idle time. Zero idle time is ideal, but in actual practice maintaining zero idle time may not be desirable because there may not be enough time to respond to sudden changes in workload. Consequently, an acceptable amount of idle time is defined and used as a threshold value against which the measured amount of idle time can be compared. If the measured amount of idle time is less than the threshold value, then the clock frequency can be increased. Too little idle time may be referred to as non-real time starvation. If the measured amount of idle time is above the threshold value, then the clock frequency can be decreased. Power consumption is a function of clock frequency, and so power can be conserved by decreasing the clock frequency when it is acceptable to do so. Different threshold values may be specified for different devices—each device can have its own threshold for detecting non-real time starvation. Also, the idleness threshold may depend on the type of task—for a given device, different thresholds may be set for different tasks.


Thus, in general, the value of a selected metric (e.g., idle time) is monitored, and if that metric fails to satisfy a condition (e.g., it is too high or too low in comparison to a threshold value) then the frequency of the clock signal generated by the clock generator 218 is adjusted (decreased or increased, respectively) by the CPU 102. Supply voltage may also be adjusted when frequency is adjusted.


Two threshold values may be used instead of a single threshold: one threshold can be used to determine whether idle time is too high; the other threshold can be used to determine whether idle time is too low; and if the amount of idle time falls between the two thresholds, then the clock frequency is maintained at its current value.



FIG. 3 is a representation of a clock signal frequency adjustment loop 300 in one embodiment in accordance with the present invention. The loop 300 is implemented using the system 200 of FIG. 2A. A feedback loop such as the loop 300 can be implemented in parallel for each device in the system 100 of FIG. 1. That is, there are multiple loops such as the loop 300 running on the CPU 102 for the multiple devices, including a loop for the CPU 102 itself. According to embodiments of the present invention, the loop 300 is used to control and adjust clock frequency only if the CPU 102 is awake; otherwise, the device performing the task uses the baseline frequency. When the CPU 102 is not awake, an interrupt (in response to a triggering event) sent from that device activates the loop 300.


With reference to FIG. 3, the DFC 216, responsive to the CPU 102, controls the frequency of the clock signal generated by the clock generator 218. A device (e.g., the device 214 of FIG. 2A) in the clock domain of the clock generator 218 uses the clock signal to perform a task that is part of an application. The idle monitor 212 measures the degree of idleness of the device, which is compared to the appropriate threshold in the manner described above, resulting in adjustment of the clock frequency, if necessary, to maintain the threshold amount of idleness. Furthermore, the clock frequency can be adjusted in response to a triggering event identified by the device's driver, the application or the task, as described above. Supply voltage may also be adjusted when frequency is adjusted.


For clarity, the discussion of FIGS. 4 and 5 below may imply the use of a single loop 300. However, as noted above, there can be multiple such loops implemented in parallel for each device in the system 100.



FIG. 4 is a diagram showing clock signal frequency and device workload versus time in one embodiment in accordance with the present invention. Prior to time T0, the CPU 102 identifies a task to be performed, identifies which device or devices are needed to perform the task, and sets a baseline frequency for each device (or for each clock domain that includes the identified device(s)). Devices not needed to perform the task may be power gated.


In the example of FIG. 4, a baseline frequency of 10 MHz is specified for the task at hand for one of the devices (e.g., the device 214 of FIG. 2A). Different baseline frequencies can be specified per task (or per use case) and per device (or per clock domain). The baseline frequencies per task or use case, and per device or clock domain, can be implemented using lookup tables, for example.


In region A, from time T0 to time T1, the CPU 102 is placed in a reduced power mode. That is, depending on the implementation, the CPU 102 may be powered down to a reduced power level or turned off completely (e.g., power gated).


In FIG. 4, one of the lines is labeled “device workload.” The workload line is not an actual measure of workload. In a sense, the workload line in FIG. 4 can be interpreted as the clock frequency that, if used, would result in the threshold amount of idle time (as described above, although zero idle time is ideal, in actual practice some idle time is permitted and a threshold value is defined accordingly). In general, the workload changes over time; in regions A and C, the baseline frequency is high enough to accommodate the workload in those regions; and in region B, the baseline frequency is adjusted to generally track the workload.


The workload on the device 214 need not be measured directly, although it may be. It is not necessarily important to precisely quantify the workload; instead, it is important to be able to identify when the workload has increased to the point where the baseline frequency has to be increased. This is accomplished using a starvation or busyness trigger as described above.


In region A, although the task at hand could in theory be accomplished at less than the baseline frequency, the clock frequency used by the device 214 is not reduced to less than the baseline frequency. Therefore, in region A, the device 214 may be operating using a higher clock frequency than needed, and thus may be consuming more power than required. However, as noted above, in region A the CPU 102 is in a reduced power state and may even be turned off. By intelligently selecting the baseline frequency, any power “lost” by driving the device 214 at a clock frequency higher than what may be needed is offset by the power savings that result from powering down or turning off the CPU 102. Thus, in region A (as well as in region C), net power consumption is reduced.


In the example of FIG. 4, a triggering event occurs at time T1. For example, a measure of remaining buffer capacity might fail to satisfy a corresponding threshold, or an increase in workload may be predicted. As a result of the triggering event, an interrupt is generated in order to wake up the CPU 102. In response to the interrupt, the CPU 102 increases the baseline clock frequency by a predetermined amount in order to accommodate the anticipated increase in workload. In the example of FIG. 4, at time T1, the clock frequency is increased to 11 MHz. The point at which the CPU 102 is awakened and the clock frequency is increased may be referred to as a “corner,” and more specifically as a “high corner.”


In region B, the CPU 102 is awake. Idle time of the device 214 is monitored and the clock frequency is adjusted accordingly as described in conjunction with FIGS. 2 and 3 above. In one embodiment, to determine idle time, a count is made of the number of clock cycles that the device 214 is idle over one or more sample intervals. The amount of idle time may be an average value of measurements taken over a moving window of some number of consecutive intervals. Periodically, e.g., each time an average measured value is determined, the measured amount of idle time is compared to a threshold or thresholds. If a single threshold is used and the measured amount of idle time is too high, then the clock frequency is decreased; otherwise, the clock frequency is further increased by, for example, a predetermined amount (e.g., another 1 MHz increment). If two thresholds are used, then the clock frequency can be decreased if the measured amount of idle time is too high; increased if the measured amount of idle time is too low; or kept at its current value if the measured amount of idle time is between the two thresholds.


In the example of FIG. 4, at time T2, the clock frequency is reset to the baseline value. That is, at time T2, the device's workload has decreased, and the amount of idle time has commensurately increased, to the point where the clock frequency can again be set to the baseline value. Upon setting the clock frequency to the baseline value, the CPU 102 can again be placed in the reduced power mode. The point at which the clock frequency is reset to the baseline value and the CPU 102 returned to the reduced power mode may be referred to as a “low corner.”


In summary, in regions A and C, the CPU 102 is in a reduced power mode, a metric such as idle time is not measured, and clock frequency is not adjusted. In region B, the CPU 102 is active, idle time is measured, and clock frequency is adjusted. Supply voltage may also be adjusted when frequency is adjusted. In regions A and C, triggering events are used to awaken the CPU 102—in a sense, the triggering events provide early warning of the need to initially increase and subsequently adjust clock frequency based on workload.


In other words, DFS is disabled in regions A and C but enabled in region B. When DFS is disabled, triggering events are relied upon to identify that DFS needs to be enabled. In regions A and C, when the workload is accomplished by the device 214, the CPU 102 has very little or no work to do. In some instances, the only reason the CPU 102 would be active is to perform DFS. Whether implemented in hardware or software, the idle monitor 212 (FIG. 2A), and any other elements associated with the implementation of DFS, will consume power when DFS is enabled. Disabling DFS and powering down or turning off the CPU 102 means that the idle monitor 212 can also be shut down.



FIG. 5 is a flowchart 500 of computer-implemented power management methods in accordance with embodiments of the present invention. Although specific steps are disclosed in the flowchart 500, such steps are exemplary. That is, embodiments of the present invention are well-suited to performing various other steps or variations of the steps recited in the flowchart 500.


Blocks 510, 520 and 530 are performed with the CPU 102 (FIG. 1) in its normal or active power mode. In block 510, the type of task (or use case) to be performed is identified. In block 520, the device or device(s)—or their respective clock domain(s)—that will perform the task are identified. In block 530, a baseline frequency specific to both the task and the device is selected, and the device is instructed to begin the task. The CPU 102 can also specify a buffer capacity threshold and/or an idleness threshold for the device. The buffer capacity threshold and the idleness threshold may also be specific to the type of task.


In block 540, the CPU 102 enters a reduced power mode (e.g., it is powered down or turned off). In one embodiment, the CPU 102 is power gated.


In block 550, while the device is performing the task using the baseline clock frequency, an interrupt is generated as a result of a triggering event (e.g., a starvation event or a busyness event), described above.


In block 560, the CPU 102 is awakened in response to the interrupt of block 550. That is, the CPU 102 exits the reduced power mode and returns to its normal power mode.


In block 570, the CPU 102 implements DFS. In other words, the CPU 102 adjusts (scales) clock frequency according to the current workload of the device. Supply voltage may also be adjusted when frequency is adjusted. In one embodiment, the amount of idle time is used as a measure of workload. If the amount of time that the device is idle is greater than a corresponding threshold, then the CPU 102 decreases the clock frequency. If the amount of time that the device is idle is less than a corresponding threshold, then the CPU 102 increases the clock frequency. The clock frequency used by the device may also be kept at its current value.


In block 580, if the clock frequency is reset to the baseline frequency, then the CPU 102 re-enters the reduced power mode. That is, if the workload is reduced to a low enough level, then DFS can be disabled and the CPU 102 can be powered down or turned off (e.g., power gated). Blocks 540 through 580 can be repeated until the task is completed.


In summary, embodiments according to the present invention provide methods and systems for conserving power. Such systems and methods are particularly useful in limited-power devices such as battery-powered devices. Power is conserved on at least two fronts. First, power consumption is reduced because the CPU is not running continuously at full power—once the CPU selects a device and a baseline frequency, it can be powered down or turned off until it is needed. Second, the frequency of the clock signal used by the device is adjusted up and down depending on workload—because power usage is a function of clock frequency, the capability to scale frequency to workload means that power is used more efficiently. Supply voltage may also be adjusted when frequency is adjusted. By intelligently selecting an appropriate baseline frequency and then adjusting it as needed, and by selectively running the CPU to implement DFS, a net savings in power is realized. As a result, limited-power devices can be used for longer periods of time and, for a given workload, batteries can be recharged less frequently.


The foregoing descriptions of specific embodiments of the present invention have been presented for purposes of illustration and description. They are not intended to be exhaustive or to limit the invention to the precise forms disclosed, and many modifications and variations are possible in light of the above teaching. The embodiments were chosen and described in order to best explain the principles of the invention and its practical application, to thereby enable others skilled in the art to best utilize the invention and various embodiments with various modifications as are suited to the particular use contemplated. It is intended that the scope of the invention be defined by the claims appended hereto and their equivalents.

Claims
  • 1. A system comprising: a device operable for executing a task; anda processor coupled to said device, wherein said processor specifies a value for a frequency for a clock signal used by said device and thereafter said processor is placed in a reduced power mode; wherein said device is operable to perform said task after said processor is placed in said reduced power mode until a triggering event causes said device to send an interrupt to said processor; wherein in response to said interrupt said processor awakens to dynamically adjust said frequency of said clock signal so that a metric satisfies a first condition.
  • 2. The system of claim 1 wherein said interrupt is sent based on a measure of buffer capacity of a buffer associated with said device.
  • 3. The system of claim 1 wherein said interrupt is sent if a measure of workload is predicted to change during execution of said task.
  • 4. The system of claim 1 wherein said metric is based on an amount of time said device is idle while said task is executed.
  • 5. The system of claim 4 wherein said processor increases said value of said frequency of said clock signal if said metric is less than a corresponding threshold value and decreases said value for said frequency for said clock signal if said metric is more than a corresponding threshold value.
  • 6. The system of claim 4 wherein said amount of time is measured over a sample interval, wherein said sample interval is extended in length if said value for said frequency of said clock signal is reduced.
  • 7. The system of claim 1 wherein said value for said frequency of said clock signal is specified according to a type of said task.
  • 8. The system of claim 1 wherein reduced power mode comprises power gating said processor.
  • 9. A method comprising: operating a processor in a first power mode;in response to a selection of a device to perform a task and a selection of a value for a frequency for a clock used by said device, entering a reduced power mode at said processor, wherein said frequency of said clock remains set to said value until a triggering event occurs;awakening said processor in response to an interrupt generated by said device so that said processor can dynamically adjust said value for said frequency of said clock.
  • 10. The method of claim 9 further comprising: monitoring a measure of buffer capacity associated with said device; andsending said interrupt if said measure is less than a threshold.
  • 11. The method of claim 9 further comprising sending said interrupt if an increase in workload associated with performing said task is predicted.
  • 12. The method of claim 9 further comprising: with said processor in said first operating mode subsequent to said awakening, monitoring a metric that corresponds to an amount of time said device is idle while performing said task;increasing said value of said frequency for said clock if said metric is less than a corresponding threshold value; anddecreasing said value of said frequency for said clock if said metric is greater than a corresponding threshold value.
  • 13. The method of claim 9 wherein said selection of said value for said frequency for said clock depends on a type of said task.
  • 14. The method of claim 9 further comprising power gating said processor in said reduced power mode.
  • 15. A system comprising: a processor; anda device coupled to said processor, wherein said processor specifies a value for a baseline clock frequency for said device and then enters a reduced power mode, wherein said device executes tasks using said value for said baseline clock frequency and awakens said processor from said reduced power mode if said value for said baseline clock frequency is to be changed.
  • 16. The system of claim 15 wherein said value for said baseline clock frequency is to be changed in response to a triggering event selected from the group consisting of: buffer capacity of said device does not satisfy a threshold value; workload of said device is predicted to change; and amount of time said device is idle does not satisfy a threshold value.
  • 17. The system of claim 15 wherein said device sends an interrupt to said processor to awaken said processor.
  • 18. The system of claim 15 wherein, after said processor awakens, said processor adjusts said value for said baseline clock frequency and then returns to said reduced power mode.
  • 19. The system of claim 15 wherein a respective value for said baseline frequency is predefined for each of said tasks, wherein said value for said baseline frequency is looked up by said processor knowing said tasks to be performed.
  • 20. The system of claim 15 further comprising a second device coupled to said processor, wherein said processor specifies a second value for a second baseline clock frequency for said second device before entering said reduced power mode, wherein said second device executes tasks using said second value for said second baseline clock frequency and awakens said processor from said reduced power mode if said second value for said second baseline clock frequency is to be changed.
RELATED U.S. APPLICATION

This application is a continuation application of and claims priority to the patent application entitled “Power Management with Dynamic Frequency Adjustments,” by Frid et al., with Ser. No. 12/029,375, filed Feb. 11, 2008, now U.S. Pat. No. 8,370,663, hereby incorporated by reference in its entirety.

US Referenced Citations (255)
Number Name Date Kind
4335445 Nercessian Jun 1982 A
4544910 Hoberman Oct 1985 A
4679130 Moscovici Jul 1987 A
4706180 Wills Nov 1987 A
4739252 Malaviya et al. Apr 1988 A
4868832 Marrington et al. Sep 1989 A
4893228 Orrick et al. Jan 1990 A
5086501 DeLuca et al. Feb 1992 A
5103110 Housworth et al. Apr 1992 A
5167024 Smith et al. Nov 1992 A
5177431 Smith et al. Jan 1993 A
5201059 Nguyen Apr 1993 A
5204863 Saint-Joigny et al. Apr 1993 A
5218704 Watts, Jr. et al. Jun 1993 A
5218705 DeLuca et al. Jun 1993 A
5230055 Katz et al. Jul 1993 A
5239652 Seibert et al. Aug 1993 A
5254878 Olsen Oct 1993 A
5300831 Pham et al. Apr 1994 A
5307003 Fairbanks et al. Apr 1994 A
5337254 Knee et al. Aug 1994 A
5339445 Gasztonyi Aug 1994 A
5350988 Le Sep 1994 A
5396443 Mese et al. Mar 1995 A
5410278 Itoh et al. Apr 1995 A
5422806 Chen et al. Jun 1995 A
5440520 Schutz et al. Aug 1995 A
5446365 Nomura et al. Aug 1995 A
5461266 Koreeda et al. Oct 1995 A
5502838 Kikinis Mar 1996 A
5511203 Wisor et al. Apr 1996 A
5513152 Cabaniss Apr 1996 A
5560020 Nakatani et al. Sep 1996 A
5561692 Maitland et al. Oct 1996 A
5568103 Nakashima et al. Oct 1996 A
5568350 Brown Oct 1996 A
5586308 Hawkins et al. Dec 1996 A
5587672 Ranganathan et al. Dec 1996 A
5589762 Iannuzo Dec 1996 A
5590342 Marisetty Dec 1996 A
5592173 Lau et al. Jan 1997 A
5594360 Wojciechowski Jan 1997 A
5630110 Mote, Jr. May 1997 A
5648766 Stengel et al. Jul 1997 A
5666522 Klein Sep 1997 A
5675272 Chu Oct 1997 A
5680359 Jeong Oct 1997 A
5682093 Kivela Oct 1997 A
5692204 Rawson et al. Nov 1997 A
5710929 Fung Jan 1998 A
5717319 Jokinen Feb 1998 A
5719800 Mittal et al. Feb 1998 A
5727208 Brown Mar 1998 A
5737613 Mensch, Jr. Apr 1998 A
5742142 Witt Apr 1998 A
5745375 Reinhardt et al. Apr 1998 A
5752011 Thomas et al. May 1998 A
5754869 Holzhammer et al. May 1998 A
5757171 Babcock May 1998 A
5757172 Hunsdorf et al. May 1998 A
5760636 Noble et al. Jun 1998 A
5764110 Ishibashi Jun 1998 A
5774703 Weiss et al. Jun 1998 A
5774704 Williams Jun 1998 A
5778237 Yamamoto et al. Jul 1998 A
5787011 Ko Jul 1998 A
5796313 Eitan Aug 1998 A
5812860 Horden et al. Sep 1998 A
5815724 Mates Sep 1998 A
5825674 Jackson Oct 1998 A
5825972 Brown Oct 1998 A
5847552 Brown Dec 1998 A
5848281 Smalley et al. Dec 1998 A
5864225 Bryson Jan 1999 A
5884049 Atkinson Mar 1999 A
5884068 Conary et al. Mar 1999 A
5894577 MacDonald et al. Apr 1999 A
5913067 Klein Jun 1999 A
5923545 Nguyen Jul 1999 A
5926394 Nguyen et al. Jul 1999 A
5933649 Lim et al. Aug 1999 A
5940785 Georgiou et al. Aug 1999 A
5940786 Steeby Aug 1999 A
5952798 Jones et al. Sep 1999 A
5974557 Thomas et al. Oct 1999 A
5977763 Loughmiller et al. Nov 1999 A
5978926 Ries et al. Nov 1999 A
5996083 Gupta et al. Nov 1999 A
5996084 Watts Nov 1999 A
6005904 Knapp et al. Dec 1999 A
6011403 Gillette Jan 2000 A
6023776 Ozaki Feb 2000 A
6025737 Patel et al. Feb 2000 A
6035357 Sakaki Mar 2000 A
6035407 Gebara et al. Mar 2000 A
6040668 Huynh et al. Mar 2000 A
6047248 Georgiou et al. Apr 2000 A
6065126 Tran et al. May 2000 A
6065131 Andrews et al. May 2000 A
6124732 Zilic et al. Sep 2000 A
6134167 Atkinson Oct 2000 A
6141762 Nicol et al. Oct 2000 A
6163583 Lin et al. Dec 2000 A
6167524 Goodnow et al. Dec 2000 A
6167529 Dalvi Dec 2000 A
6172943 Yuzuki Jan 2001 B1
6216234 Sager et al. Apr 2001 B1
6219795 Klein Apr 2001 B1
6229747 Cho et al. May 2001 B1
6242936 Ho et al. Jun 2001 B1
6243656 Arai et al. Jun 2001 B1
6255974 Morizio et al. Jul 2001 B1
6304824 Bausch et al. Oct 2001 B1
6310912 Maiocchi et al. Oct 2001 B1
6311287 Dischler et al. Oct 2001 B1
6360327 Hobson Mar 2002 B1
6363490 Senyk Mar 2002 B1
6366157 Abdesselem et al. Apr 2002 B1
6369557 Agiman Apr 2002 B1
6407571 Furuya et al. Jun 2002 B1
6415388 Browning et al. Jul 2002 B1
6422746 Weiss et al. Jul 2002 B1
6425086 Clark et al. Jul 2002 B1
6426641 Koch et al. Jul 2002 B1
6448815 Talbot et al. Sep 2002 B1
6456049 Tsuji Sep 2002 B2
6457134 Lemke et al. Sep 2002 B1
6470289 Peters et al. Oct 2002 B1
6476632 La Rosa et al. Nov 2002 B1
6484041 Aho et al. Nov 2002 B1
6489796 Tomishima Dec 2002 B2
6535424 Le et al. Mar 2003 B2
6535986 Rosno et al. Mar 2003 B1
6600575 Kohara Jul 2003 B1
6621242 Huang et al. Sep 2003 B2
6630754 Pippin Oct 2003 B1
6650074 Vyssotski et al. Nov 2003 B1
6650740 Adamczyk et al. Nov 2003 B1
6657504 Deal et al. Dec 2003 B1
6662775 Hauser Dec 2003 B2
6668346 Schulz et al. Dec 2003 B1
6674587 Chhabra et al. Jan 2004 B2
6678831 Mustafa et al. Jan 2004 B1
6690219 Chuang Feb 2004 B2
6703803 Ohiwa et al. Mar 2004 B2
6714891 Dendinger Mar 2004 B2
6718496 Fukuhisa et al. Apr 2004 B1
6721892 Osborn et al. Apr 2004 B1
6737860 Hsu et al. May 2004 B2
6748408 Bredin et al. Jun 2004 B1
6774587 Makaran et al. Aug 2004 B2
6792379 Ando Sep 2004 B2
6794836 Strothmann et al. Sep 2004 B2
6795075 Streitenberger et al. Sep 2004 B1
6795927 Altmejd et al. Sep 2004 B1
6799134 Borchers et al. Sep 2004 B2
6801004 Frankel et al. Oct 2004 B2
6804131 Galbiati et al. Oct 2004 B2
6806673 Ho Oct 2004 B2
6815938 Horimoto Nov 2004 B2
6815971 Wang et al. Nov 2004 B2
6831448 Ishii et al. Dec 2004 B2
6836849 Brock et al. Dec 2004 B2
6837063 Hood, III et al. Jan 2005 B1
6853259 Norman et al. Feb 2005 B2
6853569 Cheng et al. Feb 2005 B2
6885233 Huard et al. Apr 2005 B2
6889331 Soerensen et al. May 2005 B2
6889332 Helms et al. May 2005 B2
6914492 Hui et al. Jul 2005 B2
6938176 Alben et al. Aug 2005 B1
6947865 Mimberg et al. Sep 2005 B1
6970798 Cao et al. Nov 2005 B1
6975087 Crabill et al. Dec 2005 B1
6976112 Franke et al. Dec 2005 B2
6987370 Chheda et al. Jan 2006 B2
6990594 Kim Jan 2006 B2
7003421 Allen, III et al. Feb 2006 B1
7005894 Weder Feb 2006 B2
7042296 Hui et al. May 2006 B2
7043649 Terrell, II May 2006 B2
7045993 Tomiyoshi May 2006 B1
7051215 Zimmer et al. May 2006 B2
7068557 Norman et al. Jun 2006 B2
7071640 Kurosawa et al. Jul 2006 B2
7080271 Kardach et al. Jul 2006 B2
7100061 Halepete et al. Aug 2006 B2
7112978 Koniaris et al. Sep 2006 B1
7119522 Tomiyoshi Oct 2006 B1
7122978 Nakanishi et al. Oct 2006 B2
7129745 Lewis et al. Oct 2006 B2
7149909 Cui et al. Dec 2006 B2
7180322 Koniaris et al. Feb 2007 B1
7256571 Mimberg et al. Aug 2007 B1
7256788 Luu et al. Aug 2007 B1
7334198 Ditzel et al. Feb 2008 B2
7336090 Koniaris et al. Feb 2008 B1
7336092 Koniaris et al. Feb 2008 B1
7348827 Rahim et al. Mar 2008 B2
7348836 Velmurugan Mar 2008 B1
7363176 Patel et al. Apr 2008 B2
7409570 Suzuoki Aug 2008 B2
7414450 Luo et al. Aug 2008 B2
7490256 Marshall et al. Feb 2009 B2
7509504 Koniaris et al. Mar 2009 B1
7574613 Holle et al. Aug 2009 B2
7725749 Mitarai May 2010 B2
7739531 Krishnan Jun 2010 B1
7886164 Alben et al. Feb 2011 B1
8370663 Frid et al. Feb 2013 B2
20010033504 Galbiati et al. Oct 2001 A1
20010045779 Lee et al. Nov 2001 A1
20020002689 Yeh Jan 2002 A1
20020026597 Dai et al. Feb 2002 A1
20020029352 Borkar et al. Mar 2002 A1
20020032829 Dalrymple Mar 2002 A1
20020049920 Staiger Apr 2002 A1
20020073348 Tani Jun 2002 A1
20020083356 Dai Jun 2002 A1
20020087896 Cline et al. Jul 2002 A1
20020099964 Zdravkovic Jul 2002 A1
20020113622 Tang Aug 2002 A1
20020116650 Halepete et al. Aug 2002 A1
20020138778 Cole et al. Sep 2002 A1
20020178390 Lee Nov 2002 A1
20020194509 Plante et al. Dec 2002 A1
20030036876 Fuller, III et al. Feb 2003 A1
20030065960 Rusu et al. Apr 2003 A1
20030074591 McClendon et al. Apr 2003 A1
20030079151 Bohrer et al. Apr 2003 A1
20030110423 Helms et al. Jun 2003 A1
20030133621 Fujii et al. Jul 2003 A1
20030189465 Abadeer et al. Oct 2003 A1
20040025061 Lawrence Feb 2004 A1
20040032414 Jain et al. Feb 2004 A1
20040073821 Naveh et al. Apr 2004 A1
20040105237 Hoover et al. Jun 2004 A1
20040105327 Tanno Jun 2004 A1
20040123170 Tschanz et al. Jun 2004 A1
20040128631 Ditzel et al. Jul 2004 A1
20050007047 Strothmann et al. Jan 2005 A1
20050071705 Bruno et al. Mar 2005 A1
20050218871 Kang et al. Oct 2005 A1
20050268141 Alben et al. Dec 2005 A1
20050268189 Soltis, Jr. Dec 2005 A1
20050289367 Clark et al. Dec 2005 A1
20060074576 Patel et al. Apr 2006 A1
20060246895 Ryu Nov 2006 A1
20070220289 Holle et al. Sep 2007 A1
20070229054 Dobberpuhl et al. Oct 2007 A1
20070234088 Marshall et al. Oct 2007 A1
20070257710 Mari et al. Nov 2007 A1
20070296440 Takamiya et al. Dec 2007 A1
20080143372 Koniaris et al. Jun 2008 A1
20100318828 Elting et al. Dec 2010 A1
Foreign Referenced Citations (16)
Number Date Country
0381021 Aug 1990 EP
0474963 Mar 1992 EP
0501655 Sep 1992 EP
0632360 Jan 1995 EP
0978781 Feb 2000 EP
1096360 May 2001 EP
1182538 Feb 2002 EP
1182556 Feb 2002 EP
1398639 Mar 2004 EP
2342471 Apr 2000 GB
2393540 Mar 2004 GB
2404792 Feb 2005 GB
409185589 Jul 1997 JP
10-187300 Jul 1998 JP
0127728 Apr 2001 WO
03079171 Sep 2003 WO
Non-Patent Literature Citations (21)
Entry
Govil, K. et al.; “Comparing Algorithms for Dynamic Speed-Setting of a Low-Power PCU”; International Computer Science Institute; Berkeley, CA; Apr. 1995. Cited by other.
Hong, I. et al.; Synthesis Techniques for Low-Power Hard Real-Time Systems on Variable Voltage Processors; Real-Time System Symposium Proceedings. Dec. 1998. Cited by other.
Hong, I. et al.; Power Optimization of Variable Voltage Core-Based Systems; Jun. 1998; Design Automation Conference Proceedings. Cited by other.
Mobile Pentium(R) III Processors—Enhanced Intel(R) SpeedStep(TM) Technology, http://support.inteLcomisupport/processorstmobile/pentiumiii/tti004.htm, Sep. 12, 2002, pp. 1-4.
Mobile Pentium(R) III Processors—Thermal Diode, http://supportintel.com/support/processors/mobile/pentiumiii/diode. htm, Sep. 12, 2002, pp. 1-2.
Mobile Pentium(R) III Processors—Thermal Management, http://supportintel.com/support/processorsimobile/pentiumiii/thermal.htm, Sep. 12, 2002, pp. 1-4.
Intel, Intel Pentium 4 Processor in the 423-pin Package, pp. 78-80, (Date believed prior to Nov. 14, 2002).
“Computer Software”, Wikipedia, http://en.wikipedia.org/wiki/software, retrieved May 2, 2007.
“High Speed, Digitally Adjusted Stepdown Controllers for Notebook CPUS”, Maxim Manual, pp. 11 & 21.
Alben, et al.; A Processor Speed Adjustment System and Method; U.S. Appl. No. 10/449,942, filed May 30, 2003.
Alben, et al.; A Processor Voltage Adjustment System and Method; U.S. Appl. No. 10/448,891, filed May 30, 2003.
Baker, K. et al.; “Wafer Burn-In Isolation Circuit” IBM Technical Disclosure Bulletin, IBM Corp., New York, US, vol. 32, No. 6B, Nov. 1, 1989, pp. 442-443, XP00073858 ISSN: 0018-8689, the whole document.
Baker, K. et al.; “Shmoo Plotting: The Black Art of IC Testing”, IEEE Design and Test of Computers, IEEE vol. 14, No. 3; Jul. 1, 1997; pp. 90-97; XP000793305 ISSNL 0740-7475, the whole document.
Calavert, J.B., “The Phase-Locked Loop”, Jul. 24, 2001, http://www.du.edu/.about.etuttle/electron/elect12.htm.
Grishman, Ralph; Lecture Notes, “Computer System Design-Spring 2002”, “Lecture 2: Combinational Logic Design”, 2002, Department of Computer Science, New York University.
Operation U (Refer to Functional Diagram), LTC 1736 Linear Technology Manual, p. 9.
Kelleher, et al.; A Processor Performance Adjustment System and Method; U.S. Appl. No. 10/295,619, filed Nov. 14, 2002.
Laplante, P. Comprehensive Dictionary of Electrical Engineering, CRC Press, IEEE Press, pp. 164-165.
Microsoft Technology Inc. Linear Voltage Fan Speed Control Using Microchips TC64X Family, pp. 1-4, 2003.
Migdal, et al.; “A Processor Temperature and Ode Adjustment System and Method”, U.S. Appl. No. 10/295,748, filed Nov. 14, 2002.
Oner, H et al.; “A Compact Monitoring Circuit for Real-Time-On-Chip Diagnosis of Hot-Carrier Induced Degradation”. Microelectronics Test Structures, 1997. ICMTS 1997. Proceedings, IEEE International Conference on Monterey, CA Mar. 17, 1993-Mar. 20, 1997, pp. 72-76.
Related Publications (1)
Number Date Country
20130212417 A1 Aug 2013 US
Continuations (1)
Number Date Country
Parent 12029375 Feb 2008 US
Child 13758936 US