base: Fix uninitialized variable in Flag
[gem5.git] / util / stats / dbinit.py
index ffae88cdbad849ad923548a0c36dab788e9e3503..203582478195e2df3113d497f5f1e501f6432c25 100644 (file)
@@ -97,28 +97,6 @@ class MyDB(object):
             UNIQUE (rn_name,rn_sample)
         ) TYPE=InnoDB''')
 
-        #
-        # We keep the bin names separate so that the data table doesn't get
-        # huge since bin names are frequently repeated.
-        #
-        # COLUMNS:
-        #   'id' is the unique bin identifer.
-        #   'name' is the string name for the bin.
-        #
-        # INDEXES:
-        #   'bin' is indexed to get the name of a bin when data is retrieved
-        #       via the data table.
-        #   'name' is indexed to get the bin id for a named bin when you want
-        #       to search the data table based on a specific bin.
-        #
-        self.query('''
-        CREATE TABLE bins(
-            bn_id      SMALLINT UNSIGNED       NOT NULL AUTO_INCREMENT,
-            bn_name    VARCHAR(255)            NOT NULL,
-            PRIMARY KEY(bn_id),
-            UNIQUE (bn_name)
-        ) TYPE=InnoDB''')
-
         #
         # The stat table gives us all of the data for a particular stat.
         #
@@ -220,14 +198,12 @@ class MyDB(object):
         #   'run' is the run that the data was generated from.  Details up in
         #       the run table
         #   'tick' is a timestamp generated by the simulator.
-        #   'bin' is the name of the bin that the data was generated in, if
-        #       any.
         #   'data' is the actual stat value.
         #
         # INDEXES:
         #   'stat' is indexed so that a user can find all of the data for a
         #       particular stat. It is not unique, because that specific stat
-        #       can be found in many runs, bins, and samples, in addition to
+        #       can be found in many runs and samples, in addition to
         #       having entries for the mulidimensional cases.
         #   'run' is indexed to allow a user to remove all of the data for a
         #       particular execution run.  It can also be used to allow the
@@ -240,11 +216,10 @@ class MyDB(object):
             dt_y       SMALLINT                NOT NULL,
             dt_run     SMALLINT UNSIGNED       NOT NULL,
             dt_tick    BIGINT UNSIGNED         NOT NULL,
-            dt_bin     SMALLINT UNSIGNED       NOT NULL,
             dt_data    DOUBLE                  NOT NULL,
             INDEX (dt_stat),
             INDEX (dt_run),
-            UNIQUE (dt_stat,dt_x,dt_y,dt_run,dt_tick,dt_bin)
+            UNIQUE (dt_stat,dt_x,dt_y,dt_run,dt_tick)
         ) TYPE=InnoDB;''')
 
         #
@@ -395,12 +370,6 @@ class MyDB(object):
         LEFT JOIN data ON sd_stat=dt_stat
         WHERE dt_stat IS NULL''')
 
-        self.query('''
-        DELETE bins
-        FROM bins
-        LEFT JOIN data ON bn_id=dt_bin
-        WHERE dt_bin IS NULL''')
-
         self.query('''
         DELETE events
         FROM events