Go to the documentation of this file.
59 for (uint32_t
i = 0;
i < bins;
i++) {
73 uint32_t t_bins =
m_data.size();
75 for (uint32_t
i = 0;
i < t_bins/2;
i++) {
78 for (uint32_t
i = t_bins/2;
i < t_bins;
i++) {
109 uint32_t t_bins =
m_data.size();
123 uint32_t t_bins =
m_data.size();
125 if (hist.
getBins() != t_bins) {
129 fatal(
"Histograms with different number of bins "
130 "cannot be combined!");
145 for (uint32_t
i = 1;
i < t_bins;
i++) {
160 for (uint32_t
i = 0;
i < t_bins;
i++) {
166 fatal(
"Don't know how to combine log and linear histograms!");
182 return sqrt(variance);
205 out <<
"[binsize: log2 ";
209 out <<
"max: " <<
m_max <<
" ";
210 out <<
"count: " <<
m_count <<
" ";
213 out <<
"average: NaN |";
214 out <<
"standard deviation: NaN |";
222 if (multiplier == 1.0) {
225 out <<
" " << double(
m_data[
i]) * multiplier;
#define fatal(...)
This implements a cprintf based fatal() function.
uint64_t getData(int index) const
uint64_t getSquaredTotal() const
void printPercent(std::ostream &out) const
std::vector< uint64_t > m_data
Histogram(int binsize=1, uint32_t bins=50)
uint64_t m_sumSquaredSamples
void print(std::ostream &out) const
std::enable_if_t< std::is_integral< T >::value, int > floorLog2(T x)
void printWithMultiplier(std::ostream &out, double multiplier) const
double getStandardDeviation() const
bool node_less_then_eq(const Histogram *n1, const Histogram *n2)
Generated on Tue Mar 23 2021 19:41:28 for gem5 by doxygen 1.8.17