diff options
Diffstat (limited to 'src/mem/cache/cache.cc')
-rw-r--r-- | src/mem/cache/cache.cc | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/mem/cache/cache.cc b/src/mem/cache/cache.cc index 3bb2667af..624f244ce 100644 --- a/src/mem/cache/cache.cc +++ b/src/mem/cache/cache.cc @@ -658,6 +658,21 @@ Cache::recvAtomic(PacketPtr pkt) { promoteWholeLineWrites(pkt); + // follow the same flow as in recvTimingReq, and check if a cache + // above us is responding + if (pkt->cacheResponding()) { + assert(!pkt->req->isCacheInvalidate()); + DPRINTF(Cache, "Cache above responding to %s: not responding\n", + pkt->print()); + + // if a cache is responding, and it had the line in Owned + // rather than Modified state, we need to invalidate any + // copies that are not on the same path to memory + assert(pkt->needsWritable() && !pkt->responderHadWritable()); + + return memSidePort.sendAtomic(pkt); + } + return BaseCache::recvAtomic(pkt); } |