diff options
author | Eric Christopher <echristo@gcc.gnu.org> | 2004-08-19 21:34:37 +0000 |
---|---|---|
committer | Eric Christopher <echristo@gcc.gnu.org> | 2004-08-19 21:34:37 +0000 |
commit | 19114537c55ae227cf8b295be3e2c924965cdb18 (patch) | |
tree | 88aec2ccf229fd9ceeed5fc48cb4d5e3f6b7c217 /gcc/tree.c | |
parent | b85058289589ba4346f6881b5f0cba0410299fc0 (diff) | |
download | gcc-19114537c55ae227cf8b295be3e2c924965cdb18.zip gcc-19114537c55ae227cf8b295be3e2c924965cdb18.tar.gz gcc-19114537c55ae227cf8b295be3e2c924965cdb18.tar.bz2 |
langhooks-def.h (LANG_HOOKS_UNSAVE_EXPR_NOW): Remove.
2004-08-19 Eric Christopher <echristo@redhat.com>
* langhooks-def.h (LANG_HOOKS_UNSAVE_EXPR_NOW): Remove.
* langhooks.h (unsave_expr_now): Ditto.
* tree.h (unsave_expr_1): Remove prototype.
(lhd_unsave_expr_now): Rename to unsave_expr_now.
* tree-inline.c (unsave_expr_1): Move here
from tree.c. Make static.
(unsave_expr_now): Rename from lhd_unsave_expr_now.
* tree-sra.c: Fix up for rename.
* tree-ssa-copy.c: Ditto.
* tree-eh.c: Ditto.
* tree.c (unsave_expr_1): Move to tree-inline.c.
2004-08-19 Eric Christopher <echristo@redhat.com>
* cp-tree.h (cxx_unsave_expr_now): Delete prototype.
* tree.c (cxx_unsave_expr_now): Delete.
(cp_unsave_r): Ditto.
From-SVN: r86277
Diffstat (limited to 'gcc/tree.c')
-rw-r--r-- | gcc/tree.c | 39 |
1 files changed, 7 insertions, 32 deletions
@@ -433,7 +433,7 @@ build_int_cst (tree type, unsigned HOST_WIDE_INT low, HOST_WIDE_INT hi) if (!type) type = integer_type_node; - + switch (TREE_CODE (type)) { case POINTER_TYPE: @@ -445,14 +445,14 @@ build_int_cst (tree type, unsigned HOST_WIDE_INT low, HOST_WIDE_INT hi) ix = 0; } break; - + case BOOLEAN_TYPE: /* Cache false or true. */ limit = 2; if (!hi && low < 2) ix = low; break; - + case INTEGER_TYPE: case CHAR_TYPE: case OFFSET_TYPE: @@ -476,7 +476,7 @@ build_int_cst (tree type, unsigned HOST_WIDE_INT low, HOST_WIDE_INT hi) default: break; } - + if (ix >= 0) { if (!TYPE_CACHED_VALUES_P (type)) @@ -484,7 +484,7 @@ build_int_cst (tree type, unsigned HOST_WIDE_INT low, HOST_WIDE_INT hi) TYPE_CACHED_VALUES_P (type) = 1; TYPE_CACHED_VALUES (type) = make_tree_vec (limit); } - + t = TREE_VEC_ELT (TYPE_CACHED_VALUES (type), ix); if (t) { @@ -496,7 +496,7 @@ build_int_cst (tree type, unsigned HOST_WIDE_INT low, HOST_WIDE_INT hi) return t; } } - + t = make_node (INTEGER_CST); TREE_INT_CST_LOW (t) = low; @@ -505,7 +505,7 @@ build_int_cst (tree type, unsigned HOST_WIDE_INT low, HOST_WIDE_INT hi) if (ix >= 0) TREE_VEC_ELT (TYPE_CACHED_VALUES (type), ix) = t; - + return t; } @@ -1564,31 +1564,6 @@ tree_node_structure (tree t) abort (); } } - -/* Perform any modifications to EXPR required when it is unsaved. Does - not recurse into EXPR's subtrees. */ - -void -unsave_expr_1 (tree expr) -{ - switch (TREE_CODE (expr)) - { - case TARGET_EXPR: - /* Don't mess with a TARGET_EXPR that hasn't been expanded. - It's OK for this to happen if it was part of a subtree that - isn't immediately expanded, such as operand 2 of another - TARGET_EXPR. */ - if (TREE_OPERAND (expr, 1)) - break; - - TREE_OPERAND (expr, 1) = TREE_OPERAND (expr, 3); - TREE_OPERAND (expr, 3) = NULL_TREE; - break; - - default: - break; - } -} /* Return 1 if EXP contains a PLACEHOLDER_EXPR; i.e., if it represents a size or offset that depends on a field within a record. */ |