[Bug rtl-optimization/78546] [6/7 Regression] wrong code at -O2 and above
jakub at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Nov 28 19:20:00 GMT 2016
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78546
--- Comment #16 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Author: jakub
Date: Mon Nov 28 19:15:51 2016
New Revision: 242929
URL: https://gcc.gnu.org/viewcvs?rev=242929&root=gcc&view=rev
Log:
PR rtl-optimization/78546
* simplify-rtx.c (neg_const_int): When negating most negative
number in mode wider than HOST_BITS_PER_WIDE_INT, use
simplify_const_unary_operation to produce CONST_DOUBLE or
CONST_WIDE_INT.
(simplify_plus_minus): Hanlde the case where neg_const_int
doesn't return a CONST_INT.
* gcc.dg/torture/pr78546-1.c: New test.
* gcc.dg/torture/pr78546-2.c: New test.
Added:
trunk/gcc/testsuite/gcc.dg/torture/pr78546-1.c
trunk/gcc/testsuite/gcc.dg/torture/pr78546-2.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/simplify-rtx.c
trunk/gcc/testsuite/ChangeLog
More information about the Gcc-bugs
mailing list