Why doesn't GCC show vectorization information?

CodeBlocks is an IDE. It doesn't compile anything. GCC does. The -ftree-vectorizer-verbose used to work in previous versions. Now there's -fopt-info, which allows to retrieve information about optimizations (vectorization too); you can find the relevant documentation here.

It is even shown how to actually retrieve the vectorizer output to stderr: and this one:

gcc -O2 -ftree-vectorize -fopt-info-vec-missed 

prints information about missed optimization opportunities from vectorization passes on stderr. Note that -fopt-info-vec-missed is equivalent to -fopt-info-missed-vec.

You can change missed to e.g. optimized, all and so on as listed.

Tags:

C

Gcc