From a02f0c5dfa9246a57970aeefe5c7196a17bf7b1c Mon Sep 17 00:00:00 2001 From: Richard Guenther Date: Tue, 15 May 2012 09:20:37 +0000 Subject: [PATCH] gimple.c (gimple_set_modified): Move ... 2012-05-15 Richard Guenther * gimple.c (gimple_set_modified): Move ... * gimple.h (gimple_set_modified): ... here. From-SVN: r187503 --- gcc/ChangeLog | 5 +++++ gcc/gimple.c | 11 ----------- gcc/gimple.h | 12 +++++++++++- 3 files changed, 16 insertions(+), 12 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9b7d499d71e..ba4cd854f5a 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2012-05-15 Richard Guenther + + * gimple.c (gimple_set_modified): Move ... + * gimple.h (gimple_set_modified): ... here. + 2012-05-15 Tristan Gingold * ira-color.c (move_spill_restore): Add a guard. diff --git a/gcc/gimple.c b/gcc/gimple.c index 79da12cde51..4fc836236ff 100644 --- a/gcc/gimple.c +++ b/gcc/gimple.c @@ -2394,17 +2394,6 @@ gimple_copy (gimple stmt) } -/* Set the MODIFIED flag to MODIFIEDP, iff the gimple statement G has - a MODIFIED field. */ - -void -gimple_set_modified (gimple s, bool modifiedp) -{ - if (gimple_has_ops (s)) - s->gsbase.modified = (unsigned) modifiedp; -} - - /* Return true if statement S has side-effects. We consider a statement to have side effects if: diff --git a/gcc/gimple.h b/gcc/gimple.h index 80271a1e358..2b10f1a9b14 100644 --- a/gcc/gimple.h +++ b/gcc/gimple.h @@ -830,7 +830,6 @@ tree gimple_get_lhs (const_gimple); void gimple_set_lhs (gimple, tree); void gimple_replace_lhs (gimple, tree); gimple gimple_copy (gimple); -void gimple_set_modified (gimple, bool); void gimple_cond_get_ops_from_tree (tree, enum tree_code *, tree *, tree *); gimple gimple_build_cond_from_tree (tree, tree, tree); void gimple_cond_set_condition_from_tree (gimple, tree); @@ -1521,6 +1520,17 @@ gimple_modified_p (const_gimple g) } +/* Set the MODIFIED flag to MODIFIEDP, iff the gimple statement G has + a MODIFIED field. */ + +static inline void +gimple_set_modified (gimple s, bool modifiedp) +{ + if (gimple_has_ops (s)) + s->gsbase.modified = (unsigned) modifiedp; +} + + /* Return the tree code for the expression computed by STMT. This is only valid for GIMPLE_COND, GIMPLE_CALL and GIMPLE_ASSIGN. For GIMPLE_CALL, return CALL_EXPR as the expression code for -- 2.30.2