summaryrefslogtreecommitdiff
path: root/src/mem/ruby/profiler/CacheProfiler.cc
diff options
context:
space:
mode:
authorNilay Vaish <nilay@cs.wisc.edu>2011-03-19 18:34:59 -0500
committerNilay Vaish <nilay@cs.wisc.edu>2011-03-19 18:34:59 -0500
commit611f052e963b06b4a7e02b2fc6d847cd6d08d038 (patch)
tree0a3bdb5787d5e6ae9b0e07145cf2d32b4a532d6b /src/mem/ruby/profiler/CacheProfiler.cc
parent2f4276448b82b2aa077ae257171b5cb04b7048f6 (diff)
downloadgem5-611f052e963b06b4a7e02b2fc6d847cd6d08d038.tar.xz
Ruby: Convert CacheRequestType to RubyRequestType
This patch converts CacheRequestType to RubyRequestType so that both the protocol dependent and independent code makes use of the same request type.
Diffstat (limited to 'src/mem/ruby/profiler/CacheProfiler.cc')
-rw-r--r--src/mem/ruby/profiler/CacheProfiler.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mem/ruby/profiler/CacheProfiler.cc b/src/mem/ruby/profiler/CacheProfiler.cc
index fcad227fb..fdb4581bb 100644
--- a/src/mem/ruby/profiler/CacheProfiler.cc
+++ b/src/mem/ruby/profiler/CacheProfiler.cc
@@ -33,7 +33,7 @@
using namespace std;
CacheProfiler::CacheProfiler(const string& description)
- : m_cacheRequestType(int(CacheRequestType_NUM)), m_genericRequestType(int(GenericRequestType_NUM))
+ : m_cacheRequestType(int(RubyRequestType_NUM)), m_genericRequestType(int(GenericRequestType_NUM))
{
m_description = description;
@@ -59,7 +59,7 @@ CacheProfiler::printStats(ostream& out) const
int requests = 0;
- for (int i = 0; i < int(CacheRequestType_NUM); i++) {
+ for (int i = 0; i < int(RubyRequestType_NUM); i++) {
requests += m_cacheRequestType[i];
}
@@ -70,10 +70,10 @@ CacheProfiler::printStats(ostream& out) const
assert(m_misses == requests);
if (requests > 0) {
- for (int i = 0; i < int(CacheRequestType_NUM); i++) {
+ for (int i = 0; i < int(RubyRequestType_NUM); i++) {
if (m_cacheRequestType[i] > 0) {
out << description << "_request_type_"
- << CacheRequestType_to_string(CacheRequestType(i))
+ << RubyRequestType_to_string(RubyRequestType(i))
<< ": "
<< 100.0 * (double)m_cacheRequestType[i] /
(double)requests
@@ -111,7 +111,7 @@ CacheProfiler::printStats(ostream& out) const
void
CacheProfiler::clearStats()
{
- for (int i = 0; i < int(CacheRequestType_NUM); i++) {
+ for (int i = 0; i < int(RubyRequestType_NUM); i++) {
m_cacheRequestType[i] = 0;
}
for (int i = 0; i < int(GenericRequestType_NUM); i++) {
@@ -128,7 +128,7 @@ CacheProfiler::clearStats()
}
void
-CacheProfiler::addCacheStatSample(CacheRequestType requestType,
+CacheProfiler::addCacheStatSample(RubyRequestType requestType,
RubyAccessMode accessType,
PrefetchBit pfBit)
{