diff options
author | Jakub Jelinek <jakub@redhat.com> | 2008-08-12 20:05:43 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2008-08-12 20:05:43 +0200 |
commit | c0285905394bb04acd7650f5ac1079c798ed1487 (patch) | |
tree | dadd521bd788faebcdfbb1b321ea56646b6b71d0 /gcc/expr.c | |
parent | 4c29307df9fef2001418b25babd1018a12d8687b (diff) | |
download | gcc-c0285905394bb04acd7650f5ac1079c798ed1487.tar.gz |
re PR middle-end/37014 (internal compiler error: in expand_expr_real_1, at expr.c:8760)
PR middle-end/37014
* expr.c (expand_expr_real_1): Handle TRUTH_ANDIF_EXPR
and TRUTH_ORIF_EXPR.
* dojump.c (do_jump): Likewise.
* gcc.c-torture/compile/20080812-1.c: New test.
From-SVN: r139029
Diffstat (limited to 'gcc/expr.c')
-rw-r--r-- | gcc/expr.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/gcc/expr.c b/gcc/expr.c index 109ddebe5dc..e61dc616165 100644 --- a/gcc/expr.c +++ b/gcc/expr.c @@ -1,6 +1,6 @@ /* Convert tree expression to rtl instructions, for GNU compiler. Copyright (C) 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, - 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 + 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This file is part of GCC. @@ -8970,7 +8970,10 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode, /* If no set-flag instruction, must generate a conditional store into a temporary variable. Drop through and handle this like && and ||. */ - + /* Although TRUTH_{AND,OR}IF_EXPR aren't present in GIMPLE, they + are occassionally created by folding during expansion. */ + case TRUTH_ANDIF_EXPR: + case TRUTH_ORIF_EXPR: if (! ignore && (target == 0 || modifier == EXPAND_STACK_PARM @@ -9170,8 +9173,6 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode, case POSTDECREMENT_EXPR: case LOOP_EXPR: case EXIT_EXPR: - case TRUTH_ANDIF_EXPR: - case TRUTH_ORIF_EXPR: /* Lowered by gimplify.c. */ gcc_unreachable (); |