Forum Discussion
Altera_Forum
Honored Contributor
10 years agoPerformance counter report
Hey I am running performance counter on my C code My problem is that the report only show the result for section 1 !! (even if I change sections order it only show the first) It should show 4 ...
Altera_Forum
Honored Contributor
10 years agoIt's hard to know without seeing more code, but perhaps you are forgetting to change the second parameter of the PERF_BEGIN/PERF_END calls for the different sections?
...
// Section 1
PERF_BEGIN(PERFORMANCE_COUNTER_BASE, 1);
foo();
PERF_END(PERFORMANCE_COUNTER_BASE, 1);
// Section 2
PERF_BEGIN(PERFORMANCE_COUNTER_BASE, 2);
bar();
PERF_END(PERFORMANCE_COUNTER_BASE, 2);
...