sim: have a curTick per eventq
This patch adds a _curTick variable to an eventq. This variable is updated whenever an event is serviced in function serviceOne(), or all events upto a particular time are processed in function serviceEvents(). This change helps when there are eventqs that do not make use of curTick for scheduling events.
This commit is contained in:
@@ -39,12 +39,10 @@
|
||||
#include <string>
|
||||
|
||||
#include "base/types.hh"
|
||||
#include "sim/eventq.hh"
|
||||
|
||||
/// The universal simulation clock.
|
||||
extern Tick _curTick;
|
||||
|
||||
inline Tick curTick() { return _curTick; }
|
||||
inline void curTick(Tick newVal) { _curTick = newVal; }
|
||||
inline Tick curTick() { return mainEventQueue.getCurTick(); }
|
||||
|
||||
const Tick retryTime = 1000;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user