projects
/
calu.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
sim: highlight for instr
[calu.git]
/
3b_sim
/
ccpu.hpp
diff --git
a/3b_sim/ccpu.hpp
b/3b_sim/ccpu.hpp
index 86940a29f1f8743bbae2eb3aa923befbfd709365..4a8724004733e5812d3006f57bb4ede00e7ad5c5 100644
(file)
--- a/
3b_sim/ccpu.hpp
+++ b/
3b_sim/ccpu.hpp
@@
-5,8
+5,11
@@
#include "cmem.hpp"
#include "cpmem.hpp"
#include "cmem.hpp"
#include "cpmem.hpp"
+#include "ccolor.h"
+
class Iinstr;
class Iinstr;
+#include <boost/regex.hpp>
#include "Iinstr.hpp"
#include "Iinstr.hpp"
@@
-15,7
+18,7
@@
class CCpu {
bool m_Z, m_S, m_C, m_O;
bool m_Z, m_S, m_C, m_O;
- CDat m_pc, m_pc_next;
+ CDat m_pc, m_pc_next
, m_perf
;
CMem<CDat> m_reg, m_ram;
CPMem<Iinstr*> m_prog;
CMem<CDat> m_reg, m_ram;
CPMem<Iinstr*> m_prog;
@@
-34,6
+37,11
@@
class CCpu {
Iinstr* getProg(const int) const;
void setProg(const int, Iinstr*);
Iinstr* getProg(const int) const;
void setProg(const int, Iinstr*);
+ CDat getPerf() const;
+ void setPerf(CDat);
+ void incPerf();
+ void incPerfBy(short);
+
CDat getCurPC() const;
CDat getNextPC() const;
void setNextPC(CDat);
CDat getCurPC() const;
CDat getNextPC() const;
void setNextPC(CDat);
@@
-56,6
+64,8
@@
class CCpu {
int getStack() const;
void setStack(const int);
int getStack() const;
void setStack(const int);
+ string colorifyInstr(string instr);
+
CCpu(int,int,int);
};
CCpu(int,int,int);
};