Commit 8fca6de5 by Ira Rosen

re PR tree-optimization/30843 (ice for legal code with -ftree-vectorize -O2)

	PR tree-optimization/30843
	* tree-vect-transform.c (vect_transform_loop): Remove strided scalar
	stores only after all the group is vectorized.

From-SVN: r122225
parent e8020d1f
2007-02-22 Ira Rosen <irar@il.ibm.com>
PR tree-optimization/30843
* tree-vect-transform.c (vect_transform_loop): Remove strided scalar
stores only after all the group is vectorized.
2007-02-22 Dorit Nuzman <dorit@il.ibm.com>
PR tree-optimization/30858
......
2007-02-22 Dorit Nuzman <dorit@il.ibm.com>
Ira Rosen <irar@il.ibm.com>
PR tree-optimization/30843
* gcc.dg/vect/pr30843.c: New test.
2007-02-22 Dorit Nuzman <dorit@il.ibm.com>
PR tree-optimization/30858
* gcc.dg/vect/pr30858.c: New test.
/* { dg-do compile } */
/* { dg-require-effective-target vect_long } */
#include <stdarg.h>
#include "tree-vect.h"
#define N 16
void dacP98FillRGBMap (unsigned char *pBuffer)
{
unsigned long dw, dw1;
unsigned long *pdw = (unsigned long *)(pBuffer);
for( dw = 256, dw1 = 0; dw; dw--, dw1 += 0x01010101)
{
*pdw++ = dw1;
*pdw++ = dw1;
*pdw++ = dw1;
*pdw++ = dw1;
}
}
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { target { vect_interleave } } } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
......@@ -5059,7 +5059,7 @@ vect_transform_loop (loop_vec_info loop_vinfo)
struct loop *loop = LOOP_VINFO_LOOP (loop_vinfo);
basic_block *bbs = LOOP_VINFO_BBS (loop_vinfo);
int nbbs = loop->num_nodes;
block_stmt_iterator si;
block_stmt_iterator si, next_si;
int i;
tree ratio = NULL;
int vectorization_factor = LOOP_VINFO_VECT_FACTOR (loop_vinfo);
......@@ -5212,12 +5212,14 @@ vect_transform_loop (loop_vec_info loop_vinfo)
while (next)
{
next_si = bsi_for_stmt (next);
next_stmt_info = vinfo_for_stmt (next);
/* Free the attached stmt_vec_info and remove the stmt. */
ann = stmt_ann (next);
tmp = DR_GROUP_NEXT_DR (next_stmt_info);
free (next_stmt_info);
set_stmt_info (ann, NULL);
bsi_remove (&next_si, true);
next = tmp;
}
bsi_remove (&si, true);
......@@ -5233,16 +5235,6 @@ vect_transform_loop (loop_vec_info loop_vinfo)
continue;
}
}
else
{
if (strided_store)
{
/* This is case of skipped interleaved store. We don't free
its stmt_vec_info. */
bsi_remove (&si, true);
continue;
}
}
bsi_next (&si);
} /* stmts in BB */
} /* BBs in loop */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment