Using high-order loop analysis and transformations

High-order transformations are optimizations that specifically improve the performance of loops through techniques such as interchange, fusion, and unrolling. The goals of these loop optimizations include:

To enable high-order loop analysis and transformations, you use the -qhot option. The following table lists the suboptions available for -qhot.

Table 10. -qhot suboptions

suboption Behavior
vector Instructs the compiler to transform some loops to use optimized versions of various trigonometric functions and operations such as reciprocal and square root that reside in a built-in library, rather than use the standard versions. The optimized versions make different trade-offs with respect to precision versus performance. This suboption is enabled by default when you use -qhot, -O4, or -O5.
novector Instructs the compiler to avoid optimizations that use the above-mentioned built-in library functions. Use this suboption or -qstrict if you do not want your precision of your program's results to be affected.
arraypad Instructs the compiler to pad any arrays where it infers there might be a benefit and to pad by whatever amount it chooses.
simd Instructs the compiler to attempt automatic SIMD vectorization; that is, converting certain operations in a loop that apply to successive elements of an array into a call to a VMX instruction. This call calculates several results at one time, which is faster than calculating each result sequentially. This suboption is enabled by default on Y-HPC. This suboption is enabled by default on SUSE 9 and Red Hat 4 if you set -qarch to ppc970. This suboption is enabled on Red Hat 3 if you set -qarch to ppc970 and use -qenablevmx. .

Getting the most out of -qhot

Here are some suggestions for using -qhot:

IBM Copyright 2003