[Bug c/54103] ICE at gimplify.c:7790 on current trunk
jsm28 at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri Sep 14 16:59:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54103
--- Comment #1 from Joseph S. Myers <jsm28 at gcc dot gnu.org> 2012-09-14 16:59:21 UTC ---
Author: jsm28
Date: Fri Sep 14 16:59:10 2012
New Revision: 191304
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=191304
Log:
c:
PR c/54103
* c-typeck.c (build_unary_op): Pass original argument of
TRUTH_NOT_EXPR to c_objc_common_truthvalue_conversion, then remove
any C_MAYBE_CONST_EXPR, if it has integer operands.
(build_binary_op): Pass original arguments of TRUTH_ANDIF_EXPR,
TRUTH_ORIF_EXPR, TRUTH_AND_EXPR, TRUTH_OR_EXPR and TRUTH_XOR_EXPR
to c_objc_common_truthvalue_conversion, then remove any
C_MAYBE_CONST_EXPR, if they have integer operands. Use
c_objc_common_truthvalue_conversion not
c_common_truthvalue_conversion.
(c_objc_common_truthvalue_conversion): Build NE_EXPR directly and
call note_integer_operands for arguments with integer operands
that are not integer constants.
testsuite:
* gcc.c-torture/compile/pr54103-1.c,
gcc.c-torture/compile/pr54103-2.c,
gcc.c-torture/compile/pr54103-3.c,
gcc.c-torture/compile/pr54103-4.c,
gcc.c-torture/compile/pr54103-5.c,
gcc.c-torture/compile/pr54103-6.c: New tests.
* gcc.dg/c90-const-expr-8.c: Update expected column number.
Added:
trunk/gcc/testsuite/gcc.c-torture/compile/pr54103-1.c
trunk/gcc/testsuite/gcc.c-torture/compile/pr54103-2.c
trunk/gcc/testsuite/gcc.c-torture/compile/pr54103-3.c
trunk/gcc/testsuite/gcc.c-torture/compile/pr54103-4.c
trunk/gcc/testsuite/gcc.c-torture/compile/pr54103-5.c
trunk/gcc/testsuite/gcc.c-torture/compile/pr54103-6.c
Modified:
trunk/gcc/c/ChangeLog
trunk/gcc/c/c-typeck.c
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/gcc.dg/c90-const-expr-8.c
More information about the Gcc-bugs
mailing list