This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Information on profiling


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


Hello,

En/na Ian Lance Taylor ha escrit:
> Harald Servat <harald.servat@bsc.es> writes:
> 
>>   Is there any pointer on how GCC deals to generate profiles (-p/-pg flags)?
> 
> There may be, but I doubt it.
> 
>>   In particular, I'm looking for information on (but not only):
>>
>>   * How GCC instruments user routines when compiling a C file using -p/-pg
> 
> It varies by target.  You need to look at the gcc backend for your
> target.

  Sorry, but I can't figure at what kind of backend are you referring
to. Let's suppose I'm interested on i386 architecture and C compiled
files, where in should I start looking?

>>   * Where I can find the instrumentation code (i.e., the code called at
>> entry and exit points of user routines). Does it belongs to GCC package?
>> Or maybe belongs to a foreign package lib GLIBC?
> 
> The entry/exit code is part of gcc.  The code that it calls is mostly
> in gcc/libgcov.c.
> 

  Does it mean that the profile is built on top (or reuses code) from
the code coverage mechanism?

Thank you very much.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (GNU/Linux)

iEYEARECAAYFAkr5hzgACgkQwMPeuqUCg9xP8wCdFywki65ZrsoPZ+9Jys2CtceT
XtEAn0bsNjRXlsMYnxX+/H4aBLcGUmQW
=XlwU
-----END PGP SIGNATURE-----


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]