virtual ThreadContext *getContext(int tn) { return threadContexts[tn]; }
/// Get the number of thread contexts available
- unsigned numContexts() { return threadContexts.size(); }
+ unsigned numContexts() {
+ return static_cast<unsigned>(threadContexts.size());
+ }
/// Convert ContextID to threadID
ThreadID contextToThread(ContextID cid)
* uniform data format for all CPU models and promotes better code
* reuse.
*
- * @param os The stream to serialize to.
+ * @param cp The stream to serialize to.
*/
void serialize(CheckpointOut &cp) const override;
* promotes better code reuse.
* @param cp The checkpoint use.
- * @param section The section name of this object.
*/
void unserialize(CheckpointIn &cp) override;
/**
* Serialize a single thread.
*
- * @param os The stream to serialize to.
+ * @param cp The stream to serialize to.
* @param tid ID of the current thread.
*/
virtual void serializeThread(CheckpointOut &cp, ThreadID tid) const {};
* Unserialize one thread.
*
* @param cp The checkpoint use.
- * @param section The section name of this thread.
* @param tid ID of the current thread.
*/
virtual void unserializeThread(CheckpointIn &cp, ThreadID tid) {};
* threadEntries to get the instructions in the ROB unless you are
* double checking that variable.
*/
- int countInsts(ThreadID tid);
+ size_t countInsts(ThreadID tid);
/** Registers statistics. */
void regStats();
ROB<Impl>::resetEntries()
{
if (robPolicy != SMTQueuePolicy::Dynamic || numThreads > 1) {
- int active_threads = activeThreads->size();
+ auto active_threads = activeThreads->size();
list<ThreadID>::iterator threads = activeThreads->begin();
list<ThreadID>::iterator end = activeThreads->end();
}
template <class Impl>
-int
+size_t
ROB<Impl>::countInsts(ThreadID tid)
{
return instList[tid].size();