https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68752
Carl Love <cel at us dot ibm.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |cel at us dot ibm.com --- Comment #2 from Carl Love <cel at us dot ibm.com> --- I investigated the issue using GCC 6.1. The t1() function from file recip-vec-sqrtf.c file is as follows: void t1(void) { int i; for (i = 0; i < 4; i++) r[i] = a[i] / sqrtf (b[i]); } The assembly code being generated for the loop using the options specified in the bug plus -S to generate the assembly code results in the following -O2 -ffast-math -ftree-vectorize -mcpu=power7 -mrecip -fno-common -S .file "recip-vec-sqrtf.c" .section ".toc","aw" .section ".text" .machine power7 .align 2 .p2align 4,,15 .globl t1 .section ".opd","aw" .align 3 t1: .quad .L.t1,.TOC.@tocbase .previous .type t1, @function .L.t1: addis 9,2,.LANCHOR0@toc@ha addis 10,2,.LC0@toc@ha addi 9,9,.LANCHOR0@toc@l addi 10,10,.LC0@toc@l lxvd2x 12,0,9 lxvd2x 11,0,10 li 10,32 lxvd2x 10,9,10 li 10,16 xvrsqrtesp 0,12 xvmsubasp 12,12,11 xvmulsp 9,0,0 xvnmsubasp 11,12,9 xvmulsp 0,0,11 xvmulsp 0,0,10 stxvd2x 0,9,10 blr The expected vector instructions are there. It does not appear that any scalar instructions are being generated for the computation as implied in the bugzilla. The other loops for the test cases in attachment 36938 are similar in that they appear to only be generating the expected vector instructions. The bugzilla was filed before GCC 6 was released. It appears the issue has since been fixed.