This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/59984] OpenMP and Cilk Plus SIMD pragma makes loop incorrect
- From: "izamyatin at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 06 Feb 2014 12:59:47 +0000
- Subject: [Bug c/59984] OpenMP and Cilk Plus SIMD pragma makes loop incorrect
- Auto-submitted: auto-generated
- References: <bug-59984-4 at http dot gcc dot gnu dot org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59984
--- Comment #3 from Igor Zamyatin <izamyatin at gmail dot com> ---
Vectorizer dump snippet for main:
foo.simdclone.0 (vect__12.7_3, vect_cst_.8_53, vect_cst_.8_53,
vect_cst_.9_51, vect_cst_.9_51);
GIMPLE_NOP
vect_v1.12_37 = MEM[(int *)vectp_v1.10_39]; (1)
v1.0_14 = v1;
vect_v2.16_60 = MEM[(int *)vectp_v2.14_58]; (2)
v2.1_15 = v2;
vect__16.18_63 = vect_cst_.13_7 * vect_cst_.17_62; <--- constants instead of
_16 = v1.0_14 * v2.1_15; vect_v1.12_37 and
MEM[(int *)vectp_a.19_65] = vect__16.18_63; vect_v2.16_60
Then DCE destroys (1) and (2) and later LIM hoists the multiplication away from
the loop.