Re: Excess precision problem on IA-64

2005-10-27 Thread Geert Bosch
On Oct 27, 2005, at 17:25, Steve Ellcey wrote: It would be easy enough to add an option that turned off the use of the fused multiply and add in GCC but I would hate to see its use turned off by default. Code that cares should be able to express barriers across which no contraction is poss

Re: Excess precision problem on IA-64

2005-10-27 Thread Geert Bosch
On Oct 27, 2005, at 17:19, Andreas Schwab wrote: I think this is what the FP_CONTRACT pragma is supposed to provide. Yes, but it seems there is no way in the middle end / back end to express this. Or am I just hopelessly behind the times? :) -Geert

Re: Excess precision problem on IA-64

2005-10-27 Thread Eric Botcazou
> The HP compiler generates fused multiply and add by default and has several > settings for the +Ofltacc option to control this (and other optimizations > that affect floating point accuracy). > > +Ofltacc=default > > Allows contractions, such as fused multiply-add (FMA), but > disallo

Re: Excess precision problem on IA-64

2005-10-27 Thread Steve Ellcey
> > This seems like any other target which has a fused multiply and add > > instruction like PPC. Maybe a target option to turn on and off the fma > > instruction like there is for PPC. > > I'm under the impression that it's worse on IA-64 because of the "infinite > precision", but I might be w

Re: Excess precision problem on IA-64

2005-10-27 Thread Andreas Schwab
Geert Bosch <[EMAIL PROTECTED]> writes: > On Oct 27, 2005, at 14:12, Eric Botcazou wrote: >> I'm under the impression that it's worse on IA-64 because of the >> "infinite >> precision", but I might be wrong. > > Fused multiply-add always uses "infinite precision" in the intermediate > result. Only

Re: Excess precision problem on IA-64

2005-10-27 Thread Eric Botcazou
> Fused multiply-add always uses "infinite precision" in the intermediate > result. Only a single rounding is performed at the end. Of course, but I was implicitly referring to the 82-bit thing. But it seems I was wrong, as the testcase fails on PowerPC w/ -mfused-madd too. -- Eric Botcazou

Re: Excess precision problem on IA-64

2005-10-27 Thread Geert Bosch
On Oct 27, 2005, at 14:12, Eric Botcazou wrote: I'm under the impression that it's worse on IA-64 because of the "infinite precision", but I might be wrong. Fused multiply-add always uses "infinite precision" in the intermediate result. Only a single rounding is performed at the end. We real

Re: Excess precision problem on IA-64

2005-10-27 Thread Eric Botcazou
> This seems like any other target which has a fused multiply and add > instruction like PPC. Maybe a target option to turn on and off the fma > instruction like there is for PPC. I'm under the impression that it's worse on IA-64 because of the "infinite precision", but I might be wrong. -- E

Re: Excess precision problem on IA-64

2005-10-27 Thread Andrew Pinski
> > --Boundary-00=_dFRYDl9RKCduOdb > Content-Type: text/plain; > charset="us-ascii" > Content-Transfer-Encoding: 7bit > Content-Disposition: inline > > Hi, > > We have run into an excess precision problem on IA-64, similar to the > infamous > problem on IA-32. A C testcase is attached. > >