From 340845b13989d4823a524521f0345ecb32f10894 Mon Sep 17 00:00:00 2001 From: Derek Hower Date: Sat, 18 Jul 2009 16:58:33 -0500 Subject: ruby: better debug print for DataBlock --- src/mem/ruby/common/DataBlock.hh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mem/ruby/common/DataBlock.hh') diff --git a/src/mem/ruby/common/DataBlock.hh b/src/mem/ruby/common/DataBlock.hh index 2a0811f76..ccd73c36b 100644 --- a/src/mem/ruby/common/DataBlock.hh +++ b/src/mem/ruby/common/DataBlock.hh @@ -108,8 +108,8 @@ void DataBlock::print(ostream& out) const { int size = RubySystem::getBlockSizeBytes(); out << "[ "; - for (int i = 0; i < size; i+=4) { - out << hex << *((uint32*)(&(m_data[i]))) << " "; + for (int i = 0; i < size; i++) { + out << setw(2) << setfill('0') << hex << "0x" << (int)m_data[i] << " "; } out << dec << "]" << flush; } -- cgit v1.2.3