Mem: Put prefetcher notify call before packet is deleted.

This commit is contained in:
Ali Saidi 2011-08-19 15:08:08 -05:00
parent 2fd2b44b86
commit c9c2d979b8

View file

@ -514,18 +514,18 @@ Cache<TagStore>::timingAccess(PacketPtr pkt)
bool needsResponse = pkt->needsResponse();
if (satisfied) {
if (prefetcher && (prefetchOnAccess || (blk && blk->wasPrefetched()))) {
if (blk)
blk->status &= ~BlkHWPrefetched;
next_pf_time = prefetcher->notify(pkt, time);
}
if (needsResponse) {
pkt->makeTimingResponse();
cpuSidePort->respond(pkt, curTick()+lat);
} else {
delete pkt;
}
if (prefetcher && (prefetchOnAccess || (blk && blk->wasPrefetched()))) {
if (blk)
blk->status &= ~BlkHWPrefetched;
next_pf_time = prefetcher->notify(pkt, time);
}
} else {
// miss