more changes
authorbdemsky <bdemsky>
Wed, 20 Oct 2010 00:34:25 +0000 (00:34 +0000)
committerbdemsky <bdemsky>
Wed, 20 Oct 2010 00:34:25 +0000 (00:34 +0000)
Robust/src/IR/Flat/RuntimeConflictResolver.java

index 223f1bb5e3506c7d42272767d486d5d3f7c1f39b..0a584cde3dc1620753b1cebb4dc9b43bd99c9895 100644 (file)
@@ -669,19 +669,26 @@ public class RuntimeConflictResolver {
       currCase.append("||");
     }
 
+    int index=-1;
+    if (taint.isRBlockTaint()) {
+      FlatSESEEnterNode fsese=taint.getSESE();
+      TempDescriptor tmp=taint.getVar();
+      index=fsese.getInVarsForDynamicCoarseConflictResolution().indexOf(tmp);
+    }
+
     //Do call if we need it.
     if(primConfWrite||objConfWrite) {
       int heaprootNum = connectedHRHash.get(taint).id;
       assert heaprootNum != -1;
       int allocSiteID = connectedHRHash.get(taint).getWaitingQueueBucketNum(node);
       int traverserID = doneTaints.get(taint);
-      currCase.append("    rcr_WRITEBINCASE(allHashStructures["+heaprootNum+"],"+prefix+", record, -1"+")");
+      currCase.append("    rcr_WRITEBINCASE(allHashStructures["+heaprootNum+"],"+prefix+", record, "+index+")");
     } else if (primConfRead||objConfRead) {
       int heaprootNum = connectedHRHash.get(taint).id;
       assert heaprootNum != -1;
       int allocSiteID = connectedHRHash.get(taint).getWaitingQueueBucketNum(node);
       int traverserID = doneTaints.get(taint);
-      currCase.append("    rcr_READBINCASE(allHashStructures["+heaprootNum+"],"+prefix+", record, -1"+")");
+      currCase.append("    rcr_READBINCASE(allHashStructures["+heaprootNum+"],"+prefix+", record, "+index+")");
     }
 
     if(objConfRead) {