A method and system for energy management in a simultaneous multi-threaded
(SMT) processing system including per-thread device usage monitoring
provides control of energy usage that accommodates thread parallelism.
Per-device usage information is measured and stored on a per-thread
basis, so that upon a context switch, the previous usage evaluation state
can be restored. The per-thread usage information is used to adjust the
thresholds of device energy management decision control logic, so that
energy use can be managed with consideration as to which threads will be
running in a given execution slice. A device controller can then provide
for per-thread control of attached device power management states without
intervention by the processor and without losing the historical
evaluation state when a process is switched out. The device controller
may be a memory controller and the controlled devices memory modules or
banks within modules if individual banks can be power-managed. Local
thresholds provide the decision-making mechanism for each controlled
device and are adjusted by the operating system in conformity with the
measured usage level for threads executing within the processing system.
The per-thread usage information may be obtained from a performance
monitoring unit that is located within or external to the device
controller and the usage monitoring state is then retrieved and replaced
by the operating system at each context switch.