From 8c00ba08c614069a590c673fe20afe9a5f1f55fe Mon Sep 17 00:00:00 2001 From: Jiong Wang Date: Fri, 7 Nov 2014 11:08:30 +0000 Subject: [PATCH] [PATCH] PR63676, exit tree fold when node be TREE_CLOBBER_P gcc/ PR tree-optimization/63676 * gimple-fold.c (fold_gimple_assign): Do not fold node when TREE_CLOBBER_P be true. From-SVN: r217215 --- gcc/ChangeLog | 7 +++++++ gcc/gimple-fold.c | 3 +++ 2 files changed, 10 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 88b7422e7ee..7535286f915 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2014-11-07 Jiong Wang +2014-11-07 Richard Biener + + PR tree-optimization/63676 + * gimple-fold.c (fold_gimple_assign): Do not fold node when + TREE_CLOBBER_P be true. + 2014-11-07 Richard Biener PR middle-end/63770 diff --git a/gcc/gimple-fold.c b/gcc/gimple-fold.c index 547f9a75c36..71e46388d61 100644 --- a/gcc/gimple-fold.c +++ b/gcc/gimple-fold.c @@ -320,6 +320,9 @@ fold_gimple_assign (gimple_stmt_iterator *si) { tree rhs = gimple_assign_rhs1 (stmt); + if (TREE_CLOBBER_P (rhs)) + return NULL_TREE; + if (REFERENCE_CLASS_P (rhs)) return maybe_fold_reference (rhs, false); -- 2.30.2