https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88464
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |missed-optimization Status|UNCONFIRMED |NEW Last reconfirmed| |2018-12-12 CC| |jakub at gcc dot gnu.org, | |rguenth at gcc dot gnu.org Component|c |tree-optimization Blocks| |53947 Ever confirmed|0 |1 Known to fail| |9.0 --- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> --- Confirmed. The issue here is the target doesn't advertise scatter: 3901 if (targetm.vectorize.builtin_scatter) (gdb) n 3902 decl = targetm.vectorize.builtin_scatter (vectype, offtype, scale); (gdb) 3905 if (!decl) (gdb) p decl $5 = (tree) 0x0 (gdb) p decl $5 = (tree) 0x0 (gdb) p debug_generic_expr (vectype) vector(4) double $6 = void (gdb) p debug_generic_expr (offtype) int $7 = void (gdb) p scale $8 = 8 probably because of the "mixup" of 4-byte index and 8 byte store element type. I'm not sure whether Jakub implemented widening of the index at all. OTOH when using long for idx it doesn't help. Using -march=knl we get a little bit further but ultimately fail the same way. Referenced Bugs: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=53947 [Bug 53947] [meta-bug] vectorizer missed-optimizations