|
gem5 [DEVELOP-FOR-25.0]
|
These methods relate to the Fiber interface. More...
Functions | |
| virtual | gem5::Fiber::~Fiber () |
| void | gem5::Fiber::run () |
| Start executing the fiber represented by this object. | |
| bool | gem5::Fiber::finished () const |
| Returns whether the "main" function of this fiber has finished. | |
| bool | gem5::Fiber::started () const |
| Returns whether the "main" function of this fiber has started. | |
| static Fiber * | gem5::Fiber::currentFiber () |
| Get a pointer to the current running Fiber. | |
| static Fiber * | gem5::Fiber::primaryFiber () |
| Get a pointer to the primary Fiber. | |
Variables | |
| static const size_t | gem5::Fiber::DefaultStackSize = 0x50000 |
| gem5::Fiber::Fiber (size_t stack_size=DefaultStackSize) | |
| gem5::Fiber::Fiber (Fiber *link, size_t stack_size=DefaultStackSize) | |
These methods relate to the Fiber interface.
|
static |
Get a pointer to the current running Fiber.
Definition at line 185 of file fiber.cc.
References Fiber().
Referenced by gem5::Coroutine< PacketPtr, ItsAction >::call().
| gem5::Fiber::Fiber | ( | Fiber * | link, |
| size_t | stack_size = DefaultStackSize ) |
| gem5::Fiber::Fiber | ( | size_t | stack_size = DefaultStackSize | ) |
| Link | points to another fiber which will start executing when this fiber's main function returns. |
| stack_size | is the size of the stack available to this fiber. |
Definition at line 85 of file fiber.cc.
References Fiber(), and primaryFiber().
Referenced by sc_gem5::Thread::Context::Context(), gem5::Coroutine< PacketPtr, ItsAction >::Coroutine(), currentFiber(), Fiber(), Fiber(), LinkedFiber::LinkedFiber(), primaryFiber(), run(), sc_gem5::ScMainFiber::ScMainFiber(), and TEST().
|
inline |
Returns whether the "main" function of this fiber has finished.
Definition at line 109 of file fiber.hh.
References _finished.
Referenced by gem5::Coroutine< PacketPtr, ItsAction >::operator bool().
|
static |
Get a pointer to the primary Fiber.
This Fiber represents the thread of execution started by the OS, and which has a Fiber attached to it after the fact.
Definition at line 186 of file fiber.cc.
References Fiber().
Referenced by a(), c(), Fiber(), sc_gem5::Process::fiber(), sc_gem5::Scheduler::start(), TEST(), TEST(), and sc_gem5::Scheduler::yield().
| void gem5::Fiber::run | ( | ) |
Start executing the fiber represented by this object.
This function will "return" when the current fiber is switched back to later on.
Definition at line 166 of file fiber.cc.
References _finished, _started, createContext(), Fiber(), jmp, and panic_if.
Referenced by gem5::Coroutine< PacketPtr, ItsAction >::call(), sc_gem5::Scheduler::start(), TEST(), and sc_gem5::Scheduler::yield().
|
inline |
|
virtual |