=============================================== HP-UX Flag Descriptions for CPU2000 - May 2001 =============================================== ----------------------------------------------- Flags for HP-UX C Compiler ----------------------------------------------- -Bprotected[=symbol[,symbol...]*] The named symbols, or all symbols if no symbols are specified, are assigned the protected export class. That means these symbols will not be preempted by symbols from other load modules, so the compiler may bypass the linkage table for both code and data references and bind them to locally defined code and data symbols. When used with no symbol list, -Bprotected implies -Wl,-aarchive_shared, causing the linker to prefer an archive library over a shared library if one is available. This can be overridden by following the -Bprotected option with a subsequent -Wl,-a option. -Bprotected_data Marks only data symbols as having the protected export class. -Bprotected_def Same as -Bprotected but only locally defined (non- tentative) symbols are assigned the protected export class. +DSmodel Use the instruction scheduler tuned to the model specified. The defined values for model are: blended Tune for best performance on a combination of processors (i.e., Itanium or McKinley processors). itanium Tune for best performance on an Itanium processor. This is the only valid option for HP-UX 11i v1.5. mckinley Tune for best performance on a McKinley processor. native Tune for best performance on the processor on which the compiler is running. For this release of HP C, the default model is Itanium. effmem.o Replacement for malloc/free that assumes ANSI compliance and improves spatial locality and minimizes memory usage by not maintaining a free list. -exec Indicates that any object files created will be used to create an executable file. Constants with a protected or hidden export class are placed in the read-only data section. This option also implies -Bprotected_def. fastmem.o Replacement for malloc/free that assumes ANSI compliance. +FP flags Specify how the run time environment for floating-point operations should be initialized at program start up. The default is that all trapping behaviors are disabled. See ld(1) for specific values of flags. To dynamically change these settings at run-time, refer to fesetenv(3M). D (d) Enable sudden underflow (flush to zero) of denormalized values. +I Instrument the application for profile-based optimization. See ld(1), +P, and +pgm for more details. The +I option is incompatible with the -G, +P, and -S options. +I is equivalent to +Oprofile=collect. See ld(1), +P, and +pgm for more details. The +I option is incompatible with the -G, +P, and -S options. It is incompatible with the -g option only during compile time. Kernel Tunables (Listed separately) +Olevel Invoke optimizations selected by level. These can be preceded by either +O or -O. Defined values for level are: 0 Perform no optimizations. 1 Perform optimizations within basic blocks only. This is the default. 2 Perform level 1 and global optimizations. Same as -O and +O. 3 Perform level 2 as well as interprocedural global optimizations. 4 Perform level 3 as well as doing link time optimizations. NOTE: +Oprocelim is the general default at all levels, unless the users says +ild +ildrelink or -b. NOTE: +O4 is only supported with +P. Otherwise, attempts to activate +O4 will cause the compiler to automatically drop to +O3. +Ofast Select a combination of compilation options for optimum execution speed at build times. Currently: +O2, +Olibcalls, +Onolimit, +Ofltacc=relaxed, +FPD, +DSnative, and +Oshortdata. This option is a synonym for -fast. +Ofaster This option selects +Ofast, but with an increased optimization level. If used with +P the optimization level will be +O4. Otherwise it will be +O3. +O[no]fltacc Disable [enable] floating-point optimizations that can result in numerical differences. +Ofltacc is the same as +Ofltacc=strict. +Onofltacc is the same as +Ofltacc=relaxed. +Ofltacc=[strict|default|limited|relaxed] Control the level of floating point optimizations that the compiler may perform. The defined values for optlevel are: default Allow contractions, such as fused multiply- add ( FMA ), but disallows any other floating point optimization that can result in numerical differences. limited Like default, but also allows floating point optimizations which may affect the generation and propagation of infinities, NaNs, and the sign of zero. Also implies +Ocxlimitedrange. relaxed In addition to the optimizations allowed by limited, permits optimizations, such as reordering of expressions, even if parenthesized, that may affect a rounding error. This is the same as +Onofltacc. Also implies +Ocxlimitedrange. strict Disallow any floating point optimization that can result in numerical differences. This is the same as +Ofltacc. The default is +Ofltacc=default. +Oinlinebudget=n Control the aggressiveness of inlining. n is an integer in the range 1 - 1000000 that specifies the level of aggressiveness as follows: n Meaning = 100 Default level on inlining. > 100 More aggressive inlining. 2 - 99 Less aggressive inlining. = 1 Only inline if it reduces code size. This optimization can occur at optimization levels 3, and 4. The default is +Oinlinebudget=100. +O[no]libcalls NOTE: This option is deprecated and may not be supported on future releases. On IPF, including a system header file will cause the functions declared therein to be eligible for libcalls transformations, regardless of the state of +O[no]libcalls. +O[no]limit Suppress [do not suppress] optimizations that significantly increase compile-time or consume enormous amounts of memory. +Olimit is the same as +Olimit=min. +Onolimit is the same as +Olimit=none. +O[no]ptrs_to_globals[=name1,name2,...,nameN] Tell the optimizer whether global variables are modified [are not modified] through pointers. This optimization can occur at levels 2, 3, 4. The default is +Optrs_to_globals. +O[no]procelim Enable [disable] the elimination of functions that are not referenced by the application. Only functions with the hidden export class may be eliminated. The default is +Oprocelim. +O[no]recovery Generate [do not generate] recovery code for control speculation. The +Orecovery option reduces the risk of incorrect behavior for code that writes to uncacheable memory and may not be properly identified as volatile. Any program that uses signal handlers to catch signals that are raised by accessing memory may not behave correctly when +Onorecovery is used. The default is +Onorecovery. +Oshortdata[=size] All objects of size size bytes or smaller will be placed in the short data area, and references to such data will assume it resides in the short data area. Valid values of n are 0, or a decimal number between 8 and 4,194,304 (4MB). If no size is specified, all data is placed in the short data area. If size is 0, no data will be placed in the short data area, and all data references will use long offsets. The default is +Oshortdata=8. +O[no]type_safety=[off|limited|ansi|strong] Enable [disable] aliasing across types. off The default. Specifies that aliasing can occur freely across types. limited Code follows ANSI aliasing rules, and that unnamed objects should be treated as if they had an unknown type. ansi Code follows ANSI aliasing rules, and unnamed objects should be treated the same as named objects. strong Code follows ANSI aliasing rules, except that accesses through lvalues of a character type are not permitted to touch objects of other types. This assumes that field addresses are not taken. +P Optimize the application based on profile data found in the database file flow.data, produced by compilation with +I. +P is equivalent to +Oprofile=use or +Oprofile=use:filename. See ld(1), +I, and +df, for more details. The +P option is incompatible with the +I and -S options. It is incompatible with the -g option only during compile time. -Wl,-aarchive_shared (ld option -a search) Specifies library search order. Archive_shared caused archive libraries to be searched first, followed by shared libraries. Specify whether shared or archive libraries are searched with the -l option. The value of search should be one of archive, shared, archive_shared, shared_archive, or default. This option can appear more than once, interspersed among -l options, to control the searching for each library. The default is to use the shared version of a library if one is available, or the archive version if not. If either archive or shared is active, only the specified library type is accepted. If archive_shared is active, the archive form is preferred, but the shared form is allowed. If shared_archive is active, the shared form is preferred but the archive form is allowed. To create a statically-bound program, use the - noshared option rather than -a archive . ----------------------------------------------- Flags for HP-UX C++ Compiler ----------------------------------------------- +FPflags Specify how the run time environment for floating-point operations should be initialized at program start up. The default is that all trapping behaviors are disabled. See ld(1) for specific values of flags. To dynamically change these settings at run time, refer to fesetenv(3M). D (d) Enable sudden underflow (flush to zero) of denormalized values. +inline_level [i]num This option controls how C++ inlining hints influence aCC. Specify num as 0, 1, 2, or 3. num Meaning 0 No inlining is done (same effect as the +d option). 1 Only small functions are inlined. 2 Only large functions are not inlined. 3 Inlining hints are respected in all cases, except when the called function is recursive or when it has a variable number of arguments. The default level depends on +Olevel as shown in the following table: level num 0 1 1 1 2 2 3 2 4 2 If i is also specified, then implicit inlining is invoked for "small" functions without the inline keyword. NOTE: This option controls functions declared with the inline keyword or within the class declaration and is effective at all optimization levels. The options +Oinline and +Oinlinebudget control the high level optimizer that recognizes other opportunities in the same source file (+O3) or amongst all source files (+O4). -minshared Indicates that the result of the current compilation is going into an executable file that will make minimal use of shared libraries. Equivalent to -exec -Bprotected. +Ofast This option selects a combination of compilation options for optimum execution speed and reasonable build times. Currently: +O2, +Onolimit, +Olibcalls, +Ofltacc=relaxed, +Onoinitcheck, +FPD and +Oshortdata. This option is a synonym for -fast. +Olevel Invoke optimizations selected by level. Defined values for level are: 0 Perform minimal optimizations. 1 Perform optimizations within basic blocks only. This is the default. 2 Perform level 1 and global optimizations. Same as -O. 3 Perform level 2 as well as interprocedural global optimizations. 4 Perform level 3 as well as doing link time optimizations. Requires concurrent use of the +P option. +Ofaster This option selects +Ofast, but with an increased optimization level. If used with +P the optimization level will be +O4. Otherwise it will be +O3. +O[no]fltacc Disable [enable] floating-point optimizations that can result in numerical differences. +Ofltacc is the same as +Ofltacc=strict. +Onofltacc is the same as +Ofltacc=relaxed. +Ofltacc=level Controls the level of floating point optimizations that the compiler may perform. The defined values for level are: default Allows contractions, such as fused multiply-add (FMA), but disallows any other floating point optimization that can result in numerical differences. limited Like default, but also allows floating point optimizations which may affect the generation and propagation of infinities, NaNs, and the sign of zero. relaxed In addition to the optimizations allowed by limited, permits optimizations, such as reordering of expressions, even if parenthesized, that may affect rounding error. This is the same as +Onofltacc. strict Disallows any floating point optimization that can result in numerical differences. This is the same as +Ofltacc. The default is +Ofltacc=default. +O[no]initcheck Enable [disable] initialization to zero of any local, scalar, non-static variable that is uninitialized with respect to at least one path leading to its use. This optimization can occur at optimization levels 2, 3, and 4. The default is to enable initialization if the variable is uninitialized with respect to every path leading to its use. +O[no]libcalls NOTE: This option is deprecated and may not be supported on future releases. On IPF, including a system header file will cause the functions declared therein to be eligible for libcalls transformations, regardless of the state of +O[no]libcalls. +O[no]limit Suppress [do not suppress] optimizations that significantly increase compile-time or consume enormous amounts of memory. +Olimit is the same as +Olimit=min. +Onolimit is the same as +Olimit=none. +Oshortdata[=size] All objects of size size bytes or smaller will be placed in the short data area, and references to such data will assume it resides in the short data area. Valid values of n are 0, or a decimal number between 8 and 4,194,304 (4MB). If no size is specified, all data is placed in the short data area. If size is 0, no data will be placed in the short data area, all data references will use long offsets, and thread-local storage will not be supported. The default is +Oshortdata=8. ----------------------------------------------- Flags for HP-UX F90 Compiler ----------------------------------------------- +cat Concatenates all source files of the same source form together, then compiles the concatenated source all at once. This enables inlining at +O3 within the concatenated file. +I/+P Optimize the application based on profile data found in the database file flow.data , produced by compilation with +I ld(1), +I, and +df, for more details. The +P option is incompatible with the +I and -S options. It is incompatible with the -g option only during compile time. This option is only valid on IPF. +Ooptlevel Specify the level of optimization. Higher levels include optimizations performed at lower levels. Many other options beginning with +O enable specific optimizations; see the OPTIMIZATION section. optlevel can be one of the following: 0 Minimal optimization, fastest compile time, best debugging support. This is the default. 1 Block-level optimizations, moderately fast compile time, moderate improvement in runtime performance. 2 Full optimization within each subprogram in a file. Marked improvement in runtime performance, noticeably longer compile time, program transformations more pronounced than at lower levels. 3 Full optimization across all subprograms within the source file, including subprogram cloning and inlining. This level of optimization can greatly improve the runtime performance of programs that make frequent procedure calls. +Ofast Select a combination of compilation options for optimum execution speed at build times. Currently: +O2, +Olibcalls, +Onolimit, +Ofltacc=relaxed, +FPD, +DSnative (on IPF), and +Oshortdata. +FPflags Specify how the run time environment for floating-point operations should be initialized at program start up. The default is that all trapping behaviors are disabled. See ld(1) for specific values of flags. To dynamically change these settings at run time, refer to fesetenv(3M). D (d) Enable sudden underflow (flush to zero) of denormalized values. +Ofltacc=[strict|default|limited|relaxed] Control the level of floating point optimizations that the compiler may perform. The defined values for optlevel are: default Allow contractions, such as fused multiply-add (FMA), but disallows any other floating point optimization that can result in numerical differences. limited Like default, but also allows floating point optimizations which may affect the generation and propagation of infinities, NaNs, and the sign of zero. Also implies +Ocxlimitedrange. relaxed In addition to the optimizations allowed by limited, permits optimizations, such as reordering of expressions, even if parenthesized, that may affect a rounding error. This is the same as +Onofltacc. Also implies +Ocxlimitedrange. strict Disallow any floating point optimization that can result in numerical differences. This is the same as +Ofltacc. The default is +Ofltacc=default. +Oinline_budget=n Perform more aggressive inlining, where n specifies the degree of aggressiveness, as follows: 100 Default level of inlining. > 100 More aggressive inlining at the expense of compilation time and code size. The maximum for n is 1000000. 2 - 99 Less aggressive inlining. The optimizer gives more weight to compilation time and code size when determining whether to inline. 1 Inline only if it reduces code size. This option can be used at optimization level 3 or higher. +O[no]libcalls Use [do not use] low-call-overhead versions of select library routines. This option can be used at any level. At optimization level 0 or 1, the default is +Onolibcalls; at optimization level 2 or higher, the default is +Olibcalls. +O[no]limit Suppress [do not suppress] optimizations that significantly increase compile-time or consume large amounts of memory. This option can be used at level 2 and higher. The default is +Olimit. +O[no]loop_block Enable [disable] loopblocking for data cache optimizations. Available at optimization level 3 +O[no]loopblock Alternate spelling of loop_block. (Preferred spelling with underbar.) +O[no]loopblock Alternate spelling of +O[no]loop_block. +O[no]ptrs_to_globals[=name1,name2,...,nameN] Tell the optimizer whether global variables are modified [are not modified] through pointers. This optimization can occur at levels 2, 3, 4. The default is +Optrs_to_globals +Oshortdata[=size] All objects of size size bytes or smaller will be placed in the short data area, and references to such data will assume it resides in the short data area. Valid values of n are 0, or a decimal number between 8 and 4,194,304 (4MB). If no size is specified, all data is placed in the short data area. If size is 0, no data will be placed in the short data area, and all data references will use long offsets. The default is +Oshortdata=8. ----------------------------------------------- Descriptions of Kernel Tunables ----------------------------------------------- dbc_max_pct Maximum dynamic buffer cache size as a percent of system memory dbc_min_pct Minimum dynamic buffer cache size as a percent of system memory maxdsiz Maximum data size maxdsiz_64bit Maximum data size for 64 bit applications maxssiz Maximum stack size maxssiz_64bit Maximum stack size for 64 bit applications vps_ceiling Maximum System-Selected Page Size (in Kbytes) vps_pagesize Default user page size (in Kbytes) swapmem_on Swap to memory flag.