aboutsummaryrefslogtreecommitdiff
path: root/gcc/fold-const.c
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2011-07-08 14:08:17 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2011-07-08 14:08:17 +0000
commitb862187a34f58510107b5e77917774518ee95b69 (patch)
tree3773295f0e1d1cfd86ca9d237fad4752ea3c087a /gcc/fold-const.c
parente8e8c74b492f3e981e2c6dc8a87a896c2fb338e0 (diff)
downloadgcc-b862187a34f58510107b5e77917774518ee95b69.zip
gcc-b862187a34f58510107b5e77917774518ee95b69.tar.gz
gcc-b862187a34f58510107b5e77917774518ee95b69.tar.bz2
fold-const.c (fold_binary_loc): Remove index +p PTR -> PTR +p index folding.
2011-07-08 Richard Guenther <rguenther@suse.de> * fold-const.c (fold_binary_loc): Remove index +p PTR -> PTR +p index folding. From-SVN: r176044
Diffstat (limited to 'gcc/fold-const.c')
-rw-r--r--gcc/fold-const.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/gcc/fold-const.c b/gcc/fold-const.c
index 1b5683d..9640264 100644
--- a/gcc/fold-const.c
+++ b/gcc/fold-const.c
@@ -9575,13 +9575,6 @@ fold_binary_loc (location_t loc,
fold_convert_loc (loc, sizetype,
arg0)));
- /* index +p PTR -> PTR +p index */
- if (POINTER_TYPE_P (TREE_TYPE (arg1))
- && INTEGRAL_TYPE_P (TREE_TYPE (arg0)))
- return fold_build2_loc (loc, POINTER_PLUS_EXPR, type,
- fold_convert_loc (loc, type, arg1),
- fold_convert_loc (loc, sizetype, arg0));
-
/* (PTR +p B) +p A -> PTR +p (B + A) */
if (TREE_CODE (arg0) == POINTER_PLUS_EXPR)
{