https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65206
Bug ID: 65206 Summary: Vectorized version of loop is removed. Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: ysrumyan at gmail dot com I noticed that vectorized version of loop is deleted although compiler reports that it was successfully vectorized: t1.c:7:3: note: LOOP VECTORIZED but after we can see in vect-dump: Removing basic block 4 basic block 4, loop depth 1 pred: 45 # i_16 = PHI <i_73(45)> # ivtmp_15 = PHI <ivtmp_76(45)> # vectp_a1.11_116 = PHI <vectp_a1.12_114(45)> # vectp_a2.19_125 = PHI <vectp_a2.20_123(45)> # vectp_a3.22_130 = PHI <vectp_a3.23_128(45)> # vectp_a1.25_136 = PHI <vectp_a1.26_134(45)> # vectp_a3.34_147 = PHI <vectp_a3.35_145(45)> # ivtmp_38 = PHI <0(45)> vect__5.13_118 = MEM[(float *)vectp_a1.11_116]; _5 = a1[i_16]; _31 = &a2[i_16]; vect__ifc__32.14_122 = VEC_COND_EXPR <vect__5.13_118 >= vect_cst_.15_119, vect_cst_.16_120, vect_cst_.17_121>; _ifc__32 = _5 >= x_6(D) ? 4294967295 : 0; vect__7.18_127 = MASK_LOAD (vectp_a2.19_125, 0B, vect__ifc__32.14_122); _7 = 0.0; _33 = &a3[i_16]; vect__8.21_132 = MASK_LOAD (vectp_a3.22_130, 0B, vect__ifc__32.14_122); _8 = 0.0; vect__9.24_133 = vect__7.18_127 + vect__8.21_132; _9 = _7 + _8; _34 = &a1[i_16]; MASK_STORE (vectp_a1.25_136, 0B, vect__ifc__32.14_122, vect__9.24_133); vect__11.27_140 = vect_cst_.28_37 + vect_cst_.29_139; _11 = x_6(D) + 1.0e+0; _35 = &a3[i_16]; vect__ifc__36.30_144 = VEC_COND_EXPR <vect__5.13_118 >= vect_cst_.31_141, vect_cst_.32_142, vect_cst_.33_143>; _ifc__36 = _5 >= x_6(D) ? 0 : 4294967295; ... Test and compile options will be attached.