Fixed some simX bugs

This commit is contained in:
fares
2019-11-21 20:28:02 -05:00
parent fd80fa14c7
commit d8d98d8ea7
17 changed files with 165568 additions and 593539 deletions

View File

@@ -381,7 +381,15 @@ Instruction *WordDecoder::decode(const std::vector<Byte> &v, Size &idx) {
imeed = 0 | (bits_10_1 << 1) | (bit_11 << 11) | (bits_19_12 << 12) | (bit_20 << 20);
inst.setSrcImm(signExt(imeed, 20, j_immed_mask));
// cout << "Immediate src: " << hex << imeed << "\n";
// cout << "bit 20 = " << bit_20 << '\n';
// if (bit_20 == 1)
// {
// imeed = imeed * -1;
// }
inst.setSrcImm(signExt(imeed, 21, j_immed_mask));
usedImm = true;
break;
defualt: