Eden Avivi has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/33511 )

Change subject: mem: MasterID to UniqueID
......................................................................

mem: MasterID to UniqueID

Change-Id: I1282ede2f818c0b1d99c5ef90efd83f2f5dbd286
---
M src/mem/cache/prefetch/base.hh
M src/mem/cache/prefetch/queued.cc
M src/mem/cache/prefetch/queued.hh
M src/mem/cache/prefetch/stride.cc
M src/mem/cache/tags/base.cc
M src/mem/dram_ctrl.hh
M src/mem/external_master.hh
M src/mem/mem_master.hh
M src/mem/packet.hh
M src/mem/qos/mem_ctrl.cc
M src/mem/qos/mem_ctrl.hh
M src/mem/qos/policy.hh
M src/mem/qos/policy_fixed_prio.cc
M src/mem/qos/policy_fixed_prio.hh
M src/mem/qos/policy_pf.cc
M src/mem/qos/policy_pf.hh
M src/mem/qos/q_policy.cc
M src/mem/qos/q_policy.hh
M src/mem/request.hh
M src/mem/ruby/slicc_interface/AbstractController.hh
M src/mem/ruby/system/RubySystem.cc
M src/mem/ruby/system/RubySystem.hh
22 files changed, 75 insertions(+), 75 deletions(-)



diff --git a/src/mem/cache/prefetch/base.hh b/src/mem/cache/prefetch/base.hh
index 7009db7..d080591 100644
--- a/src/mem/cache/prefetch/base.hh
+++ b/src/mem/cache/prefetch/base.hh
@@ -94,7 +94,7 @@
         /** The program counter that generated this address. */
         Addr pc;
         /** The requestor ID that generated this address. */
-        MasterID masterId;
+        UniqueID masterId;
         /** Validity bit for the PC of this address. */
         bool validPC;
         /** Whether this address targets the secure memory space. */
@@ -152,7 +152,7 @@
          * Gets the requestor ID that generated this address
          * @return the requestor ID that generated this address
          */
-        MasterID getMasterId() const
+        UniqueID getMasterId() const
         {
             return masterId;
         }
@@ -281,7 +281,7 @@
     const bool onInst;

     /** Request id for prefetches */
-    const MasterID masterId;
+    const UniqueID masterId;

     const Addr pageBytes;

diff --git a/src/mem/cache/prefetch/queued.cc b/src/mem/cache/prefetch/queued.cc
index c2ae090..15ac013 100644
--- a/src/mem/cache/prefetch/queued.cc
+++ b/src/mem/cache/prefetch/queued.cc
@@ -51,7 +51,7 @@

 void
 Queued::DeferredPacket::createPkt(Addr paddr, unsigned blk_size,
- MasterID mid, bool tag_prefetch, + UniqueID mid, bool tag_prefetch,
                                             Tick t) {
     /* Create a prefetch memory request */
     RequestPtr req = std::make_shared<Request>(paddr, blk_size, 0, mid);
diff --git a/src/mem/cache/prefetch/queued.hh b/src/mem/cache/prefetch/queued.hh
index 5af9093..95974c1 100644
--- a/src/mem/cache/prefetch/queued.hh
+++ b/src/mem/cache/prefetch/queued.hh
@@ -106,7 +106,7 @@
          *        tagged
          * @param t time when the prefetch becomes ready
          */
-        void createPkt(Addr paddr, unsigned blk_size, MasterID mid,
+        void createPkt(Addr paddr, unsigned blk_size, UniqueID mid,
                        bool tag_prefetch, Tick t);

         /**
diff --git a/src/mem/cache/prefetch/stride.cc b/src/mem/cache/prefetch/stride.cc
index 36773c6..9f8ac8b 100644
--- a/src/mem/cache/prefetch/stride.cc
+++ b/src/mem/cache/prefetch/stride.cc
@@ -124,7 +124,7 @@
     Addr pf_addr = pfi.getAddr();
     Addr pc = pfi.getPC();
     bool is_secure = pfi.isSecure();
-    MasterID master_id = useMasterId ? pfi.getMasterId() : 0;
+    UniqueID master_id = useMasterId ? pfi.getMasterId() : 0;

     // Get corresponding pc table
     PCTable* pcTable = findTable(master_id);
diff --git a/src/mem/cache/tags/base.cc b/src/mem/cache/tags/base.cc
index faad7be..89742a3 100644
--- a/src/mem/cache/tags/base.cc
+++ b/src/mem/cache/tags/base.cc
@@ -105,7 +105,7 @@
     // to insert the new one

     // Deal with what we are bringing in
-    MasterID master_id = pkt->req->masterId();
+    UniqueID master_id = pkt->req->masterId();
     assert(master_id < system->maxMasters());
     stats.occupancies[master_id]++;

diff --git a/src/mem/dram_ctrl.hh b/src/mem/dram_ctrl.hh
index a8433c8..656849e 100644
--- a/src/mem/dram_ctrl.hh
+++ b/src/mem/dram_ctrl.hh
@@ -617,8 +617,8 @@
         /** This comes from the outside world */
         const PacketPtr pkt;

-        /** MasterID associated with the packet */
-        const MasterID _masterId;
+        /** UniqueID associated with the packet */
+        const UniqueID _masterId;

         const bool read;

@@ -674,10 +674,10 @@
         inline uint8_t qosValue() const { return _qosValue; }

         /**
-         * Get the packet MasterID
+         * Get the packet UniqueID
          * (interface compatibility with Packet)
          */
-        inline MasterID masterId() const { return _masterId; }
+        inline UniqueID masterId() const { return _masterId; }

         /**
          * Get the packet size
diff --git a/src/mem/external_master.hh b/src/mem/external_master.hh
index d7aec11..4551aae 100644
--- a/src/mem/external_master.hh
+++ b/src/mem/external_master.hh
@@ -128,7 +128,7 @@

     void init() override;

-    const MasterID masterId;
+    const UniqueID masterId;
 };


diff --git a/src/mem/mem_master.hh b/src/mem/mem_master.hh
index 468cd11..2393ce4 100644
--- a/src/mem/mem_master.hh
+++ b/src/mem/mem_master.hh
@@ -53,7 +53,7 @@
 {
     MasterInfo(const SimObject* _obj,
                std::string master_name,
-               MasterID master_id)
+               UniqueID master_id)
       : obj(_obj), masterName(master_name), masterId(master_id)
     {}

@@ -63,8 +63,8 @@
     /** Master Name */
     std::string masterName;

-    /** Master ID */
-    MasterID masterId;
+    /** Unique ID */
+    UniqueID masterId;
 };

 #endif // __MEM_MEM_MASTER_HH__
diff --git a/src/mem/packet.hh b/src/mem/packet.hh
index 4af0d0b..5cab456 100644
--- a/src/mem/packet.hh
+++ b/src/mem/packet.hh
@@ -706,7 +706,7 @@
     inline void qosValue(const uint8_t qos_value)
     { _qosValue = qos_value; }

-    inline MasterID masterId() const { return req->masterId(); }
+    inline UniqueID masterId() const { return req->masterId(); }

     // Network error conditions... encapsulate them as methods since
     // their encoding keeps changing (from result field to command
diff --git a/src/mem/qos/mem_ctrl.cc b/src/mem/qos/mem_ctrl.cc
index 50e6035..b5de6c5 100644
--- a/src/mem/qos/mem_ctrl.cc
+++ b/src/mem/qos/mem_ctrl.cc
@@ -83,7 +83,7 @@
 }

 void
-MemCtrl::logRequest(BusState dir, MasterID m_id, uint8_t qos,
+MemCtrl::logRequest(BusState dir, UniqueID m_id, uint8_t qos,
                     Addr addr, uint64_t entries)
 {
     // If needed, initialize all counters and statistics
@@ -140,7 +140,7 @@
 }

 void
-MemCtrl::logResponse(BusState dir, MasterID m_id, uint8_t qos,
+MemCtrl::logResponse(BusState dir, UniqueID m_id, uint8_t qos,
                      Addr addr, uint64_t entries, double delay)
 {
     panic_if(!hasMaster(m_id),
@@ -209,7 +209,7 @@
 }

 uint8_t
-MemCtrl::schedule(MasterID m_id, uint64_t data)
+MemCtrl::schedule(UniqueID m_id, uint64_t data)
 {
     if (policy) {
         return policy->schedule(m_id, data);
@@ -266,7 +266,7 @@
 }

 void
-MemCtrl::addMaster(MasterID m_id)
+MemCtrl::addMaster(UniqueID m_id)
 {
     if (!hasMaster(m_id)) {
         masters.emplace(m_id, _system->getMasterName(m_id));
diff --git a/src/mem/qos/mem_ctrl.hh b/src/mem/qos/mem_ctrl.hh
index 0e29fcc..cefb0cb 100644
--- a/src/mem/qos/mem_ctrl.hh
+++ b/src/mem/qos/mem_ctrl.hh
@@ -85,13 +85,13 @@
     const bool qosSyncroScheduler;

     /** Hash of master ID - master name */
-    std::unordered_map<MasterID, const std::string> masters;
+    std::unordered_map<UniqueID, const std::string> masters;

     /** Hash of masters - number of packets queued per priority */
-    std::unordered_map<MasterID, std::vector<uint64_t> > packetPriorities;
+    std::unordered_map<UniqueID, std::vector<uint64_t> > packetPriorities;

     /** Hash of masters - address of request - queue of times of request */
-    std::unordered_map<MasterID,
+    std::unordered_map<UniqueID,
std::unordered_map<uint64_t, std::deque<uint64_t>> > requestTimes;

     /**
@@ -157,7 +157,7 @@
      *
      * @param m_id the master ID
      */
-    void addMaster(const MasterID m_id);
+    void addMaster(const UniqueID m_id);

     /**
      * Called upon receiving a request or
@@ -169,7 +169,7 @@
      * @param addr packet address
      * @param entries number of entries to record
      */
-    void logRequest(BusState dir, MasterID m_id, uint8_t qos,
+    void logRequest(BusState dir, UniqueID m_id, uint8_t qos,
                     Addr addr, uint64_t entries);

     /**
@@ -183,7 +183,7 @@
      * @param entries number of entries to record
      * @param delay response delay
      */
-    void logResponse(BusState dir, MasterID m_id, uint8_t qos,
+    void logResponse(BusState dir, UniqueID m_id, uint8_t qos,
                      Addr addr, uint64_t entries, double delay);

     /**
@@ -200,7 +200,7 @@
                         uint64_t queue_entry_size, const PacketPtr pkt);

     using SimObject::schedule;
-    uint8_t schedule(MasterID m_id, uint64_t data);
+    uint8_t schedule(UniqueID m_id, uint64_t data);
     uint8_t schedule(const PacketPtr pkt);

     /**
@@ -234,7 +234,7 @@
     template<typename Queues>
     void escalate(std::initializer_list<Queues*> queues,
                   uint64_t queue_entry_size,
-                  MasterID m_id, uint8_t tgt_prio);
+                  UniqueID m_id, uint8_t tgt_prio);

     /**
      * Escalates/demotes priority of all packets
@@ -253,7 +253,7 @@
      */
     template<typename Queues>
     void escalateQueues(Queues& queues, uint64_t queue_entry_size,
- MasterID m_id, uint8_t curr_prio, uint8_t tgt_prio); + UniqueID m_id, uint8_t curr_prio, uint8_t tgt_prio);

   public:
     /**
@@ -294,7 +294,7 @@
      * @return true if the memory controller has received a packet
      *         from the master, false otherwise.
      */
-    bool hasMaster(MasterID m_id) const
+    bool hasMaster(UniqueID m_id) const
     {
         return masters.find(m_id) != masters.end();
     }
@@ -351,7 +351,7 @@
 template<typename Queues>
 void
 MemCtrl::escalateQueues(Queues& queues, uint64_t queue_entry_size,
-                        MasterID m_id, uint8_t curr_prio, uint8_t tgt_prio)
+                        UniqueID m_id, uint8_t curr_prio, uint8_t tgt_prio)
 {
     auto it = queues[curr_prio].begin();
     while (it != queues[curr_prio].end()) {
@@ -424,7 +424,7 @@
 void
 MemCtrl::escalate(std::initializer_list<Queues*> queues,
                   uint64_t queue_entry_size,
-                  MasterID m_id, uint8_t tgt_prio)
+                  UniqueID m_id, uint8_t tgt_prio)
 {
     // If needed, initialize all counters and statistics
     // for this master
diff --git a/src/mem/qos/policy.hh b/src/mem/qos/policy.hh
index 3ffe481..7c70eb6 100644
--- a/src/mem/qos/policy.hh
+++ b/src/mem/qos/policy.hh
@@ -74,18 +74,18 @@
     void setMemCtrl(MemCtrl* mem) { memCtrl = mem; };

     /**
-     * Builds a MasterID/value pair given a master input.
+     * Builds a UniqueID/value pair given a master input.
      * This will be lookuped in the system list of masters in order
-     * to retrieve the associated MasterID.
+     * to retrieve the associated UniqueID.
      * In case the master name/object cannot be resolved, the pairing
      * method will panic.
      *
      * @param master Master to lookup in the system
-     * @param value Value to be associated with the MasterID
-     * @return A MasterID/Value pair.
+     * @param value Value to be associated with the UniqueID
+     * @return A UniqueID/Value pair.
      */
     template <typename M, typename T>
-    std::pair<MasterID, T> pair(M master, T value);
+    std::pair<UniqueID, T> pair(M master, T value);

     /**
      * Schedules data - must be defined by derived class
@@ -94,7 +94,7 @@
      * @param data data to schedule
      * @return QoS priority value
      */
-    virtual uint8_t schedule(const MasterID mId, const uint64_t data) = 0;
+    virtual uint8_t schedule(const UniqueID mId, const uint64_t data) = 0;

     /**
      * Schedules a packet. Non virtual interface for the scheduling
@@ -111,7 +111,7 @@
 };

 template <typename M, typename T>
-std::pair<MasterID, T>
+std::pair<UniqueID, T>
 Policy::pair(M master, T value)
 {
     auto id = memCtrl->system()->lookupMasterId(master);
@@ -123,7 +123,7 @@
             "Master %s [id %d] associated with QoS data %d\n",
             master, id, value);

-    return std::pair<MasterID, T>(id, value);
+    return std::pair<UniqueID, T>(id, value);
 }

 } // namespace QoS
diff --git a/src/mem/qos/policy_fixed_prio.cc b/src/mem/qos/policy_fixed_prio.cc
index 449a25d..ce081f9 100644
--- a/src/mem/qos/policy_fixed_prio.cc
+++ b/src/mem/qos/policy_fixed_prio.cc
@@ -73,9 +73,9 @@
 }

 uint8_t
-FixedPriorityPolicy::schedule(const MasterID mId, const uint64_t data)
+FixedPriorityPolicy::schedule(const UniqueID mId, const uint64_t data)
 {
-    // Reads a packet's MasterID contained in its encapsulated request
+    // Reads a packet's UniqueID contained in its encapsulated request
     // if a match is found in the configured priority map, returns the
     // matching priority, else returns zero

@@ -84,7 +84,7 @@
     if (ret != priorityMap.end()) {
         return ret->second;
     } else {
-        DPRINTF(QOS, "Master %s (MasterID %d) not present in priorityMap, "
+        DPRINTF(QOS, "Master %s (UniqueID %d) not present in priorityMap, "
                      "assigning default priority %d\n",
                       memCtrl->system()->getMasterName(mId),
                       mId, defaultPriority);
diff --git a/src/mem/qos/policy_fixed_prio.hh b/src/mem/qos/policy_fixed_prio.hh
index 08f46a4..c11f015 100644
--- a/src/mem/qos/policy_fixed_prio.hh
+++ b/src/mem/qos/policy_fixed_prio.hh
@@ -48,7 +48,7 @@
 /**
  * Fixed Priority QoS Policy
  *
- * Fixed Priority Policy: based on a configured MasterID to priority map,
+ * Fixed Priority Policy: based on a configured UniqueID to priority map,
* it returns a fixed QoS priority value: every master has a fixed priority.
  */
 class FixedPriorityPolicy : public Policy
@@ -87,7 +87,7 @@
      * @param data data to schedule
      * @return QoS priority value
      */
-    virtual uint8_t schedule(const MasterID, const uint64_t) override;
+    virtual uint8_t schedule(const UniqueID, const uint64_t) override;

   protected:
     /** Default fixed priority value for non-listed masters */
@@ -97,7 +97,7 @@
      * Priority map, associates configured masters with
      * a fixed QoS priority value
      */
-    std::map<MasterID, uint8_t> priorityMap;
+    std::map<UniqueID, uint8_t> priorityMap;
 };

 } // namespace QoS
diff --git a/src/mem/qos/policy_pf.cc b/src/mem/qos/policy_pf.cc
index 58c4e38..157db77 100644
--- a/src/mem/qos/policy_pf.cc
+++ b/src/mem/qos/policy_pf.cc
@@ -57,7 +57,7 @@
 void
 PropFairPolicy::initMaster(const Master master, const double score)
 {
-    MasterID m_id = memCtrl->system()->lookupMasterId(master);
+    UniqueID m_id = memCtrl->system()->lookupMasterId(master);

     assert(m_id != Request::invldMasterId);

@@ -89,7 +89,7 @@
 }

 uint8_t
-PropFairPolicy::schedule(const MasterID pkt_mid, const uint64_t pkt_size)
+PropFairPolicy::schedule(const UniqueID pkt_mid, const uint64_t pkt_size)
 {
     auto sort_pred =
     [] (const MasterHistory& lhs, const MasterHistory& rhs)
@@ -105,7 +105,7 @@
     uint8_t pkt_priority = 0;
for (auto m_hist = history.begin(); m_hist != history.end(); m_hist++) {

-        MasterID curr_mid = m_hist->first;
+        UniqueID curr_mid = m_hist->first;
         double& curr_score = m_hist->second;

         if (curr_mid == pkt_mid) {
diff --git a/src/mem/qos/policy_pf.hh b/src/mem/qos/policy_pf.hh
index c741e9c..f0864a6 100644
--- a/src/mem/qos/policy_pf.hh
+++ b/src/mem/qos/policy_pf.hh
@@ -94,7 +94,7 @@
      * @return QoS priority value
      */
     virtual uint8_t
-    schedule(const MasterID m_id, const uint64_t pkt_size) override;
+    schedule(const UniqueID m_id, const uint64_t pkt_size) override;

   protected:
     template <typename Master>
@@ -108,7 +108,7 @@
     const double weight;

     /** history is keeping track of every master's score */
-    using MasterHistory = std::pair<MasterID, double>;
+    using MasterHistory = std::pair<UniqueID, double>;
     std::vector<MasterHistory> history;
 };

diff --git a/src/mem/qos/q_policy.cc b/src/mem/qos/q_policy.cc
index 88ce95d..6d03255 100644
--- a/src/mem/qos/q_policy.cc
+++ b/src/mem/qos/q_policy.cc
@@ -68,7 +68,7 @@
     QueuePolicy::PacketQueue::iterator ret = q->end();

     // Tracks one packet per master in the queue
-    std::unordered_map<MasterID, QueuePolicy::PacketQueue::iterator> track;
+    std::unordered_map<UniqueID, QueuePolicy::PacketQueue::iterator> track;

     // Cycle queue only once
     for (auto pkt_it = q->begin(); pkt_it != q->end(); ++pkt_it) {
@@ -78,8 +78,8 @@
         panic_if(!pkt->req,
                  "QoSQPolicy::lrg detected packet without request");

-        // Get Request MasterID
-        MasterID m_id = pkt->req->masterId();
+        // Get Request UniqueID
+        UniqueID m_id = pkt->req->masterId();
         DPRINTF(QOS, "QoSQPolicy::lrg checking packet "
                      "from queue with id %d\n", m_id);

@@ -93,7 +93,7 @@
         if (toServe.front() == m_id) {
             DPRINTF(QOS, "QoSQPolicy::lrg matched to served "
                          "master id %d\n", m_id);
-            // This packet matches the MasterID to be served next
+            // This packet matches the UniqueID to be served next
             // move toServe front to back
             toServe.push_back(m_id);
             toServe.pop_front();
@@ -138,7 +138,7 @@
 void
 LrgQueuePolicy::enqueuePacket(PacketPtr pkt)
 {
-    MasterID m_id = pkt->masterId();
+    UniqueID m_id = pkt->masterId();
     if (!memCtrl->hasMaster(m_id)) {
         toServe.push_back(m_id);
     }
diff --git a/src/mem/qos/q_policy.hh b/src/mem/qos/q_policy.hh
index ba36b43..a13ff17 100644
--- a/src/mem/qos/q_policy.hh
+++ b/src/mem/qos/q_policy.hh
@@ -182,7 +182,7 @@
      * keeps track of serviced masters,
      * always serve the front element.
      */
-    std::list<MasterID> toServe;
+    std::list<UniqueID> toServe;
 };

 } // namespace QoS
diff --git a/src/mem/request.hh b/src/mem/request.hh
index 7b324dc..506be1d 100644
--- a/src/mem/request.hh
+++ b/src/mem/request.hh
@@ -81,7 +81,7 @@
 class ThreadContext;

 typedef std::shared_ptr<Request> RequestPtr;
-typedef uint16_t MasterID;
+typedef uint16_t UniqueID;

 class Request
 {
@@ -196,9 +196,9 @@
     static const FlagsType STORE_NO_DATA = CACHE_BLOCK_ZERO |
         CLEAN | INVALIDATE;

-    /** Master Ids that are statically allocated
+    /** Unique Ids that are statically allocated
      * @{*/
-    enum : MasterID {
+    enum : UniqueID {
         /** This master id is used for writeback requests by the caches */
         wbMasterId = 0,
         /**
@@ -212,7 +212,7 @@
          * Invalid master id for assertion checking only. It is
          * invalid behavior to ever send this id as part of a request.
          */
-        invldMasterId = std::numeric_limits<MasterID>::max()
+        invldMasterId = std::numeric_limits<UniqueID>::max()
     };
     /** @} */

@@ -302,7 +302,7 @@
     /** The requestor ID which is unique in the system for all ports
      * that are capable of issuing a transaction
      */
-    MasterID _masterId = invldMasterId;
+    UniqueID _masterId = invldMasterId;

     /** Flag structure for the request. */
     Flags _flags;
@@ -376,7 +376,7 @@
      * just physical address, size, flags, and timestamp (to curTick()).
      * These fields are adequate to perform a request.
      */
-    Request(Addr paddr, unsigned size, Flags flags, MasterID mid) :
+    Request(Addr paddr, unsigned size, Flags flags, UniqueID mid) :
         _paddr(paddr), _size(size), _masterId(mid), _time(curTick())
     {
         _flags.set(flags);
@@ -384,7 +384,7 @@
     }

     Request(Addr vaddr, unsigned size, Flags flags,
-            MasterID mid, Addr pc, ContextID cid,
+            UniqueID mid, Addr pc, ContextID cid,
             AtomicOpFunctorPtr atomic_op=nullptr)
     {
         setVirt(vaddr, size, flags, mid, pc, std::move(atomic_op));
@@ -442,7 +442,7 @@
      * allocated Request object.
      */
     void
-    setVirt(Addr vaddr, unsigned size, Flags flags, MasterID mid, Addr pc,
+    setVirt(Addr vaddr, unsigned size, Flags flags, UniqueID mid, Addr pc,
             AtomicOpFunctorPtr amo_op=nullptr)
     {
         _vaddr = vaddr;
@@ -653,7 +653,7 @@
     }

     /** Accesssor for the requestor id. */
-    MasterID
+    UniqueID
     masterId() const
     {
         return _masterId;
diff --git a/src/mem/ruby/slicc_interface/AbstractController.hh b/src/mem/ruby/slicc_interface/AbstractController.hh
index daa52da..ebf1bf0 100644
--- a/src/mem/ruby/slicc_interface/AbstractController.hh
+++ b/src/mem/ruby/slicc_interface/AbstractController.hh
@@ -147,7 +147,7 @@

   public:
     MachineID getMachineID() const { return m_machineID; }
-    MasterID getMasterId() const { return m_masterId; }
+    UniqueID getMasterId() const { return m_masterId; }

     Stats::Histogram& getDelayHist() { return m_delayHistogram; }
     Stats::Histogram& getDelayVCHist(uint32_t index)
@@ -185,8 +185,8 @@
     MachineID m_machineID;
     const NodeID m_clusterID;

-    // MasterID used by some components of gem5.
-    const MasterID m_masterId;
+    // UniqueID used by some components of gem5.
+    const UniqueID m_masterId;

     Network *m_net_ptr;
     bool m_is_blocking;
diff --git a/src/mem/ruby/system/RubySystem.cc b/src/mem/ruby/system/RubySystem.cc
index c35ab02..c4543ae 100644
--- a/src/mem/ruby/system/RubySystem.cc
+++ b/src/mem/ruby/system/RubySystem.cc
@@ -130,16 +130,16 @@
 void
 RubySystem::registerMasterIDs()
 {
-    // Create the map for MasterID to network node. This is done in init()
-    // because all MasterIDs must be obtained in the constructor and
+    // Create the map for UniqueID to network node. This is done in init()
+    // because all UniqueIDs must be obtained in the constructor and
// AbstractControllers are registered in their constructor. This is done
     // in two steps: (1) Add all of the AbstractControllers. Since we don't
-    // have a mapping of MasterID to MachineID this is the easiest way to
+    // have a mapping of UniqueID to MachineID this is the easiest way to
     // filter out AbstractControllers from non-Ruby masters. (2) Go through
- // the system's list of MasterIDs and add missing MasterIDs to network 0 + // the system's list of UniqueIDs and add missing UniqueIDs to network 0
     // (the default).
     for (auto& cntrl : m_abs_cntrl_vec) {
-        MasterID mid = cntrl->getMasterId();
+        UniqueID mid = cntrl->getMasterId();
         MachineID mach_id = cntrl->getMachineID();

         // These are setup in Network constructor and should exist
diff --git a/src/mem/ruby/system/RubySystem.hh b/src/mem/ruby/system/RubySystem.hh
index d14b383..a0dceff 100644
--- a/src/mem/ruby/system/RubySystem.hh
+++ b/src/mem/ruby/system/RubySystem.hh
@@ -142,7 +142,7 @@
     Cycles m_start_cycle;

     std::unordered_map<MachineID, unsigned> machineToNetwork;
-    std::unordered_map<MasterID, unsigned> masterToNetwork;
+    std::unordered_map<UniqueID, unsigned> masterToNetwork;
std::unordered_map<unsigned, std::vector<AbstractController*>> netCntrls;

   public:

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/33511
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I1282ede2f818c0b1d99c5ef90efd83f2f5dbd286
Gerrit-Change-Number: 33511
Gerrit-PatchSet: 1
Gerrit-Owner: Eden Avivi <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to