XLEN parameterization for simx

This commit is contained in:
Santosh Srivatsan
2022-02-03 15:19:31 -05:00
parent 54dd2cfe1d
commit 836c777680
191 changed files with 5520 additions and 32163 deletions

View File

@@ -11,7 +11,7 @@ class Core;
class Instr;
class pipeline_trace_t;
struct DomStackEntry {
DomStackEntry(const ThreadMask &tmask, XWord PC)
DomStackEntry(const ThreadMask &tmask, Word PC)
: tmask(tmask)
, PC(PC)
, fallThrough(false)
@@ -26,7 +26,7 @@ struct DomStackEntry {
{}
ThreadMask tmask;
XWord PC;
Word PC;
bool fallThrough;
bool unanimous;
};
@@ -40,7 +40,7 @@ struct vtype {
class Warp {
public:
Warp(Core *core, Word id);
Warp(Core *core, uint32_t id);
void clear();
@@ -62,15 +62,15 @@ public:
return 0;
}
Word id() const {
uint32_t id() const {
return id_;
}
Word getPC() const {
uint32_t getPC() const {
return PC_;
}
void setPC(Word PC) {
void setPC(uint32_t PC) {
PC_ = PC;
}
@@ -79,13 +79,13 @@ public:
active_ = tmask_.any();
}
Word getTmask() const {
uint32_t getTmask() const {
if (active_)
return tmask_.to_ulong();
return 0;
}
Word getIRegValue(int reg) const {
uint32_t getIRegValue(int reg) const {
return ireg_file_.at(0).at(reg);
}
@@ -95,14 +95,14 @@ private:
void execute(const Instr &instr, pipeline_trace_t *trace);
Word id_;
uint32_t id_;
Core *core_;
bool active_;
XWord PC_;
Word PC_;
ThreadMask tmask_;
std::vector<std::vector<XWord>> ireg_file_;
std::vector<std::vector<Word>> ireg_file_;
std::vector<std::vector<FWord>> freg_file_;
std::vector<std::vector<Byte>> vreg_file_;
std::stack<DomStackEntry> dom_stack_;