31 #ifndef __BASE_STATS_INFO_HH__
32 #define __BASE_STATS_INFO_HH__
40 typedef ::Flags<FlagsType>
Flags;
107 virtual bool check()
const = 0;
123 virtual void reset() = 0;
129 virtual bool zero()
const = 0;
239 virtual std::string
str()
const = 0;
259 #endif // __BASE_STATS_INFO_HH__
double Result
All results are doubles.
const FlagsType pdf
Print the percent of the total that this entry represents.
std::map< Counter, int > MCounter
map of counters
std::string name
The name of the stat.
static int id_count
A unique stat ID for each stat in the simulator.
void enable()
Enable the stat for use.
VResult rvec
Local storage for the entry values, used for printing.
std::vector< std::string > subdescs
std::vector< std::string > subdescs
static std::string separatorString
The separator string used for vectors, dist, etc.
virtual bool zero() const =0
const FlagsType nonan
Don't print if this is NAN.
virtual size_type size() const =0
virtual void enable()
Enable the stat for use.
virtual Result total() const =0
std::vector< std::string > subnames
Names and descriptions of subfields.
std::vector< std::string > y_subnames
virtual Result result() const =0
void enable()
Enable the stat for use.
virtual void prepare()=0
Prepare the stat for dumping.
std::vector< std::string > subnames
Names and descriptions of subfields.
virtual void reset()=0
Reset the stat to the default state.
double Counter
All counters are of 64-bit values.
virtual Result total() const =0
Data structure of sparse histogram.
virtual const VResult & result() const =0
VCounter cvec
Local storage for the entry values, used for printing.
const Info * prereq
A pointer to a prerequisite Stat.
static bool less(Info *stat1, Info *stat2)
Checks if the first stat's name is alphabetically less than the second.
virtual Result total() const =0
Flags flags
The formatting flags.
const FlagsType oneline
Print all values on a single line.
virtual size_type size() const =0
void setName(const std::string &name)
Set the name of this statistic.
virtual Counter value() const =0
std::vector< DistData > data
const FlagsType display
Print this stat.
const FlagsType none
Nothing extra to print.
void enable()
Enable the stat for use.
int precision
The display precision.
std::vector< std::string > subdescs
const FlagsType total
Print the total.
const FlagsType __reserved
Mask of flags that can't be set directly.
void setSeparator(std::string _sep)
virtual const VCounter & value() const =0
virtual bool check() const =0
Check that this stat has been set up properly and is ready for use.
const StorageParams * storageParams
SparseHistData data
Local storage for the entry values, used for printing.
::Flags< FlagsType > Flags
const FlagsType nozero
Don't print if this is zero.
const FlagsType dist
Print the distribution.
const FlagsType cdf
Print the cumulative percentage of total upto this entry.
DistData data
Local storage for the entry values, used for printing.
const FlagsType init
This Stat is Initialized.
std::vector< std::string > subnames
Names and descriptions of subfields.
virtual void visit(Output &visitor)=0
Visitor entry for outputing statistics data.
std::string desc
The description of the stat.