Hoa Nguyen has submitted this change. ( https://gem5-review.googlesource.com/c/public/gem5/+/37835 )

Change subject: mem-ruby: Fix cache hits being profiled as cache misses
......................................................................

mem-ruby: Fix cache hits being profiled as cache misses

There are some instances where a cache hit is profiled as a cache
miss. This commit addresses this error.

Change-Id: I7dafa806ef3f1e3717650dc25f8657a0ea741dd1
Signed-off-by: Hoa Nguyen <[email protected]>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/37835
Reviewed-by: Matt Sinclair <[email protected]>
Reviewed-by: Daniel Gerzhoy <[email protected]>
Reviewed-by: Jason Lowe-Power <[email protected]>
Maintainer: Matt Sinclair <[email protected]>
Tested-by: kokoro <[email protected]>
---
M src/mem/ruby/protocol/MI_example-cache.sm
M src/mem/ruby/protocol/MOESI_AMD_Base-CorePair.sm
M src/mem/ruby/protocol/MOESI_hammer-cache.sm
3 files changed, 7 insertions(+), 7 deletions(-)

Approvals:
  Jason Lowe-Power: Looks good to me, approved
  Matt Sinclair: Looks good to me, approved; Looks good to me, approved
  Daniel Gerzhoy: Looks good to me, but someone else must approve
  kokoro: Regressions pass



diff --git a/src/mem/ruby/protocol/MI_example-cache.sm b/src/mem/ruby/protocol/MI_example-cache.sm
index 8738f33..2c9bdb7 100644
--- a/src/mem/ruby/protocol/MI_example-cache.sm
+++ b/src/mem/ruby/protocol/MI_example-cache.sm
@@ -353,7 +353,7 @@
       ++cacheMemory.demand_misses;
   }

-  action(p_profileHit, "ph", desc="Profile cache miss") {
+  action(p_profileHit, "ph", desc="Profile cache hit") {
       ++cacheMemory.demand_hits;
   }

diff --git a/src/mem/ruby/protocol/MOESI_AMD_Base-CorePair.sm b/src/mem/ruby/protocol/MOESI_AMD_Base-CorePair.sm
index a9589d6..fb957f0 100644
--- a/src/mem/ruby/protocol/MOESI_AMD_Base-CorePair.sm
+++ b/src/mem/ruby/protocol/MOESI_AMD_Base-CorePair.sm
@@ -1283,19 +1283,19 @@
   }

   action(l10h_profileHit, "l10h", desc="l10h hit profile") {
-    ++L1D0cache.demand_misses;
+    ++L1D0cache.demand_hits;
   }

   action(l11h_profileHit, "l11h", desc="l11h hit profile") {
-    ++L1D1cache.demand_misses;
+    ++L1D1cache.demand_hits;
   }

   action(l1ih_profileHit, "l1lh", desc="l1ih hit profile") {
-    ++L1Icache.demand_misses;
+    ++L1Icache.demand_hits;
   }

   action(l2h_profileHit, "l2h", desc="l2h hit profile") {
-    ++L2cache.demand_misses;
+    ++L2cache.demand_hits;
   }

   action(yy_recycleProbeQueue, "yy", desc="recycle probe queue") {
diff --git a/src/mem/ruby/protocol/MOESI_hammer-cache.sm b/src/mem/ruby/protocol/MOESI_hammer-cache.sm
index 8541f35..5440eb8 100644
--- a/src/mem/ruby/protocol/MOESI_hammer-cache.sm
+++ b/src/mem/ruby/protocol/MOESI_hammer-cache.sm
@@ -1285,12 +1285,12 @@
       ++L2cache.demand_misses;
   }

-  action(uu_profileL2Hit, "\uh", desc="Profile the demand hits ") {
+  action(uu_profileL2Hit, "\uh", desc="Profile the demand hits") {
       ++L2cache.demand_hits;
   }

action(zz_stallAndWaitMandatoryQueue, "\z", desc="Send the head of the mandatory queue to the back of the queue.") {
-    stall_and_wait(mandatoryQueue_in, address);
+    stall_and_wait(mandatoryQueue_in, address);
   }

   action(z_stall, "z", desc="stall") {

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/37835
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I7dafa806ef3f1e3717650dc25f8657a0ea741dd1
Gerrit-Change-Number: 37835
Gerrit-PatchSet: 3
Gerrit-Owner: Hoa Nguyen <[email protected]>
Gerrit-Reviewer: Bobby R. Bruce <[email protected]>
Gerrit-Reviewer: Daniel Gerzhoy <[email protected]>
Gerrit-Reviewer: Hoa Nguyen <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: Matt Sinclair <[email protected]>
Gerrit-Reviewer: kokoro <[email protected]>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to