add comment on where reshape map is set up
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 3 Nov 2018 15:22:32 +0000 (15:22 +0000)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Sat, 3 Nov 2018 15:22:32 +0000 (15:22 +0000)
riscv/sv_insn_redirect.cc

index bb3dd26d224a0fa1db521337121aadd7c66b6627..eacf96db7525c861a3568ce960c39cd0810eadb8 100644 (file)
@@ -125,6 +125,10 @@ unsigned int sv_proc_t::remap(reg_spec_t const& spec)
     if (shape == NULL) {
         return offs;
     }
+    // this table is pre-calculated by sv_shape_t::setup_map().
+    // changing the CSRs is the way to change the map.
+    // the map is still calculated even for the 1D case
+    // because it's a linear map
     return (unsigned int)shape->map[offs] + shape->offs;
 }