cpu-simple: Fix BaseSimpleCPU to reset group stats
authorseanzw <seanyukigeek@gmail.com>
Mon, 10 Aug 2020 18:49:33 +0000 (11:49 -0700)
committerZHENGRONG WANG <seanzw@g.ucla.edu>
Wed, 12 Aug 2020 02:17:58 +0000 (02:17 +0000)
BaseSimpleCPU::resetStats() should call Stats::Group::resetStats()
to reset new style hierarchy stats.

Change-Id: I932280449b29577d214db56ac8347aca4143c949
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/32434
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/cpu/simple/base.cc

index c9db86c3adebfc99debb1e7565bf2d059b12a01d..23b99715bd5e5936d8e6673d0f34136c8e63cd93 100644 (file)
@@ -396,6 +396,7 @@ BaseSimpleCPU::regStats()
 void
 BaseSimpleCPU::resetStats()
 {
+    BaseCPU::resetStats();
     for (auto &thread_info : threadInfo) {
         thread_info->notIdleFraction = (_status != Idle);
     }