summaryrefslogtreecommitdiff
path: root/src/unittest
diff options
context:
space:
mode:
authorNathan Binkert <nate@binkert.org>2010-07-21 15:53:53 -0700
committerNathan Binkert <nate@binkert.org>2010-07-21 15:53:53 -0700
commit2a1309f2134986edcbff846aff5951ec1e8df6e1 (patch)
treec5168a212471551d5b08817bbafc2a24d8fa1666 /src/unittest
parent76c92c3e308c13b031dfa739d51f9f1f6917bd4b (diff)
downloadgem5-2a1309f2134986edcbff846aff5951ec1e8df6e1.tar.xz
stats: cleanup a few small problems in stats
Diffstat (limited to 'src/unittest')
-rw-r--r--src/unittest/stattest.cc14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/unittest/stattest.cc b/src/unittest/stattest.cc
index 9c10d078c..7c7b116a8 100644
--- a/src/unittest/stattest.cc
+++ b/src/unittest/stattest.cc
@@ -38,6 +38,7 @@
#include "base/stats/text.hh"
#include "base/stats/mysql.hh"
#include "base/types.hh"
+#include "sim/stat_control.hh"
using namespace std;
using namespace Stats;
@@ -67,7 +68,6 @@ int
main(int argc, char *argv[])
{
bool descriptions = false;
- bool compat = false;
bool text = false;
#if USE_MYSQL
@@ -82,9 +82,6 @@ main(int argc, char *argv[])
progname = argv[0];
while ((c = getopt(argc, argv, "cD:dh:P:p:s:tu:")) != -1) {
switch (c) {
- case 'c':
- compat = true;
- break;
case 'd':
descriptions = true;
break;
@@ -113,9 +110,11 @@ main(int argc, char *argv[])
}
}
- if (!text && (compat || descriptions))
+ if (!text && descriptions)
usage();
+ initSimStats();
+
Scalar s1;
Scalar s2;
Average s3;
@@ -304,7 +303,7 @@ main(int argc, char *argv[])
f4 += s5[3];
f5 = constant(1);
- check();
+ enable();
reset();
s16[1][0] = 1;
@@ -545,10 +544,11 @@ main(int argc, char *argv[])
s12.sample(100);
+ prepare();
+
if (text) {
Text out(cout);
out.descriptions = descriptions;
- out.compat = compat;
out();
}