These options affect the characteristics of the object code, preprocessed code, or other output generated by the compiler.
| Option name | Equivalent pragma name | Description |
|---|---|---|
| -q32, -q64 | None. | Selects either 32-bit or 64-bit compiler mode. |
| -qalloca, -ma (C only) | #pragma alloca | Provides an inline definition of system function alloca when it is called from source code that does not include the alloca.h header. |
| -qconcurrentupdate (C only) | None. | Supports updating the operating system while the kernel is running. |
| -qeh (C++ only) | None. | Controls whether exception handling is enabled in the module being compiled. |
| -qexpfile | None. | When used together with the -qmkshrobj or -G option, saves all exported symbols in a designated file. |
| -qfuncsect | #pragma options funcsect | Places instructions for each function in a separate object file control section or CSECT which may reduce the size of your program. Placing each function in its own CSECT enables the linker to perform garbage collection on a per function basis rather than per object file. |
| -qinlglue | #pragma options inlglue | When used with -O2 or higher optimization, inlines glue code that optimizes external function calls in your application. |
| -qkeepinlines (C++ only) | None. | Keeps or discards definitions for unreferenced extern inline functions. |
| -qpic | None. | Generates Position-Independent Code suitable for use in shared libraries. |
| -qppline | None. | When used in conjunction with the -E or -P options, enables or disables the generation of #line directives. |
| -qpriority (C++ only) | #pragma options priority, #pragma priority | Specifies the priority level for the initialization of static objects. |
| -qproto (C only) | #pragma options proto | Specifies the linkage conventions for passing floating-point arguments to functions that have not been prototyped. |
| -qreserved_reg | None. | Indicates that the given list of registers cannot be used during the compilation except as a stack pointer, frame pointer or in some other fixed role. |
| -qro | #pragma options ro, #pragma strings | Specifies the storage type for string literals. |
| -qroconst | #pragma options roconst | Specifies the storage location for constant values. |
| -qroptr | None. | Specifies the storage location for constant pointers. |
| -qrtti (C++ only) | None. | Generates runtime type identification (RTTI) information for exception handling and for use by the typeid and dynamic_cast operators. |
| -s | None. | Strips the symbol table, line number information, and relocation information from the output file. |
| -qsaveopt | None. | 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. |
| -qstackprotect | None. | Provides protection against malicious code or programming errors that overwrite or corrupt the stack. |
| -qstatsym | None. | Adds user-defined, nonexternal names that have a persistent storage class, such as initialized and uninitialized static variables, to the symbol table of the object file. |
| -qtbtable | #pragma options tbtable | Controls the amount of debugging traceback information that is included in the object files. |
| -qthreaded | None. | Indicates to the compiler whether it must generate threadsafe code. |
| -qtls | None. | Enables recognition of the __thread storage class specifier, which designates variables that are to be allocated threadlocal storage; and specifies the threadlocal storage model to be used. |
| -qunique | None. | Generates unique names for static constructor/destructor file compilation units. |
| -qweakexp | None. | When used with the -qmkshrobj or -G option, includes or excludes global symbols marked as weak from the export list generated when you create a shared object. |
| -qweaksymbol | None. | Enables the generation of weak symbols. |
| -qxcall | None. | Generates code to treat static functions within a compilation unit as if they were external functions. |