diff options
author | Brad Danofsky <bradley.danofsky@amd.com> | 2011-04-20 11:14:52 -0700 |
---|---|---|
committer | Brad Danofsky <bradley.danofsky@amd.com> | 2011-04-20 11:14:52 -0700 |
commit | 46a538ceab12c89f1806293f6e5f4e89f6605da4 (patch) | |
tree | 5785b1f6dbac1aa3a06ff5569e8bc17cc9463d52 /src/base/statistics.hh | |
parent | dd38b4b83e6c8bf7a9031dfeead13a5ef354f46c (diff) | |
download | gem5-46a538ceab12c89f1806293f6e5f4e89f6605da4.tar.xz |
stats: add user settable separator string for arrayed stats
Default is '::', so no visible change unless it is overridden
Diffstat (limited to 'src/base/statistics.hh')
-rw-r--r-- | src/base/statistics.hh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/base/statistics.hh b/src/base/statistics.hh index de5540272..f139bce61 100644 --- a/src/base/statistics.hh +++ b/src/base/statistics.hh @@ -256,6 +256,23 @@ class DataWrap : public InfoAccess const std::string &name() const { return this->info()->name; } /** + * Set the character(s) used between the name and vector number + * on vectors, dist, etc. + * @param _sep The new separator string + * @return A reference to this stat. + */ + Derived & + setSeparator(const std::string &_sep) + { + this->info()->setSeparator(_sep); + return this->self(); + } + const std::string &setSeparator() const + { + return this->info()->separatorString; + } + + /** * Set the description and marks this stat to print at the end of * simulation. * @param desc The new description. |