From 7bd68dbc368e2d877f6159f5d0039198983e459a Mon Sep 17 00:00:00 2001 From: Jose Marinho Date: Thu, 19 Oct 2017 18:45:26 +0100 Subject: cpu: Make automatic transition to OFF optional Add the power_gating_on_idle option to control whether a core automatically enters the power gated state. The default behaviour is to transition to clock gated when idle, but not to power gated. When this option is set to true, the core automatically transitions to the power gated state after a configurable latency. Change-Id: Ida98c7fc532de4140d0e511c25613769b47b3702 Reviewed-on: https://gem5-review.googlesource.com/5741 Reviewed-by: Jason Lowe-Power Maintainer: Andreas Sandberg --- src/cpu/base.hh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/cpu/base.hh') diff --git a/src/cpu/base.hh b/src/cpu/base.hh index 7039fcfbc..13c56a945 100644 --- a/src/cpu/base.hh +++ b/src/cpu/base.hh @@ -588,10 +588,13 @@ class BaseCPU : public MemObject bool waitForRemoteGDB() const; Cycles syscallRetryLatency; + // Enables CPU to enter power gating on a configurable cycle count protected: - const Cycles pwrGatingLatency; void enterPwrGating(); + + const Cycles pwrGatingLatency; + const bool powerGatingOnIdle; EventFunctionWrapper enterPwrGatingEvent; }; -- cgit v1.2.3