Using Compiler Options for Optimizing the Application
You can use the compiler options that are provided by the Oracle Developer Studio compiler to optimize the application. The compiler options that are used in this
use case are described in the following table.
Table 2 Compiler Options
|
|
–DSOLARIS
|
Assigns the macro symbol Solaris to the preprocessor.
|
–fast
|
Provides maximum runtime performance. This option provides the
following individual compilation optimizations:
|
–fns – Enables the nonstandard
floating-point mode in SPARC platforms.
|
–fsimple=2 – Selects floating-point
optimization preferences.
|
–xarch – Specifies the target instruction
set architecture.
|
–xbuiltin=%all – Enables better optimization
of standard library calls.
|
–xcache – Defines cache properties that are
used by the optimizer.
|
–xchip – Specifies the target processor that
is used by the optimizer.
|
–xlibmil – Inlines the selected
libm library routines for
optimization.
|
–xlibmopt – Uses library of optimized math
routines.
|
–xmemalign – Controls the assumptions that
the compiler makes about the alignment of data.
|
–xO5 – Generates the highest level of
optimization.
|
–m64
|
Specifies 64-bit memory model for the compiled binary
object.
|
–xtarget=T5
|
Specifies the target platform for instruction set and
optimization.
|
–xautopar
|
Enables automatic parallelization for multiple processors.
|
–xdepend
|
Analyzes loops for inter-iteration data dependencies and does loop
restructuring, including loop interchange, loop fusion, scalar
replacement, and elimination of “dead array” assignments.
|
–xprefetch=auto
|
Enables automatic generation of the prefetch
instructions.
|
–xcode=pic32
|
Generates position-independent code (large model), which might not
be as fast as pic13, but has full range.
Equivalent to –KPIC. Permits references to at most
2**30 unique external symbols on 32-bit architectures; 2**29 on
64-bit.
|
–xipo=2
|
Performs inter-procedural aliasing analysis as well as
optimizations of memory allocation and layout to improve cache
performance.
|
–xlinkopt=2
|
Instructs the compiler to perform link-time optimization on the
resulting executable or dynamic library in addition to any
optimizations in the object files. Performs additional data flow
analysis, including dead-code elimination and address computation
simplification, at link time.
|
|