aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-copy.c
diff options
context:
space:
mode:
authorRichard Biener <rguenther@suse.de>2018-10-23 09:36:13 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2018-10-23 09:36:13 +0000
commitb1a5c719518cffabfcd81a87518d0c82ee40a3da (patch)
tree20e26e91eaaa5c60a02ad4902f94e936207c7991 /gcc/tree-ssa-copy.c
parent20e363e4927ac76d314bd511bc726eb71d65d70f (diff)
downloadgcc-b1a5c719518cffabfcd81a87518d0c82ee40a3da.zip
gcc-b1a5c719518cffabfcd81a87518d0c82ee40a3da.tar.gz
gcc-b1a5c719518cffabfcd81a87518d0c82ee40a3da.tar.bz2
re PR tree-optimization/87700 (Compile time hog w/ -O1)
2018-10-23 Richard Biener <rguenther@suse.de> PR tree-optimization/87700 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic. * gcc.dg/torture/pr87700.c: New testcase. From-SVN: r265418
Diffstat (limited to 'gcc/tree-ssa-copy.c')
-rw-r--r--gcc/tree-ssa-copy.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/tree-ssa-copy.c b/gcc/tree-ssa-copy.c
index 0c667da..b526758 100644
--- a/gcc/tree-ssa-copy.c
+++ b/gcc/tree-ssa-copy.c
@@ -155,7 +155,7 @@ set_copy_of_val (tree var, tree val)
copy_of[ver].value = val;
if (old != val
- || (val && !operand_equal_p (old, val, 0)))
+ && (!old || !operand_equal_p (old, val, 0)))
return true;
return false;