diff options
author | Steve Reinhardt <stever@eecs.umich.edu> | 2004-05-17 12:10:28 -0700 |
---|---|---|
committer | Steve Reinhardt <stever@eecs.umich.edu> | 2004-05-17 12:10:28 -0700 |
commit | 02af86f7e813db27b12214ea377948f07f891b69 (patch) | |
tree | 1a73c1cc7d4bbb6348a04300c8c97b5ab0c582d4 /sim/system.hh | |
parent | 9ca875f189dc1a507758a92697294a623a6ad935 (diff) | |
parent | b8082eb508f15f09eb7416a67b6d3a1886b4fa34 (diff) | |
download | gem5-02af86f7e813db27b12214ea377948f07f891b69.tar.xz |
Merge zizzer:/bk/m5 into isabel.reinhardt.house:/z/stever/bk/m5
--HG--
extra : convert_revision : 4dae71fe3482737a22745b27c2ca6983191c4a18
Diffstat (limited to 'sim/system.hh')
-rw-r--r-- | sim/system.hh | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/sim/system.hh b/sim/system.hh index 050d1dd11..564579fe4 100644 --- a/sim/system.hh +++ b/sim/system.hh @@ -35,6 +35,7 @@ #include "base/loader/symtab.hh" #include "base/statistics.hh" #include "cpu/pc_event.hh" +#include "kern/system_events.hh" #include "sim/sim_object.hh" #include "sim/sw_context.hh" @@ -48,17 +49,20 @@ class ExecContext; class System : public SimObject { // lisa's binning stuff - protected: + private: std::map<const std::string, Statistics::MainBin *> fnBins; std::map<const Addr, SWContext *> swCtxMap; + protected: + std::vector<FnEvent *> fnEvents; + public: Statistics::Scalar<> fnCalls; Statistics::MainBin *Kernel; Statistics::MainBin *User; Statistics::MainBin * getBin(const std::string &name); - virtual bool findCaller(std::string, std::string) const = 0; + bool findCaller(std::string, std::string) const; SWContext *findContext(Addr pcb); bool addContext(Addr pcb, SWContext *ctx) { @@ -68,18 +72,23 @@ class System : public SimObject swCtxMap.erase(pcb); return; } - - virtual void dumpState(ExecContext *xc) const = 0; + void dumpState(ExecContext *xc) const; virtual void serialize(std::ostream &os); virtual void unserialize(Checkpoint *cp, const std::string §ion); - // + + + private: + std::multimap<const std::string, std::string> callerMap; + void populateMap(std::string caller, std::string callee); +// public: const uint64_t init_param; MemoryController *memCtrl; PhysicalMemory *physmem; bool bin; + std::vector<string> binned_fns; PCEventQueue pcEventQueue; @@ -90,7 +99,8 @@ class System : public SimObject public: System(const std::string _name, const uint64_t _init_param, - MemoryController *, PhysicalMemory *, const bool); + MemoryController *, PhysicalMemory *, const bool, + const std::vector<string> &binned_fns); ~System(); virtual Addr getKernelStart() const = 0; |