From: yeom Date: Sat, 6 Nov 2010 00:00:21 +0000 (+0000) Subject: change: more aggressively re-initialize fields of rcrRecords. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=eaacef5b9ddee2772b3e8335d05889606e97d7b2;p=IRC.git change: more aggressively re-initialize fields of rcrRecords. now, rcr is working fine with all benchmarks, except mergesort. --- diff --git a/Robust/src/IR/Flat/BuildCode.java b/Robust/src/IR/Flat/BuildCode.java index 92ef2616..3cfd3827 100644 --- a/Robust/src/IR/Flat/BuildCode.java +++ b/Robust/src/IR/Flat/BuildCode.java @@ -4490,6 +4490,8 @@ public class BuildCode { Set weset=seseWaitingQueue.getWaitingElementSet(td); int numqueues=weset.size(); output.println(" seseToIssue->rcrRecords["+i+"].flag="+numqueues+";"); + output.println(" seseToIssue->rcrRecords["+i+"].index=0;"); + output.println(" seseToIssue->rcrRecords["+i+"].next=NULL;"); output.println(" int dispCount"+i+"=0;"); for(Iterator wtit=weset.iterator();wtit.hasNext();) { diff --git a/Robust/src/IR/Flat/RuntimeConflictResolver.java b/Robust/src/IR/Flat/RuntimeConflictResolver.java index f09e79fc..a326d864 100644 --- a/Robust/src/IR/Flat/RuntimeConflictResolver.java +++ b/Robust/src/IR/Flat/RuntimeConflictResolver.java @@ -655,14 +655,15 @@ public class RuntimeConflictResolver { if(cases.size() == 0) { cFile.println(" return;"); } else { - cFile.println(" int totalcount=RUNBIAS;\n"); - + cFile.println(" int totalcount=RUNBIAS;"); if (taint.isStallSiteTaint()) { - cFile.println(" record->rcrRecords[0].count=RUNBIAS;\n"); + cFile.println(" record->rcrRecords[0].count=RUNBIAS;"); + cFile.println(" record->rcrRecords[0].index=0;"); + cFile.println(" record->rcrRecords[0].next=NULL;"); } else { - cFile.println(" record->rcrRecords["+index+"].count=RUNBIAS;\n"); - cFile.println(" record->rcrRecords["+index+"].index=0;\n"); - cFile.println(" record->rcrRecords["+index+"].next=NULL;\n"); + cFile.println(" record->rcrRecords["+index+"].count=RUNBIAS;"); + cFile.println(" record->rcrRecords["+index+"].index=0;"); + cFile.println(" record->rcrRecords["+index+"].next=NULL;"); } //clears queue and hashtable that keeps track of where we've been.