# Patent

## Title
Method and apparatus to configure thermal design power in a microprocessor

## Abstract

A technique to change a thermal design power (TDP) value. In one embodiment, one or more environmental or user-driven changes may cause a processor's TDP value to be changed. Furthermore, in some embodiments a change in TDP may alter a turbo mode target frequency.

## Background
RELATED APPLICATIONS
This is a Continuation of application Ser. No. 13/118,183, filed May 27, 2011, currently pending, which is a Continuation-in-Part of application Ser. No. 12/974,100 filed Dec. 21, 2010, now abandoned.


FIELD OF THE INVENTION
Embodiments of the invention relate generally to the field of information processing and more specifically, to the field of power management in computing systems and microprocessors.
BACKGROUND
Controlling power consumption in microprocessors is increasing in importance. Some prior art techniques for controlling processor power consumption have not adequately allowed flexible configuration of the thermal design power (TDP) specification for the processor.



BRIEF DESCRIPTION OF THE DRAWINGS
Embodiments of the invention are 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 and in which:
FIG. 1 illustrates a technique to configure thermal design power (TDP) according to one embodiment
FIG. 2 illustrates aspects of at least one technique to configure TDP according to one embodiment.
FIG. 3 illustrates aspects of an initialization technique corresponding to a configurable TDP according to one embodiment.
FIG. 4 illustrates aspects of at least one technique to configure TDP according to one embodiment.
FIG. 5 illustrates aspects of at least one technique to configure TDP according to one embodiment.
FIG. 6 illustrates aspects of at least one technique to configure TDP according to one embodiment.
FIG. 7 illustrates a block diagram of a microprocessor, in which at least one embodiment of the invention may be used;
FIG. 8 illustrates a block diagram of a shared bus computer system, in which at least one embodiment of the invention may be used;
FIG. 9 illustrates a block diagram a point-to-point interconnect computer system, in which at least one embodiment of the invention may be used.



DETAILED DESCRIPTION
Embodiments of the invention pertain to a configurable thermal design power (TDP) consumption for a processor. Although there are multiple embodiments of multiple aspects of the invention, at least one or more aspects are illustrated herein by way of example in order to teach embodiments of the invention and should not be construed to be an exhaustive or exclusive set of embodiments.
Processors may be rated or specified to include both performance and power related characteristics. Individual products or product families may have an associated specification including specific base and turbo frequency capabilities as well as other performance related characteristics. A range of power consumption in a processor may be specified for a product family. For example, standard voltage (SV) mobile processors might have a thermal design power (TDP) rating of 35 Watts. This rating may be an indication to original equipment manufacturers (OEMs) that processors purchased by an OEM will dissipate power that is less than or equal to the specified TDP value for the product when running a specified TDP workload, which may represent a worst case real-world workload scenario when operating at a worst case temperature. While specified performance characteristics may change across a product family, TDP may be specified as the same value across numerous product families. This allows an OEM to design a single platform that is capable of dissipating the specified TDP while offering a range of performance at different price points. Turbo capability, on the other hand, is a potential performance upside in that the TDP workload may cause the TDP power to be dissipated at the base frequency.
In some embodiments, there are several types of turbo mode. Above is a version of turbo mode pertaining to workload or package power sharing, in which case workloads that are otherwise lower natural power than TDP apps without turbo may benefit at the same frequency. These workloads may benefit by allowing power to rise back up to the package TDP power by giving it more than the base frequency. Another version of turbo mode is dynamic turbo mode, in which power is allowed to exceed TDP power for a limited duration, such that on average, over time, the power is still TDP power, which allows brief excursions exceeding TDP if preceded by powers lower than TDP, whether, for example, it be an idle workload or just a workload that does not draw a power equal to the TDP power threshold. TDP power also impacts power delivery design requirements.
Platform thermal capability is a design choice for OEMs as it impacts, size, weight, audible noise, and bill of materials (BOM) cost. The specified TDP for the processor therefore may have significant impact on the platform thermal design. Some processors are sold with only a few TDPs. For example, mobile processors' SV at 35W, low voltage processors' SV at 25W, and ultra-low-voltage processors' SV at 18W.
In mobile platforms, it is possible that cooling capability and audible noise tolerance may vary depending on the use environment. For example, when docked and running on alternating current (AC) power a platform may have more cooling capability than when running undocked on battery power.
Running a higher power processor in an environment of lesser cooling capability than that which can cool the specified TDP may cause thermal control to reduce performance to what is really an unknown capability level that varies across products. Additionally, turbo capability may be disabled as part of thermal control.
A configurable TDP, according to one embodiment, may allow the OEM to configure the TDP of the processor to one of several values. This configuration can be performed either statically at initialization or dynamically, “on-the-fly”. This is effectively accomplished by changing the base frequency of the processor to one of several supported base frequencies. The implication of this change may be that a certain performance is guaranteed by the base frequency and the TDP is specified for each of the supported base frequencies. Additionally, when the base frequency/TDP is changed, the point where turbo engages may also change accordingly. This provides the OEM with the capability to ensure that maximum power dissipation is known while still delivering turbo boost performance when the presented workload allows it.
FIG. 1 illustrates a technique to provide a configurable TDP in a processor, according to one embodiment, by providing three TDP levels, such as “TDP Up” 105, “Nominal TDP” 110, and “TDP Down” 115, which may correspond to power states, such as P-states P0 130, P5 125, and P9 120, respectively. As the TDP value changes dynamically, in one embodiment, the amount of turbo capability changes as well allowing more upside to turbo boost technology while still providing a specific performance to the end user.
In one embodiment, a configurable TDP technique includes validated and configured sets of frequencies and TDP values provided for a processor. In one embodiment, the validated values may be fused, programmed or otherwise configured into the hardware allowing the platform firmware or software to detect and utilize the capability.
In one embodiment, configurable TDP provides a mechanism for designing processors into new segments of platforms. For example, processors supporting configurable TDP may command a premium over other non-configurable TDP processors. OEMs may then choose to purchase a processor and configure it for their needs or provide it in a platform that supports on-the fly reconfiguration of performance and power. One such example is a “mobile extreme edition” platform un-docked and on battery. Configurable TDP has the potential to reduce the number of product families offered, as well.
In one embodiment, configurable TDP architecture makes no assumptions on standards or interdependencies with other technologies, etc. Table 1 below describes the various aspects and portions of a platform that may be affected by a configurable TDP, according to one embodiment.








TABLE 1





Platform Component
Processor Impact







Core
Microcode for new MSRs


Uncore
Three configurable P1 ratios at respective 



TDP power levels change the current P1 ratio 



to one of the available three ratios Turbo states 



still available. Ability to turbo on any ratio 



request above current P1 ratio. (Different TDPs 



do not limit turbo ratios.) Ability to inform 



processor of new Turbo P-states.



Expand allowable long time window power 



limit programming to include all TDP points



Fuse corresponding to power set for TDP



Fuse for ratios (set) for each of the three points



2X Fuses for down-binning OR a bit where make 



non-configurable when down-binned (“chicken bit”)


Chipset
No Impact


Firmware/BIOS
Operating System power management interaction 



to limit OS P-state usage, detect Trigger (hot key), 



adjust RAPL limit, program turbo ratio.


OS
No Impact


Software
Software Stack implementation


Ecosystem
Segment to Segment Arbitrage


Boards/Chassis
Power delivery, System cooling, EC (enabling only)


Enabling
Power, Battery Life, Performance Characterization.









In one embodiment, changes may be made to the model specific registers (MSRs) of a processor and new MSRs may be used to support configurable TDP for the processor. These registers may provide the ability to change the point where turbo engages, for example, and to set the runtime average power limiting (RAPL) power limit value for the new base frequency. In one embodiment, a list of registers that may be accessed, changed, or added using a configurable TDP, include:

    
    
        PLATFORM_INFO: This register may be used to detect the configurable TDP capability,
        CONFIG_TDP_LIMIT_1; CONFIG_TDP_LIMIT_2: This register may be used to detect the configurable TDP ratios and corresponding TDP power and power range,
        CONFIG_TDP_CONTROL: This register may be used to allow software to select different TDP points and read current selection,
        PSTATE_NOTIFY Hook: This register may be used to allow software to enable turbo from a new P1 ratio point. Having this register separate from CONFIG_TDP_CONTROL may allow usage models where the OS might select a specific ceiling for allowable turbo range.
    
    


In other embodiments, other registers or storage (e.g., memory, cache, etc.), may be used in providing for a configurable TDP. Moreover, in some embodiments the functions provided in the above registers may be incorporated into a smaller number of registers or storage.
In some embodiments, there may not be unique platform physical requirements for configurable TDP. However, in some embodiments, specifications for power delivery and cooling may be developed to address requirements for each of the TDP points. Specifications may reflect the ability to select TDP levels for design and accommodate or not accommodate other points, in some embodiments.
In some embodiments, new interfaces or technologies may not be specifically required to support a configurable TDP. However, in some embodiments, affected design characteristics that may be addressed in specifications and enabling include thermal design current (ITDC) and the maximum possible current that may be supported (e.g., “Iccmax”). In some embodiments, parameters may be defined for each TDP point.
TDP may imply an indefinitely sustained cooling level be present to support the corresponding TDP power level. However, in one embodiment, no specific technique is required to represent the changes in cooling capabilities, whether exotic design, docked cooling, changes in fan speed, changes in ambient environment, etc. Cooling design requirements may be established for each TDP level in enabling documentation, however.
In one embodiment, configurable TDP for other logic, such as graphics, memory control, or peripheral control may used. For example, if configurable TDP is used for graphics, a graphics driver may need to be notified about the new TDP level and corresponding RP1 frequency. This can be done in at least two ways, in one embodiment:
(1) Via an interrupt to the graphics device driver from the processor when the TDP level and the corresponding RP1 frequency changes. This may require interrupt configuration and status registers in addition to the registers already needed to support configurable TDP, in one embodiment.

(2) Via the software stack notifying the graphics driver when the TDP level and the corresponding RP1 frequency changes. This may require updates to the software-to-graphics driver communication interface already in place as part of software stack.

In one embodiment, changing the TDP configuration may require the platform to restrict the OS from utilizing certain P-states (e.g., ACPI Notification), exposing all possible P-states to the OS at initialization and by enabling turbo capability at various operating points. The ACPI P-state table (PSS) may be populated appropriately, in some embodiments. In one embodiment, there may not be ecosystem requirements for supporting configurable TDP.
In one embodiment, configurable TDP is either statically configured to a value other than the fused defaults by the BIOS during initialization, for example, or by either the BIOS or a software driver dynamically during run-time. In one embodiment, a configuring the TDP is accomplished by writing a new turbo ratio limit to an MSR to set the point where turbo engages and writing a corresponding power limit to the RAPL power limit MSR in accordance with the value specified for the part/base frequency. Additionally, in some embodiments, the operating system may be notified to limit its use of P-states in accordance with the new base frequency. This may be accomplished, in one embodiment, by causing the OS to evaluate the ACPI_PPC object (Performance Present Capabilities) under each logical processor.
FIG. 2 illustrates logic for configuring TDP, according to one embodiment. The logic illustrated in FIG. 2 may be included in processor hardware or some other hardware. Alternatively, the logic of FIG. 2 may be incorporated into a tangible, machine-readable medium having stored therein instructions, which if executed, causes the function of the logic illustrated in FIG. 2 to be performed. In FIG. 2, the OSPM power configuration applet 215 may be optional and its use of DPPE serves as a trigger 245 to invoke a TDP configuration change. Upon a trigger 245, for example a power source or power plan change, the applet communicates the change to the DPTF driver 220.
The DPTF driver 220 receives a TDP configuration change from the OSPM power configuration applet and performs two functions as a result. The first is to evaluate an ACPI object within its device scope that causes an ACPI notification to be issued by the BIOS 210 on logical processor 225 to the OS to inform it to re-evaluate the PPC object under each logical processor. The return value from the object is derived from a value passed in by the DPTF driver 220 and limits the operating systems use of certain P-states to the new base frequency and below. After this is accomplished, the DPTF driver 220 writes the new TDP configuration 270 to the processor 225 (MSR writes) to set the new turbo ratio (point where turbo is invoked) for the processor and the corresponding RAPL Power Limit value for the new base frequency.
In one embodiment, the processor contains the MSRs described above. Writing MSR may convey information to the power control unit (PCU) on the P-state where turbo is invoked (turbo ratio) as well as the RAPL power limit value.
In one embodiment, the BIOS 210 contains ACPI firmware and natively executable code. The BIOS 210 may be responsible for detecting Configurable TDP 255 feature availability, in one embodiment, and setting up ACPI firmware structures (_PSS) appropriately. The BIOS 210 may statically configure a TDP that is less than the maximum for a product or product family during initialization. Alternatively, the BIOS 210 alone may dynamically set the TDP configuration through a combination of SMM execution and ACPI notifications, in one embodiment. DPTF may also be utilized for setting the TDP configuration dynamically but in either case, the BIOS 210 may contain ACPI firmware that is evaluated to signal the OS to re-evaluate the _PPC object under each logical processor. In one embodiment, the _PPC object evaluation determines which P-states are currently available for use by the OS—corresponding to the TDP configuration (including the P-state where turbo is invoked).
In one embodiment, the OS receives an ACPI notification 230 that causes it to re-evaluate the _PPC object under each logical processor. The value returned from _PPC object evaluation limits the operating systems P-state control 205 software from using certain P-states in accordance with the TDP configuration. When the TDP configuration changes, the highest performance P-state allowed by the _PPC object is configured to become a P-state that invokes turbo operation.
To initialize configurable TDP 255, Platform BIOS 210 may first detect the feature availability, according to one embodiment. Then it may build the OSPM _PSS table using the configurable TDP 255 information it gathers from the processor. FIG. 3 illustrates an initialization technique, according to one embodiment. For example, BIOS 310 may first detect the feature availability in process 330. Then BIOS 310 may build the OSPM _PSS table in process 325 using configurable TDP information such as TDP levels and ratios it gathers from processor/PCU 315 in process 335.
BIOS 310 may program a maximal TDP ratio or a desired TDP ratio as the current TDP ratio in processor/PCU 315 as illustrated in process 340. BIOS 310 may also set _PPC to zero “0” or the P-state corresponding to a desired TDP ratio to indicate the allowed P-states in process 345, and report _PSS table to OSPM 320. OSPM 320 may change the P-state for processor/PCU 315 to a new maximal P-state (depending on workload) in process 355. If the target rate is greater than the current P1 ratio, then processor/PCU 315 may enable turbo in process 350. The initialization technique of FIG. 3 and other processes or mechanisms herein disclosed are performed by processing logic that may comprise dedicated hardware or software or firmware operation codes executable by general purpose machines or by special purpose machines or by a combination of both.
In one embodiment, there are three possible mechanisms with which the TDP can be changed during run time. In other embodiments other techniques or mechanisms may be used to change TDP during run-time. In one embodiment, the platform may provide an option for the end user 405 to select specific modes of operation for the system and it could be provided as a hot key input 425. In this example, the hot key action by the user triggers the change of the TDP value during run time. FIG. 4 illustrates the flow of a user initiated TDP change, according to one embodiment. Following selection of a new TDP mode of operation for the system as a hot key input in process 425, BIOS 410 may program a new P1 ratio and program the RAPL power limit to the new TDP point in processor/PCU 415 as illustrated in process 430. BIOS 410 may also set _PPC to a new maximal available P-state (new turbo P-state in _PSS) in process 440, and report _PSS table to OSPM 420. OSPM 420 may then change the P-state for processor/PCU 415 to the new maximal P-state (depending on workload) in process 445. If the target rate is greater than the current P1 ratio, then processor/PCU 415 may enable turbo in process 435.
A usage model, according to one embodiment, uses platform software to intercept user input and convert that to BIOS 510 calls to invoke the TDP change. FIG. 5 illustrates this usage model, according to one embodiment. In process 530, for example, event 505 may comprise a user selection of a new TDP mode via a power-pan setting or a software GUI or a dock, etc., and a change triggered by event 505 is communicated to DPTF driver 520. DPTF driver 520 invokes an ACPI method with a new P1 selection that causes an ACPI notification to be issued by the BIOS 510 in process 540 to OSPM 515 to inform it to set the _PPC object to a new maximal available P-state (new turbo P-state in _PSS). OSPM 515 may then change the P-state for processor/PCU 515 to the new maximal P-state (depending on workload) in process 555. The return value from the ACPI object is derived from a value passed in by the DPTF driver 520.
In one embodiment, processor/PCU 525 contains MSRs as described above. Writing an MSR may convey information to processor/PCU 525 on the P-state where turbo is invoked (turbo ratio) as well as the RAPL power limit value. So in process 545, DPTF driver 520 programs the new P1 ratio in processor/PCU 525 (via MMIO/MSR writes) to set the new turbo ratio (point where turbo is invoked) for processor/PCU 525, and programs the corresponding RAPL Power Limit value for the new TDP base frequency point. If the target rate is greater than the current P1 ratio, then processor/PCU 525 may enable turbo in process 550.
In some embodiments, the platform may choose to not provide a user control to modify the TDP, but, base the decision on system events like AC to DC switch, or docked vs. undocked event, etc. This usage model is depicted in the sequence shown in FIG. 6, according to one embodiment. In process 625, for example, platform EC 605 notifies BIOS 610 of a new TDP requirement according to a system event as described above. BIOS 610 may program a new P1 ratio and program the RAPL power limit to the new TDP point in processor/PCU 615 as illustrated in process 630. BIOS 610 may also set _PPC to a new maximal available P-state (new turbo P-state in _PSS) in process 635, and report _PSS table to OSPM 620. OSPM 620 may then change the P-state for processor/PCU 615 to the new maximal P-state (depending on workload) in process 645. If the target rate is greater than the current P1 ratio, then processor/PCU 615 may enable turbo in process 640.
In one embodiment, the TDP configuration can be changed dynamically as described above.
In one embodiment, configurable TDP may interoperate with platform firmware and thermal control capability that manipulates ACPI objects to ensure that collisions do not occur. In one embodiment, runtime average power limiting (RAPL) allows a platform to limit the power consumption of the processor. Because platform may use the TDP details as a basis for RAPL limits, the fact that the TDP dynamically changes might result in the RAPL limit becoming invalid. For example, consider a case where the current TDP is 15W and the RAPL limit has been set to 14W by the platform. When the current TDP changes to 23W, the RAPL limit of 14W is too restricting and the processor will not be able to maintain the RAPL limit. In order to solve this issue, the RAPL limit may be updated as part of the configurable TDP change during run time to match with the new TDP level, according to one embodiment.
In one embodiment, configurable TDP maps to two platform features (grouping of interfaces specification)). These are TDP configurability interface (Configuration) and Trigger.
Feature Name: ConfigTDP
Platform Feature (PFAS) ConfigTDP
ConfigTDP.Trigger
ConfigTDP.Trigger.app
ConfigTDP.Trigger.driver (DPTF)
ConfigTDP.Trigger.bios
ConfigTDP.Configuration(Interface)
ConfigTDP.Configuration.bios
ConfigTDP.Configuration.driver(DPTF)
ConfigTDP.Configuration.cpu
ConfigTDP.Configuration.GFXDriver
Some additional features, according to one embodiment, include new or new uses of processor MSRs and graphics driver changes.
FIG. 7 illustrates a microprocessor in which at least one embodiment of the invention may be used. In particular, FIG. 7 illustrates microprocessor 700 having one or more processor cores 705 and 710, each having associated therewith a local cache 707 and 713, respectively. Also illustrated in FIG. 7 is a shared cache memory 715 which may store versions of at least some of the information stored in each of the local caches 707 and 713. In some embodiments, microprocessor 700 may also include other logic not shown in FIG. 7, such as an integrated memory controller, integrated graphics controller, as well as other logic to perform other functions within a computer system, such as I/O control. In one embodiment, each microprocessor in a multi-processor system or each processor core in a multi-core processor may include or otherwise be associated with logic 719 to enable flexible configuration of the TDP specification techniques, in accordance with at least one embodiment. The logic may include circuits, software (embodied in a tangible medium) or both to enable more efficient resource allocation among a plurality of cores or processors than in some prior art implementations.
FIG. 8, for example, illustrates a front-side-bus (FSB) computer system in which one embodiment of the invention may be used. Any processor 801, 805, 810, or 815 may access information from any local level one (L1) cache memory 820, 825, 830, 835, 840, 845, 850, 855 within or otherwise associated with one of the processor cores 823, 827, 833, 837, 843, 847, 853, 857. Furthermore, any processor 801, 805, 810, or 815 may access information from any one of the shared level two (L2) caches 803, 807, 813, 817 or from system memory 860 via chipset 865. One or more of the processors in FIG. 8 may include or otherwise be associated with logic 819 to enable flexible configuration of the TDP specification techniques, in accordance with at least one embodiment.
In addition to the FSB computer system illustrated in FIG. 8, other system configurations may be used in conjunction with various embodiments of the invention, including point-to-point (P2P) interconnect systems and ring interconnect systems. The P2P system of FIG. 9, for example, may include several processors, of which only two, processors 970, 980 are shown by example. Processors 970, 980 may each include a local memory controller hub (MCH) 972, 982 to connect with memory 92, 94. Processors 970, 980 may exchange data via a point-to-point (PtP) interface 950 using PtP interface circuits 978, 988. Processors 970, 980 may each exchange data with a chipset 990 via individual PtP interfaces 952, 954 using point to point interface circuits 976, 994, 986, 998. Chipset 990 may also exchange data with a high-performance graphics circuit 938 via a high-performance graphics interface 939. Embodiments of the invention may be located within any processor having any number of processing cores, or within each of the PtP bus agents of FIG. 9. In one embodiment, any processor core may include or otherwise be associated with a local cache memory (not shown). Furthermore, a shared cache (not shown) may be included in either processor outside of both processors, yet connected with the processors via p2p interconnect, such that either or both processors' local cache information may be stored in the shared cache if a processor is placed into a low power mode. One or more of the processors or cores in FIG. 9 may include or otherwise be associated with logic 919 to enable flexible configuration of the TDP specification techniques, in accordance with at least one embodiment.
One or more aspects of at least one embodiment may be implemented by representative data stored on a machine-readable medium which represents or is coupled with various functionally descriptive matter and/or logic within the processor, which when read by a machine causes the machine to fabricate logic to perform the techniques described herein. Such representations, known as “IP cores” may be stored on a tangible, machine readable medium (“tape”) and supplied to various customers or manufacturing facilities to load into the fabrication machines that actually make the logic or processor.
Embodiments of the invention may be included in or applied to any hardware device or portion thereof, including central processing units, graphics processing units, or other processing logic or cores within a processor or in a computer system. Embodiments may also be embodied in a tangible machine readable medium having stored there on a set of instructions which if performed by a machine causes the machine to perform operations described herein.
Thus, a method and apparatus for directing micro-architectural memory region accesses has been described. It is to be understood that the above description is intended to be illustrative and not restrictive. Many other embodiments will be apparent to those of skill in the art upon reading and understanding the above description. The scope of the invention may, therefore, be determined with reference to the appended claims, along with the full scope of equivalents to which such claims are entitled.

## Claims

1. A processor comprising:
a plurality of cores;
an integrated memory controller to communicatively couple the cores to a system memory;
first circuitry to set a thermal design power (TDP) setting in a Basic Input/Output System (BIOS) based on a user selection in a user interface for the processor and to change a configurable power limit value for the processor based on the TDP setting, wherein the configurable power limit value is to limit a power consumption of the processor,
second circuitry to read the configurable power limit value and write, in a register of a first core, power state information associated with the configurable power limit value, the power state information including a maximum power state for the first core and indicating one of a plurality of power states in which the first core is to currently operate,
wherein the plurality of power states includes at least one low power state and at least one turbo mode state;
a level one cache integral to each one of the plurality of cores;
a first shared cache shared by two or more of the plurality of cores; and
an inter-processor interconnect to communicatively couple the plurality of cores to cores of one or more other processors.

2. The processor of claim 1, wherein the power state information is associated with one of a plurality of Advanced Configuration and Power Interface (ACPI) power states.

3. The processor of claim 1, wherein each of the plurality of power states maps to a distinct frequency to operate one core.

4. The processor of claim 3, wherein mapped frequencies comprise a plurality of frequencies that have an integer number of an offset frequency from a base frequency.