[Bug middle-end/57073] __builtin_powif (-1.0, k) should be optimized to "1.0 - 2.0 * (K%2)"
burnus at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Apr 29 08:41:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57073
--- Comment #5 from Tobias Burnus <burnus at gcc dot gnu.org> 2013-04-29 08:40:59 UTC ---
(In reply to comment #4)
> patch that fails
The Fortran patch of the attachments looks fine, except for:
+ one = gfc_copy_expr (op1);
+ gfc_free_expr (op1);
+ gfc_free_expr (op2);
+ *e = *one;
I would simply use "op1" directly instead of copying it and then freeing the
original expression. Otherwise, I am okay with that patch (with a test case).
* * *
For the middle-end patch: Richard things that the problem is probably in the
COND_EXPR re-gimplification - which means the problem is elsewhere.
More information about the Gcc-bugs
mailing list