diff options
author | Korey Sewell <ksewell@umich.edu> | 2011-02-18 14:31:31 -0500 |
---|---|---|
committer | Korey Sewell <ksewell@umich.edu> | 2011-02-18 14:31:31 -0500 |
commit | bc16bbc158613b7eaebe7d2021a6a0503c4a0635 (patch) | |
tree | 804f5d9bb3de96bf292876dfbd28c28fac572008 /src/cpu/inorder/resource.cc | |
parent | 64d31e75b960f08de57cf78f8bdc793d1135c5cd (diff) | |
download | gem5-bc16bbc158613b7eaebe7d2021a6a0503c4a0635.tar.xz |
inorder: add names and slot #s to res. dprints
Diffstat (limited to 'src/cpu/inorder/resource.cc')
-rw-r--r-- | src/cpu/inorder/resource.cc | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/cpu/inorder/resource.cc b/src/cpu/inorder/resource.cc index 701785658..24211532e 100644 --- a/src/cpu/inorder/resource.cc +++ b/src/cpu/inorder/resource.cc @@ -31,6 +31,8 @@ #include <vector> #include <list> + +#include "base/str.hh" #include "cpu/inorder/resource.hh" #include "cpu/inorder/cpu.hh" using namespace std; @@ -376,7 +378,7 @@ int ResourceRequest::maxReqCount = 0; ResourceRequest::ResourceRequest(Resource *_res) : res(_res), inst(NULL), stagePasses(0), valid(false), doneInResource(false), - complSlotNum(-1), completed(false), squashed(false), processing(false), + completed(false), squashed(false), processing(false), memStall(false) { } @@ -391,6 +393,12 @@ ResourceRequest::~ResourceRequest() inst = NULL; } +std::string +ResourceRequest::name() +{ + return res->name() + "." + to_string(slotNum); +} + void ResourceRequest::setRequest(DynInstPtr _inst, int stage_num, int res_idx, int slot_num, unsigned _cmd) @@ -433,11 +441,6 @@ ResourceRequest::done(bool completed) setCompleted(completed); - // Used for debugging purposes - if (completed) { - complSlotNum = slotNum; - } - doneInResource = true; } @@ -466,7 +469,8 @@ ResourceEvent::process() const char * ResourceEvent::description() { - string desc = resource->name() + " event"; + string desc = resource->name() + "-event:slot[" + to_string(slotIdx) + + "]"; return desc.c_str(); } |