summaryrefslogtreecommitdiff
path: root/src/mem/ruby/profiler/Profiler.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/mem/ruby/profiler/Profiler.hh')
-rw-r--r--src/mem/ruby/profiler/Profiler.hh19
1 files changed, 15 insertions, 4 deletions
diff --git a/src/mem/ruby/profiler/Profiler.hh b/src/mem/ruby/profiler/Profiler.hh
index 7945b6c73..58043dfaf 100644
--- a/src/mem/ruby/profiler/Profiler.hh
+++ b/src/mem/ruby/profiler/Profiler.hh
@@ -58,7 +58,6 @@
#include "mem/protocol/RubyAccessMode.hh"
#include "mem/protocol/RubyRequestType.hh"
#include "mem/ruby/common/Address.hh"
-#include "mem/ruby/common/Consumer.hh"
#include "mem/ruby/common/Global.hh"
#include "mem/ruby/common/Histogram.hh"
#include "mem/ruby/common/Set.hh"
@@ -70,7 +69,7 @@
class RubyRequest;
class AddressProfiler;
-class Profiler : public SimObject, public Consumer
+class Profiler : public SimObject
{
public:
typedef RubyProfilerParams Params;
@@ -244,6 +243,20 @@ class Profiler : public SimObject, public Consumer
bool m_all_instructions;
int m_num_of_sequencers;
+
+ protected:
+ class ProfileEvent : public Event
+ {
+ public:
+ ProfileEvent(Profiler *_profiler)
+ {
+ profiler = _profiler;
+ }
+ private:
+ void process() { profiler->wakeup(); }
+ Profiler *profiler;
+ };
+ ProfileEvent m_event;
};
inline std::ostream&
@@ -255,5 +268,3 @@ operator<<(std::ostream& out, const Profiler& obj)
}
#endif // __MEM_RUBY_PROFILER_PROFILER_HH__
-
-