[maemo-developers] Profiling on Nokia N810
From: Bruno botte.pub at gmail.comDate: Fri Sep 5 15:08:46 EEST 2008
- Previous message: qtnx on maemo
- Next message: Profiling on Nokia N810
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello everybody ! I've been trying to profile my program on the nokia N810 for some times now, and I'm not able to get good results. I installed the oprofile package and the oprofile modified kernel, and then tried to run gprof. I tried 2 ways to get my profiling information (my program is called src ... not really explicit I know ! ) : compile with normal compiler paramaters, no -pg. Then : Nokia-N810:~# opcontrol --init Nokia-N810:~# opcontrol --no-vmlinux Nokia-N810:~# opcontrol -e=CPU_CYCLES:100000 Nokia-N810:~# opcontrol --start Nokia-N810:~# ./src Nokia-N810:~# opcontrol --stop Nokia-N810:~# opgprof src Nokia-N810:~# gprof src > lala.txt gprof: gmon.out is file is missing call-graph data Nokia-N810:~# gprof -Q src > lala.txt and here is the text file I obtain : Flat profile: Each sample counts as 1 samples. % cumulative self self total time samples samples calls T1/call T1/call name 26.86 9243.00 9243.00 VjDetect_DetectFace 14.55 14250.00 5007.00 _init 14.51 19243.00 4993.00 detect_face(mainstruct*, _IplImage*) 13.38 23847.00 4604.00 VjDetect_SetWindowSizeInCascade 11.80 27908.00 4061.00 LBP(_IplImage*) As you see, I have the percentage of time each function take, but not the number of calls... So I tried something else : I compile with -pg option for linker and compiler. Then I use gprof the way I would do on a normal linux architecture. Nokia-N810:~# ./src Nokia-N810:~# gprof src > lala.txt And what I get is : Flat profile: Each sample counts as 0.01 seconds. % cumulative self self total time seconds seconds calls Ts/call Ts/call name 100.01 0.01 0.01 LoadCascade 0.00 0.01 0.00 2663842 0.00 0.00 CalcSum 0.00 0.01 0.00 14708 0.00 0.00 CalcSqSum 0.00 0.01 0.00 14708 0.00 0.00 VjDetect_DetectFace 0.00 0.01 0.00 12 0.00 0.00 VjDetect_SetWindowSizeInCascade 0.00 0.01 0.00 9 0.00 0.00 cvSize(int, int) or : Flat profile: Each sample counts as 0.01 seconds. % cumulative self self total time seconds seconds calls Ts/call Ts/call name 50.01 0.01 0.01 DoCoarseScan 50.01 0.02 0.01 LoadCascade 0.00 0.02 0.00 6568635 0.00 0.00 CalcSum 0.00 0.02 0.00 40447 0.00 0.00 CalcSqSum 0.00 0.02 0.00 40447 0.00 0.00 VjDetect_DetectFace 0.00 0.02 0.00 33 0.00 0.00 VjDetect_SetWindowSizeInCascade 0.00 0.02 0.00 30 0.00 0.00 cvSize(int, int) or even : Flat profile: Each sample counts as 0.01 seconds. no time accumulated % cumulative self self total time seconds seconds calls Ts/call Ts/call name 0.00 0.00 0.00 5042653 0.00 0.00 CalcSum 0.00 0.00 0.00 25739 0.00 0.00 CalcSqSum 0.00 0.00 0.00 25739 0.00 0.00 VjDetect_DetectFace 0.00 0.00 0.00 21 0.00 0.00 VjDetect_SetWindowSizeInCascade 0.00 0.00 0.00 18 0.00 0.00 cvSize(int, int) 0.00 0.00 0.00 7 0.00 0.00 VjDetect_DetectAllFaces 0.00 0.00 0.00 7 0.00 0.00 VjDetect_IntegralImage So now I have the number of calls, but no or weird times informations. For information I used the precompiled maemo diablo kernel for oprofile. Anybody got a similar problem ? Or a solution ? Thanks in advance, I'm starting to desesperate to profile this one ! Best regards, Bruno
- Previous message: qtnx on maemo
- Next message: Profiling on Nokia N810
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]