Properly chack the pkt pointer on upgrades to insure no segfaults when writebacks delete the packet.
--HG-- extra : convert_revision : 72b1c6296a16319f4d16c62bc7038365654dbc40
This commit is contained in:
parent
288b98eb69
commit
6e8bfa4e63
1 changed files with 2 additions and 1 deletions
3
src/mem/cache/cache_impl.hh
vendored
3
src/mem/cache/cache_impl.hh
vendored
|
@ -272,10 +272,11 @@ template<class TagStore, class Buffering, class Coherence>
|
|||
void
|
||||
Cache<TagStore,Buffering,Coherence>::sendResult(PacketPtr &pkt, MSHR* mshr, bool success)
|
||||
{
|
||||
if (success && !(pkt->flags & NACKED_LINE)) {
|
||||
if (success && !(pkt && (pkt->flags & NACKED_LINE))) {
|
||||
missQueue->markInService(mshr->pkt, mshr);
|
||||
//Temp Hack for UPGRADES
|
||||
if (mshr->pkt->cmd == Packet::UpgradeReq) {
|
||||
assert(pkt); //Upgrades need to be fixed
|
||||
pkt->flags &= ~CACHE_LINE_FILL;
|
||||
BlkType *blk = tags->findBlock(pkt);
|
||||
CacheBlk::State old_state = (blk) ? blk->status : 0;
|
||||
|
|
Loading…
Reference in a new issue