Re: [PATCH] Fix PR47566

2011-08-09 Thread Ulrich Weigand
Richard Guenther wrote: > On Mon, 8 Aug 2011, Ulrich Weigand wrote: > > OK, so what about the following version? This keeps not linking against > > libm so it will fail if cabs is not folded. On the other hand, it will > > provide a dummy implementation of sqrt to avoid failure simply because > >

Re: [PATCH] Fix PR47566

2011-08-09 Thread Richard Guenther
On Mon, 8 Aug 2011, Ulrich Weigand wrote: > Richard Guenther wrote: > > > Of course testing for the fold makes sure we also test for the crash ... > > so yes, the idea was to also test for the fold. As the LTO testing > > harness does not support scanning dumps (sigh...) link tests are > > the o

Re: [PATCH] Fix PR47566

2011-08-08 Thread Ulrich Weigand
Richard Guenther wrote: > Of course testing for the fold makes sure we also test for the crash ... > so yes, the idea was to also test for the fold. As the LTO testing > harness does not support scanning dumps (sigh...) link tests are > the only possibility right now. OK, so what about the follo

Re: [PATCH] Fix PR47566

2011-07-23 Thread Richard Guenther
On Fri, Jul 22, 2011 at 7:28 PM, Richard Henderson wrote: > On 07/22/2011 10:19 AM, Ulrich Weigand wrote: >> Richard Henderson wrote: >>> On 07/22/2011 07:42 AM, Ulrich Weigand wrote: Well, it works for me with just adding -lm to the dg-extra-ld-options. This still folds cabs to sqrt in

Re: [PATCH] Fix PR47566

2011-07-22 Thread Richard Henderson
On 07/22/2011 10:19 AM, Ulrich Weigand wrote: > Richard Henderson wrote: >> On 07/22/2011 07:42 AM, Ulrich Weigand wrote: >>> Well, it works for me with just adding -lm to the dg-extra-ld-options. >>> This still folds cabs to sqrt in the LTO step, and then satisfies that >>> call via the libm routi

Re: [PATCH] Fix PR47566

2011-07-22 Thread Ulrich Weigand
Richard Henderson wrote: > On 07/22/2011 07:42 AM, Ulrich Weigand wrote: > > Well, it works for me with just adding -lm to the dg-extra-ld-options. > > This still folds cabs to sqrt in the LTO step, and then satisfies that > > call via the libm routine ... If I understood your intent correctly, >

Re: [PATCH] Fix PR47566

2011-07-22 Thread Richard Henderson
On 07/22/2011 07:42 AM, Ulrich Weigand wrote: > Well, it works for me with just adding -lm to the dg-extra-ld-options. > This still folds cabs to sqrt in the LTO step, and then satisfies that > call via the libm routine ... If I understood your intent correctly, > this should still test the same t

Re: [PATCH] Fix PR47566

2011-07-22 Thread Ulrich Weigand
Richard Guenther wrote: > On Fri, 22 Jul 2011, Ulrich Weigand wrote: > > Now that we have the linker plugin, this fails on spu-elf with: > > > > /tmp/cce6KuRb.ltrans0.ltrans.o: In function `foo': > > cce6KuRb.ltrans0.o:(.text+0x28): undefined reference to `sqrt' > > > > because nothing links agai

Re: [PATCH] Fix PR47566

2011-07-22 Thread Richard Guenther
On Fri, 22 Jul 2011, Ulrich Weigand wrote: > Richard Guenther wrote: > > > + /* { dg-lto-do run } */ > > + /* { dg-lto-options { { -O0 -flto } } } */ > > + /* { dg-extra-ld-options "-O2 -ffast-math -fuse-linker-plugin" } */ > > + /* { dg-require-linker-plugin "" } */ > > + > > + /* We require a

Re: [PATCH] Fix PR47566

2011-07-22 Thread Ulrich Weigand
Richard Guenther wrote: > + /* { dg-lto-do run } */ > + /* { dg-lto-options { { -O0 -flto } } } */ > + /* { dg-extra-ld-options "-O2 -ffast-math -fuse-linker-plugin" } */ > + /* { dg-require-linker-plugin "" } */ > + > + /* We require a linker plugin because otherwise we'd need to link > +aga