The profiling options used in config/init/defaults.pm are specific to
gcc. This should probably be specified in the relevant hints file.
This flag convinces gcc to generate profiling code specifically for
the GNU profiler, "gprof". I find it *extremely* unlikely that this
flag would be available and/or mean the same thing for other compilers,
but I do not currently have any others to test with.
Mark
The profiling options code in config/init/defaults.pm reads:
if ( $conf->options->get('profile') ) {
$conf->data->set(
cc_debug => " -pg ",
ld_debug => " -pg ",
);
}
Can anyone confirm that these are indeed gcc-specific? Thanks.
kid51
Yes. They are gcc-specific. A plain -p is common on Unix systems, but
-pg is gcc-specific. For example, with Sun's C compiler, -xpg would be
the equivalent flag. (Though Sun's C compiler also has other profile
options selected by -xprofile. I haven't looked at them in ages, so I
can't tell you anything useful about them.)
--
Andy Dougherty doug...@lafayette.edu