Attributing energy consumption to individual code threads in a data processing system

Saved in:
Bibliographic Details
Title: Attributing energy consumption to individual code threads in a data processing system
Document Number: 20060155415
Publication Date: July 13, 2006
Appl. No: 11/034558
Application Filed: January 13, 2005
Abstract: A data processing system attributes energy consumption to individual program segments or threads includes a processor that executes a first thread during a first portion of a measurement interval and a second thread during a second portion of the interval. An energy monitor measures the total energy during the interval. Energy attribution code attributes a first amount of the total energy to the first thread and a second amount to the second thread based in part on the execution times of the threads. The code may define a range of possible energy values by determining maximum and minimum energy constraints for the threads. The invention may also be extended to a multiprocessor environment and to a simultaneous multithreading (SMT) processor. In addition, the process may be expanded to determine energy consumed by various peripheral units such as hard disk controllers and the like.
Inventors: Lefurgy, Charles R. (Round Rock, TX, US); Ware, Malcolm Scott (Austin, TX, US)
Claim: 1. A data processing system, comprising: a processor enabled to execute a first thread during a first portion of a measurement interval and a second thread during a second portion of the measurement interval; an energy monitor enabled to determine the total energy consumed by the processor during the measurement interval; and energy attribution code, stored in a processor readable storage medium, to estimate a first amount of the total energy attributable to the first thread and a second amount of the total energy attributable to the second thread, wherein the energy attribution code includes code to determine the execution time of the first and second threads and wherein the estimates of the amount of the total energy attributable to the first and second threads is based at least in part on the respective execution times of the first and second threads.
Claim: 2. The data processing system of claim 1, wherein the energy attribution code includes code to; determine from the execution time of the first thread a first maximum and minimum energy constraint for the first thread wherein the first maximum and minimum energy constraint for the first thread represent constraints on the amount of the total energy attributable to the first thread; determine from the execution time of the second thread a first maximum and minimum energy constraint for the second thread wherein the first maximum and minimum energy constraints for the second thread represent boundaries on the amount of the total energy attributable to the second thread; use the first thread maximum and minimum energy constraints, the second thread maximum and minimum energy constraints, and the total energy to define a range for the amount of the total energy attributable to the first thread; and use a point centralized within the defined range as the estimate of the amount of the total energy attributable to the first thread.
Claim: 3. The data processing system of claim 2, wherein the energy attribution code to use the first thread maximum and minimum energy, the second thread maximum and minimum energy, and the total energy includes code to: determine a minimum constraint on the range by determining a second minimum energy constraint for the first thread representing the amount of the total energy attributable to the first thread assuming the processor consumed the maximum amount of energy to execute the second thread; and selecting the greater of the first minimum energy constraint for the first thread and the second minimum energy constraint for the first thread as the operative minimum constraint.
Claim: 4. The data processing system of claim 3, wherein the energy attribution code to use the first thread maximum and minimum energy, the second thread maximum and minimum energy, and the total energy includes code to: determine a maximum constraint on the range by determining a second maximum energy constraint for the first thread representing the amount of energy attributable to the first thread assuming the processor consumed the minimum amount of energy to execute the second thread; and selecting the lesser of the first maximum energy constraint for the first thread and the second maximum energy constraint for the first thread as the operative maximum constraint.
Claim: 5. The data processing system of claim 1, further comprising a second processor and a second energy monitor enabled to determine the total energy consumed by the second processor during the measurement interval, wherein the energy attribution code estimates an amount of the total energy consumed by the second processor to execute a third thread and an amount of the total energy consumed by the second processor used to execute a fourth thread.
Claim: 6. A data processing system, comprising: a functional unit configured to perform tasks for multiple objects including a first object and a second object; an energy monitor configured to measure total energy consumed by the functional unit during a measurement period; a scheduler enabled to provide timing information indicative of time periods during which the functional unit was performing tasks for each of objects; an application to attribute portions of the total energy to each of the objects based on the timing information.
Claim: 7. The data processing system of claim 6, wherein the functional unit is a processor.
Claim: 8. The data processing system of claim 6, wherein the functional unit is a peripheral device.
Claim: 9. The data processing system of claim 8, wherein the functional unit is a disk controller.
Claim: 10. The data processing system of claim 6, wherein each of the multiple objects is a thread executing under control of an operating system.
Claim: 11. The data processing system of claim 6, wherein each of the multiple objects is an operating system executing control of a hypervisor.
Claim: 12. The data processing system of claim 6, wherein the application is configured to attribute portions of the total energy to each of the objects subject to maximum and minimum energy consumption constraints.
Claim: 13. The data processing system of claim 12, wherein the maximum and minimum constraints are determined from maximum and minimum energy consumption rates associated with the functional unit and the timing information.
Claim: 14. The data processing system of claim 6, wherein the system is configured to determine the measurement period based on the timing information wherein a first object was performing tasks for a substantial majority of the measurement period.
Claim: 15. A computer program product comprising computer executable instructions, stored on a computer readable medium, for attributing energy consumption in a data processing system, objects executing in the system, the program product comprising: computer code means for determining a total energy consumed by the data processing system during a measurement period; computer code means for determining timing information for a plurality of objects, wherein the timing information is indicative of which objects were executing during the measurement period; and computer code means for using the timing information and the total energy to attribute the total energy to each of the objects.
Claim: 16. The computer program product of claim 15, wherein the computer code means for determining timing information comprises a scheduler configured to schedule execution of threads on a processor of the data processing system.
Claim: 17. The computer program product of claim 15, wherein the computer code means for determining timing information comprises a hypervisor scheduler configured to schedule execution of a one or more operating system objects.
Claim: 18. The computer program product of claim 15, wherein the computer code means for determining timing information comprises disk controller scheduler configured to schedule tasks for execution on a disk controller.
Claim: 19. The computer program product of claim 15, wherein the computer code means for using the timing information and the total energy information includes computer code means for deriving maximum and minimum energy constraints for each of the objects.
Claim: 20. The computer program product of claim 19, further comprising computer code means for determining an energy consumption value midway between the corresponding maximum and minimum energy consumption constraints.
Current U.S. Class: 700130/000
Current International Class: 06
Accession Number: edspap.20060155415
Database: USPTO Patent Applications
Be the first to leave a comment!
You must be logged in first