Move mlp and sese stuff into a separate compiler pass
[IRC.git] / Robust / src / IR / Flat / FlatSESEEnterNode.java
index 7c521a3deb4705da201721a8216247bc21635860..6b17aacc4305939f4fd895ed881297f6ef4b7d4d 100644 (file)
@@ -1,21 +1,52 @@
 package IR.Flat;
 import IR.Tree.SESENode;
-import java.util.Vector;
+import java.util.HashSet;
 
 public class FlatSESEEnterNode extends FlatNode {
   private static int identifier=0;
   private int id;
   protected FlatSESEExitNode exit;
   protected SESENode treeNode;
+  protected HashSet<TempDescriptor> inVars;
+  protected HashSet<TempDescriptor> outVars;
 
   public FlatSESEEnterNode( SESENode sn ) {
-    this.id=identifier++;
-    treeNode = sn;    
+    this.id  = identifier++;
+    treeNode = sn;
+    inVars   = new HashSet<TempDescriptor>();
+    outVars  = new HashSet<TempDescriptor>();
   }
+
   public void rewriteUse() {
   }
+
   public void rewriteDef() {
   }
+
+  public void addInVar( TempDescriptor td ) {
+    inVars.add( td );
+  }
+
+  public void addOutVar( TempDescriptor td ) {
+    outVars.add( td );
+  }
+
+  public void addInVarSet( HashSet<TempDescriptor> s ) {
+    inVars.addAll( s );
+  }
+
+  public void addOutVarSet( HashSet<TempDescriptor> s ) {
+    outVars.addAll( s );
+  }
+
+  public HashSet<TempDescriptor> getInVarSet() {
+    return inVars;
+  }
+
+  public HashSet<TempDescriptor> getOutVarSet() {
+    return outVars;
+  }
+
   public SESENode getTreeNode() {
     return treeNode;
   }