diff options
author | Andreas Hansson <andreas.hansson@arm.com> | 2015-03-02 04:00:35 -0500 |
---|---|---|
committer | Andreas Hansson <andreas.hansson@arm.com> | 2015-03-02 04:00:35 -0500 |
commit | f26a28929583f2ed7fb55521e49c3f9bef557c05 (patch) | |
tree | e5d71fc69566b02a394015776b0f3f4e3be81427 /src/mem/port.cc | |
parent | 6ebe8d863ae0c5a7799e9421da32593ac35e1cc7 (diff) | |
download | gem5-f26a28929583f2ed7fb55521e49c3f9bef557c05.tar.xz |
mem: Split port retry for all different packet classes
This patch fixes a long-standing isue with the port flow
control. Before this patch the retry mechanism was shared between all
different packet classes. As a result, a snoop response could get
stuck behind a request waiting for a retry, even if the send/recv
functions were split. This caused message-dependent deadlocks in
stress-test scenarios.
The patch splits the retry into one per packet (message) class. Thus,
sendTimingReq has a corresponding recvReqRetry, sendTimingResp has
recvRespRetry etc. Most of the changes to the code involve simply
clarifying what type of request a specific object was accepting.
The biggest change in functionality is in the cache downstream packet
queue, facing the memory. This queue was shared by requests and snoop
responses, and it is now split into two queues, each with their own
flow control, but the same physical MasterPort. These changes fixes
the previously seen deadlocks.
Diffstat (limited to 'src/mem/port.cc')
-rw-r--r-- | src/mem/port.cc | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/mem/port.cc b/src/mem/port.cc index 898f19c08..03b68814f 100644 --- a/src/mem/port.cc +++ b/src/mem/port.cc @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012 ARM Limited + * Copyright (c) 2012,2015 ARM Limited * All rights reserved * * The license below extends only to copyright in the software and shall @@ -190,9 +190,9 @@ MasterPort::sendTimingSnoopResp(PacketPtr pkt) } void -MasterPort::sendRetry() +MasterPort::sendRetryResp() { - _slavePort->recvRetry(); + _slavePort->recvRespRetry(); } void @@ -261,7 +261,13 @@ SlavePort::sendTimingSnoopReq(PacketPtr pkt) } void -SlavePort::sendRetry() +SlavePort::sendRetryReq() { - _masterPort->recvRetry(); + _masterPort->recvReqRetry(); +} + +void +SlavePort::sendRetrySnoopResp() +{ + _masterPort->recvRetrySnoopResp(); } |