This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug gcov-profile/40498] There is neither a negative form of -pg nor an __attribute__ to disable instrumentation of a specific function
- From: "naesten at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 20 Jun 2009 20:03:50 -0000
- Subject: [Bug gcov-profile/40498] There is neither a negative form of -pg nor an __attribute__ to disable instrumentation of a specific function
- References: <bug-40498-17802@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from naesten at gmail dot com 2009-06-20 20:03 -------
Oh, hmm ... looks like you're right: I was looking at the wrong function in
objdump -- possibly because the functions somehow came out in a different order
in the object file from the source file.
Perhaps the documentation should be updated to mention that
"no_instrument_function" applies even for -pg? Right now,
http://gcc.gnu.org/onlinedocs/gcc-4.4.0/gcc/Function-Attributes.html only says:
no_instrument_function
If -finstrument-functions is given, profiling function calls will be
generated at entry and exit of most user-compiled functions. Functions with
this attribute will not be so instrumented.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40498