aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-if-conv.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2015-05-29 15:06:23 +0200
committerJakub Jelinek <jakub@gcc.gnu.org>2015-05-29 15:06:23 +0200
commit2395a8ea086886c24090f1c9e9dde2515dc2fda8 (patch)
treec894b409080257241f8d72971627df9474722fca /gcc/tree-if-conv.c
parent52fc6859fe39a811a2a5ca81813e27cf1800b9c2 (diff)
downloadgcc-2395a8ea086886c24090f1c9e9dde2515dc2fda8.zip
gcc-2395a8ea086886c24090f1c9e9dde2515dc2fda8.tar.gz
gcc-2395a8ea086886c24090f1c9e9dde2515dc2fda8.tar.bz2
re PR tree-optimization/66142 (Loop is not vectorized because not sufficient support for GOMP_SIMD_LANE)
PR tree-optimization/66142 * tree-if-conv.c (if_convertible_phi_p): Don't give up on virtual phis that feed themselves. * gcc.dg/vect/pr66142.c: New test. From-SVN: r223863
Diffstat (limited to 'gcc/tree-if-conv.c')
-rw-r--r--gcc/tree-if-conv.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/tree-if-conv.c b/gcc/tree-if-conv.c
index a85c7a2..28e1c47 100644
--- a/gcc/tree-if-conv.c
+++ b/gcc/tree-if-conv.c
@@ -594,7 +594,8 @@ if_convertible_phi_p (struct loop *loop, basic_block bb, gphi *phi,
FOR_EACH_IMM_USE_FAST (use_p, imm_iter, gimple_phi_result (phi))
{
- if (gimple_code (USE_STMT (use_p)) == GIMPLE_PHI)
+ if (gimple_code (USE_STMT (use_p)) == GIMPLE_PHI
+ && USE_STMT (use_p) != (gimple) phi)
{
if (dump_file && (dump_flags & TDF_DETAILS))
fprintf (dump_file, "Difficult to handle this virtual phi.\n");