thread = new SimpleThread(this, /* thread_num */ 0, process,
/* asid */ 0);
- thread->setStatus(ThreadContext::Suspended);
tc = thread->getTC();
threadContexts.push_back(tc);
#endif
thread = new SimpleThread(this, 0, systemPtr, itb, dtb, false);
- thread->setStatus(ThreadContext::Suspended);
tc = thread->getTC();
threadContexts.push_back(tc);
delete thread->kernelStats;
i, this->thread[i]);
this->thread[i] = new Thread(this, i, params->workload[i],
i);
-
- // Start thread's off in "Suspended" status
- this->thread[i]->setStatus(ThreadContext::Suspended);
-
} else {
//Allocate Empty thread so M5 can use later
//when scheduling threads to CPU
// SMT is not supported in FS mode yet.
assert(this->numThreads == 1);
this->thread[i] = new Thread(this, 0);
- this->thread[i]->setStatus(ThreadContext::Suspended);
#else
if (i < params->workload.size()) {
DPRINTF(O3CPU, "Workload[%i] process is %#x",
(typename Impl::O3CPU *)(this),
i, params->workload[i], i);
- this->thread[i]->setStatus(ThreadContext::Suspended);
-
//usedTids[i] = true;
//threadMap[i] = i;
} else {
#if FULL_SYSTEM
ThreadState::ThreadState(BaseCPU *cpu, int _tid)
- : baseCpu(cpu), _threadId(_tid), lastActivate(0), lastSuspend(0),
+#else
+ThreadState::ThreadState(BaseCPU *cpu, int _tid,
+ Process *_process, short _asid)
+#endif
+ : numInst(0), numLoad(0), _status(ThreadContext::Halted),
+ baseCpu(cpu), _threadId(_tid), lastActivate(0), lastSuspend(0),
+#if FULL_SYSTEM
profile(NULL), profileNode(NULL), profilePC(0), quiesceEvent(NULL),
kernelStats(NULL), physPort(NULL), virtPort(NULL),
- microPC(0), nextMicroPC(1), funcExeInst(0), storeCondFailures(0)
#else
-ThreadState::ThreadState(BaseCPU *cpu, int _tid, Process *_process,
- short _asid)
- : baseCpu(cpu), _threadId(_tid), lastActivate(0), lastSuspend(0),
port(NULL), process(_process), asid(_asid),
- microPC(0), nextMicroPC(1), funcExeInst(0), storeCondFailures(0)
#endif
+ microPC(0), nextMicroPC(1), funcExeInst(0), storeCondFailures(0)
{
- numInst = 0;
- numLoad = 0;
}
ThreadState::~ThreadState()
#if FULL_SYSTEM
ThreadState(BaseCPU *cpu, int _tid);
#else
- ThreadState(BaseCPU *cpu, int _tid, Process *_process,
- short _asid);
+ ThreadState(BaseCPU *cpu, int _tid, Process *_process, short _asid);
#endif
~ThreadState();