cpu: o3: replace issueLatency with bool pipelined
[gem5.git] / src / cpu / pc_event.hh
index 8194723914ef2e1c6cd4a8533481b30c53b91601..11fce2ca04b49f638d7e86a45cc4fe1c6936edf4 100644 (file)
 #include <vector>
 
 #include "base/misc.hh"
+#include "base/types.hh"
 
-class ExecContext;
+class ThreadContext;
 class PCEventQueue;
+class System;
 
 class PCEvent
 {
@@ -58,7 +60,7 @@ class PCEvent
     Addr pc() const { return evpc; }
 
     bool remove();
-    virtual void process(ExecContext *xc) = 0;
+    virtual void process(ThreadContext *tc) = 0;
 };
 
 class PCEventQueue
@@ -90,7 +92,7 @@ class PCEventQueue
   protected:
     map_t pc_map;
 
-    bool doService(ExecContext *xc);
+    bool doService(ThreadContext *tc);
 
   public:
     PCEventQueue();
@@ -98,12 +100,12 @@ class PCEventQueue
 
     bool remove(PCEvent *event);
     bool schedule(PCEvent *event);
-    bool service(ExecContext *xc)
+    bool service(ThreadContext *tc)
     {
         if (pc_map.empty())
             return false;
 
-        return doService(xc);
+        return doService(tc);
     }
 
     range_t equal_range(Addr pc);
@@ -137,7 +139,18 @@ class BreakPCEvent : public PCEvent
   public:
     BreakPCEvent(PCEventQueue *q, const std::string &desc, Addr addr,
                  bool del = false);
-    virtual void process(ExecContext *xc);
+    virtual void process(ThreadContext *tc);
+};
+
+void sched_break_pc_sys(System *sys, Addr addr);
+
+void sched_break_pc(Addr addr);
+
+class PanicPCEvent : public PCEvent
+{
+  public:
+    PanicPCEvent(PCEventQueue *q, const std::string &desc, Addr pc);
+    virtual void process(ThreadContext *tc);
 };
 
 #endif // __PC_EVENT_HH__