58 :
ClockedObject(p), blkSize(p->block_size), blkMask(blkSize - 1),
60 lookupLatency(p->tag_latency),
61 accessLatency(p->sequential_access ?
62 p->tag_latency + p->data_latency :
63 std::max(p->tag_latency, p->data_latency)),
64 cache(nullptr), warmupBound(0),
65 warmedUp(false), numBlocks(0)
81 using namespace Stats;
86 .
desc(
"number of replacements")
92 .
desc(
"Cycle average of tags in use")
97 .
desc(
"Total number of references to valid blocks.")
102 .
desc(
"Sample count of references to valid blocks.")
107 .
desc(
"Average number of references to valid blocks.")
114 .
desc(
"Cycle when the warmup percentage was hit.")
120 .desc(
"Average occupied blocks per requestor")
129 .
desc(
"Average percentage of cache occupancy")
140 .
name(
name() +
".occ_task_id_blocks")
141 .
desc(
"Occupied blocks per task id")
147 .
name(
name() +
".age_task_id_blocks")
148 .
desc(
"Occupied blocks per task id")
153 .
name(
name() +
".occ_task_id_percent")
154 .
desc(
"Percentage of cache occupancy per task id")
162 .
desc(
"Number of tag accesses")
167 .
desc(
"Number of data accesses")
Declares a basic cache interface BaseCache.
Stats::Scalar sampledRefs
The number of reference counts sampled.
Derived & init(size_type _x, size_type _y)
Derived & subname(off_type index, const std::string &name)
Set the subfield name for the given index, and marks this stat to print at the end of simulation...
std::string getMasterName(MasterID master_id)
Get the name of an object for a given request id.
const FlagsType nonan
Don't print if this is NAN.
Stats::Average tagsInUse
Per cycle average of the number of tags that hold valid data.
Stats::Scalar totalRefs
The total number of references to a block before it is replaced.
System * system
System we are currently operating in.
Stats::Vector occupanciesTaskId
Occupancy of each context/cpu using the cache.
Stats::Vector replacements
Number of replacements of valid blocks per thread.
Derived & flags(Flags _flags)
Set the flags and marks this stat to print at the end of simulation.
Derived & init(size_type size)
Set this vector to have the given size.
Stats::Formula percentOccsTaskId
Occ % of each context/cpu using the cache.
The ClockedObject class extends the SimObject with a clock and accessor functions to relate ticks to ...
Stats::Scalar tagAccesses
Number of tags consulted over all accesses.
void registerExitCallback(Callback *callback)
Register an exit callback.
Stats::Scalar warmupCycle
The cycle that the warmup percentage was hit.
Stats::Formula avgOccs
Average occ % of each requestor using the cache.
Stats::Vector2d ageTaskId
Occupancy of each context/cpu using the cache.
Stats::Formula avgRefs
Average number of references to a block before is was replaced.
int maxThreadsPerCPU
The maximum number of active threads across all cpus.
const FlagsType total
Print the total.
void registerDumpCallback(Callback *cb)
Register a callback that should be called whenever statistics are about to be dumped.
MasterID maxMasters()
Get the number of masters registered in the system.
Stats::Scalar dataAccesses
Number of data blocks consulted over all accesses.
Derived & name(const std::string &name)
Set the name and marks this stat to print at the end of simulation.
virtual const std::string name() const
Derived & desc(const std::string &_desc)
Set the description and marks this stat to print at the end of simulation.
const FlagsType nozero
Don't print if this is zero.
Stats::AverageVector occupancies
Average occupancy of each requestor using the cache.
void regStats() override
Register statistics for this object.