re PR tree-optimization/32421 (-ftree-vectorize -msse2 ICEs in build2_stat when vectorizing POINTER_PLUS_EXPR)
2007-06-25 Andrew Pinski <andrew_pinski@playstation.sony.com> PR tree-opt/32421 * tree-vect-transform.c (vectorizable_operation): Convert POINTER_PLUS_EXPR over to PLUS_EXPR. 2007-06-25 Andrew Pinski <andrew_pinski@playstation.sony.com> PR tree-opt/32421 * gcc.dg/vect/pr32421.c: New test. From-SVN: r126012
This commit is contained in:
parent
20ec6b5150
commit
2caf766b63
4 changed files with 29 additions and 0 deletions
|
@ -1,3 +1,9 @@
|
|||
2007-06-25 Andrew Pinski <andrew_pinski@playstation.sony.com>
|
||||
|
||||
PR tree-opt/32421
|
||||
* tree-vect-transform.c (vectorizable_operation): Convert
|
||||
POINTER_PLUS_EXPR over to PLUS_EXPR.
|
||||
|
||||
2007-06-25 Chao-ying Fu <fu@mips.com>
|
||||
|
||||
* doc/rtl.texi (Machine Modes): Document QQ, HQ, SQ, DQ, TQ,
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2007-06-25 Andrew Pinski <andrew_pinski@playstation.sony.com>
|
||||
|
||||
PR tree-opt/32421
|
||||
* gcc.dg/vect/pr32421.c: New test.
|
||||
|
||||
2006-06-26 Simon Martin <simartin@users.sourceforge.net>
|
||||
|
||||
PR c++/32111
|
||||
|
|
12
gcc/testsuite/gcc.dg/vect/pr32421.c
Normal file
12
gcc/testsuite/gcc.dg/vect/pr32421.c
Normal file
|
@ -0,0 +1,12 @@
|
|||
/* { dg-do compile } */
|
||||
|
||||
|
||||
int f(int **__restrict a, int ** __restrict b)
|
||||
{
|
||||
int i;
|
||||
for(i= 0;i<32;i++)
|
||||
a[i] = b[i] + 1;
|
||||
}
|
||||
|
||||
/* { dg-final { cleanup-tree-dump "vect" } } */
|
||||
|
|
@ -2968,6 +2968,12 @@ vectorizable_operation (tree stmt, block_stmt_iterator *bsi, tree *vec_stmt)
|
|||
|
||||
operation = GIMPLE_STMT_OPERAND (stmt, 1);
|
||||
code = TREE_CODE (operation);
|
||||
|
||||
/* For pointer addition, we should use the normal plus for
|
||||
the vector addition. */
|
||||
if (code == POINTER_PLUS_EXPR)
|
||||
code = PLUS_EXPR;
|
||||
|
||||
optab = optab_for_tree_code (code, vectype);
|
||||
|
||||
/* Support only unary or binary operations. */
|
||||
|
|
Loading…
Add table
Reference in a new issue