summaryrefslogtreecommitdiff
path: root/src/wb.cc
diff options
context:
space:
mode:
authorSiddarth-Suresh <65844402+Siddarth-Suresh@users.noreply.github.com>2025-04-27 15:04:25 -0400
committerSiddarth-Suresh <65844402+Siddarth-Suresh@users.noreply.github.com>2025-04-27 15:04:25 -0400
commit7aaa516c0de444c956dff88342a57e9313a19e34 (patch)
tree011c07d24ec6e226ac703d50aab7dbf6089935d3 /src/wb.cc
parent66dbfb6ee729e1ff8352c876e6c42aca2081f2e5 (diff)
WB and MEM changes for vectors
Diffstat (limited to 'src/wb.cc')
-rw-r--r--src/wb.cc11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/wb.cc b/src/wb.cc
index 79efe44..0dae5f2 100644
--- a/src/wb.cc
+++ b/src/wb.cc
@@ -51,7 +51,16 @@ void WB::write_handler()
this->checked_out.pop_front();
reg = this->curr_instr->checked_out;
- this->store_register<signed int>(reg, this->curr_instr->operands.integer.slot_one);
+
+ if(this->is_vector_type(this->curr_instr->mnemonic)) {
+ if(this->curr_instr->mnemonic != STOREV && this->curr_instr->mnemonic != LOADV) {
+ this->store_register<std::array<signed int, V_R_LIMIT>>(reg, this->curr_instr->operands.vector.slot_one);
+ } else {
+ this->store_register<std::array<signed int, V_R_LIMIT>>(reg, this->curr_instr->operands.load_store_vector.vector_register);
+ }
+ } else{
+ this->store_register<signed int>(reg, this->curr_instr->operands.integer.slot_one);
+ }
}
void WB::jump_handler()