Using GPROF

From Cpre584
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

This command will generate a test file:

gcc -lm -pg sobel.c
./a.out
gprof a.out > test
  

test file:

%      cumulative  self             self     total           
   
 100.27    0.04     0.04        1    40.11    40.11  sobel_filtering
 0.00      0.04     0.00        1     0.00     0.00  load_image_data
 0.00      0.04     0.00        1     0.00     0.00  save_image_data