summaryrefslogtreecommitdiff
path: root/src/mem/ruby/buffers/MessageBuffer.cc
diff options
context:
space:
mode:
authorNathan Binkert <nate@binkert.org>2010-04-02 11:20:32 -0700
committerNathan Binkert <nate@binkert.org>2010-04-02 11:20:32 -0700
commit141f61d83a23096dcff20df704bdd734c520f535 (patch)
treeee2383d721a039bb056bd6442a7241aa305d187e /src/mem/ruby/buffers/MessageBuffer.cc
parentf1c3f3044b73d890ffdfdd113b3b37ae2809d21b (diff)
downloadgem5-141f61d83a23096dcff20df704bdd734c520f535.tar.xz
ruby: get rid of gems_common/util.hh and .cc and use stuff in src/base
Diffstat (limited to 'src/mem/ruby/buffers/MessageBuffer.cc')
-rw-r--r--src/mem/ruby/buffers/MessageBuffer.cc17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/mem/ruby/buffers/MessageBuffer.cc b/src/mem/ruby/buffers/MessageBuffer.cc
index 086f92ab7..e64e47cad 100644
--- a/src/mem/ruby/buffers/MessageBuffer.cc
+++ b/src/mem/ruby/buffers/MessageBuffer.cc
@@ -26,6 +26,7 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
+#include "base/cprintf.hh"
#include "mem/ruby/buffers/MessageBuffer.hh"
#include "mem/ruby/system/System.hh"
@@ -123,8 +124,8 @@ MessageBuffer::peekAtHeadOfQueue() const
DEBUG_NEWLINE(QUEUE_COMP, MedPrio);
DEBUG_MSG(QUEUE_COMP, MedPrio,
- "Peeking at head of queue " + m_name + " time: "
- + int_to_string(g_eventQueue_ptr->getTime()) + ".");
+ csprintf("Peeking at head of queue %s time: %d.",
+ m_name, g_eventQueue_ptr->getTime()));
assert(isReady());
msg_ptr = m_prio_heap.peekMin().m_msgptr.ref();
@@ -151,8 +152,9 @@ void
MessageBuffer::enqueue(const MsgPtr& message, Time delta)
{
DEBUG_NEWLINE(QUEUE_COMP, HighPrio);
- DEBUG_MSG(QUEUE_COMP, HighPrio, "enqueue " + m_name + " time: "
- + int_to_string(g_eventQueue_ptr->getTime()) + ".");
+ DEBUG_MSG(QUEUE_COMP, HighPrio,
+ csprintf("enqueue %s time: %d.", m_name,
+ g_eventQueue_ptr->getTime()));
DEBUG_EXPR(QUEUE_COMP, MedPrio, message);
DEBUG_NEWLINE(QUEUE_COMP, HighPrio);
@@ -228,10 +230,9 @@ MessageBuffer::enqueue(const MsgPtr& message, Time delta)
m_prio_heap.insert(thisNode);
DEBUG_NEWLINE(QUEUE_COMP, HighPrio);
- DEBUG_MSG(QUEUE_COMP, HighPrio, "enqueue " + m_name
- + " with arrival_time " + int_to_string(arrival_time)
- + " cur_time: " + int_to_string(g_eventQueue_ptr->getTime())
- + ".");
+ DEBUG_MSG(QUEUE_COMP, HighPrio,
+ csprintf("enqueue %s with arrival_time %d cur_time: %d.",
+ m_name, arrival_time, g_eventQueue_ptr->getTime()));
DEBUG_EXPR(QUEUE_COMP, MedPrio, message);
DEBUG_NEWLINE(QUEUE_COMP, HighPrio);