System and method for providing adaptive voltage scaling with multiple clock domains inside a single voltage domain

A system and method is disclosed for providing a plurality of hardware performance monitors for adaptive voltage scaling in an integrated circuit system that comprises a plurality of clock domains. Each hardware performance monitor is associated with one of the plurality of clock domains and provides a signal that measures a performance of its respective clock domain temperature, process corner and supply voltage. The difference between the measured performance and a nominal expected performance for each hardware performance monitor is determined. The largest of the plurality of difference signals is selected and used in an advanced power controller to provide adaptive voltage scaling for the integrated circuit system.

CROSS REFERENCE TO RELATED APPLICATION

The present invention is related to a United States Patent Application by the same inventors entitled “System and Method for Providing Hardware Performance Monitors for Adaptive Voltage Scaling With a Plurality of VTLogic Libraries” that was filed on Mar. 1, 2007 with patent application Ser. No. 11/712,709.

TECHNICAL FIELD OF THE INVENTION

The present invention relates generally to low power integrated circuits and, more particularly, to low power integrated circuits that employ adaptive voltage scaling and operate with a plurality of clock domains inside a single voltage domain.

BACKGROUND OF THE INVENTION

Modern digital integrated circuits such as central processing units (CPUs) are typically capable of operating with several different clock frequencies. Assume that a CPU can reduce its clock frequency while still meeting the processing requirements of an application that is running on the CPU. As is well known, a reduction in the clock frequency of the CPU proportionally reduces the CPU power consumption. With a lower clock frequency less power is consumed because there are fewer signal level changes within a given time period.

As is also well known, the power consumption of a digital circuit is quadratically proportional to the operating voltage. Therefore, decreasing the voltage level of the operating voltage (i.e., the supply voltage) and reducing the clock frequency can provide significant power savings in a digital circuit.

Dynamic Voltage Scaling (DVS) is a power management technique in which pre-determined voltage values (within a voltage table) are used for each requested operating clock frequency of a CPU. The voltage levels that are defined in the voltage table must be carefully selected in order to adequately cover all process and temperature corners so that the CPU will function correctly at each clock frequency.

Adaptive Voltage Scaling (AVS) is a power management technique in which the supply voltage of a digital integrated circuit is adjusted automatically. The supply voltage is adjusted using closed loop feedback to a minimum level that is required for the proper operation of the integrated circuit at a given clock frequency.

The major difference between Dynamic Voltage Scaling (DVS) and Adaptive Voltage Scaling (AVS) is that the Adaptive Voltage Scaling (AVS) automatically measures variation of the process and temperature in order to balance the supply voltage and system delay (digital cell delay) that is due to closed loop feedback. This means that the supply voltage in the AVS system is automatically reduced at lower temperatures and for faster silicon. As the supply voltage is reduced, the power consumption is also reduced.

FIG. 1illustrates a block diagram of an embodiment of an exemplary prior art Adaptive Voltage Scaling (AVS) system100. AVS system100comprises a System-on-a-Chip (SoC) unit110and an Energy Management Unit (EMU)120. The System-on-a-Chip (SoC) unit110comprises a Clock Management Unit (CMU)130, a Variable Voltage Domain CPU System140, a Hardware Performance Monitor (HPM)150, and an Advanced Power Controller (APC)160. The Hardware Performance Monitor (HPM)150is located within the Variable Voltage Domain CPU System140.

The Clock Management Unit (CMU)130receives a system clock signal from a system clock unit (not shown inFIG. 1). The Clock Management Unit (CMU)130provides clock frequencies for the central processing unit (CPU) (also not shown inFIG. 1). The Clock Management Unit (CMU)130also provides clock frequencies for the Hardware Performance Monitor (HPM)150. The clock frequencies that are provided to the Hardware Performance Monitor (HPM)150are represented by the designation HPM CLOCK.

The Hardware Performance Monitor (HPM)150tracks gate delays in the current operational conditions. The CPU system and the Hardware Performance Monitor (HPM)150are in the Variable Voltage Domain CPU System140. The Hardware Performance Monitor (HPM)150outputs a performance code to the Advanced Power Controller (APC)160. The performance code indicates the propagation delay of digital gate cells. The Advanced Power Controller (APC)160processes the delay data and requests appropriate changes to the supply voltage.

The Advanced Power Controller (APC)160is coupled to and communicates with the Energy Management Unit (EMU)120. In one embodiment the coupling between the Advanced Power Controller (APC)160and the Energy Management Unit (EMU)120is a PowerWise® interface (PWI). The mark PowerWise® is a registered trademark of the National Semiconductor Corporation. The Advanced Power Controller (APC)160sends a request to the Energy Management Unit (EMU)120to change the supply voltage. The Energy Management Unit (EMU)120provides the requested supply voltage level to the System-on-a-Chip (SoC)110. The adjustable supply voltage from the Energy Management Unit (EMU)120is designated VAVSinFIG. 1.

The operating system of a modern central processing unit (CPU) may support a real time scheduling of performance levels. Each performance level may have associated with it a specific value of operating clock frequency. The operating system is capable of selecting an operating clock frequency for which the CPU performance is minimized on a real time basis and for which the deadlines of a particular application are still met. For example, while an MPEG4 movie encoding application is running, a performance scheduling algorithm of the operating system may predict and change the performance level of the CPU in ten millisecond (10 ms) intervals.

The Hardware Performance Monitor (HPM)150tracks gate delays in the current operational conditions. The Hardware Performance Monitor (HPM)150outputs a performance code to the Advanced Power Controller160. The performance code indicates the propagation delay of digital gate cells. In particular, Hardware Performance Monitor (HPM)150sends the performance code to the Advanced Power Controller160. The Advanced Power Controller160then subtracts the performance code from a standard Reference Calibration Code (RCC) to obtain an error signal.

The error signal is referred to as “Slack Time”. The Slack Time error signal comprises a digital error signal in a two's complement number format. If the Slack Time is positive an increase in voltage is required. If the Slack Time is negative a decrease in voltage is required. The Slack Time error signal is provided to a Compensation Unit (not shown) within the Advanced Power Controller160. Based on the value of the Slack Time error signal, the Compensation Unit sends a signal to the Energy Management Unit (EMU)120to cause the Energy Management Unit (EMU)120to adjust the value of the adjustable output voltage (VAVS) of Energy Management Unit (EMU)120.

Modern System-on-a-Chip (SoC) digital logic circuits may consume large amounts of power both in terms of leakage power and dynamic power. Leakage power is the power that is consumed when no switching activity occurs within the logic circuitry. Dynamic power is the power that is consumed by the logic circuitry to alter its internal states (e.g., charging and discharging internal nodes).

When a closed loop adaptive voltage scaling system of the type illustrated inFIG. 1minimizes the supply voltage, both the dynamic power and the leakage power are minimized. The expression for the power of the System-on-a-Chip (Soc) is given by the expression:
P=αCV2fCLK+VILEq. (1)

P is the total power of the System-on-a-Chip (SoC). Alpha (α) is a switching activity factor. Alpha (α) represents the percentage of nodes that are switching at each clock cycle. C is the node capacitance inside the SoC. The expression fCLKis the SoC clock frequency. V is the supply voltage. The expression ILis the leakage current. Equation (1) assumes rail-to-rail switching for the CMOS logic.

In modern implementations of System-on-a-Chip (SoC) systems there are multiple independent functional blocks. These blocks may include general purpose processor cores, digital signal processing (DSP), and hardware accelerators for specific functions like Digital Video Broadcasting-Handheld (DVB-H) reception, encoding and decoding in MPEG 2/MPEG 4/VC1 video standards, baseband processing and the like. The multiple independent functional hardware blocks are used for different functions because it is much more efficient in terms of power consumption to use a hardware implementation rather than a software implementation. For example, DVB-H decoding that is performed in a dedicated hardware block is more efficient in terms of power consumption than DVB-H decoding that is performed using software running in a central processing unit (CPU).

In addition, the individual multiple independent functional hardware blocks are activated only when they are needed. When they are not required, the individual multiple independent functional hardware blocks remain inactive to reduce power consumption.

There are several independent functional hardware blocks inside a System-on-a-Chip (SoC) system. Each hardware block has its own characteristic usage requirements and operating frequencies (which may also be variable frequencies). Each of the hardware blocks can further reduce its power consumption by using techniques like Dynamic Voltage Scaling (DVS) and Adaptive Voltage Scaling (AVS). This requires that an Adaptive Voltage Scaling (AVS) system100of the type that is shown inFIG. 1be implemented in parallel for each independent functional hardware blocks inside the System-on-a-Chip (SoC) system. This type of arrangement provides an optimal supply voltage for each of the independent functional hardware blocks.

However, there are two main disadvantages with this approach. First, the number of required adjustable voltage regulators (and associated external components) may be too large. That is, the number of circuit elements that are required to implement this solution may be too large for this solution to be feasible in a size-constrained portable device. Second, even if the size and complexity problems could be overcome, the cost of all of the required hardware may be too great for a particular application.

Therefore, there is a need in the art for a system and method that allows a system architect to define an optimum balance between power efficiency and the number of independent voltage domains (and associated adjustable voltage regulators and their external components) in terms of size and cost while optimizing the power consumption of a complex, multi-function System-on-a-Chip (SoC) system. There is a need in the art for a system and method that is capable of efficiently providing accurate adaptive voltage scaling (AVS) for a System-on-a-Chip (SoC) system that operates with a plurality of clock domains inside a single voltage domain.

SUMMARY OF THE INVENTION

To address the above-discussed deficiencies of the prior art, it is a primary object of the present invention to provide a system and method for efficiently providing accurate adaptive voltage scaling (AVS) for a System-on-a-Chip (SoC) system that operates with a plurality of clock domains inside a single voltage domain.

In an advantageous embodiment of the present invention the adaptive voltage scaling (AVS) system comprises a plurality of Hardware Performance Monitors (HPMs) for use with an Advanced Power Controller (APC) loop control unit and a System-on-a-Chip (SoC). Each Hardware Performance Monitor (HPM) is associated with one of a plurality of functional blocks. Each functional block comprises a separate clock domain.

Each Hardware Performance Monitor (HPM) provides a signal that measures a performance of its respective functional block die temperature, process corner and supply voltage. The difference between the measured performance and a nominal expected performance for each Hardware Performance Monitor (HPM) is determined. Then the largest of the plurality of difference signals is selected and used in the Advanced Power Controller (APC) loop control unit to provide adaptive voltage scaling for the system.

DETAILED DESCRIPTION OF THE INVENTION

The present invention solves the problems that exist in the prior art by connecting a plurality of Hardware Performance Monitors (HPMs) to the control loop of the adaptive voltage scaling (AVS) system. One Hardware Performance Monitor (HPM) is provided for each different clock domain in the system. For example, in the case of a system with two clock domains, two Hardware Performance Monitors (HPMs) are provided. The first Hardware Performance Monitor (HPM1) is provided for the first clock domain and the second Hardware Performance Monitor (HPM2) is provided for the second clock domain. Three Hardware Performance Monitors (HPMs) are provided for designs that have three different clock domains, and so on.

The present invention enables a system architect to implement and manage the supply voltage of an adaptive voltage domain that includes multiple functional blocks that may be independently frequency scaled. The ability to combine, if needed, multiple functional blocks (with independent clock domains) into a large Adaptive Voltage Scaling (AVS) domain allows the system architect to make trade offs between system size and cost versus power efficiency. At the same time, independent frequency selection for each functional block within the Adaptive Voltage Scaling (AVS) domain allows optimization of the operating frequency of each function. This provides optimization of system performance and power consumption.

For example, a large, high-power function that is often used might be allocated a first independent Adaptive Voltage Scaling (AVS) domain to minimize its power consumption. At the same time, several auxiliary functions might be combined in a second shared voltage domain with a second shared Adaptive Voltage Scaling (AVS) power supply in order to reduce the system size and cost.

If the functions of the second shared Adaptive Voltage Scaling (AVS) domain are rarely used together, then the overall power efficiency of the system can still be close to that of a system that has an independent Adaptive Voltage Scaling (AVS) domain for each function. In an extreme case where the multiple functions in the second shared Adaptive Voltage Scaling (AVS) domain are never used at the same time, this arrangement is as power efficient (for dynamic power consumption) as having a dedicated power supply for each function, but at a cost of (1/N) of the regulator hardware cost, where N is the number of functional blocks within the Adaptive Voltage Scaling (AVS) domain.

For an Adaptive Voltage Scaling (AVS) domain that is shared by more than one functional block, a system and method is needed to determine a supply voltage that is adequate for all of the functional blocks.FIG. 2is a block diagram illustrating an advantageous embodiment200of the present invention that comprises two such functional blocks. The two functional blocks in the Adaptive Voltage Scaling (AVS) domain205ofFIG. 2are a central processing unit (CPU)210and a digital signal processing (DSP) unit220. Each functional block comprises a separate clock domain. Although the principles of the present invention will be described with reference to two functional blocks, it is understood that the present invention is not limited to two functional blocks. It is understood that in the present invention any number of functional blocks may be implemented inside an Adaptive Voltage Scaling (AVS) domain.

The advantageous embodiment200of the present invention comprises a System-on-a-Chip (SoC) Clock Management Unit (CMU)230. SoC CMU230comprises a CPU Clock Management Unit (CMU)235and a Digital Signal Processing (DSP) Clock Management Unit (CMU)240. The CPU CMU235and the DSP CMU240are each functionally equivalent to the Clock Management Unit (CMU)130that is shown inFIG. 1for the prior art System-on-a-Chip (SoC)110. The CPU CMU235and the DSP CMU240are each fully independent. The operating frequencies of the CPU CMU235may be adjusted without regard to the operating frequencies of the DSP CMU240. Similarly, the operating frequencies of the DSP CMU240may be adjusted without regard to the operating frequencies of the CPU CMU235.

The central processing unit (CPU)210in the AVS voltage domain205comprises a first Hardware Performance Monitor (HPM1)215. The digital signal processing (DSP) unit220in the AVS voltage domain205comprises a second Hardware Performance Monitor (HPM2)225.

As shown inFIG. 2, the CPU210receives a CPU reference clock signal (CPU CLOCK) from the CPU Clock Management Unit (CMU)235within the System-on-a-Chip (SoC) Clock Management Unit (CMU)230. The first Hardware Performance Monitor (HPM1)215also receives a first HPM reference clock signal (HPM1Clock) from the CPU Clock Management Unit (CMU)235within the System-on-a-Chip (SoC) Clock Management Unit (CMU)230.

The DSP unit220receives a DSP reference clock signal (DSP CLOCK) from the DSP Clock Management Unit (CMU)240within the System-on-a-Chip (SoC) Clock Management Unit (CMU)230. The second Hardware Performance Monitor (HPM2)225also receives a second HPM reference clock signal (HPM2Clock) from the DSP Clock Management Unit (CMU)240within the System-on-a-Chip (SoC) Clock Management Unit (CMU)230.

The first Hardware Performance Monitor (HPM)215and the second Hardware Performance Monitor (HPM)225each produce an output that is relative to the performance of its respective die temperature, process corner and supply voltage. As will be described more fully below, the outputs of the two Hardware Performance Monitors (215and225) are compared in real time to their respective nominal expected outputs. The Hardware Performance Monitor whose output indicates a requirement for a higher supply voltage is used to control the voltage regulator of the AVS system (i.e., the PWI Controlled Voltage Regulator295).

As shown inFIG. 2, the output of the first Hardware Performance Monitor (HPM1)215and the output of the second Hardware Performance Monitor (HPM2)225are provided to the Advanced Power Controller (APC) loop control unit265. As will be more fully described the APC loop control unit265(1) receives “target index” values from the System-on-a-Chip (Soc) CMU230for each of the two functional blocks, and (2) receives performance data from the output of the first Hardware Performance Monitor (HPM1)215and the output of the second Hardware Performance Monitor (HPM2)225, and (3) produces output voltage commands for the PWI Controlled Voltage Regulator295, and (4) produces “current index” values for the CPU Clock Management Unit (CMU)235and the DSP Clock Management Unit240within the System-on-a-Chip (SoC) Clock Management Unit (CMU)230. The “current index” values indicate which clock frequency can be safely used inside the AVS voltage domain205.

As shown inFIG. 2, the CPU CMU235provides a target index value (designated Target Index CPU) to the APC loop control unit265via signal line245. The CPU CMU235receives a current index value (designated Current Index CPU) from the APC loop control unit265on signal line250. The DSP CMU240provides a target index value (designated Target Index DSP) to the APC loop control unit265via signal line255. The DSP CMU240receives a current index value (designated Current Index DSP) from the APC loop control unit265on signal line260.

The PWI Controlled Voltage Regulator295receives voltage values via the PowerWise® interface (PWI) from the control loop logic unit290of the APC loop control unit265. The PWI Controlled Voltage Regulator295produces an output voltage (designated AVS supply voltage) as directed by the incoming voltage value from the APC loop control unit265. The PWI Controlled Voltage Regulator295typically comprises an external integrated circuit (IC) that is located outside of the System-on-a-Chip (Soc) system. However, it is also possible to implement the PWI Controlled Voltage Regulator295on the same SoC die or in the same package. All of the variations are functionally equivalent. The PWI Controlled Voltage Regulator295provides the AVS supply voltage to the AVS domain205via a supply rail or a pin on the SoC chip.

Because the Adaptive Voltage Scaling (AVS) loop has only a single common supply voltage, the data from the two Hardware Performance Monitors (HPM1215and HPM2225) has to be used to determine which functional block (CPU or DSP) requires a higher supply voltage. The overall voltage level is determined based on the more critical block just as if only a single functional block existed inside the Adaptive Voltage Scaling (AVS) domain205.

Each Clock Management Unit (CMU) (i.e., CPU CMU235and DSP CMU240) provides its respective reference clock signal (HPM1Clock and HPM2Clock) to its respective Hardware Performance Monitor (HPM1and HPM2) inside the functional block that the Clock Management Unit (CMU) controls. Each Hardware Performance Monitor outputs a code relative to the performance of the logic in its respective functional block.

These codes are compared to expected values for those operating frequencies. The code that indicates the lowest level of performance (relative to the required performance) is used as a control input by the APC loop control unit265to adjust the supply voltage.

The CPU210and the DSP unit220are able to share the same Adaptive Voltage Scaling (AVS) domain205because of steps that are taken by the APC loop control unit265based on information from the two Hardware Performance Monitors (HPM1215and HPM2225). APC loop control unit265comprises a curve table unit285that comprises a first “curve table” that stores the expected output of the first Hardware Performance Monitor (HPM1215) at each operating frequency of the CPU210. The output of the first Hardware Performance Monitor (HPM1215) is subtracted from the value obtained from the first “curve table.”

Curve table unit285also comprises a second “curve table” that stores the expected output of the second Hardware Performance Monitor (HPM2225) at each operating frequency of the DSP unit220. The output of the second Hardware Performance Monitor (HPM2225) is subtracted from the value obtained from the second “curve table.”

In the case of two independent functional blocks (i.e., two independent clock domains) within a single Adaptive Voltage Scaling (AVS) domain205, there must be a separately maintained curve table for each of the two blocks. For each of the two blocks, a value that corresponds to a desired operating frequency (indicated by the “target index” value) is fetched from the curve table and compared to the Hardware Performance Monitor output to compute an output signal (referred to as a “Slack Time”).

The output of the first Hardware Performance Monitor (HPM1215) is provided to a first subtraction unit270. First subtraction unit270also receives a value that represents the nominal expected output of the first Hardware Performance Monitor (HPM1215) from the curve table unit285. Curve table unit285contains the nominal expected values for first Hardware Performance Monitor (HPM1215). A value of the target index for the CPU is provided to the curve table unit285from the CPU CMU235.

As also shown inFIG. 2, the output of the second Hardware Performance Monitors (HPM2225) is provided to second subtraction unit275. Second subtraction unit275also receives a value that represents the nominal expected output of the second Hardware Performance Monitor (HPM2225) from curve table unit285. Curve table unit285contains the nominal expected values for second Hardware Performance Monitor (HPM2225). A value of the target index for the DSP is provided to the curve table unit285from the DSP CMU240.

The first subtraction unit270subtracts the output of the first Hardware Performance Monitor (HPM1215) from the nominal expected output of the first Hardware Performance Monitor (HPM1215) from curve table unit285. The output of the first subtraction unit270(designated as “first Slack Time”) is provided to a comparator unit280(designated MAX [SLACK TIME] inFIG. 2).

The second subtraction unit275subtracts the output of the second Hardware Performance Monitor (HPM2225) from the nominal expected output of the second Hardware Performance Monitor (HPM2225) from curve table unit285. The output of the second subtraction unit275(designated as “second Slack Time”) is also provided to the comparator unit280.

The result of the subtraction in the subtraction units (270and275) provides indirect information about the supply voltage level and the performance of the logic. A positive number for the Slack Time indicates an inadequate supply voltage for the current operating frequency. A negative number for the Slack Time indicates an excessive supply voltage. The magnitude of the Slack Time indicates the size of the voltage error. By taking the larger of the two “Slack Time” signals, the APC loop control unit265can adjust the supply voltage for both the CPU210and the DSP unit220. The block that requires the higher supply voltage sets the final voltage level. The block that requires the lower supply voltage will actually receive a higher than optimal supply voltage level.

Unless both blocks need exactly the same voltage level to run at a desired frequency, one of the two blocks will not be fully optimized. However, the savings in system size and cost due to having to use fewer voltage regulators may be more important than this inefficiency. If only one of the blocks (CPU or DPS) is active at a time, the supply voltage is optimal for the block that is active.

Comparator unit280compares in real time the value of the first Slack Time from the first subtraction unit270and the value of the second Slack Time from the second subtraction275. Comparator unit280selects the Slack Time signal from the subtraction unit that has the larger value. The comparator unit280then outputs the selected Slack Time signal to the control loop logic unit290of the Advanced Power Controller (APC) loop control unit265.

From this point the adaptive voltage scaling (AVS) system works in exactly the same manner as in the case of a single Hardware Performance Monitor (HPM) operating with a single functional block. The Advanced Power Controller (APC) loop control unit265provides the PowerWise® interface (PWI) signal to PWI Controlled Voltage Regulator295.

The Advanced Power Controller (APC) loop control unit265also provides the Current Index CPU to the CPU Clock Management Unit (CMU)235via signal line250. The Advanced Power Controller (APC) loop control unit265also provides the Current Index DSP to the DSP Clock Management Unit (CMU)240via signal line260. The Advanced Power Controller (APC) loop control unit265also receives the Target Index CPU from the CPU Clock Management Unit (CMU)235via signal line245. The Advanced Power Controller (APC) loop control unit265also receives the Target Index DSP from the DSP Clock Management Unit (CMU)240via signal line255.

When the clock frequency for one of the two functional blocks (CPU or DSP) is changed, the corresponding Clock Management Unit (CMU) first updates the respective Target Index and HPM clock frequency to the new value. The APC loop control unit265sees the change in the Target Index relative to the Current Index and realizes that a frequency change has been requested. The APC loop control unit265will also see that the output of the corresponding Hardware Performance Monitor (HPM) has changed because the HPM clock frequency has changed. Inside the APC loop control unit265a new reference value is fetched from the respective curve table based on the new Target Index.

Note that if both (or multiple) clock frequency changes occur simultaneously, then the HPM clocks, Target Indexes, and reference values are updated for all of them in parallel.

After the initial updates, the APC loop control unit265will monitor the maximum of the “Slack Times.” Based on the history, sign and magnitude of the “Slack Time,” the APC loop control unit265will adjust the AVS supply voltage using the PWI Controlled Voltage Regulator295until the “Slack Time” is negative. A negative “Slack Time” indicates that the supply voltage is adequate for all the functional blocks inside the AVS voltage domain205.

Note that due to the independent parallel nature of the functional blocks (CPU and DSP) inside the AVS voltage domain205(and their independent clock frequencies), there may not always be a voltage change after a frequency change. A voltage change only occurs (1) if the functional block that requires more voltage than the other functional block changes frequency, or (2) if the functional block becomes (or ceases to be) the functional block that requires the highest voltage after the voltage change. Because the APC loop control unit265operates using the maximal “Slack Time” as its input, the APC loop control unit265will automatically adjust the supply voltage so that all blocks have an adequate supply voltage.

After the APC loop control unit265adjusts the supply voltage to the correct level, the APC loop control unit265grants the new frequency by updating the Current Index to be the same as the Target Index. This will (1) cause the CPU CMU235to enable the new CPU clock as needed, or (2) cause the DSP CMU240to enable the new DSP clock as needed.

The advantageous embodiment200of the present invention enables two independent clock domains (CPU210and DSP unit220) to share a common Adaptive Voltage Scaling (AVS) domain205and have their supply voltage optimized in a closed loop so that the two clock domains can safely operate at their chosen frequencies.

An advantageous embodiment of the present invention has been described for the case of a two independent functional blocks (CPU and DSP). However, it is understood that the present invention is not limited to use with two independent functional blocks and that any number of independent functional blocks may be implemented. This principle is illustrated inFIG. 3.

FIG. 3is a block diagram illustrating an advantageous embodiment300of the present invention showing a portion of an Adaptive Voltage Scaling (AVS) system that comprises a plurality of independent functional blocks (310,320, . . . ,330) in an adaptive voltage scaling (AVS) voltage domain305. This embodiment comprises a plurality N of Hardware Performance Monitors (HPMs) (315,325, . . . ,335).

As shown inFIG. 3, the first Hardware Performance Monitor (HPM1315) is associated with a CPU block310. The second Hardware Performance Monitor (HPM2325) is associated with a DSP block320. The last (or Nth) Hardware Performance Monitor (HPMN335) is associated with an NTHblock330.

The first Hardware Performance Monitor (HPM1315) provides an output to a first subtraction unit340. The first subtraction unit340also receives a value that represents the nominal expected output of the first Hardware Performance Monitor (HPM1315) from an HPM1curve table (not shown inFIG. 3).

The first subtraction unit340subtracts the output of the first Hardware Performance Monitor (HPM1315) from the nominal expected output of the first Hardware Performance Monitor (HPM1315) from the HPM1curve table. The output of the first subtraction unit340is provided to a comparator unit370(designated MAX [SLACK TIME] inFIG. 3).

The second Hardware Performance Monitor (HPM2325) provides an output to a second subtraction unit350. The second subtraction unit350also receives a value that represents the nominal expected output of the second Hardware Performance Monitor (HPM2325) from an HPM2curve table (not shown inFIG. 3).

The second subtraction unit350subtracts the output of the second Hardware Performance Monitor (HPM2325) from the nominal expected output of the second Hardware Performance Monitor (HPM2325) from the HPM2curve table. The output of the second subtraction unit350is provided to the comparator unit370.

Lastly, the last (or Nth) Hardware Performance Monitor (HPMN335) provides an output to a last (or Nth) subtraction table360. The last subtraction unit360also receives a value that represents the nominal expected output of the last (or Nth) Hardware Performance Monitor (HPMN335) from an HPMN curve table (not shown inFIG. 3).

The last subtraction unit360subtracts the output of the last (or Nth) Hardware Performance Monitor (HPMN335) from the nominal expected output of the last (or Nth) Hardware Performance Monitor (HPMN335) from the HPMN curve table. The output of the last subtraction unit360is provided to the comparator unit370.

Comparator unit370compares in real time the first Slack Time value from the first subtraction unit340and the second Slack Time value from the second subtraction unit350and the Slack Time values from all the other subtraction units up to and including the last subtraction unit360. Comparator unit370selects the Slack Time signal from the subtraction unit that has the largest value. The comparator unit370then outputs the selected Slack Time signal to an Advanced Power Controller (APC) control loop logic unit (not shown inFIG. 3). This embodiment illustrates that the present invention may employ any desired number of Hardware Performance Monitors (HPMs).

FIG. 4is a flow chart400illustrating an advantageous embodiment of a method of the invention. In an adaptive voltage scaling (AVS) system a Hardware Performance Monitor (HPM) is provided for each different clock domain (i.e., functional block) in the AVS system (step410). As previously described, each functional block comprises a separate clock domain. Each Hardware Performance Monitor (HPM) detects process and temperature effects on its own clock domain (step420).

Each Hardware Performance Monitor (HPM) outputs to its own respective subtraction unit a signal that represents the performance of its own clock domain die temperature, process corner and supply voltage (step430). Each respective subtraction unit receives from a curve table unit a signal that represents the nominal expected output of its respective Hardware Performance Monitor (HPM) (step440).

Each respective subtraction unit subtracts the signal received from its Hardware Performance Monitor (HPM) from its respective signal received from the curve table unit to calculate a Slack Time and provides the Slack Time to a comparator unit (step450). The comparator unit compares a Slack Time from each subtraction unit and selects the Slack Time signal that has the largest value and outputs the largest Slack Time signal to a control loop logic unit of an Advanced Power Controller (APC) loop control circuit (step460). From this point the adaptive voltage scaling (AVS) system works in exactly the same manner as in the case of a single Hardware Performance Monitor (HPM) operating with a single clock domain.