summaryrefslogtreecommitdiff
path: root/src/mem/cache/mshr.cc
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2015-02-03 14:25:59 -0500
committerAndreas Hansson <andreas.hansson@arm.com>2015-02-03 14:25:59 -0500
commit193325ff60d11012f4fefb26c2b574b227ad5f1d (patch)
treeb1f4114989279a595f27329c6424ae300b05c82e /src/mem/cache/mshr.cc
parentf0a764edc6dd9c844a1514a005f0695a9149b58a (diff)
downloadgem5-193325ff60d11012f4fefb26c2b574b227ad5f1d.tar.xz
mem: Clarify cache behaviour for pending dirty responses
This patch adds a bit of clarification around the assumptions made in the cache when packets are sent out, and dirty responses are pending. As part of the change, the marking of an MSHR as in service is simplified slightly, and comments are added to explain what assumptions are made.
Diffstat (limited to 'src/mem/cache/mshr.cc')
-rw-r--r--src/mem/cache/mshr.cc6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/mem/cache/mshr.cc b/src/mem/cache/mshr.cc
index 793db02c2..50196edd1 100644
--- a/src/mem/cache/mshr.cc
+++ b/src/mem/cache/mshr.cc
@@ -238,7 +238,7 @@ MSHR::clearDownstreamPending()
}
bool
-MSHR::markInService(PacketPtr pkt)
+MSHR::markInService(bool pending_dirty_resp)
{
assert(!inService);
if (isForwardNoResponse()) {
@@ -249,10 +249,8 @@ MSHR::markInService(PacketPtr pkt)
return true;
}
- assert(pkt != NULL);
inService = true;
- pendingDirty = targets.needsExclusive ||
- (!pkt->sharedAsserted() && pkt->memInhibitAsserted());
+ pendingDirty = targets.needsExclusive || pending_dirty_resp;
postInvalidate = postDowngrade = false;
if (!downstreamPending) {