Visible to Intel only — GUID: GUID-276392FD-7457-47A1-A5E6-1DD05B102F81
Visible to Intel only — GUID: GUID-276392FD-7457-47A1-A5E6-1DD05B102F81
Portability and GCC-Compatible Warning Options
This section discusses portability options and GCC-compatible warning options.
This content does not apply for SYCL.
Portability Options
A challenge in porting applications from one compiler to another is making sure that there is support for the compiler options you use to build your application. The Intel® compiler supports many of the options that are valid on other compilers you may be using.
The first table lists compiler options that are supported by the Intel® compiler and the GCC Compiler. Following this table, you will see information about GCC-compatible warning options.
The second table lists compiler options that are supported by the Intel® compiler and the Microsoft C++ Compiler .
Options that are unique to either compiler are not listed in this topic.
Linux
This table lists compiler options that are supported by both the Intel® compiler and the GCC Compiler.
-ansi |
-B |
-C |
-c |
-D |
-dD |
-dM |
-E |
-fargument-noalias |
-fargument-noalias-global |
-fcf-protection |
-fdata-sections |
-ffunction-sections |
-f[no-]builtin |
-f[no-]common |
-f[no-]freestanding |
-f[no-]gnu-keywords |
-f[no-]inline |
-f[no-]inline-functions |
-f[no-]math-errno |
-f[no-]operator-names |
-f[no-]stack-protector |
-f[no-]unsigned-bitfields |
-fpack-struct |
-fpermissive |
-fPIC |
-fpic |
-fshort-enums |
-fsyntax-only |
-funroll-loops |
-funsigned-char |
-fverbose-asm |
-H |
-help |
-I |
-idirafter |
-imacros |
-iprefix |
-iwithprefix |
-iwithprefixbefore |
-l |
-L |
-M |
-march |
-mcpu |
-MD |
-MF |
-MG |
-MM |
-MMD |
-m[no-]ieee-fp |
-MP |
-MQ |
-msse |
-msse2 |
-msse3 |
-MT |
-nodefaultlibs |
-nostartfiles |
-nostdinc |
-nostdinc++ |
-nostdlib |
-o |
-O |
-O0 |
-O1 |
-O2 |
-O3 |
-Os |
-p |
-P |
-S |
-shared |
-static |
-std |
-trigraphs |
-U |
-u |
-v |
-V |
-Wall |
-Werror |
-W[no-]cast-qual |
-W[no-]comment |
-W[no-]comments |
-W[no-]deprecated |
-W[no-]fatal-errors |
-W[no-]format-security |
-W[no-]main |
-W[no-]missing-declarations |
-W[no-]missing-prototypes |
-W[no-]overflow |
-W[no-]overloaded-virtual |
-W[no-]pointer-arith |
-W[no-]return-type |
-W[no-]strict-prototypes |
-W[no-]trigraphs |
-W[no-]uninitialized |
-W[no-]unknown-pragmas |
-W[no-]unused-function |
-W[no-]unused-variable |
-X |
-x assembler-with-cpp |
-x c |
-x c++ |
-Xlinker |
The Intel® compiler recognizes many GCC-compatible warning options, but many are not documented.
In general, if a GCC-compatible option is accepted by the compiler, but not documented, the implementation of the option is the same as described in the GCC documentation.
To find the GCC documentation about GCC warning options, you can do any of the following:
Enter the command:
man gcc
Check the GCC website.
Search the web for "gcc warning options".
Windows
This table lists compiler options that are supported by both the Intel® compiler and the Microsoft C++ Compiler.
For complete details about these options, such as the possible values for <n> when it appears below, see the Microsoft Visual Studio C++ documentation.
/C |
/c |
/D<name>{=|#}<text> |
/E |
/EH{a|s|c|r} |
/EP |
/F<n> |
/Fa[file] |
/FA[{c|s|cs}] |
/FC |
/Fe<file> |
/FI<file> |
/Fo<file> |
/fp:<model> |
/Fp<file> |
/FR[<file>] |
/GA |
/Gd |
/GF |
/GR[-] |
/GS[-] |
/Gs[<n>] |
/Gy[-] |
/GZ |
/H<n> |
/help |
/I<dir> |
/J |
/LD |
/LDd |
/link |
/MD |
/MDd |
/MT |
/MTd |
/nologo |
/O1 |
/O2 |
/Od |
/Oi[-] |
/Os |
/Ot |
/Ox |
/P |
/QIfist[-] |
/RTC{1|c|s|u} |
/showIncludes |
/TC |
/Tc<source file> |
/TP |
/Tp<source file> |
/u |
/U<name> |
/vd<n> |
/vmg |
/vmv |
/W<n> |
/Wall |
/WX |
/X |
/Y- |
/Yc[<file>] |
/Yu[<file>] |
/Z7 |
/Zc:<arg1>[, <arg2>] |
/Zg |
/Zi |
/ZI |
/Zl |
/Zp[<n>] |
/Zs |