diff options
author | Nathan Binkert <nate@binkert.org> | 2011-01-10 11:11:16 -0800 |
---|---|---|
committer | Nathan Binkert <nate@binkert.org> | 2011-01-10 11:11:16 -0800 |
commit | ff592e0ed1d03609a3e0d8dee9a4fc83a3d8e807 (patch) | |
tree | 79b3537e98fd900a4b570e64e3479c8d1bae0909 | |
parent | fcc621ac796f824f784ecae2e4335ab183313000 (diff) | |
download | gem5-ff592e0ed1d03609a3e0d8dee9a4fc83a3d8e807.tar.xz |
stats: fix the distribution stat
-rw-r--r-- | src/base/statistics.hh | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/base/statistics.hh b/src/base/statistics.hh index 9c10164a9..529871dc4 100644 --- a/src/base/statistics.hh +++ b/src/base/statistics.hh @@ -1361,9 +1361,8 @@ class DistStor if (val > max_val) max_val = val; - Counter sample = val * number; - sum += sample; - squares += sample * sample; + sum += val * number; + squares += val * val * number; samples += number; } |