summaryrefslogtreecommitdiff
path: root/src/sim/eventq.cc
diff options
context:
space:
mode:
authorNathan Binkert <nate@binkert.org>2010-04-02 15:28:22 -0700
committerNathan Binkert <nate@binkert.org>2010-04-02 15:28:22 -0700
commitf32674d9bcfc801a5f9c24c8d96c6f417391325f (patch)
tree283194957483d53ba3ece6ce146c12ad5d407320 /src/sim/eventq.cc
parent2ee3edba8edda618b31fcb7a3cc84b76bae18bf7 (diff)
downloadgem5-f32674d9bcfc801a5f9c24c8d96c6f417391325f.tar.xz
eventq: Clean up some flags
- Make the initialized flag always available, not just in debug mode. - Make the Initialized flag actually use several bits so it is very unlikely that something that's uninitialized accidentally looks initialized. - Add an initialized() function that tells you if the current event is indeed initialized. - Clear the flags on delete so it can't be accidentally thought of as initialized. - Fix getFlags assert statement. "How did this ever work?"
Diffstat (limited to 'src/sim/eventq.cc')
-rw-r--r--src/sim/eventq.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/sim/eventq.cc b/src/sim/eventq.cc
index d1f84fcb2..430c6d8ab 100644
--- a/src/sim/eventq.cc
+++ b/src/sim/eventq.cc
@@ -60,6 +60,7 @@ Counter Event::instanceCounter = 0;
Event::~Event()
{
assert(!scheduled());
+ flags = 0;
}
const std::string