Compiler Options Cross-reference

Linux* Windows* Description Default
-0f -QI0f Enable/disable the patch for the PentiumŪ 0f erratum. OFF
-A[-] -QA[-] Remove all predefined macros. OFF
-Aname[(val)] -QAname[(val)]

Create an assertion name having value val.

OFF
-ansi[-] -Qansi[-] Enable/disable assumption of ANSI conformance. ON
-ax{i|K|M|W} -Qax{i|K|M|W} Generate code specialized for processor extensions specified by codes (i,K,M,W) while also generating generic IA-32 code. i = Pentium Pro and Pentium II processor instructions
K
= Steaming SIMD extensions
M
= MMX(TM)
W
= Streaming SIMD Extensions 2
OFF
-C -C Don't strip comments. OFF
-c -c Compile to object (.o) only, do not link. OFF
-Dname[{=|#}{text}] -Dname[=value] Define macro. OFF
-E -E Preprocess to stdout. OFF
-fdiv_check -QIfdiv[-] Enable the patch for the Pentium FDIV erratum. OFF
-fp -Oy[-] Disable using EBP as general purpose register (no frame pointer). OFF
-g -Zi Produce symbolic debug information in object file. OFF
-H -Hn Print include file order. OFF
-help -help Print help message listing. OFF
-Idirectory -Idirectory Add directory to include file search path. OFF
-inline_debug_info -Qinline_debug_info Preserve the source position of inlined code instead of assigning the call-site source position to inlined code. OFF
-ip -Qip Enable single-file IP optimizations (within files). OFF
-ip_no_inlining -Qip_no_inlining Optimize the behavior of IP: disable full and partial inlining (requires -ip or -ipo). OFF
-ipo -Qipo Enable multi-file IP optimizations (between files). OFF
-ipo_obj -Qipo_obj Optimize the behavior of IP: force generation of real object files (requires -ipo). OFF
-Knovtab -vd{0|1} Suppress definition of vftables for classes without non-inline vfns.

OFF

-KPIC NA Generate position independent code (same as -Kpic).

OFF

-Kpic NA Generate position independent code (same as -KPIC).

OFF

-long_double -Qlong_double Enable 80-bit long double.

OFF

-m NA Instruct linker to produce map file.

OFF

-M -QM Generate makefile dependency information.

OFF

-mp -Op[-] Maintain floating-point precision (disables some optimizations).

OFF

-mp1 -Qprec Improve floating-point precision (speed impact is less than -mp).

OFF

-nobss_init NA Disable placement of zero-initialized variables in BSS (use DATA).

OFF

-nolib_inline -Oi[-] Disable inline expansion of intrinsic functions.

OFF

-O -O2 Same as -O1.

OFF

-ofile -ofile Name output file.

OFF

-O0 -Od Disable optimizations.

OFF

-O1 -O1 Optimizes for size.

OFF

-O2 -O2 Same as -O1.

ON

-P -EP Preprocess to file.

OFF

-pc32 -Qpc 32 Set internal FPU precision to 24-bit significand.

OFF

-pc64 -Qpc 64 Set internal FPU precision to 53-bit significand.

ON

-pc80 -Qpc 80 Set internal FPU precision to 64-bit significand.

OFF

-prec_div -Qprec_div Improve precision of floating-point divides (some speed impact).

OFF

-prof_dir directory -Qprof_dir directory Specify directory for profiling output files (*.dyn and *.dpi).

OFF

-prof_file filename NA Specify filename for profiling summary file.

OFF

-prof_gen[x] -Qprof_genx Instrument program for profiling; with the x qualifier, extra information is gathered.

OFF

-prof_use -Qprof_use Enable use of profiling information during optimization.

OFF

-Qinstall dir NA Set dir as root of compiler installation.

OFF

-Qlocation,str,dir -Qlocation, tool, path Set dir as the location of tool specified by str.

OFF

-Qoption,str,opts -Qoption, tool, list Pass options opts to tool specified by str.

OFF

-qp, -p NA Compile and link for function profiling with UNIX gprof tool.

OFF

-r -w2 Enable remarks, warnings and errors.

OFF

-rcd -Qrcd Enable fast floating-point-to-integer conversions.

OFF

-restrict -Qrestrict Enable the restrict keyword for disambiguating pointers.

OFF

-S -S Compile to assembly (.s) only, do not link (*I).

OFF

-sox[-] -Qsox Enable (default)/disable saving of compiler options and version in the executable.

ON

-syntax -Zs Perform syntax check only.

OFF

-Timplinc NA Enable implicit inclusion of source files for finding template definitions.

OFF

-Tlocal NA Instantiate template functions used in this compilation and make local.

OFF

-Tnoauto NA Disable automatic instantiation of templates.

OFF

-tpp5 -G5 Optimize for Pentium processor.

OFF

-tpp6 -G6 Optimize for Pentium Pro, Pentium II and Pentium III processors.

OFF

-Tused NA Instantiate template functions used in this compilation.

OFF

-Uname -U name Remove predefined macro.

OFF

-unroll[n] -Qunrolln Set maximum number of times to unroll loops. Omit n to use default heuristics. Use n=0 to disable loop unroller.

OFF

-V -V text Display compiler version information.

OFF

-w -w Display errors. OFF
-wn -Wn Control diagnostics. Display errors (n=0). Display warnings and errors (n=1). Display remarks, warnings, and errors (n=2). OFF
-wdL1[,L2,...] -Qwd[tag] Disable diagnostics L1 through LN. OFF
-weL1[,L2,...] -Qwe[tag] Change severity of diagnostics L1 through LN to error. OFF
-wnn -Qwn[tag]

Print a maximum of n  errors.

OFF
-wrL1[,L2,...] -Qwr[tag] Change severity of diagnostics L1 through LN to remark. OFF
-wwL1[,L2,...] -Qww[tag] Change severity of diagnostics L1 through LN to warning. OFF
-X -X Remove standard directories from include file search path. OFF
-x{i|K|M|W} -Qx[i|M|K|W] Generate code specialized for processor extensions specified by codes (i,K,M,W) while also generating generic IA-32 code. i = PentiumŪ Pro and Pentium II processor instructions
K
= Steaming SIMD extensions
M
= MMX(TM)
W
= Streaming SIMD Extensions 2.
OFF
-Xa -Ze Select extended ANSI C dialect. OFF
-XA NA C++ compilation follows ARM. OFF
-XC NA C++ compilation follows cfront. OFF
-Xc -Za Select strict ANSI conformance dialect. OFF
-Xk NA Select K&R dialect. OFF
-XO NA C++ compilation follows ARM with anachronisms. OFF
-Xt NA Select ANSI transition dialect. OFF
-XU NA C++ compilation follows ARM and cfront with anachronisms. OFF
-Zp{1|2|4|8|16} -Zp[n]

Specify, in bytes, alignment constraint for structures (n =1,2,4,8,16). Default n =8. This option overrides the default alignment of code.

OFF