Lines Matching full:stats
1 //===-- Statistic.cpp - Easy way to expose stats information --------------===//
12 // printed at the end of a run, when the -stats command line option is enabled
37 /// -stats - Command line option to cause transformations to emit stats about
42 "stats",
51 std::vector<const Statistic*> Stats; member in __anon63f6d1d60111::StatisticInfo
58 Stats.push_back(S); in addStatistic()
69 // If stats are enabled, inform StatInfo that this statistic should be in RegisterStatistic()
99 StatisticInfo &Stats = *StatInfo; in PrintStatistics() local
103 for (size_t i = 0, e = Stats.Stats.size(); i != e; ++i) { in PrintStatistics()
105 (unsigned)utostr(Stats.Stats[i]->getValue()).size()); in PrintStatistics()
107 (unsigned)std::strlen(Stats.Stats[i]->getName())); in PrintStatistics()
111 std::stable_sort(Stats.Stats.begin(), Stats.Stats.end(), in PrintStatistics()
126 for (size_t i = 0, e = Stats.Stats.size(); i != e; ++i) in PrintStatistics()
128 MaxValLen, Stats.Stats[i]->getValue(), in PrintStatistics()
129 MaxNameLen, Stats.Stats[i]->getName(), in PrintStatistics()
130 Stats.Stats[i]->getDesc()); in PrintStatistics()
139 StatisticInfo &Stats = *StatInfo; in PrintStatistics() local
142 if (Stats.Stats.empty()) return; in PrintStatistics()
149 // Check if the -stats option is set instead of checking in PrintStatistics()
150 // !Stats.Stats.empty(). In release builds, Statistics operators in PrintStatistics()
151 // do nothing, so stats are never Registered. in PrintStatistics()