1/*
2 * Copyright (c) 2001-2006 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

--- 145 unchanged lines hidden (view full) ---

154SimpleThread::dumpFuncProfile()
155{
156 std::ostream *os = simout.create(csprintf("profile.%s.dat",
157 baseCpu->name()));
158 profile->dump(tc, *os);
159}
160
161void
162SimpleThread::activate(Cycles delay)
162SimpleThread::activate()
163{
164 if (status() == ThreadContext::Active)
165 return;
166
167 lastActivate = curTick();
168
169// if (status() == ThreadContext::Unallocated) {
170// cpu->activateWhenReady(_threadId);
171// return;
172// }
173
168 _status = ThreadContext::Active;
175
176 // status() == Suspended
177 baseCpu->activateContext(_threadId, delay);
169 baseCpu->activateContext(_threadId);
170}
171
172void
173SimpleThread::suspend()
174{
175 if (status() == ThreadContext::Suspended)
176 return;
177

--- 46 unchanged lines hidden ---