Hashtable paramstable;
Hashtable tempstable;
Hashtable fieldorder;
+ Hashtable flagorder;
int tag=0;
String localsprefix="___locals___";
String paramsprefix="___params___";
paramstable=new Hashtable();
tempstable=new Hashtable();
fieldorder=new Hashtable();
+ flagorder=new Hashtable();
this.typeutil=typeutil;
virtualcalls=new Virtual(state);
}
}
private int maxcount=0;
+ /** This function outputs the virtual dispatch tables for methods. */
private void buildVirtualTables(PrintWriter outvirtual) {
Iterator classit=state.getClassSymbolTable().getDescriptorsIterator();
}
}
+
+ /* Map flags to integers consistently between inherited
+ * classes. */
+
+ private void mapFlags(ClassDescriptor cn) {
+ ClassDescriptor sp=cn.getSuperDesc();
+ if (sp!=null)
+ mapFlags(sp);
+ int max=0;
+ if (!flagorder.containsKey(cn)) {
+ Hashtable flags=new Hashtable();
+ flagorder.put(cn,flags);
+ if (sp!=null) {
+ Hashtable superflags=(Hashtable)flagorder.get(sp);
+ Iterator superflagit=superflags.keySet().iterator();
+ while(superflagit.hasNext()) {
+ FlagDescriptor fd=(FlagDescriptor)superflagit.next();
+ Integer number=(Integer)superflags.get(fd);
+ flags.put(fd, number);
+ if (number.intValue()>max)
+ max=number.intValue();
+ }
+ }
+
+ Iterator flagit=cn.getFlags();
+ while(flagit.hasNext()) {
+ FlagDescriptor fd=(FlagDescriptor)flagit.next();
+ if (sp==null||!sp.getFlagTable().contains(fd.getSymbol()))
+ flags.put(fd, new Integer(++max));
+ }
+ }
+ }
+
/** This function outputs (1) structures that parameters are
* passed in (when PRECISE GC is enabled) and (2) function
* prototypes for the methods */
exit(o1{role1'=false},o2{role3'=false},onew{role4=true});
}
+----------------------------------------------------------------
+----------------------------------------------------------------
+
+Initial design:
+----------------------------------------------------------------
+
+Provide runtime with:
+1) List of tasks
+ a) Task names
+ b) Parameter types
+ c) Flag settings
+
+2) List of flags for each type
+
+3) Flag transition calls