I've been porting an application to the Cell/BE using the SystemSim and I wanted to get an idea of its performance.
The original applications uses the clock() system call to get timing data, but this doesn't seem to work on the SystemSim.
What is the indicated/best way of getting timings on the SystemSim? I'm just looking for a stopwatch-type function from which I can extract either system or wall-clock times or even the number of cycles...
This topic has been locked.
1 reply Latest Post - 2010-07-06T14:23:48Z by PedroGonnet
Pinned topic Timing programs on the SystemSim
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2010-07-06T14:23:48Z at 2010-07-06T14:23:48Z by PedroGonnet
PedroGonnet 110000GM7U12 PostsACCEPTED ANSWER
Re: Timing programs on the SystemSim2010-07-06T14:23:48Z in response to PedroGonnetSorry, just solved this myself... Should google better next time.
I've #included <ppu_intrinsics.h> and use __mftb() to get an unsigned long long. If I divide the difference between the return values of two calls by the timebase delivered by "cat /proc/cpuinfo", I get the number of elapsed seconds.
Cheers and sorry for posting unnecessarily,