summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel R. Carvalho <odanrc@yahoo.com.br>2018-12-05 15:29:58 +0100
committerDaniel Carvalho <odanrc@yahoo.com.br>2019-03-07 13:07:09 +0000
commita4686352714aa0d91b2d98b25a6f45b84262f97d (patch)
tree781fac0de8b1b05b0bef536aeb0fa15f246c6678 /src
parent6d8694a5fb5cfb905186249581cc6a3fde6cc38a (diff)
downloadgem5-a4686352714aa0d91b2d98b25a6f45b84262f97d.tar.xz
mem-cache: Add header delay to handleFill whenReady
A prefetch response will have a header delay, which was not being taken into account. Change-Id: I66a071bc81ef41b8c0de37aa2df75171d1979a6f Signed-off-by: Daniel R. Carvalho <odanrc@yahoo.com.br> Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/14895 Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com> Maintainer: Nikos Nikoleris <nikos.nikoleris@arm.com>
Diffstat (limited to 'src')
-rw-r--r--src/mem/cache/base.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mem/cache/base.cc b/src/mem/cache/base.cc
index 2f734ea16..a42f2ebda 100644
--- a/src/mem/cache/base.cc
+++ b/src/mem/cache/base.cc
@@ -1289,8 +1289,9 @@ BaseCache::handleFill(PacketPtr pkt, CacheBlk *blk, PacketList &writebacks,
pkt->writeDataToBlock(blk->data, blkSize);
}
- // We pay for fillLatency here.
- blk->setWhenReady(clockEdge(fillLatency) + pkt->payloadDelay);
+ // The block will be ready when the payload arrives and the fill is done
+ blk->setWhenReady(clockEdge(fillLatency) + pkt->headerDelay +
+ pkt->payloadDelay);
return blk;
}