[Cfp-interest 1477] Re: complex multiplication and division
paul zimmermann
Paul.Zimmermann at inria.fr
Mon Feb 10 01:41:29 PST 2020
Dear Damian,
on the gcc10 machine from the GCC compile farm, with gcc 6.3.0, I get:
x=(-1.0689346237980500e+252,7.8846096489686452e-145)
y=(5.1152592576527620e-318,6.7327111521288819e+78)
x/y=(1.1710898434244477e-223,1.5876733750267203e+173)
Same on the machine "devel03" from the Plafrim platform with gcc 4.8.5:
x=(-1.0689346237980500e+252,7.8846096489686452e-145)
y=(5.1152592576527620e-318,6.7327111521288819e+78)
x/y=(1.1710898434244477e-223,1.5876733750267203e+173)
This is with -O0 (or no -O option), with -O1 or higher I get the MPC result
(since then GCC uses constant folding, calling MPC).
Paul
> Date: Sun, 9 Feb 2020 22:22:35 +1100 (AEDT)
> From: Damian McGuckin <damianm at esi.com.au>
>
> I tried your program on a GCC 9.2.1 on Power9, and GCC 4.8.1 and 8.? on
> Xeon. I was specifically looking at division because something is very
> obviously wrong. You mentioned:
>
> > /* MPC gives (-3.5164330596706266e-225,1.5876733750267203e+173) */
> > /* GCC 9.2.1 gives (1.1710898434244477e-223,1.5876733750267203e+173) */
> > /* ICC 19.0.4.243: (-3.5164330596706266e-225,1.5876733750267203e+173) */
>
> I get the same answer as MPC. Not your answer. On an ancient Xeon with GCC
> 4.4.7, I get your 1.171.....e-223 answer. A quick guess is that something
> is probably not quite right with your installation of GCC. But I could be
> wrong.
>
> Regards - Damian
>
> Pacific Engineering Systems International, 277-279 Broadway, Glebe NSW 2037
> Ph:+61-2-8571-0847 .. Fx:+61-2-9692-9623 | unsolicited email not wanted here
> Views & opinions here are mine and not those of any past or present employer
>
More information about the Cfp-interest
mailing list