This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/43432] New: Missed vectorization: "complicated access pattern" for increasing and decreasing data indexing
- From: "spop at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Mar 2010 21:06:48 -0000
- Subject: [Bug tree-optimization/43432] New: Missed vectorization: "complicated access pattern" for increasing and decreasing data indexing
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
Both these loop kernels fail with:
gcc-4.5 -c vector_fmul_window.c -O3 -ffast-math -ftree-vectorizer-verbose=7
-msse2
[...]
vector_fmul_window.c:7: note: not vectorized: complicated access pattern.
They look similar in the fact that they use both an increasing and a decreasing
induction variables indexing data references.
void vector_fmul_reverse_c(float *dst, const float *src0, const float *src1,
int len){
int i;
src1 += len-1;
for(i=0; i<len; i++)
dst[i] = src0[i] * src1[-i];
}
void ff_vector_fmul_window_c(float *dst, const float *src0, const float *src1,
const float *win, float add_bias, int len)
{
int i,j;
dst += len;
win += len;
src0+= len;
for(i=-len, j=len-1; i<0; i++, j--) {
float s0 = src0[i];
float s1 = src1[j];
float wi = win[i];
float wj = win[j];
dst[i] = s0*wj - s1*wi + add_bias;
dst[j] = s0*wi + s1*wj + add_bias;
}
}
--
Summary: Missed vectorization: "complicated access pattern" for
increasing and decreasing data indexing
Product: gcc
Version: 4.5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: spop at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43432