Enabling Aggressive Optimizations on HP-UX [ HP C Programmer's Guide ] MPE/iX 5.0 Documentation
HP C Programmer's Guide
Enabling Aggressive Optimizations on HP-UX
To enable aggressive optimizations at the second, third, or fourth
optimization levels, use the +Oaggressive option as follows:
cc +O2 +Oaggressive sourcefile.c
or:
cc +O3 +Oaggressive sourcefile.c
or:
cc +O4 +Oaggressive sourcefile.c
Aggressive optimizations are new optimizations or are optimizations that
can change the behavior of programs. These optimizations may do any of
the following:
* convert certain library calls to millicode and inline instructions
* cause the inlined routines strcpy(), sqrt(), fabs(), and alloca()
to not return the routine's completion status in ERRNO
* alter exception handling and asynchronous interrupt handling as a
result of instruction scheduling optimization
* cause less precise floating-point results
* cause programs that perform comparisions between pointers to
shared memory and pointers to private memory to run incorrectly
Use aggressive optimizations with stable, well-structured,
ANSI-conforming code. These types of optimizations give you faster code,
but are riskier than the default optimizations.
MPE/iX 5.0 Documentation