diff options
author | Andreas Hansson <andreas.hansson@arm.com> | 2012-01-17 12:55:09 -0600 |
---|---|---|
committer | Andreas Hansson <andreas.hansson@arm.com> | 2012-01-17 12:55:09 -0600 |
commit | de34e49d15b95cc8be51dbed2e98c469e7486959 (patch) | |
tree | fc3d2ab7d4c8c75fedbff44bb29d479c620eb620 /src/mem/bridge.cc | |
parent | b3f930c884ef23e4d784553fdccc91a772334fd7 (diff) | |
download | gem5-de34e49d15b95cc8be51dbed2e98c469e7486959.tar.xz |
MEM: Simplify ports by removing EventManager
This patch removes the inheritance of EventManager from the ports and
moves all responsibility for event queues to the owner. Eventually the
event manager should be the interface block, which could either be the
structural owner or a subblock like a LSQ in the O3 CPU for example.
Diffstat (limited to 'src/mem/bridge.cc')
-rw-r--r-- | src/mem/bridge.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mem/bridge.cc b/src/mem/bridge.cc index 9e5e64069..65ce3012e 100644 --- a/src/mem/bridge.cc +++ b/src/mem/bridge.cc @@ -165,7 +165,7 @@ Bridge::BridgePort::nackRequest(PacketPtr pkt) // nothing on the list, add it and we're done if (sendQueue.empty()) { assert(!sendEvent.scheduled()); - schedule(sendEvent, readyTime); + bridge->schedule(sendEvent, readyTime); sendQueue.push_back(buf); return; } @@ -187,7 +187,7 @@ Bridge::BridgePort::nackRequest(PacketPtr pkt) while (i != end && !done) { if (readyTime < (*i)->ready) { if (i == begin) - reschedule(sendEvent, readyTime); + bridge->reschedule(sendEvent, readyTime); sendQueue.insert(i,buf); done = true; } @@ -230,7 +230,7 @@ Bridge::BridgePort::queueForSendTiming(PacketPtr pkt) // should already be an event scheduled for sending the head // packet. if (sendQueue.empty()) { - schedule(sendEvent, readyTime); + bridge->schedule(sendEvent, readyTime); } sendQueue.push_back(buf); } @@ -284,7 +284,7 @@ Bridge::BridgePort::trySend() if (!sendQueue.empty()) { buf = sendQueue.front(); DPRINTF(BusBridge, "Scheduling next send\n"); - schedule(sendEvent, std::max(buf->ready, curTick() + 1)); + bridge->schedule(sendEvent, std::max(buf->ready, curTick() + 1)); } } else { DPRINTF(BusBridge, " unsuccessful\n"); @@ -305,7 +305,7 @@ Bridge::BridgePort::recvRetry() if (nextReady <= curTick()) trySend(); else - schedule(sendEvent, nextReady); + bridge->schedule(sendEvent, nextReady); } /** Function called by the port when the bus is receiving a Atomic |