diff options
author | Lisa Hsu <hsul@eecs.umich.edu> | 2006-10-23 18:46:05 -0400 |
---|---|---|
committer | Lisa Hsu <hsul@eecs.umich.edu> | 2006-10-23 18:46:05 -0400 |
commit | 764f27a0c9a6ba6008f60757769b52f5eee46ec1 (patch) | |
tree | 9e9309da58a0a403a673d353a354308b49a3a7ea /src/cpu/simple | |
parent | ef8b7713ca1b6120ae4e851877f2a9ce71296219 (diff) | |
parent | 4da3938ed99e3691cfb16c275eea659cbaaa6c30 (diff) | |
download | gem5-764f27a0c9a6ba6008f60757769b52f5eee46ec1.tar.xz |
Merge zizzer:/bk/newmem
into zed.eecs.umich.edu:/z/hsul/work/m5/newmem
--HG--
extra : convert_revision : bb58679e101570d50c040519fb08ffbabfee7416
Diffstat (limited to 'src/cpu/simple')
-rw-r--r-- | src/cpu/simple/atomic.cc | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/cpu/simple/atomic.cc b/src/cpu/simple/atomic.cc index 25c478ae9..edba55b0d 100644 --- a/src/cpu/simple/atomic.cc +++ b/src/cpu/simple/atomic.cc @@ -183,11 +183,14 @@ AtomicSimpleCPU::unserialize(Checkpoint *cp, const string §ion) void AtomicSimpleCPU::resume() { - changeState(SimObject::Running); - if (thread->status() == ThreadContext::Active) { + if (_status != SwitchedOut && _status != Idle) { assert(system->getMemoryMode() == System::Atomic); - if (!tickEvent.scheduled()) - tickEvent.schedule(curTick); + + changeState(SimObject::Running); + if (thread->status() == ThreadContext::Active) { + if (!tickEvent.scheduled()) + tickEvent.schedule(curTick); + } } } |