From 41f6cbce9aa24f9cd8a6eb4a340dcc2e9671cdcb Mon Sep 17 00:00:00 2001 From: Steve Reinhardt Date: Mon, 28 May 2007 08:11:43 -0700 Subject: Restructure SimpleTimingPort a bit: - factor out checkFunctional() code so it can be called from derived classes - use EventWrapper for sendEvent, move event handling code from event to port where it belongs - make sendEvent a pointer so derived classes can override it - replace std::pair with new class for readability --HG-- extra : convert_revision : 5709de2daacfb751a440144ecaab5f9fc02e6b7a --- src/mem/physical.cc | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'src/mem/physical.cc') diff --git a/src/mem/physical.cc b/src/mem/physical.cc index 6621c36cf..9d840fe69 100644 --- a/src/mem/physical.cc +++ b/src/mem/physical.cc @@ -414,20 +414,7 @@ PhysicalMemory::MemoryPort::recvAtomic(PacketPtr pkt) void PhysicalMemory::MemoryPort::recvFunctional(PacketPtr pkt) { - //Since we are overriding the function, make sure to have the impl of the - //check or functional accesses here. - std::list >::iterator i = transmitList.begin(); - std::list >::iterator end = transmitList.end(); - bool notDone = true; - - while (i != end && notDone) { - PacketPtr target = i->second; - // If the target contains data, and it overlaps the - // probed request, need to update data - if (target->intersect(pkt)) - notDone = fixPacket(pkt, target); - i++; - } + checkFunctional(pkt); // Default implementation of SimpleTimingPort::recvFunctional() // calls recvAtomic() and throws away the latency; we can save a -- cgit v1.2.3