summaryrefslogtreecommitdiffstats
path: root/contrib/gcc/fold-const.c
diff options
context:
space:
mode:
authormm <mm@FreeBSD.org>2011-03-29 20:53:51 +0000
committermm <mm@FreeBSD.org>2011-03-29 20:53:51 +0000
commit24a0f968ca05de3f4d12a803e9141af94f6d0aee (patch)
tree8dd18f9d0a6d8b9d0b38d505e33d37244cd1c655 /contrib/gcc/fold-const.c
parent9d571f70778884c98026689ff71368ffa7c1cb9d (diff)
downloadFreeBSD-src-24a0f968ca05de3f4d12a803e9141af94f6d0aee.zip
FreeBSD-src-24a0f968ca05de3f4d12a803e9141af94f6d0aee.tar.gz
Upgrade of base gcc and libstdc++ to the last GPLv2-licensed revision
(rev. 127959 of gcc-4_2-branch). Resolved GCC bugs: c++: 17763, 29365, 30535, 30917, 31337, 31941, 32108, 32112, 32346, 32898, 32992 debug: 32610, 32914 libstdc++: 33084, 33128 middle-end: 32563 rtl-optimization: 33148 tree-optimization: 25413, 32723 target: 32218 Tested by: pointyhat (miwi) Obtained from: gcc (gcc-4_2-branch up to rev. 127959) PR: gnu/153298, gnu/153959, gnu/154385 MFC after: 1 month
Diffstat (limited to 'contrib/gcc/fold-const.c')
-rw-r--r--contrib/gcc/fold-const.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/gcc/fold-const.c b/contrib/gcc/fold-const.c
index ea16eae..0753caa 100644
--- a/contrib/gcc/fold-const.c
+++ b/contrib/gcc/fold-const.c
@@ -9387,6 +9387,7 @@ fold_binary (enum tree_code code, tree type, tree op0, tree op1)
/* ~X | X is -1. */
if (TREE_CODE (arg0) == BIT_NOT_EXPR
+ && INTEGRAL_TYPE_P (TREE_TYPE (arg1))
&& operand_equal_p (TREE_OPERAND (arg0, 0), arg1, 0))
{
t1 = build_int_cst (type, -1);
@@ -9396,6 +9397,7 @@ fold_binary (enum tree_code code, tree type, tree op0, tree op1)
/* X | ~X is -1. */
if (TREE_CODE (arg1) == BIT_NOT_EXPR
+ && INTEGRAL_TYPE_P (TREE_TYPE (arg0))
&& operand_equal_p (arg0, TREE_OPERAND (arg1, 0), 0))
{
t1 = build_int_cst (type, -1);
@@ -9503,6 +9505,7 @@ fold_binary (enum tree_code code, tree type, tree op0, tree op1)
/* ~X ^ X is -1. */
if (TREE_CODE (arg0) == BIT_NOT_EXPR
+ && INTEGRAL_TYPE_P (TREE_TYPE (arg1))
&& operand_equal_p (TREE_OPERAND (arg0, 0), arg1, 0))
{
t1 = build_int_cst (type, -1);
@@ -9512,6 +9515,7 @@ fold_binary (enum tree_code code, tree type, tree op0, tree op1)
/* X ^ ~X is -1. */
if (TREE_CODE (arg1) == BIT_NOT_EXPR
+ && INTEGRAL_TYPE_P (TREE_TYPE (arg0))
&& operand_equal_p (arg0, TREE_OPERAND (arg1, 0), 0))
{
t1 = build_int_cst (type, -1);
OpenPOWER on IntegriCloud