This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: PR bootstrap/63784: [5 Regression] profiledbootstrap failure with bootstrap-lto
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: Markus Trippelsdorf <markus at trippelsdorf dot de>
- Cc: Jakub Jelinek <jakub at redhat dot com>, Richard Biener <richard dot guenther at gmail dot com>, Paolo Bonzini <bonzini at gnu dot org>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 10 Nov 2014 12:05:58 -0800
- Subject: Re: PATCH: PR bootstrap/63784: [5 Regression] profiledbootstrap failure with bootstrap-lto
- Authentication-results: sourceware.org; auth=none
- References: <20141109164614 dot GA17351 at intel dot com> <CAFiYyc0N+ai4=sO3ExEUvKSZuHPdK35Ph6L+OABUDyHNq48MEA at mail dot gmail dot com> <20141110120519 dot GH5026 at tucnak dot redhat dot com> <CAMe9rOopxt=Ut9Rv1GdNgQAcKRuRS3yaJhCQ2VnBtB=WZ81mEg at mail dot gmail dot com> <20141110134318 dot GI5026 at tucnak dot redhat dot com> <CAFiYyc19+QeTDHETDScfRufZnSCAoKxkqg_+2K1rXGzntB0yPw at mail dot gmail dot com> <20141110142416 dot GJ5026 at tucnak dot redhat dot com> <CAMe9rOqX4+Yhq8qo6T7MuZcaOjjh=J=ciiAdoT6pC8jRs6xVCQ at mail dot gmail dot com> <20141110195717 dot GA346 at x4>
On Mon, Nov 10, 2014 at 11:57 AM, Markus Trippelsdorf
<markus@trippelsdorf.de> wrote:
> On 2014.11.10 at 11:43 -0800, H.J. Lu wrote:
>> On Mon, Nov 10, 2014 at 6:24 AM, Jakub Jelinek <jakub@redhat.com> wrote:
>> > On Mon, Nov 10, 2014 at 02:44:55PM +0100, Richard Biener wrote:
>> >> >> > I admit I haven't tried LTO bootstrap, but from normal bootstrap logs,
>> >> >> > libcc1 is built normally using libtool using -fPIC only, and linked into
>> >> >> > libcc1.so.0.0.0 and libcc1plugin.so.0.0.0, and of course against the
>> >> >> > pic/libiberty.a, because we need PIC code in the shared libraries.
>> >> >> > So, I don't understand the change at all.
>> >> >> >
>> >> >> > Jakub
>> >> >>
>> >> >> This is the command line to build libcc1.la:
>> >> >
>> >> > Sure, but there was -fPIC used to compile all the *.o files that are being
>> >> > linked into libcc1.so, so LTO should know that.
>> >>
>> >> And it does. If not please file a bug with a smaller testcase than libcc1
>> >> and libiberty.
>> >
>> > Ah, supposedly we should add $(POSTSTAGE1_HOST_EXPORTS) after $(HOST_EXPORTS)
>> > to the libcc1 rules iff the libcc1 module is built by the newly built
>> > bootstrapped compiler (but not when the compiler is not bootstrapped and
>> > thus it is built by the host compiler), because if we first bootstrap the
>> > compiler and build libcc1 by stage3, it is really post-stage1 building.
>>
>> It doesn't help. The problem is the missing -fPIC when libtool calls
>> g+++ to create the shared object. My patch fixes it.
>
> But wouldn't it be better to update to a more recent libtool version
> instead of adding hack upon hack?
Hack is safer than the newer libtool :-(. A new libtool needs to be
verified on all hosts for all targets.
> This would also allow bootstrap-lto without the need of the gcc-ar
> (, etc.) wrappers.
>
> And you are one of the very few persons who could handle such an update.
>
What did you mean by "you"?
--
H.J.