summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRon Dreslinski <rdreslin@umich.edu>2006-10-11 00:13:53 -0400
committerRon Dreslinski <rdreslin@umich.edu>2006-10-11 00:13:53 -0400
commit23bbd144261430c0071daaecfcda8524d302bea9 (patch)
treeefebd048647c8f928ad598c53799c8bebed9e391 /src
parentc9102b08fa25df7a1ef98d63f067bebd3978c19d (diff)
downloadgem5-23bbd144261430c0071daaecfcda8524d302bea9.tar.xz
Writebacks can be pulled out from under the BusRequest when snoops of uprgades to owned blocks hit in the WB buffer
--HG-- extra : convert_revision : f0502836a79ce303150daa7e571badb0bce3a97a
Diffstat (limited to 'src')
-rw-r--r--src/mem/cache/base_cache.cc18
1 files changed, 14 insertions, 4 deletions
diff --git a/src/mem/cache/base_cache.cc b/src/mem/cache/base_cache.cc
index c4d8dceef..8b724209e 100644
--- a/src/mem/cache/base_cache.cc
+++ b/src/mem/cache/base_cache.cc
@@ -135,7 +135,12 @@ BaseCache::CachePort::recvRetry()
else if (!isCpuSide)
{
DPRINTF(CachePort, "%s attempting to send a retry for MSHR\n", name());
- assert(cache->doMasterRequest());
+ if (cache->doMasterRequest()) {
+ //This can happen if I am the owner of a block and see an upgrade
+ //while the block was in my WB Buffers. I just remove the
+ //wb and de-assert the masterRequest
+ return;
+ }
pkt = cache->getPacket();
MSHR* mshr = (MSHR*)pkt->senderState;
bool success = sendTiming(pkt);
@@ -236,10 +241,15 @@ BaseCache::CacheEvent::process()
}
}
else if (!cachePort->isCpuSide)
- {
+ { //MSHR
DPRINTF(CachePort, "%s trying to send a MSHR request\n", cachePort->name());
- assert(cachePort->cache->doMasterRequest());
- //MSHR
+ if (cachePort->cache->doMasterRequest()) {
+ //This can happen if I am the owner of a block and see an upgrade
+ //while the block was in my WB Buffers. I just remove the
+ //wb and de-assert the masterRequest
+ return;
+ }
+
pkt = cachePort->cache->getPacket();
MSHR* mshr = (MSHR*) pkt->senderState;
bool success = cachePort->sendTiming(pkt);