Use carry-in bit to create a selector? Perhaps a waste of an ALU.
-Carry-save / carry completion stuff.
-
Flags: zero, negative, overflow, ?
+\begin{verbatim}
move elsewhere:
//MUL:
//DIV:
//MOD:
+\end{verbatim}
== Fleeterpreter ====================================================
public long resolveLiteral(String literal) {
if (box_in1.dataReadyForShip() &&
box_in2.dataReadyForShip() &&
box_inOp.dataReadyForShip() &&
- box_out.readyForItemFromShip()) {
- int a = box_in1.removeDataForShip();
- int b = box_in2.removeDataForShip();
- int op = box_inOp.removeDataForShip();
- switch(op) {
+ box_out.readyForDataFromShip()) {
+ long a = box_in1.removeDataForShip();
+ long b = box_in2.removeDataForShip();
+ long op = box_inOp.removeDataForShip();
+ switch((int)op) {
case 0: box_out.addDataFromShip(a+b); // ADD
break;
case 1: box_out.addDataFromShip(a-b); // SUB