summaryrefslogtreecommitdiff
path: root/src/mem/bus.hh
diff options
context:
space:
mode:
authorSteve Reinhardt <stever@eecs.umich.edu>2006-05-26 13:48:35 -0400
committerSteve Reinhardt <stever@eecs.umich.edu>2006-05-26 13:48:35 -0400
commitda6a7b1263cf624790f06a5f944366fb113dffc8 (patch)
tree16110f2f8efa8b98a42d3b85c43a3a7b8ae1f1ce /src/mem/bus.hh
parentcf826ae296a4277bdf2ce46e4484295efde5a3c2 (diff)
downloadgem5-da6a7b1263cf624790f06a5f944366fb113dffc8.tar.xz
Add names to memory Port objects for tracing.
--HG-- extra : convert_revision : ddf30084e343e8656e4812ab20356292b35507ee
Diffstat (limited to 'src/mem/bus.hh')
-rw-r--r--src/mem/bus.hh12
1 files changed, 3 insertions, 9 deletions
diff --git a/src/mem/bus.hh b/src/mem/bus.hh
index 38573e514..1d3a7e528 100644
--- a/src/mem/bus.hh
+++ b/src/mem/bus.hh
@@ -100,8 +100,8 @@ class Bus : public MemObject
public:
/** Constructor for the BusPort.*/
- BusPort(Bus *_bus, int _id)
- : bus(_bus), id(_id)
+ BusPort(const std::string &_name, Bus *_bus, int _id)
+ : Port(_name), bus(_bus), id(_id)
{ }
protected:
@@ -146,13 +146,7 @@ class Bus : public MemObject
public:
/** A function used to return the port associated with this bus object. */
- virtual Port *getPort(const std::string &if_name)
- {
- // if_name ignored? forced to be empty?
- int id = interfaces.size();
- interfaces.push_back(new BusPort(this, id));
- return interfaces.back();
- }
+ virtual Port *getPort(const std::string &if_name);
virtual void init();