From 9cdfcf93470ca11c12eeac50aea9536ef914790f Mon Sep 17 00:00:00 2001 From: Jason Lowe-Power Date: Tue, 20 Jun 2017 11:01:08 -0500 Subject: [PATCH] sim: Updated ClockedObject power state warning To prevent this warning from printing for *every* simulation, this patch adds a check to only print the warning if we are not at the beginning of simulation. Change-Id: I7f6154f0ca26bef6280f909f799aa1c7936b624a Signed-off-by: Jason Lowe-Power Reviewed-on: https://gem5-review.googlesource.com/3840 Reviewed-by: Andreas Sandberg Maintainer: Andreas Sandberg --- src/sim/clocked_object.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sim/clocked_object.cc b/src/sim/clocked_object.cc index f0b176509..ddf9e0f4d 100644 --- a/src/sim/clocked_object.cc +++ b/src/sim/clocked_object.cc @@ -90,7 +90,7 @@ ClockedObject::pwrState(Enums::PwrState p) // same tick if other conditions are not met elsewhere. // Any state change related stats would have been recorded on previous call // to the pwrState() function. - if (prvEvalTick == curTick()) { + if (prvEvalTick == curTick() && curTick() != 0) { warn("ClockedObject: More than one power state change request "\ "encountered within the same simulation tick"); _currPwrState = p; -- 2.30.2