diff options
author | Nilay Vaish <nilay@cs.wisc.edu> | 2011-03-18 14:12:03 -0500 |
---|---|---|
committer | Nilay Vaish <nilay@cs.wisc.edu> | 2011-03-18 14:12:03 -0500 |
commit | 3f27ccbb5488a6904f8bffc7e2ecc58c39a09119 (patch) | |
tree | f206d3d898a181d1ce94ec5e02e562fe4fea71ad /src/mem/slicc/symbols | |
parent | 847ba941ea345f01b2f5176432b6541902a41d2b (diff) | |
download | gem5-3f27ccbb5488a6904f8bffc7e2ecc58c39a09119.tar.xz |
SLICC: Remove the keyword wake_up_dependents
In order to add stall and wait facility for protocols, a keyword
wake_up_dependents was introduced. This patch removes the keyword,
instead this functionality is now implemented as function call.
Diffstat (limited to 'src/mem/slicc/symbols')
-rw-r--r-- | src/mem/slicc/symbols/StateMachine.py | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/src/mem/slicc/symbols/StateMachine.py b/src/mem/slicc/symbols/StateMachine.py index 301e34ea5..5be9b4ced 100644 --- a/src/mem/slicc/symbols/StateMachine.py +++ b/src/mem/slicc/symbols/StateMachine.py @@ -721,19 +721,21 @@ $c_ident::stallBuffer(MessageBuffer* buf, Address addr) void $c_ident::wakeUpBuffers(Address addr) { - // - // Wake up all possible lower rank (i.e. lower priority) buffers that could - // be waiting on this message. - // - for (int in_port_rank = m_cur_in_port_rank - 1; - in_port_rank >= 0; - in_port_rank--) { - if ((*(m_waiting_buffers[addr]))[in_port_rank] != NULL) { - (*(m_waiting_buffers[addr]))[in_port_rank]->reanalyzeMessages(addr); + if (m_waiting_buffers.count(addr) > 0) { + // + // Wake up all possible lower rank (i.e. lower priority) buffers that could + // be waiting on this message. + // + for (int in_port_rank = m_cur_in_port_rank - 1; + in_port_rank >= 0; + in_port_rank--) { + if ((*(m_waiting_buffers[addr]))[in_port_rank] != NULL) { + (*(m_waiting_buffers[addr]))[in_port_rank]->reanalyzeMessages(addr); + } } + delete m_waiting_buffers[addr]; + m_waiting_buffers.erase(addr); } - delete m_waiting_buffers[addr]; - m_waiting_buffers.erase(addr); } void |