[Bug rtl-optimization/112483] [14 Regression] gfortran.dg/ieee/ieee_2.f90 fails on loongarch64-linux-gnu at -O1 or above
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Nov 16 23:46:01 GMT 2023
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112483
--- Comment #20 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Xi Ruoyao <xry111@gcc.gnu.org>:
https://gcc.gnu.org/g:9e9279fadbd1c673c875b9d20261d2de0473f63f
commit r14-5542-g9e9279fadbd1c673c875b9d20261d2de0473f63f
Author: Andrew Pinski <pinskia@gmail.com>
Date: Mon Nov 13 20:18:34 2023 +0000
Only allow (copysign x, NEG_CONST) -> (fneg (fabs x)) simplification for
constant folding [PR112483]
On targets with native copysign instructions, (copysign x, -1) is
usually more efficient than (fneg (fabs x)). Since r14-5284, in the
middle end we always optimize (fneg (fabs x)) to (copysign x, -1), not
vice versa. If the target does not support native fcopysign,
expand_COPYSIGN will expand it as (fneg (fabs x)) anyway.
gcc/ChangeLog:
PR rtl-optimization/112483
* simplify-rtx.cc (simplify_binary_operation_1) <case COPYSIGN>:
Call simplify_unary_operation for NEG instead of
simplify_gen_unary.
More information about the Gcc-bugs
mailing list