File tree 1 file changed +8
-1
lines changed
1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -295,6 +295,10 @@ int main(int argc, char * argv[])
295
295
bool show_partial_core_output = false ;
296
296
std::bitset<MAX_CORES> ycores;
297
297
298
+ // Occasionally the memory is not properly nulled because counters appear to
299
+ // be programmed even without given arguments so making really sure
300
+ memset ( ®s, 0 , sizeof (regs) );
301
+
298
302
conf.fixedCfg = NULL ; // default
299
303
conf.nGPCounters = 4 ;
300
304
conf.gpCounterCfg = regs;
@@ -432,7 +436,10 @@ int main(int argc, char * argv[])
432
436
}
433
437
continue ;
434
438
}
435
- } while (argc > 1 ); // end of command line partsing loop
439
+ } while (argc > 1 ); // end of command line parsing loop
440
+
441
+ if ( cur_event == 0 )
442
+ cerr << " WARNING: you did not provide any custom events, is this intentional?\n " ;
436
443
437
444
conf.OffcoreResponseMsrValue [0 ] = events[0 ].msr_value ;
438
445
conf.OffcoreResponseMsrValue [1 ] = events[1 ].msr_value ;
You can’t perform that action at this time.
0 commit comments