This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/19953] Special-case real + complex arithmetic operation (-ffast-math)
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Feb 2005 21:36:29 -0000
- Subject: [Bug middle-end/19953] Special-case real + complex arithmetic operation (-ffast-math)
- References: <20050214155119.19953.Thomas.Koenig@online.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-02-28 21:36 -------
For me I get:
D.1542 = COMPLEX_EXPR <REALPART_EXPR <b> / SR.4, IMAGPART_EXPR <b> / SR.4>;
D.1541 = D.1542;
D.1500 = D.1541;
return (double) REALPART_EXPR <D.1500> + (double) IMAGPART_EXPR <D.1500> < 0.0;
The only problem with this is we don't do SRA or complex propagation so we don't do have just the real
and imag parts seperated.
Are you sure that you are doing the correct thing?
Without -fno-cx-limited-range I get:
SR.4 = a;
D.1529 = __builtin_powf (SR.4, 2.0e+0);
return (double) (SR.4 * REALPART_EXPR <b> / D.1529) + (double) (SR.4 * IMAGPART_EXPR <b> /
D.1529) < 0.0;
Now without -std=c99 -fno-cx-limited-range and -ffast-math, I get what you got there is one thing
which can be optimizated out at the tree level but that would be PR 20139.
Now -ffast-math I get:
SR.4 = a;
D.1612 = __builtin_powf (SR.4, 2.0e+0);
return (double) (SR.4 * REALPART_EXPR <b> / D.1612) + (double) (SR.4 * IMAGPART_EXPR <b> /
D.1612) < 0.0;
these all look fine to me.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19953