sim: Add an option to forward work items to Python
[gem5.git] / src / sim / sim_events.hh
index 5be2609fd02449b5bdbd328dcc11abcbf22b5dde..9a79a2e9d9c00044e917a3314361b0a92a9c3328 100644 (file)
@@ -63,7 +63,7 @@ class GlobalSimLoopExitEvent : public GlobalEvent
     // non-scheduling version for createForUnserialize()
     GlobalSimLoopExitEvent();
     GlobalSimLoopExitEvent(Tick when, const std::string &_cause, int c,
-                           Tick repeat = 0, bool serialize = false);
+                           Tick repeat = 0);
 
     const std::string getCause() const { return cause; }
     const int getCode() const { return code; }
@@ -83,21 +83,18 @@ class LocalSimLoopExitEvent : public Event
 
   public:
     LocalSimLoopExitEvent();
-    LocalSimLoopExitEvent(const std::string &_cause, int c, Tick repeat = 0,
-                          bool serialize = false);
+    LocalSimLoopExitEvent(const std::string &_cause, int c, Tick repeat = 0);
 
     const std::string getCause() const { return cause; }
     const int getCode() const { return code; }
 
-    void process();     // process event
+    void process() override;     // process event
 
-    virtual const char *description() const;
+    const char *description() const override;
 
-    virtual void serialize(std::ostream &os);
-    virtual void unserialize(Checkpoint *cp, const std::string &section);
-    virtual void unserialize(Checkpoint *cp, const std::string &section,
-                             EventQueue *eventq);
-    static Serializable *createForUnserialize(Checkpoint *cp,
+    void serialize(CheckpointOut &cp) const override;
+    void unserialize(CheckpointIn &cp) override;
+    static Serializable *createForUnserialize(CheckpointIn &cp,
                                               const std::string &section);
 };
 
@@ -110,7 +107,7 @@ class CountedDrainEvent : public Event
   public:
     CountedDrainEvent();
 
-    void process();
+    void process() override;
 
     void setCount(int _count) { count = _count; }
 
@@ -131,9 +128,9 @@ class CountedExitEvent : public Event
   public:
     CountedExitEvent(const std::string &_cause, int &_downCounter);
 
-    void process();     // process event
+    void process() override;     // process event
 
-    virtual const char *description() const;
+    const char *description() const override;
 };