diff options
author | Andreas Hansson <andreas.hansson@arm.com> | 2015-09-25 06:45:52 -0400 |
---|---|---|
committer | Andreas Hansson <andreas.hansson@arm.com> | 2015-09-25 06:45:52 -0400 |
commit | 3bd78a141ec60ae65d910286c3d99ae7030ba703 (patch) | |
tree | 32351d239e872bdc6c8f81ce200c05e41898b1bc | |
parent | 40fcb59c5440054f43675fd60ad8244c851f5050 (diff) | |
download | gem5-3bd78a141ec60ae65d910286c3d99ae7030ba703.tar.xz |
mem: Do not include snoop-filter latency in crossbar occupancy
This patch ensures that the snoop-filter latency only contributes to
the packet latency, and not to the crossbar throughput/occupancy. In
essence we treat the snoop-filter lookup as pipelined.
-rw-r--r-- | src/mem/coherent_xbar.cc | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/mem/coherent_xbar.cc b/src/mem/coherent_xbar.cc index 9e5407981..52f69e0c9 100644 --- a/src/mem/coherent_xbar.cc +++ b/src/mem/coherent_xbar.cc @@ -192,11 +192,10 @@ CoherentXBar::recvTimingReq(PacketPtr pkt, PortID slave_port_id) if (snoopFilter) { // check with the snoop filter where to forward this packet auto sf_res = snoopFilter->lookupRequest(pkt, *src_port); - // If SnoopFilter is enabled, the total time required by a packet - // to be delivered through the xbar has to be charged also with - // to lookup latency of the snoop filter (sf_res.second). + // the time required by a packet to be delivered through + // the xbar has to be charged also with to lookup latency + // of the snoop filter pkt->headerDelay += sf_res.second * clockPeriod(); - packetFinishTime += sf_res.second * clockPeriod(); DPRINTF(CoherentXBar, "recvTimingReq: src %s %s 0x%x"\ " SF size: %i lat: %i\n", src_port->name(), pkt->cmdString(), pkt->getAddr(), sf_res.first.size(), @@ -384,7 +383,10 @@ CoherentXBar::recvTimingSnoopReq(PacketPtr pkt, PortID master_port_id) if (snoopFilter) { // let the Snoop Filter work its magic and guide probing auto sf_res = snoopFilter->lookupSnoop(pkt); - // No timing here: packetFinishTime += sf_res.second * clockPeriod(); + // the time required by a packet to be delivered through + // the xbar has to be charged also with to lookup latency + // of the snoop filter + pkt->headerDelay += sf_res.second * clockPeriod(); DPRINTF(CoherentXBar, "recvTimingSnoopReq: src %s %s 0x%x"\ " SF size: %i lat: %i\n", masterPorts[master_port_id]->name(), pkt->cmdString(), pkt->getAddr(), sf_res.first.size(), |