Re: [PATCH] Fix up LTO TARGET_OPTION_NODE handling on x86 (PR lto/64374)

2015-02-25 Thread Richard Biener
On Tue, 24 Feb 2015, Jakub Jelinek wrote: > On Tue, Feb 24, 2015 at 08:48:19PM +0100, Jan Hubicka wrote: > > Thanks, the i386 parts of the patch are OK, but I think you want to add the > > reverse > > transformation, too. I.e. if someone compiles with -fPIC but links without. > > I've only done

Re: [PATCH] Fix up LTO TARGET_OPTION_NODE handling on x86 (PR lto/64374)

2015-02-24 Thread Jeff Law
On 02/24/15 15:56, Jakub Jelinek wrote: On Tue, Feb 24, 2015 at 10:21:23PM +0100, Jan Hubicka wrote: On Tue, Feb 24, 2015 at 08:48:19PM +0100, Jan Hubicka wrote: Thanks, the i386 parts of the patch are OK, but I think you want to add the reverse transformation, too. I.e. if someone compiles w

Re: [PATCH] Fix up LTO TARGET_OPTION_NODE handling on x86 (PR lto/64374)

2015-02-24 Thread Jakub Jelinek
On Tue, Feb 24, 2015 at 10:21:23PM +0100, Jan Hubicka wrote: > > On Tue, Feb 24, 2015 at 08:48:19PM +0100, Jan Hubicka wrote: > > > Thanks, the i386 parts of the patch are OK, but I think you want to add > > > the reverse > > > transformation, too. I.e. if someone compiles with -fPIC but links >

Re: [PATCH] Fix up LTO TARGET_OPTION_NODE handling on x86 (PR lto/64374)

2015-02-24 Thread Jan Hubicka
> On Tue, Feb 24, 2015 at 08:48:19PM +0100, Jan Hubicka wrote: > > Thanks, the i386 parts of the patch are OK, but I think you want to add the > > reverse > > transformation, too. I.e. if someone compiles with -fPIC but links without. > > I've only done it this way because that is what > ix86_op

Re: [PATCH] Fix up LTO TARGET_OPTION_NODE handling on x86 (PR lto/64374)

2015-02-24 Thread Jakub Jelinek
On Tue, Feb 24, 2015 at 08:48:19PM +0100, Jan Hubicka wrote: > Thanks, the i386 parts of the patch are OK, but I think you want to add the > reverse > transformation, too. I.e. if someone compiles with -fPIC but links without. I've only done it this way because that is what ix86_option_override_

Re: [PATCH] Fix up LTO TARGET_OPTION_NODE handling on x86 (PR lto/64374)

2015-02-24 Thread Jan Hubicka
> Hi! > > As mentioned in the PR, the ix86_cmodel option is TargetSave, > but during option processing is adjusted from flag_pic, which is > for LTO a global option. > This causes a problem when some translation unit is compiled with LTO > without -fpic, and then the final link is done with -fpic

[PATCH] Fix up LTO TARGET_OPTION_NODE handling on x86 (PR lto/64374)

2015-02-24 Thread Jakub Jelinek
Hi! As mentioned in the PR, the ix86_cmodel option is TargetSave, but during option processing is adjusted from flag_pic, which is for LTO a global option. This causes a problem when some translation unit is compiled with LTO without -fpic, and then the final link is done with -fpic - then ix86_cm