# HG changeset patch # User Nina Engelhardt # Date 1328286768 -3600 # Node ID fe5ad5726e362543cc206020bed27a1a1f63503a # Parent 69eb54ce9c4bdd90fa673bc0ded914733dedb529 counters working ...sort of diff -r 69eb54ce9c4b -r fe5ad5726e36 MasterLoop.c --- a/MasterLoop.c Tue Jan 31 18:30:35 2012 +0100 +++ b/MasterLoop.c Fri Feb 03 17:32:48 2012 +0100 @@ -152,9 +152,10 @@ saveLowTimeStampCountInto( startStamp1 ); #endif #ifdef MEAS__PERF_COUNTERS + VirtProcr p_sav = *(currSlot->procrAssignedToSlot); uint64 cycles, instrs; saveCyclesAndInstrs(thisCoresIdx,cycles, instrs); - //(*counterHandler)(MasterLoop_beforeReqHdlr,currSlot->procrAssignedToSlot,cycles,instrs); + (*counterHandler)(MasterLoop_beforeReqHdlr,&p_sav,cycles,instrs); #endif //============================================================ (*requestHandler)( currSlot->procrAssignedToSlot, semanticEnv ); @@ -170,7 +171,7 @@ //done with constraints check uint64 cycles2,instrs2; saveCyclesAndInstrs(thisCoresIdx,cycles2, instrs2); - (*counterHandler)(MasterLoop_afterReqHdlr,currSlot->procrAssignedToSlot,cycles2,instrs2); + (*counterHandler)(MasterLoop_afterReqHdlr,&p_sav,cycles2,instrs2); #endif //============================================================ } diff -r 69eb54ce9c4b -r fe5ad5726e36 VMS.h --- a/VMS.h Tue Jan 31 18:30:35 2012 +0100 +++ b/VMS.h Fri Feb 03 17:32:48 2012 +0100 @@ -42,7 +42,7 @@ #define dbgAppFlow FALSE /* Top level flow of application code -- general*/ #define dbgProbes FALSE /* for issues inside probes themselves*/ #define dbgB2BMaster FALSE /* in coreloop, back to back master VPs*/ -#define dbgRqstHdlr TRUE /* in request handler code*/ +#define dbgRqstHdlr FALSE /* in request handler code*/ #define dbgDependency TRUE /* in request handler code, print dependencies */ //Comment or un- the substitute half to turn on/off types of debug message @@ -82,7 +82,7 @@ //========================= Hardware related Constants ===================== //This value is the number of hardware threads in the shared memory // machine -#define NUM_CORES 2 +#define NUM_CORES 4 // tradeoff amortizing master fixed overhead vs imbalance potential // when work-stealing, can make bigger, at risk of losing cache affinity