15 #include "cacheStats.h" 30 _total_cache_size = 0;
62 write(ostream &out,
const char *name)
const {
64 out << name <<
" cache: " << _cache_hits <<
" hits, " 65 << _cache_misses <<
" misses\n" 66 << _cache_adds + _cache_new_adds <<
"(" << _cache_new_adds <<
") adds(new), " 67 << _cache_dels <<
" dels, " 68 << _total_cache_size <<
" / " << _num_states <<
" = " 69 << (double)_total_cache_size / (
double)_num_states
70 <<
" average cache size\n";
This is a convenience class to specialize ConfigVariable as a boolean type.
void reset(double now)
Reinitializes just those parts of the CacheStats that should be reset between each reporting interval...
This is a convenience class to specialize ConfigVariable as a floating-point type.
void init()
Initializes the CacheStats for the first time.