GNU bug report logs -
#79001
Retain profile image files generated during build
Previous Next
Full log
Message #23 received at 79001 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
I revised the patch to fix a bug causing profiling to always be
enabled. The commit message is much more detailed.
I have also noticed a bug in the current build process that occurs
when enable-profiling is specified and with a parallel build. I
randomly see compile jobs reporting segmentation faults. The compiled
files appear to be correctly output, so my best guess (and that is all
it is) is that the race condition for 32 compile processes all
competing to write "gmon.out" triggers some bug in the profiling code
inserted by gcc with the pg flag. I don't see these issues with this
patch, but a more targeted fix could be to have emacs specify the
environment variable "GMON_OUT_PREFIX" at startup if it is not already
set, since the profiling code will then use that name suffixed by the
process id instead of just "gmon.out". That should at least address
the race condition, both with other instances of emacs and with the
helper executables which will also race for the file "gmon.out" if
executed from the same directory as the emacs process that invokes
them.
I don't know whether the segfaults should be considered a bug in "gcc
-pg", or a violation of the requirements imposed on using the
instrumented code generated by "gcc -pg".
Lynn
[0001-Support-for-retaining-profile-images-from-build.patch (text/x-patch, attachment)]
This bug report was last modified 26 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.