On Jul 13, 2007, at 5:36 PM, Joseph Wakeling wrote:
Benoit SIGOURE wrote:The .la file is a piece of shell script that contains information usefulto libtool.Now the answer to your question is to ask libtool to run gprof (or gdb)for you: ./libtool --mode=execute gprof ./fooAh! That explains much. Thank you. I still get results that I don't understand. This is the beginning of what I get for profiling my executable: ----------------------------------------------------------------- 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 56133 0.00 0.00 data_start 0.00 0.00 0.00 19 0.00 0.00 MG_sigma2_Theta_threaded ----------------------------------------------------------------- There's a record of calls but not of times, and _nothing_ for the library functions. The library and this executable are all built together in one big ./configure && make. I don't know whether I need to do more than add -pg to the CFLAGS whenbuilding the library or whether it's simply gprof I'm not using correctly.
Hmm you are right, I didn't notice during my test that I also had zeros. Build a static version of your project and it'll work. ./configure --disable-shared make clean all CFLAGS='-pg -all-static' Cheers, -- Benoit Sigoure aka Tsuna EPITA Research and Development Laboratory
PGP.sig
Description: This is a digitally signed message part
_______________________________________________ http://lists.gnu.org/mailman/listinfo/libtool