diff --git a/src/cpu/base.cc b/src/cpu/base.cc --- a/src/cpu/base.cc +++ b/src/cpu/base.cc @@ -392,9 +392,10 @@ { assert(!_switchedOut); _switchedOut = true; - if (profileEvent && profileEvent->scheduled()) + if (FullSystem) { + if (profileEvent && profileEvent->scheduled()) deschedule(profileEvent); - + } // Flush all TLBs in the CPU to avoid having stale translations if // it gets switched in later. flushTLBs();