Developer Guide and Reference

  • 2021.2
  • 04/07/2021
  • Public Content
  • Download as PDF
Contents

Alphabetical List of Compiler Options

The following table lists all the current compiler options in alphabetical order.
Determines whether variables and arrays are naturally aligned.
This content is specific to C++; it does not apply to
DPC++
.
Enables language compatibility with the gcc option ansi.
Specifies a directory that can be used to find include files, libraries, and executables.
Enables dynamic linking of libraries at run time.
This content is specific to C++; it does not apply to
DPC++
.
Enables static linking of a user's library.
This content is specific to C++; it does not apply to
DPC++
.
Binds references to all global symbols in a program to the definitions within a user's shared library.
This content is specific to C++; it does not apply to
DPC++
.
Binds references to all global function symbols in a program to the definitions within a user's shared library.
This content is specific to C++; it does not apply to
DPC++
.
Places comments in preprocessed source output.
Prevents linking.
Defines a
macro name
that can be associated with an optional value.
Tells the compiler to link to certain libraries in the
Intel® oneAPI Data Analytics Library
(
oneDAL
). Option -daal is a deprecated option; the replacement option is -qdaal.
Same as option -dM, but outputs #define directives in preprocessed source.
Enables or disables generation of debugging information.
This content is specific to C++; it does not apply to
DPC++
.
Enables or disables generation of debugging information.
This content is specific to C++; it does not apply to
DPC++
.
Enables or disables certain device libraries. This is a deprecated option that will be removed in a future release.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to output macro definitions in effect after preprocessing.
Specifies that driver tool commands should be shown but not executed.
This content is specific to C++; it does not apply to
DPC++
.
Displays the target machine and operating system configuration.
Displays the version number of the compiler.
Specifies a dynamic linker other than the default.
This content is specific to C++; it does not apply to
DPC++
.
Causes the preprocessor to send output to stdout.
Specifies the model of exception handling to be performed.
Causes the preprocessor to send output to stdout, omitting #line directives.
Specifies the stack reserve amount for the program.
This content is specific to C++; it does not apply to
DPC++
.
Specifies that an assembly listing file should be generated.
Specifies the contents of an assembly listing file.
Enables the use of blocks and entire functions of assembly code within a C or C++ file.
Maximizes speed across the entire program.
This content is specific to C++; it does not apply to
DPC++
.
Determines whether unwind information is precise at an instruction boundary or at a call boundary.
Enables or disables inline expansion of intrinsic functions.
Displays the full path of source files passed to the compiler in diagnostics.
Determines whether the compiler treats common symbols as global definitions.
Generates file dependencies related to the Microsoft* C/C++ compiler.
Lets you specify a name for a program database (PDB) file created by the compiler.
Specifies the name for a built program or dynamic-link library.
Enables exception handling table generation.
Ensures that compilation takes place in a freestanding environment.
Places each function in its own COMDAT section.
Tells the compiler to use C89 semantics for inline functions when in C99 mode.
Defines the maximum allowable absolute error for math library function results.
This content is specific to C++; it does not apply to
DPC++
.
Defines the relative error for math library function results, including division and square root.
This content is specific to C++; it does not apply to
DPC++
.
Ensures that the math library functions produce consistent results across different microarchitectural implementations of the same architecture.
This content is specific to C++; it does not apply to
DPC++
.
Indicates the input arguments domain on which math functions must provide correct results.
This content is specific to C++; it does not apply to
DPC++
.
Instructs the compiler to use run-time dispatch in calls to math functions.
This content is specific to C++; it does not apply to
DPC++
.
Defines the maximum allowable relative error for math library function results, including division and square root.
This content is specific to C++; it does not apply to
DPC++
.
Lets you specify a level of accuracy (precision) that the compiler should use when determining which math library functions to use.
This content is specific to C++; it does not apply to
DPC++
.
Instructs the compiler to use the Short Vector Math Library (SVML) rather than the Intel® Math Library (LIBM) to implement math library functions.
This content is specific to C++; it does not apply to
DPC++
.
Enables function inlining for single file compilation.
Tells the compiler to inline functions declared with
__inline and perform C++ inlining
.
Lets you perform ahead-of-time (AOT) compilation with the Field Programmable Gate Array (FPGA).
This content is specific to
DPC++
.
Enables OpenMP* 4.5 support for Intel® Xeon® Scalable processors.
Tells the preprocessor to include a specified file name as the header file.
Causes the linker to create a program that can be loaded only at its preferred base address.
This content is specific to C++; it does not apply to
DPC++
.
Determines whether jump tables are generated for switch statements.
Tells the compiler to preserve allocation of variables that are not referenced in the source.
Tells the compiler that errno can be reliably tested after calls to standard math library functions.
Tells the linker to generate a link map file. This is a deprecated option. There is no replacement option.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to not recognize typeof as a keyword.
Disables support for the operator names specified in the standard.
Disables support for run-time type information (RTTI).
Disables the check for libspirv (the SPIR-V* tools library).
This content is specific to
DPC++
.
Tells the compiler to link with a fat (multi-architecture) static library.
This content is specific to
DPC++
.
Determines whether EBP is used as a general-purpose register in optimizations.
Enables or disables certain device libraries for an OpenMP* target.
Enables OpenMP* 4.5 offloading support for Intel® GPUs.
Determines whether the compiler optimizes tail recursive calls.
Specifies the name for an object file.
Specifies that structure members should be packed together.
Tells the compiler to allow for Pascal-style string literals.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to allow for non-conformant code.
Determines whether the compiler generates position-independent code.
Tells the compiler to generate position-independent code. The generated code can only be linked into executables.
Lets you specify an alternate path or file name for precompiled header files.
Controls the semantics of floating-point calculations.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to return struct and union values in registers when possible.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to allocate as many bytes as needed for enumerated types.
Enables or disables stack overflow security checks for certain (or all) routines.
Determines whether the compiler generates code that detects some buffer overruns.
This content is specific to C++; it does not apply to
DPC++
.
Enables a program to be compiled as a SYCL* program rather than as plain C++11 program.
This content is specific to
DPC++
.
Lets you add arbitrary device binary images to the fat SYCL* binary when linking.
This content is specific to
DPC++
.
Enables elimination of DPC++ dead kernel arguments.
This content is specific to
DPC++
.
Specifies a SYCL* device code module assembly.
This content is specific to
DPC++
.
Enables or disables certain device libraries for a SYCL* target.
Tells the compiler to generate a device-only binary.
This content is specific to
DPC++
.
Enables LLVM-related optimizations before SPIR-V* generation.
This content is specific to
DPC++
.
Enables function pointers and support for virtual functions for DPC++ kernels and device functions.
This content is specific to
DPC++
.
It is an experimental feature.
Enables or disables the experimental "Explicit SIMD" SYCL* extension.
This content is specific to
DPC++
.
Causes help information to be emitted from the device compiler backend.
This content is specific to
DPC++
.
Tells the compiler to assume that SYCL ID queries fit within MAX_INT.
This content is specific to
DPC++
.
Tells the compiler to link only device code.
This content is specific to
DPC++
.
Tells the compiler to perform a partial link of device binaries to be used with Field Programmable Gate Array (FPGA).
This content is specific to
DPC++
.
Tells the compiler to generate code for specified devices.
This content is specific to
DPC++
.
Enables unnamed SYCL* lambda kernels.
This content is specific to
DPC++
.
Tells the compiler to produce device code in LLVM IR bitcode format into fat objects.
This content is specific to
DPC++
.
Tells the compiler to check only for correct syntax.
Initializes stack local variables to an unusual value to aid error detection.
Change default char type to unsigned.
Tells the compiler to use a different linker instead of the default linker (ld).
Produces an assembly listing with compiler comments, including options and version information.
Specifies the default visibility for global symbols or the visibility for symbols in declarations, functions, or variables.
This content is specific to C++; it does not apply to
DPC++
.
Determines whether the compiler places in the DATA section any variables explicitly initialized with zeros.
Tells the compiler to generate a level of debugging information in the object file.
Enables faster access to certain thread-local storage (TLS) variables.
Lets you specify the location of the base toolchain.
Makes __cdecl the default calling convention.
Lets you specify a DWARF Version format when generating debug information.
Enables read-only string-pooling optimization.
Enables a minimal rebuild.
Causes the command line options that were used to invoke the compiler to be appended to the DW_AT_producer attribute in DWARF debugging information.
Enables or disables C++ Run Time Type Information (RTTI).
Makes __fastcall the default calling convention.
This content is specific to C++; it does not apply to
DPC++
.
Determines whether the compiler generates code that detects some buffer overruns.
Lets you control the threshold at which the stack checking routine is called or not called.
Creates a separate object file containing DWARF debug information.
Enables the control flow protection mechanism.
Tells the compiler to use the vector calling convention (__vectorcall) when passing vector type arguments.
Separates functions into COMDATs for the linker.
This content is specific to C++; it does not apply to
DPC++
.
This is a deprecated option. There is no replacement option.
Initializes all local variables. This is a deprecated option. The replacement option is /RTC1.
This content is specific to C++; it does not apply to
DPC++
.
Makes __stdcall the default calling convention.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to display the include file order and continue compilation.
Displays all supported compiler options or supported compiler options within a specified category of options.
Specifies an additional directory to search for include files.
Splits the include path.
Adds a directory to the second include file search path.
Allows a header to be specified that is included in front of the other headers in the translation unit.
Lets you compile in the absence of a gcc environment.
This content is specific to C++; it does not apply to
DPC++
.
Lets you specify the target operating system for compilation.
This content is specific to C++; it does not apply to
DPC++
.
Enables interprocedural optimization between files.
Tells the compiler to link to the some or all of the Intel® Integrated Performance Primitives (Intel® IPP) libraries. Option -ipp is a deprecated option; the replacement option is -qipp.
Controls whether the compiler links to static or dynamic threaded Intel® Integrated Performance Primitives (Intel® IPP) run-time libraries.
Lets you indicate the prefix for referencing directories that contain header files.
Adds a directory to the front of the include file search path for files included with quotes but not brackets.
Specifies a directory to add to the start of the system include path.
Appends a directory to the prefix passed in by -iprefix and puts it on the include search path at the end of the include directories.
Similar to -iwithprefix except the include directory is placed in the same place as -I command-line include directories.
Sets the default character type to unsigned.
Tells the compiler to process all source or unrecognized file types as C++ source files.
This is a deprecated option. The replacement option for Kc++ is -x c++; the replacement option for /TP is /Tp<file>.
This content is specific to C++; it does not apply to
DPC++
.
Tells the linker to search for a specified library when linking.
Tells the linker to search for libraries in a specified directory before searching the standard directories.
Specifies that a program should be linked as a dynamic-link (DLL) library.
Passes user-specified options directly to the linker at compile time.
Tells the compiler to generate makefile dependency lines for each source file.
Tells the compiler to generate code for a specific architecture.
Specifies whether the compiler can use x87 instructions.
Determines whether double, long double, and long long types are naturally aligned.
This option is equivalent to specifying option align.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to generate code for processors that support certain features.
Tells the compiler to generate the assembler output file using a selected dialect.
Tells the compiler to align branches and fused branches on 32-byte boundaries for better performance.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to use a specific memory model to generate code and store data.
Lets you identify and fix code that may be vulnerable to speculative execution side-channel attacks, which can leak your secure data as a result of bad speculation of a conditional branch direction.
This content is specific to C++; it does not apply to
DPC++
.
Preprocess and compile, generating output file containing dependency information ending with extension .d.
Tells the linker to search for unresolved references in a multithreaded, dynamic-link run-time library.
Tells the compiler to generate makefile dependency information in a file.
Tells the compiler to generate makefile dependency lines for each source file.
Enables functions containing calls to intrinsics that require a specific CPU feature to have their target architecture automatically promoted to allow the required feature.
Tells the compiler to generate makefile dependency lines for each source file.
Tells the compiler to generate an output file containing dependency information.
Determines whether the frame pointer is omitted or kept in leaf functions.
Tells the compiler to add a phony target for each dependency.
Changes the default target rule for dependency generation.
Lets you control the number registers used to pass integer arguments.
This content is specific to C++; it does not apply to
DPC++
.
Changes the default target rule for dependency generation.
Tells the linker to search for unresolved references in a multithreaded, static run-time library.
Determines whether multi-byte characters are supported.
This content is specific to C++; it does not apply to
DPC++
.
Creates multiple processes that can be used to compile large numbers of source files at the same time.
This content is specific to C++; it does not apply to
DPC++
.
Prevents the compiler from using standard libraries when linking.
Prevents the linking of certain gcc-specific libraries.
This content is specific to C++; it does not apply to
DPC++
.
Disables inline expansion of standard library or intrinsic functions.
This content is specific to C++; it does not apply to
DPC++
.
Disables linking of the SYCL* runtime library.
This content is specific to
DPC++
.
Tells the compiler to not display compiler version information.
Prevents the compiler from using standard startup files when linking.
Do not search for header files in the standard directories for C++, but search the other standard directories.
Prevents the compiler from using standard libraries and startup files when linking.
Specifies the code optimization for applications.
Specifies the name for an output file.
Disables all optimizations.
Sets certain aggressive options to improve the speed of your application.
Enables optimizations that do not increase code size; it produces smaller code size than O2.
Enables all speed optimizations.
Enables maximum optimizations.
Tells the compiler to stop the compilation process and write the results to a file.
Lets you specify the name for a program database (PDB) file created by the linker.
This content is specific to C++; it does not apply to
DPC++
.
Determines whether the compiler generates position-independent code that will be linked into an executable.
Specifies which interpretation of the optimization_level pragma should be used if no prefix is specified.
This content is specific to C++; it does not apply to
DPC++
.
Prints information about where system libraries should be found.
Tells the compiler to use pthreads library for multithreading support.
Enables standard C++ features without disabling Microsoft* features.
Specifies the root directory where the compiler installation was performed.
This content is specific to C++; it does not apply to
DPC++
.
Specifies the directory for supporting tools.
This content is specific to C++; it does not apply to
DPC++
.
Changes the default size of the long double data type.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to link to certain libraries in the
Intel® oneAPI Math Kernel Library
(
oneMKL
). On Windows systems, you must specify this option at compile time.
Enables the parallelizer to generate multi-threaded code based on OpenMP* directives.
Lets you specify an OpenMP* run-time library to use for linking.
Controls whether the compiler links to static or dynamic OpenMP* run-time libraries.
Enables compilation of OpenMP* programs in sequential mode.
Lets you set a level of performance tuning for loops.
This content is specific to C++; it does not apply to
DPC++
.
Passes options to a specified tool.
This content is specific to C++; it does not apply to
DPC++
.
Enables or disables the optimization for multiple adjacent gather/scatter type vector memory references.
This content is specific to C++; it does not apply to
DPC++
.
Enables the generation of transformation remarks report when specified with icx or icpx.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to generate code such that references to statically assigned addresses can be patched.
Registers exception handlers for safe exception handling.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler that the __regcall calling convention should be used for functions that do not directly specify a calling convention.
Tells the compiler to speed up Field Programmable Gate Array (FPGA) target compile time.
This content is specific to
DPC++
.
Enables checking for certain run-time conditions.
Causes the compiler to compile to an assembly file only and not link.
Tells the compiler to save intermediate files created during compilation.
Causes Intel-provided libraries to be linked in dynamically.
This content is specific to C++; it does not apply to
DPC++
.
Links the GNU libgcc library dynamically.
Tells the compiler to produce a dynamic shared object instead of an executable.
Tells the compiler to display a list of the include files.
Causes Intel-provided libraries to be linked in statically.
This content is specific to C++; it does not apply to
DPC++
.
Links the GNU libgcc library statically.
Links the GNU libstdc++ library statically.
Prevents linking with shared libraries.
Tells the compiler to conform to a specific language standard.
Tells the compiler to implement strict ANSI conformance dialect.
This content is specific to C++; it does not apply to
DPC++
.
Specifies the root directory where headers and libraries are located.
Tells the linker to read link commands from a file.
Tells the compiler to link to the
Intel® oneAPI Threading Building Blocks
(
oneTBB
) libraries. Option -tbb is a deprecated option; the replacement option is -qtbb.
Tells the compiler to process a file as a C source file.
Tells the compiler to process all source or unrecognized file types as C source files.
Tells the compiler to process a file as a C++ source file.
Undefines any definition currently in effect for the specified
macro
.
Tells the compiler the specified symbol is undefined.
Disables all predefined macros and assertions.
This content is specific to C++; it does not apply to
DPC++
.
Disables all predefined
macros
.
Tells the compiler the maximum number of times to unroll loops.
Determines whether the performance headers directory is added to the include path search list.
This content is specific to C++; it does not apply to
DPC++
.
Enables the use of blocks and entire functions of assembly code within a C or C++ file.
Specifies that driver tool commands should be displayed and executed.
Enables or suppresses hidden vtordisp members in C++ objects.
Enables or disables vectorization.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to display GCC-style version information.
Selects the general representation that the compiler uses for pointers to members.
Enables pointers to members of any inheritance type.
Disables all warning messages.
Specifies the level of diagnostic messages to be generated by the compiler.
Passes options to the assembler for processing.
Determines whether a warning is issued if generated code is not C++ ABI compliant.
Enables warning and error diagnostics.
Tells the compiler to display certain information to the console output window.
This content is specific to C++; it does not apply to
DPC++
.
Determines whether a warning is issued when /* appears in the middle of a /* */ comment.
Determines whether warnings are issued for deprecated C++ headers.
Enables warnings based on certain C++ programming guidelines.
Changes all warnings to errors.
Causes all warnings and currently enabled remarks to be reported as errors.
Determines whether warnings are issued about extra tokens at the end of preprocessor directives.
Determines whether argument checking is enabled for calls to printf, scanf, and so forth.
Determines whether the compiler issues a warning when the use of format functions may cause security problems.
Passes options to the linker for processing.
Determines whether a warning is issued if the return type of main is not expected.
Determines whether warnings are issued for global functions and variables without prior declaration.
Determines whether warnings are issued for missing prototypes.
Disables warnings that enforce strict SYCL* language compatibility.
Determines whether warnings are issued for questionable pointer arithmetic.
Passes options to the preprocessor.
Tells the compiler to issue a warning when the order of member initializers does not match the order in which they must be executed.
Determines whether warnings are issued when a function is declared without a return type, when the definition of a function returning void contains a return statement with an expression, or when the closing brace of a function returning non-void is reached.
Determines whether a warning is issued when a variable declaration hides a previous declaration.
Determines whether warnings are issued when a comparison between signed and unsigned values could produce an incorrect result when the signed value is converted to unsigned.
Determines whether warnings are issued for code that might violate the optimizer's strict aliasing rules.
Determines whether warnings are issued for functions declared or defined without specified argument types.
Determines whether warnings are issued if any trigraphs are encountered that might change the meaning of the program.
Determines whether a warning is issued if a variable is used before being initialized.
Determines whether a warning is issued if an unknown #pragma directive is used.
Determines whether a warning is issued if a declared function is not used.
Determines whether a warning is issued if a local or non-constant static variable is unused after being declared.
Issues a diagnostic message if const char * is converted to (non-const) char *.
Removes standard directories from the include file search path.
Tells the compiler which processor features it may target, including which instruction sets and optimizations it may generate.
All source files found subsequent to -x type will be recognized as a particular type.
Passes a linker option directly to the linker.
Enables options to be passed to the specified tool in the device compilation tool chain for the target. This compiler option supports OpenMP* offloading.
Passes options to the backend tool.
This content is specific to
DPC++
.
Enables options to be passed to the specified tool in the device compilation tool chain for the target. This compiler option supports SYCL* offloading.
This content is specific to
DPC++
.
Tells the compiler to ignore all other precompiled header files.
Tells the compiler to create a precompiled header file.
Tells the compiler to use a precompiled header file.
Lets you specify ANSI C standard conformance for certain language features.
Tells the compiler to generate function prototypes. This is a deprecated option. There is no replacement option.
This content is specific to C++; it does not apply to
DPC++
.
Tells the compiler to generate full debugging information in either an object (.obj) file or a project database (PDB) file.
Causes library names to be omitted from the object file.
Specifies alignment for structures on byte boundaries.
Tells the compiler to check only for correct syntax.

Product and Performance Information

1

Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.