From de9ca83325022069c18d8052dca0e52f2708718a Mon Sep 17 00:00:00 2001 From: jjenista Date: Tue, 9 Nov 2010 02:24:06 +0000 Subject: [PATCH] bug fixes in logic --- Robust/src/IR/Flat/RuntimeConflictResolver.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Robust/src/IR/Flat/RuntimeConflictResolver.java b/Robust/src/IR/Flat/RuntimeConflictResolver.java index 34eadf13..0b75b8d4 100644 --- a/Robust/src/IR/Flat/RuntimeConflictResolver.java +++ b/Robust/src/IR/Flat/RuntimeConflictResolver.java @@ -672,7 +672,7 @@ public class RuntimeConflictResolver { cFile.println(" return;"); } else { cFile.println(" int totalcount=RUNBIAS;"); - if (!taint.isStallSiteTaint()) { + if (taint.isStallSiteTaint()) { cFile.println(" record->rcrRecords[0].count=RUNBIAS;"); } else { cFile.println(" record->rcrRecords["+index+"].count=RUNBIAS;"); @@ -699,13 +699,13 @@ public class RuntimeConflictResolver { if (taint.isStallSiteTaint()) { //need to add this - cFile.println(" if(atomic_sub_and_test(RUNBIAS-totalcount,&(record->rcrRecords[0].count))) {"); + cFile.println(" if(atomic_sub_and_test(totalcount,&(record->rcrRecords[0].count))) {"); cFile.println(" psem_give_tag(record->common.parentsStallSem, record->tag);"); cFile.println(" BARRIER();"); cFile.println("}"); cFile.println(" record->common.rcrstatus=0;"); } else { - cFile.println(" if(atomic_sub_and_test(RUNBIAS-totalcount,&(record->rcrRecords["+index+"].count))) {"); + cFile.println(" if(atomic_sub_and_test(totalcount,&(record->rcrRecords["+index+"].count))) {"); cFile.println(" int flag=LOCKXCHG32(&(record->rcrRecords["+index+"].flag),0);"); cFile.println(" if(flag) {"); //we have resolved a heap root...see if this was the last dependence -- 2.34.1