https://gcc.gnu.org/bugzilla/show_bug.cgi?id=49795
--- Comment #7 from Andrew Pinski ---
(In reply to vincenzo Innocente from comment #6)
loop1, loop2, and loop4 all vectorize now at -O3.
loop3 can vectorize with -O3 -fno-trapping-math (it can also be vectorize at
-O3 on x86_64 with -march=skyla
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49795
--- Comment #6 from vincenzo Innocente
2011-07-20 16:59:20 UTC ---
actually -ftree-loop-if-convert-stores does the "trick" with -Ofast
things are not fully consistent though
of these four loop I get the following
notice how the combination -ftr
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49795
Richard Guenther changed:
What|Removed |Added
Keywords||missed-optimization
Status
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49795
--- Comment #4 from Jakub Jelinek 2011-07-20
12:41:07 UTC ---
That is something different, yeah, in that case the transformation doesn't
introduce new data races and is desirable as well, not just for vectorization.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49795
--- Comment #3 from vincenzo Innocente
2011-07-20 12:32:21 UTC ---
my actual code looks more like this
void loop() {
for (int i=0; i!=N; ++i) {
d[i]=a[i]+b[i];
if (c[i]<0) d[i] = -d[i];
}
}
where d[i] IS written unconditionally (and d
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49795
--- Comment #2 from Paolo Carlini 2011-07-20
12:00:32 UTC ---
Interesting. Then I would be curious to know what other respected compilers vs
OpenMP do in this area, eg, Intel..
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49795
Jakub Jelinek changed:
What|Removed |Added
CC||jakub at gcc dot gnu.org
--- Comment #1 f