Last Comment Bug 602245 - PGO builds fail with --enable-tests where SIMPLE_PROGRAMS are linked against objects compiled with -fprofile-generate
: PGO builds fail with --enable-tests where SIMPLE_PROGRAMS are linked against ...
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: Build Config (show other bugs)
: Trunk
: All Linux
: -- normal (vote)
: mozilla6
Assigned To: Mike Hommey [:glandium]
:
Mentors:
: 642461 (view as bug list)
Depends on: 643817
Blocks: 542504 gcc4.5
  Show dependency treegraph
 
Reported: 2010-10-06 10:26 PDT by Chris Coulson
Modified: 2011-04-14 02:26 PDT (History)
4 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Build failure (6.51 KB, text/plain)
2010-10-06 10:26 PDT, Chris Coulson
no flags Details
Don't build SIMPLE_PROGRAMS during MOZ_PROFILE_GENERATE pass (6.17 KB, patch)
2011-03-24 06:29 PDT, Mike Hommey [:glandium]
no flags Details | Diff | Review
Don't build SIMPLE_PROGRAMS during MOZ_PROFILE_GENERATE pass (6.80 KB, patch)
2011-03-24 10:29 PDT, Mike Hommey [:glandium]
ted: review+
Details | Diff | Review

Description Chris Coulson 2010-10-06 10:26:12 PDT
Created attachment 481263 [details]
Build failure

I tried doing a profiledbuild with latest mozilla-central. I get a build failure when trying to link nsIFileEnumerator (I've attached the error).

The issue seems to be that the objects in libxpcomglue_s are compiled with -fprofile-generate, but the linking is done without (as a side-effect of bug 542504).

The GCC manual states "You must use ‘-fprofile-generate’ both when compiling and when linking your program."
Comment 1 Chris Coulson 2010-10-06 10:33:08 PDT
Urgh, and, of course - I meant to say "--enable-tests" ;)
Comment 2 Ted Mielczarek [:ted.mielczarek] 2010-10-07 05:41:17 PDT
I guess we should fix it the way I said in bug 542504 comment 3 instead. :-/
Comment 3 Mike Hommey [:glandium] 2011-03-18 01:42:27 PDT
*** Bug 642461 has been marked as a duplicate of this bug. ***
Comment 4 Mike Hommey [:glandium] 2011-03-24 06:29:34 PDT
Created attachment 521477 [details] [diff] [review]
Don't build SIMPLE_PROGRAMS during MOZ_PROFILE_GENERATE pass
Comment 5 Mike Hommey [:glandium] 2011-03-24 10:29:25 PDT
Created attachment 521543 [details] [diff] [review]
Don't build SIMPLE_PROGRAMS during MOZ_PROFILE_GENERATE pass

The previous iteration led to a failure to build on windows due to xpcom/tests/windows/Makefile.in including config.mk before setting CPP_UNIT_TESTS.
Comment 6 Mike Hommey [:glandium] 2011-04-14 02:26:01 PDT
http://hg.mozilla.org/mozilla-central/rev/1203611ef3dc

Note You need to log in before you can comment on or make changes to this bug.