-qsaveopt

Category

Object code control

@PROCESS

None.

Purpose

Saves the command-line options used for compiling a source file, the user's configuration file name and the options specified in the configuration files, the version and level of each compiler component invoked during compilation, and other information to the corresponding object file.

Syntax

Read syntax diagramSkip visual syntax diagram
        .-nosaveopt-.   
>>- -q--+-saveopt---+------------------------------------------><

Defaults

-qnosaveopt

Usage

This option has effect only when compiling to an object (.o) file (that is, using the -c option). Though each object might contain multiple compilation units, only one copy of the command-line options is saved. Compiler options specified with @PROCESS directives are ignored.

Command-line compiler options information is copied as a string into the object file, using the following format:
Read syntax diagramSkip visual syntax diagram
>>-@(#)--opt--+-f-+--invocation--options-----------------------><
              +-c-+                        
              '-C-'                        

Read syntax diagramSkip visual syntax diagram
>>-@(#)--cfg----config_file_options_list-----------------------><

Read syntax diagramSkip visual syntax diagram
>>-@(#)--env----env_var_definition-----------------------------><

where:
f
Signifies a Fortran language compilation.
c
Signifies a C language compilation.
C
Signifies a C++ language compilation.
invocation
Shows the command used for the compilation, for example, xlf.
options
The list of command line options specified on the command line, with individual options separated by space.
config_file_options_list
The list of options specified by the options attribute in all configuration files that take effect in the compilation, separated by space.
env_var_definition
The environment variables that are used by the compiler. Currently only XLF_USR_CONFIG is listed.
Note: You can always use this option, but the corresponding information is only generated when the environment variable XLF_USR_CONFIG is set.

For more information about the environment variable XLF_USR_CONFIG, see XLF_USR_CONFIG.

Note: The string of the command-line options is truncated after 64k bytes.
Compiler version and release information, as well as the version and level of each component invoked during compilation, are also saved to the object file in the format:
Read syntax diagramSkip visual syntax diagram
         .-------------------------------------------------------------------------------------------------------------.   
         V                                                                                                             |   
>>-@(#)----version--+-Version-- : -VV.RR.MMMM.LLLL-------------------------------------------------------------------+-+-><
                    '-component_name--Version--:--VV.RR--(--product_name--)--Level--:--YYMMDD--:--component_level_ID-'     

where:
V
Represents the version.
R
Represents the release.
M
Represents the modification.
L
Represents the level.
component_name
Specifies the components that were invoked for this compilation, such as the low-level optimizer.
product_name
Indicates the product to which the component belongs (for example, C/C++ or Fortran).
YYMMDD
Represents the year, month, and date of the installed update (PTF). If the update installed is at the base level, the level is displayed as BASE.
component_level_ID
Represents the ID associated with the level of the installed component.

If you want to simply output this information to standard output without writing it to the object file, use the -qversion option.

Examples

Compile t.f with the following command:
xlf t.f -c -qsaveopt -qhot
Issuing the what command on the resulting t.o object file produces information similar to the following:
opt f /opt/IBM/xlf/15.1.0/bin/xlf t.f -c -qsaveopt -qhot
cfg -qnozerosize -qsave -qalias=intptr -qposition=appendold
 -qxlf90=noautodealloc:nosignedzero:oldpad
 -qxlf77=intarg:intxor:persistent:noleadzero:gedit77:noblankpad:oldboz:softeof
 -qxlf2003=nopolymorphic:nobozlitargs:nostopexcept:novolatile:noautorealloc:oldnaninf -bh:4
version IBM XL Fortran for AIX, V15.1
version Version: 15.01.0000.0000
version Driver Version: 15.01(Fortran) Level: 121020 ID: _acSDAheyEeK928eKYVtYGg
version Fortran Front End and Run Time Version: 15.01(Fortran) Level: 121020 ID: _0lpiYhmQEeK928eKYVtYGg
version Fortran Transformer Version: 15.01(Fortran) Level: 121021 ID: _gYSYgRpREeK928eKYVtYGg
version High-Level Optimizer Version: 13.01(C/C++) and 15.01(Fortran) Level: 121021 ID: _d6ZMohn3EeK928eKYVtYGg
version Low-Level Optimizer Version: 13.01(C/C++) and 15.01(Fortran) Level: 121020 ID: _H1wQwhn3EeK928eKYVtYGg

In the first line, t.f identifies the source used as Fortran, bin/xlf shows the invocation command used, and -qhot -qsaveopt shows the compilation options. The second line, which starts with cfg, shows the compiler options added by the configuration file.

The remaining lines list each compiler component invoked during compilation, and its version and level. Components that are shared by multiple products may show more than one version number. Level numbers shown may change depending on the updates (PTFs) you have installed on your system.

Related information