I want to benchmark the performance of two threads communicating with each other, each pinned to its own core. Specifically I want to benchmark the work as well as interaction/communication delays of these threads and have decided to use the PMU (performance monitoring unit) values like the cycle counter register and some other event counters.
My problem is now that the two PMUs aren’t in sync and I can’t compare the recorded values for each thread after the benchmark is done.
Is there a way to synchronize the PMUs?
What i found is the ClockCycles command. In the QNX documentation it is stated that these command might use a free running timer located directly on a core. In my case I think this command uses the global timer of the system, but I am not exactly sure.
How can i find out if the source of ClockCycles is the global timer? (Where to search in the BSP?)
Or can anyone recommend a better approach?
Thank in advance!