Some changes to support blocking in the caches
src/mem/cache/base_cache.cc: src/mem/cache/base_cache.hh: src/mem/cache/cache_impl.hh: Outstanding blocking updates for cache --HG-- extra : convert_revision : 3a7b4aa4921de8239f604f1852f262a2305862c0
This commit is contained in:
parent
f7216daee0
commit
dc375e42bc
3 changed files with 13 additions and 1 deletions
10
src/mem/cache/base_cache.cc
vendored
10
src/mem/cache/base_cache.cc
vendored
|
@ -71,6 +71,11 @@ BaseCache::CachePort::deviceBlockSize()
|
|||
bool
|
||||
BaseCache::CachePort::recvTiming(Packet *pkt)
|
||||
{
|
||||
if (blocked)
|
||||
{
|
||||
mustSendRetry = true;
|
||||
return false;
|
||||
}
|
||||
return cache->doTimingAccess(pkt, this, isCpuSide);
|
||||
}
|
||||
|
||||
|
@ -95,6 +100,11 @@ BaseCache::CachePort::setBlocked()
|
|||
void
|
||||
BaseCache::CachePort::clearBlocked()
|
||||
{
|
||||
if (mustSendRetry)
|
||||
{
|
||||
mustSendRetry = false;
|
||||
sendRetry();
|
||||
}
|
||||
blocked = false;
|
||||
}
|
||||
|
||||
|
|
2
src/mem/cache/base_cache.hh
vendored
2
src/mem/cache/base_cache.hh
vendored
|
@ -105,6 +105,8 @@ class BaseCache : public MemObject
|
|||
|
||||
bool blocked;
|
||||
|
||||
bool mustSendRetry;
|
||||
|
||||
bool isCpuSide;
|
||||
};
|
||||
|
||||
|
|
2
src/mem/cache/cache_impl.hh
vendored
2
src/mem/cache/cache_impl.hh
vendored
|
@ -71,7 +71,7 @@ doTimingAccess(Packet *pkt, CachePort *cachePort, bool isCpuSide)
|
|||
else
|
||||
snoop(pkt);
|
||||
}
|
||||
return true; //Deal with blocking....
|
||||
return true;
|
||||
}
|
||||
|
||||
template<class TagStore, class Buffering, class Coherence>
|
||||
|
|
Loading…
Reference in a new issue