summaryrefslogtreecommitdiff
path: root/src/sim/serialize.hh
diff options
context:
space:
mode:
authorAli Saidi <Ali.Saidi@ARM.com>2012-06-05 01:23:10 -0400
committerAli Saidi <Ali.Saidi@ARM.com>2012-06-05 01:23:10 -0400
commit70d7d6cc7f7c25d43f0dc56fe133073eb4a97298 (patch)
tree5736150e2002e2fecc733ad8cb69078e0659137b /src/sim/serialize.hh
parent2e988bbab0c1a3c90c69b03fc79a62d7c61a540a (diff)
downloadgem5-70d7d6cc7f7c25d43f0dc56fe133073eb4a97298.tar.xz
sim: Provide a framework for detecting out of data checkpoints and migrating them.
Diffstat (limited to 'src/sim/serialize.hh')
-rw-r--r--src/sim/serialize.hh9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/sim/serialize.hh b/src/sim/serialize.hh
index bc64e74f8..ae20b40c2 100644
--- a/src/sim/serialize.hh
+++ b/src/sim/serialize.hh
@@ -50,6 +50,15 @@ class Serializable;
class Checkpoint;
class SimObject;
+/** The current version of the checkpoint format.
+ * This should be incremented by 1 and only 1 for every new version, where a new
+ * version is defined as a checkpoint created before this version wont work on
+ * the current version until the checkpoint format is updated. Adding a new
+ * SimObject shouldn't cause the version number to increase, only changes to
+ * existing objects such as serializing/unserializing more stote, changing sizes
+ * of serialized arrays, etc. */
+static const uint64_t gem5CheckpointVersion = 0x0000000000000001;
+
template <class T>
void paramOut(std::ostream &os, const std::string &name, const T &param);