The recent PFA early-break vectorization fix left us with a POINTER_PLUS
and non-sizetype offset.
Bootstrapped on x86_64-unknown-linux-gnu, testing in progress. I'll
push to trunk and branch.
PR tree-optimization/119858
* tree-vect-loop.cc (vectorizable_live_operation): Convert
pointer offset to sizetype.
---
gcc/tree-vect-loop.cc | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/gcc/tree-vect-loop.cc b/gcc/tree-vect-loop.cc
index 958b829fa8d..2d35fa12886 100644
--- a/gcc/tree-vect-loop.cc
+++ b/gcc/tree-vect-loop.cc
@@ -11657,8 +11657,12 @@ vectorizable_live_operation (vec_info *vinfo,
stmt_vec_info stmt_info,
break_lhs_phi);
if (POINTER_TYPE_P (TREE_TYPE (new_tree)))
- tmp2 = gimple_build (&iv_stmts, POINTER_PLUS_EXPR,
- TREE_TYPE (new_tree), new_tree, tmp2);
+ {
+ tmp2 = gimple_convert (&iv_stmts, sizetype, tmp2);
+ tmp2 = gimple_build (&iv_stmts, POINTER_PLUS_EXPR,
+ TREE_TYPE (new_tree), new_tree,
+ tmp2);
+ }
else
{
tmp2 = gimple_convert (&iv_stmts, TREE_TYPE (new_tree),
--
2.43.0