diff options
Diffstat (limited to 'util/statetrace/regstate.hh')
-rw-r--r-- | util/statetrace/regstate.hh | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/util/statetrace/regstate.hh b/util/statetrace/regstate.hh index e97d535a3..ae23b58ca 100644 --- a/util/statetrace/regstate.hh +++ b/util/statetrace/regstate.hh @@ -36,23 +36,24 @@ class RegState { -protected: - virtual bool update(int pid) = 0; -public: - virtual int getNumRegs() = 0; - virtual bool diffSinceUpdate(int num) = 0; - virtual std::string getRegName(int num) = 0; - virtual int getRegNum(std::string name) - { - int numregs = getNumRegs(); - for(unsigned int x = 0; x < numregs; x++) - if(getRegName(x) == name) - return x; - return -1; - } - virtual int64_t getRegVal(int num) = 0; - virtual int64_t getOldRegVal(int num) = 0; - virtual char * printReg(int num) = 0; + protected: + virtual bool update(int pid) = 0; + public: + virtual int getNumRegs() = 0; + virtual bool diffSinceUpdate(int num) = 0; + virtual std::string getRegName(int num) = 0; + virtual int + getRegNum(std::string name) + { + int numregs = getNumRegs(); + for (unsigned int x = 0; x < numregs; x++) + if(getRegName(x) == name) + return x; + return -1; + } + virtual int64_t getRegVal(int num) = 0; + virtual int64_t getOldRegVal(int num) = 0; + virtual char * printReg(int num) = 0; }; #endif |