diff options
author | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-12-04 12:54:49 +0000 |
---|---|---|
committer | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-12-04 12:54:49 +0000 |
commit | bdff91a14bf8e5d18b1eb47bb529894482065762 (patch) | |
tree | 4515b21fe5d3e25b4d5c8f907d3e78834e1e40ac /gcc/gimple.c | |
parent | 0158370253d4aef042c4d67b2c0278ded58d83fd (diff) | |
parent | 8192796762b4781de57ce2a6c104a71dcbd874e3 (diff) | |
download | gcc-bdff91a14bf8e5d18b1eb47bb529894482065762.tar.gz |
Merge with trunk.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/wide-int@205668 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/gimple.c')
-rw-r--r-- | gcc/gimple.c | 67 |
1 files changed, 10 insertions, 57 deletions
diff --git a/gcc/gimple.c b/gcc/gimple.c index 25f1296a36d..e9e38785cc2 100644 --- a/gcc/gimple.c +++ b/gcc/gimple.c @@ -28,9 +28,13 @@ along with GCC; see the file COPYING3. If not see #include "calls.h" #include "stmt.h" #include "stor-layout.h" -#include "ggc.h" #include "hard-reg-set.h" #include "basic-block.h" +#include "tree-ssa-alias.h" +#include "internal-fn.h" +#include "tree-eh.h" +#include "gimple-expr.h" +#include "is-a.h" #include "gimple.h" #include "gimple-iterator.h" #include "gimple-walk.h" @@ -176,7 +180,7 @@ gimple_build_with_ops_stat (enum gimple_code code, unsigned subcode, gimple gimple_build_return (tree retval) { - gimple s = gimple_build_with_ops (GIMPLE_RETURN, ERROR_MARK, 2); + gimple s = gimple_build_with_ops (GIMPLE_RETURN, ERROR_MARK, 1); if (retval) gimple_return_set_retval (s, retval); return s; @@ -697,8 +701,8 @@ gimple_build_wce (gimple_seq cleanup) gimple gimple_build_resx (int region) { - gimple_statement_eh_ctrl *p = - as_a <gimple_statement_eh_ctrl> ( + gimple_statement_resx *p = + as_a <gimple_statement_resx> ( gimple_build_with_ops (GIMPLE_RESX, ERROR_MARK, 0)); p->region = region; return p; @@ -747,8 +751,8 @@ gimple_build_switch (tree index, tree default_label, vec<tree> args) gimple gimple_build_eh_dispatch (int region) { - gimple_statement_eh_ctrl *p = - as_a <gimple_statement_eh_ctrl> ( + gimple_statement_eh_dispatch *p = + as_a <gimple_statement_eh_dispatch> ( gimple_build_with_ops (GIMPLE_EH_DISPATCH, ERROR_MARK, 0)); p->region = region; return p; @@ -1950,57 +1954,6 @@ const unsigned char gimple_rhs_class_table[] = { #undef DEFTREECODE #undef END_OF_BASE_TREE_CODES -void -recalculate_side_effects (tree t) -{ - enum tree_code code = TREE_CODE (t); - int len = TREE_OPERAND_LENGTH (t); - int i; - - switch (TREE_CODE_CLASS (code)) - { - case tcc_expression: - switch (code) - { - case INIT_EXPR: - case MODIFY_EXPR: - case VA_ARG_EXPR: - case PREDECREMENT_EXPR: - case PREINCREMENT_EXPR: - case POSTDECREMENT_EXPR: - case POSTINCREMENT_EXPR: - /* All of these have side-effects, no matter what their - operands are. */ - return; - - default: - break; - } - /* Fall through. */ - - case tcc_comparison: /* a comparison expression */ - case tcc_unary: /* a unary arithmetic expression */ - case tcc_binary: /* a binary arithmetic expression */ - case tcc_reference: /* a reference */ - case tcc_vl_exp: /* a function call */ - TREE_SIDE_EFFECTS (t) = TREE_THIS_VOLATILE (t); - for (i = 0; i < len; ++i) - { - tree op = TREE_OPERAND (t, i); - if (op && TREE_SIDE_EFFECTS (op)) - TREE_SIDE_EFFECTS (t) = 1; - } - break; - - case tcc_constant: - /* No side-effects. */ - return; - - default: - gcc_unreachable (); - } -} - /* Canonicalize a tree T for use in a COND_EXPR as conditional. Returns a canonicalized tree that is valid for a COND_EXPR or NULL_TREE, if we failed to create one. */ |