make getDestAddr() return a BitVector
[fleet.git] / src / edu / berkeley / fleet / fpga / Fpga.java
index 36c2024..7566cee 100644 (file)
@@ -51,6 +51,10 @@ public class Fpga extends FleetTwoFleet {
         } catch (Exception e) { throw new RuntimeException(e); }
     }
 
+    public BitVector getDestAddr(Path path) {
+        return ((FpgaPath)path).toBitVector();
+    }
+
     // Setup //////////////////////////////////////////////////////////////////////////////
 
     public Ship createShip(String type, String name) throws IOException {
@@ -70,8 +74,12 @@ public class Fpga extends FleetTwoFleet {
         createShip("Memory",      "memory1");
 
         if (small) {
-            createShip("Fifo", "fifo");
-            createShip("Alu",  "alu");
+            createShip("Fifo",           "fifo");
+            createShip("Alu",            "alu");
+            createShip("Counter",        "counter");
+            createShip("CarrySaveAdder", "csa1");
+            createShip("Rotator",        "rotator");
+            createShip("Lut3",           "lut");
         } else {
             //createShip("Memory",    "memory2");
             //createShip("Memory",    "memory3");
@@ -398,15 +406,4 @@ public class Fpga extends FleetTwoFleet {
         } catch (Exception e) { throw new RuntimeException(e); }
     }
 
-    public long getDestAddr(Path path) {
-        return ((FpgaPath)path).toLong();
-    }
-    public Dock getBoxByInstAddr(long dest) {
-        for(Ship ship : Fpga.this)
-            for(Dock bb : ship)
-                if (((FpgaDestination)((FpgaDock)bb).getInstructionDestination()).getAddr() == dest)
-                    return bb;
-        return null;
-    }
-
 }