ruby: improved stall and wait debugging

Added dprintfs and asserts for identifying stall and wait bugs.
This commit is contained in:
Brad Beckmann 2015-07-20 09:15:18 -05:00
parent 848861a17d
commit 6b52f828cc
2 changed files with 7 additions and 2 deletions

View file

@ -295,7 +295,7 @@ MessageBuffer::reanalyzeList(list<MsgPtr> &lt, Tick schdTick)
void
MessageBuffer::reanalyzeMessages(const Address& addr)
{
DPRINTF(RubyQueue, "ReanalyzeMessages\n");
DPRINTF(RubyQueue, "ReanalyzeMessages %s\n", addr);
assert(m_stall_msg_map.count(addr) > 0);
Tick curTick = m_receiver->clockEdge();

View file

@ -26,8 +26,10 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include "mem/protocol/MemoryMsg.hh"
#include "mem/ruby/slicc_interface/AbstractController.hh"
#include "debug/RubyQueue.hh"
#include "mem/protocol/MemoryMsg.hh"
#include "mem/ruby/system/Sequencer.hh"
#include "mem/ruby/system/System.hh"
#include "sim/system.hh"
@ -103,6 +105,9 @@ AbstractController::stallBuffer(MessageBuffer* buf, Address addr)
msgVec->resize(m_in_ports, NULL);
m_waiting_buffers[addr] = msgVec;
}
DPRINTF(RubyQueue, "stalling %s port %d addr %s\n", buf, m_cur_in_port,
addr);
assert(m_in_ports > m_cur_in_port);
(*(m_waiting_buffers[addr]))[m_cur_in_port] = buf;
}