diff options
author | bd <bdunaisky@umass.edu> | 2025-04-02 04:05:18 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-04-02 04:05:18 +0000 |
commit | 9fb95d655393777dde5929182f94de36f903821d (patch) | |
tree | 4462f35895737460a01fab891a15f87aba2efb70 /src/sim/instrDTO.cc | |
parent | 24f0bd8af57381ab3112b5774d4ad23ac80f0718 (diff) | |
parent | 3eeb345d673bee6d62b04fc8a8a95ab822dc1e45 (diff) |
Merge pull request #46 from bdunahu/bdunahu
Ensure all stages only do work if they are not 'OK'
Diffstat (limited to 'src/sim/instrDTO.cc')
-rw-r--r-- | src/sim/instrDTO.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/sim/instrDTO.cc b/src/sim/instrDTO.cc index b33c26b..aa49b7e 100644 --- a/src/sim/instrDTO.cc +++ b/src/sim/instrDTO.cc @@ -7,8 +7,9 @@ InstrDTO::InstrDTO() this->s1 = 0; this->s2 = 0; this->s3 = 0; - this->mnemonic = NONE; + this->mnemonic = ADD; this->type = INV; + this->pc = 0; } int InstrDTO::get_time_of(Accessor a) { return this->hist[a]; } @@ -25,6 +26,8 @@ Mnemonic InstrDTO::get_mnemonic() { return this->mnemonic; } Type InstrDTO::get_type() { return this->type; } +unsigned int InstrDTO::get_pc() { return this->pc; } + void InstrDTO::set_time_of(Accessor a, int i) { this->hist[a] = i; } void InstrDTO::set_instr_bits(signed int instr) { this->instr_bits = instr; } @@ -38,3 +41,5 @@ void InstrDTO::set_s3(signed int s) { this->s3 = s; } void InstrDTO::set_mnemonic(Mnemonic m) { this->mnemonic = m; } void InstrDTO::set_type(Type t) { this->type = t; } + +void InstrDTO::set_pc(unsigned int pc) { this->pc = pc; } |