move add to its own simple example
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Tue, 25 Jun 2019 15:14:20 +0000 (16:14 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Tue, 25 Jun 2019 15:14:20 +0000 (16:14 +0100)
simple_v_extension/simple_add_example.mdwn

index 41e73770136a7df5e84a7b6ba1095a13c1fbe0ea..34f77f80ddbba754264870209afab49532dd89fb 100644 (file)
@@ -5,7 +5,7 @@
       rs1 = int_vec[rs1].isvector ? int_vec[rs1].regidx : rs1;
       rs2 = int_vec[rs2].isvector ? int_vec[rs2].regidx : rs2;
       for (i = 0; i < VL; i++)
-        xSTATE.srcoffs = i # save context
+        STATE.srcoffs = i # save context
         if (predval & 1<<i) # predication uses intregs
            ireg[rd+id] <= ireg[rs1+irs1] + ireg[rs2+irs2];
            if (!int_vec[rd ].isvector) break;
@@ -14,7 +14,7 @@
         if (int_vec[rs2].isvector)  { irs2 += 1; }
         if (id == VL or irs1 == VL or irs2 == VL) {
           # end VL hardware loop
-          xSTATE.srcoffs = 0; # reset
-          xSTATE.ssvoffs = 0; # reset
+          STATE.srcoffs = 0; # reset
+          STATE.ssvoffs = 0; # reset
           return;
         }