#pragma novector


The #pragma novector directive instructs the compiler to not auto-vectorize the loop immediately following this directive.


Read syntax diagramSkip visual syntax diagram>>-#--pragma--novector-----------------------------------------><


This directive has effect only on architectures that support Vectorization and when used with -qhot=vector option. With -qhot=vector in effect, the compiler will convert certain operations that are performed in a loop on successive elements of an array (for example, square root, reciprocal square root) into a call to a vector library routine (MASS libraries). This call will calculate several results at one time, which is faster than calculating each result sequentially.

The #pragma novector directive applies only to DO, WHILE, and FOR loops.

The #pragma novector directive applies only to the loops immediately following it. The directive has no effect on other loops that may be nested within the specified loop.

You can use #pragma novector directive can be mixed with loop optimization, and SMP directives without requiring any specific optimization level.


#pragma novector
for (i=1; i<1000; i++) {
    /* program code */


Related information