|
From: <sv...@va...> - 2012-11-23 00:01:44
|
petarj 2012-11-23 00:01:36 +0000 (Fri, 23 Nov 2012)
New Revision: 13136
Log:
Flush events in Callgrind before enering a RMW region.
On some MIPS platforms, we had an issue in which SC would fail each time
due to some memory access occuring in the RMW region.
If code for simulator events is called before LL, it can help SC to pass.
This change fixes a few LL/SC issues on MIPS arch.
The patch by Josef Weidendorfer.
Modified files:
trunk/callgrind/main.c
Modified: trunk/callgrind/main.c (+2 -0)
===================================================================
--- trunk/callgrind/main.c 2012-11-22 18:57:29 +00:00 (rev 13135)
+++ trunk/callgrind/main.c 2012-11-23 00:01:36 +00:00 (rev 13136)
@@ -1073,6 +1073,8 @@
dataTy = typeOfIRTemp(sbIn->tyenv, st->Ist.LLSC.result);
addEvent_Dr( &clgs, curr_inode,
sizeofIRType(dataTy), st->Ist.LLSC.addr );
+ /* flush events before LL, should help SC to succeed */
+ flushEvents( &clgs );
} else {
/* SC */
dataTy = typeOfIRExpr(sbIn->tyenv, st->Ist.LLSC.storedata);
|