Small fix for a bootstrap-O3 ICE. Sorry this one slipped me and my O2 bootstrap
by.
Bootstrapped at O2, O3, and O3+LTO on aarch64, armhf, and x86_64
Pushing as obvious.
KR,
Alfie
-- >8 --
gcc/ChangeLog:
* tree-vect-loop-manip.cc (vect_set_loop_condition_normal):
Check if loop_vinfo is null before dereference.
---
gcc/tree-vect-loop-manip.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/tree-vect-loop-manip.cc b/gcc/tree-vect-loop-manip.cc
index ff90a21c8dd..ec9dec1b713 100644
--- a/gcc/tree-vect-loop-manip.cc
+++ b/gcc/tree-vect-loop-manip.cc
@@ -1355,7 +1355,7 @@ vect_set_loop_condition_normal (loop_vec_info loop_vinfo,
edge exit_edge,
create_iv (init, PLUS_EXPR, step, NULL_TREE, loop,
&incr_gsi, insert_after,
&indx_before_incr, &indx_after_incr,
- LOOP_VINFO_IV_INCREMENT_INVARIANT_P (loop_vinfo));
+ !loop_vinfo || LOOP_VINFO_IV_INCREMENT_INVARIANT_P (loop_vinfo));
indx_after_incr = force_gimple_operand_gsi (&loop_cond_gsi, indx_after_incr,
true, NULL_TREE, true,
--
2.34.1