[gcc(refs/users/marxin/heads/loop-unswitch-improvement-v4)] Fix me.

Martin Liska marxin@gcc.gnu.org
Wed Dec 1 14:12:57 GMT 2021


https://gcc.gnu.org/g:8c4a79ac39b4367d3449f2920bd94b4227c24811

commit 8c4a79ac39b4367d3449f2920bd94b4227c24811
Author: Martin Liska <mliska@suse.cz>
Date:   Wed Dec 1 15:03:19 2021 +0100

    Fix me.

Diff:
---
 gcc/tree-ssa-loop-unswitch.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/gcc/tree-ssa-loop-unswitch.c b/gcc/tree-ssa-loop-unswitch.c
index f7660a1f9ac..6ffa0c31eeb 100644
--- a/gcc/tree-ssa-loop-unswitch.c
+++ b/gcc/tree-ssa-loop-unswitch.c
@@ -385,7 +385,10 @@ find_range_for_lhs (predicate_vector &predicate_path, tree lhs,
       bool true_edge = predicate_path[i].second;
 
       if (operand_equal_p (predicate->lhs, lhs, 0))
-	range = true_edge ? predicate->true_range : predicate->false_range;
+	{
+	  range = true_edge ? predicate->true_range : predicate->false_range;
+	  return;
+	}
     }
 }


More information about the Gcc-cvs mailing list