Re: AVR gives weird error with LTO

2010-01-09 Thread Denis Chertykov
>> Eric; Denis Chertykov >> Subject: Re: AVR gives weird error with LTO >> >> >> >> Thank you David and Rafel >> >> >> >> I will dig further into collect2.  I had noted that avr.h >> has the following: >> >> >> &g

RE: AVR gives weird error with LTO

2009-12-30 Thread Weddington, Eric
> -Original Message- > From: Andrew Hutchinson [mailto:andrewhutchin...@cox.net] > Sent: Wednesday, December 30, 2009 4:34 PM > To: Richard Guenther > Cc: Dave Korn; Rafael Espindola; GCC Development; Weddington, > Eric; Denis Chertykov > Subject: Re: AVR gives

Re: AVR gives weird error with LTO

2009-12-30 Thread Andrew Hutchinson
Thank you David and Rafel I will dig further into collect2. I had noted that avr.h has the following: /* This is undefined macro for collect2 disabling */ #define LINKER_NAME "ld" That's indeed going to break LTO. Richard. That seems to be the key issue. Without #define LINKER_N

Re: AVR gives weird error with LTO

2009-12-30 Thread Richard Guenther
On Thu, Dec 31, 2009 at 12:04 AM, Andrew Hutchinson wrote: > > Dave Korn wrote: >> >> Rafael Espindola wrote: >>  It's not a valid option for ld.  It *is* a valid option for the collect2 driver/wrapper executable that gcc uses to invoke ld, which suggests to me that t

Re: AVR gives weird error with LTO

2009-12-30 Thread Andrew Hutchinson
Dave Korn wrote: Rafael Espindola wrote: It's not a valid option for ld. It *is* a valid option for the collect2 driver/wrapper executable that gcc uses to invoke ld, which suggests to me that the AVR port must be configured not to build collect2, but that it is going to need to do so if i

Re: AVR gives weird error with LTO

2009-12-30 Thread Dave Korn
Rafael Espindola wrote: >> It's not a valid option for ld. It *is* a valid option for the collect2 >> driver/wrapper executable that gcc uses to invoke ld, which suggests to me >> that the AVR port must be configured not to build collect2, but that it is >> going to need to do so if it wants to u

Re: AVR gives weird error with LTO

2009-12-30 Thread Rafael Espindola
>  It's not a valid option for ld.  It *is* a valid option for the collect2 > driver/wrapper executable that gcc uses to invoke ld, which suggests to me > that the AVR port must be configured not to build collect2, but that it is > going to need to do so if it wants to use LTO/WHOPR.  See use_colle

Re: AVR gives weird error with LTO

2009-12-30 Thread Dave Korn
Andrew Hutchinson wrote: > I used "v" and progressed a little > > The problem seems to be that linker is called with -fwhopr or -flto as > command line option. > > ld -fwhopr . > > Linker find '-f' and complains. > > I assume this is not a valid option for ld? Or is my linker wrong > vers

Re: AVR gives weird error with LTO

2009-12-30 Thread Andrew Hutchinson
I used "v" and progressed a little The problem seems to be that linker is called with -fwhopr or -flto as command line option. ld -fwhopr . Linker find '-f' and complains. I assume this is not a valid option for ld? Or is my linker wrong version or something? Note this is cross comp

Re: AVR gives weird error with LTO

2009-12-30 Thread Dave Korn
Andrew Hutchinson wrote: > When AVR target is built, without explicitly disabling LTO, it will > produce 1000's of testsuite failures of -LTO -WHOPR tests with this > compilation error: > > "ld: -f may not be used without -shared" > > Any idea what is wrong or how to make LTO work correctly here?

AVR gives weird error with LTO

2009-12-30 Thread Andrew Hutchinson
When AVR target is built, without explicitly disabling LTO, it will produce 1000's of testsuite failures of -LTO -WHOPR tests with this compilation error: "ld: -f may not be used without -shared" Any idea what is wrong or how to make LTO work correctly here? Andy http://gcc.gnu.org/bugzilla/