diff options
author | Kazu Hirata <kazu@cs.umass.edu> | 2005-04-23 02:01:53 +0000 |
---|---|---|
committer | Kazu Hirata <kazu@gcc.gnu.org> | 2005-04-23 02:01:53 +0000 |
commit | 721425b6ada0661975ba11b6b4dfc83421150886 (patch) | |
tree | 4d5c798a9511b850de0000a74818df18ef340983 /gcc/fold-const.c | |
parent | 84d658141e6b1d315b0eba5f19a3c57a7c51fd3f (diff) | |
download | gcc-721425b6ada0661975ba11b6b4dfc83421150886.zip gcc-721425b6ada0661975ba11b6b4dfc83421150886.tar.gz gcc-721425b6ada0661975ba11b6b4dfc83421150886.tar.bz2 |
re PR tree-optimization/21088 (VRP passes fold the type of operands of a comparison)
PR tree-optimization/21088
* fold-const.c (fold_unary, fold_binary, fold_ternary):
Export.
* tree-vrp.c (compare_values): Use fold_binary to compare
pointers. Use boolean_type_node as the type of a comparison
expression being folded.
* tree.h: Add prototypes for fold_unary, fold_binary,
fold_ternary.
From-SVN: r98600
Diffstat (limited to 'gcc/fold-const.c')
-rw-r--r-- | gcc/fold-const.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/fold-const.c b/gcc/fold-const.c index af1af33..1327c74 100644 --- a/gcc/fold-const.c +++ b/gcc/fold-const.c @@ -6678,7 +6678,7 @@ fold_complex_div (tree type, tree ac, tree bc, enum tree_code code) OP0. Return the folded expression if folding is successful. Otherwise, return NULL_TREE. */ -static tree +tree fold_unary (enum tree_code code, tree type, tree op0) { tree tem; @@ -7113,7 +7113,7 @@ fold_unary (enum tree_code code, tree type, tree op0) OP0 and OP1. Return the folded expression if folding is successful. Otherwise, return NULL_TREE. */ -static tree +tree fold_binary (enum tree_code code, tree type, tree op0, tree op1) { tree t1 = NULL_TREE; @@ -9852,7 +9852,7 @@ fold_binary (enum tree_code code, tree type, tree op0, tree op1) OP0, OP1, and OP2. Return the folded expression if folding is successful. Otherwise, return NULL_TREE. */ -static tree +tree fold_ternary (enum tree_code code, tree type, tree op0, tree op1, tree op2) { tree tem; |