summaryrefslogtreecommitdiff
path: root/src/mem
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2015-12-28 11:14:15 -0500
committerAndreas Hansson <andreas.hansson@arm.com>2015-12-28 11:14:15 -0500
commitfbf3987c7b60334bec7aaac848c0d778c0135213 (patch)
tree943106b2dfc574dc3d3e7e4c272cbaf86d79aabe /src/mem
parentb93a9d0d515472d7b616e4d535d242290deeb791 (diff)
downloadgem5-fbf3987c7b60334bec7aaac848c0d778c0135213.tar.xz
mem: Avoid unecessary checks when creating HardPFReq in cache
The checks made before sending out a HardPFReq were unecessarily complex, and checked for cases that never occur. This patch tidies it up.
Diffstat (limited to 'src/mem')
-rw-r--r--src/mem/cache/cache.cc19
1 files changed, 5 insertions, 14 deletions
diff --git a/src/mem/cache/cache.cc b/src/mem/cache/cache.cc
index fb37f524b..489f198c0 100644
--- a/src/mem/cache/cache.cc
+++ b/src/mem/cache/cache.cc
@@ -2352,22 +2352,13 @@ Cache::getTimingPacket()
DPRINTF(Cache, "Block present, prefetch squashed by cache. "
"Deallocating mshr target %#x.\n",
mshr->blkAddr);
-
// Deallocate the mshr target
- if (!tgt_pkt->isWriteback()) {
- if (mshr->queue->forceDeallocateTarget(mshr)) {
- // Clear block if this deallocation resulted freed an
- // mshr when all had previously been utilized
- clearBlocked((BlockedCause)(mshr->queue->index));
- }
- return NULL;
- } else {
- // If this is a Writeback, and the snoops indicate that the blk
- // is cached above, set the BLOCK_CACHED flag in the Writeback
- // packet, so that it does not reset the bits corresponding to
- // this block in the snoop filter below.
- tgt_pkt->setBlockCached();
+ if (mshr->queue->forceDeallocateTarget(mshr)) {
+ // Clear block if this deallocation resulted freed an
+ // mshr when all had previously been utilized
+ clearBlocked((BlockedCause)(mshr->queue->index));
}
+ return NULL;
}
}