12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946 |
- #!/bin/sh -x
- $HOME/intel/oneapi/compiler/latest/linux/bin/intel64/icc --version
- $HOME/intel/oneapi/compiler/latest/linux/bin/intel64/icc -m64 -c -Wall -S -fverbose-asm -qopt-report-embed d4dag.c
- $HOME/intel/oneapi/compiler/latest/linux/bin/intel64/icc -m64 -Wall d4dag.c main.c -o main
- exit 0
- with older icc this generated control flow data
- -mP20P2_il0_print=6
- Intel(R) C++ Compiler Help
- ==========================
- Intel(R) Compiler includes compiler options that optimize for instruction
- sets that are available in both Intel(R) and non-Intel microprocessors, but
- may perform additional optimizations for Intel microprocessors than for
- non-Intel microprocessors. In addition, certain compiler options for
- Intel(R) Compiler are reserved for Intel microprocessors. For a detailed
- description of these compiler options, including the instructions they
- implicate, please refer to "Intel(R) Compiler User and Reference Guides >
- Compiler Options."
- usage: icc [options] file1 [file2 ...]
- icpc [options] file1 [file2 ...]
- where options represents zero or more compiler options
- fileN is a C/C++ source (.C .c .cc .cpp .cxx .c++ .i .ii),
- assembly (.s .S), object (.o), static library (.a), or other
- linkable file
- The icpc command uses the same compiler options as the
- icc command. Invoking the compiler using icpc
- compiles .c and .i files as C++. Invoking the compiler using
- icc compiles .c and .i files as C. Using icpc
- always links in C++ libraries. Using icc only
- links in C++ libraries if C++ source is provided on the command line.
- Commonly used options may be placed in the icc .cfg file.
- Some options listed are only available on a specific system
- i32 indicates the feature is available on systems based on IA-32
- architecture
- i64em indicates the feature is available on systems using Intel(R) 64
- architecture
- Compiler Option List
- --------------------
- Optimization
- ------------
- -O1 optimize for maximum speed, but disable some optimizations which
- increase code size for a small speed benefit
- -O2 optimize for maximum speed (DEFAULT)
- -O3 optimize for maximum speed and enable more aggressive optimizations
- that may not improve performance on some programs
- -O same as -O2
- -Os enable speed optimizations, but disable some optimizations which
- increase code size for small speed benefit
- -O0 disable optimizations
- -Ofast enable -O3 -no-prec-div -fp-model fast=2 optimizations
- -fno-alias
- assume no aliasing in program
- -fno-fnalias
- assume no aliasing within functions, but assume aliasing across calls
- -f[no-]builtin
- disable inline expansion of intrinsic functions
- -fno-builtin-<func>
- disable the <func> intrinsic
- -ffunction-sections
- separate functions for the linker (COMDAT)
- -fdata-sections
- place each data item into its own section
- -f[no-]defer-pop
- disable optimizations which may result in
- deferred clearance of the stack arguments
- -nolib-inline
- disable inline expansion of intrinsic functions
- -f[no-]optimize-sibling-calls
- Optimize sibling and tail recursive calls.
- Enabled at levels -O2, -O3, -Os.
- -f[no-]protect-parens
- enable/disable(DEFAULT) a reassociation optimization for REAL
- and COMPLEX expression evaluations by not honoring parenthesis
- -qsimd-honor-fp-model
- enforces the selected fp-model in SIMD loops.
- Specify -qno-simd-honor-fp-model(DEFAULT) to override
- the fp-model in SIMD loops.
- -qsimd-serialize-fp-reduction
- serializes FP reductions for improved floating point consistency in
- SIMD loops while allowing the rest of the loop to be vectorized.
- Default is -qno-simd-serialize-fp-reduction
- Code Generation
- ---------------
- -x<code> generate specialized code to run exclusively on processors
- indicated by <code> as described below
- SSE2 May generate Intel(R) SSE2 and SSE instructions for Intel
- processors. Optimizes for the Intel NetBurst(R)
- microarchitecture.
- SSE3 May generate Intel(R) SSE3, SSE2, and SSE instructions for
- Intel processors. Optimizes for the enhanced Pentium(R) M
- processor microarchitecture and Intel NetBurst(R)
- microarchitecture.
- SSSE3 May generate Intel(R) SSSE3, SSE3, SSE2, and SSE
- instructions for Intel processors. Optimizes for the
- Intel(R) Core(TM) microarchitecture.
- SSE4.1 May generate Intel(R) SSE4 Vectorizing Compiler and Media
- Accelerator instructions for Intel processors. May
- generate Intel(R) SSSE3, SSE3, SSE2, and SSE instructions
- and it may optimize for Intel(R) 45nm Hi-k next generation
- Intel Core(TM) microarchitecture.
- SSE4.2 May generate Intel(R) SSE4 Efficient Accelerated String
- and Text Processing instructions supported by Intel(R)
- Core(TM) i7 processors. May generate Intel(R) SSE4
- Vectorizing Compiler and Media Accelerator, Intel(R) SSSE3,
- SSE3, SSE2, and SSE instructions and it may optimize for
- the Intel(R) Core(TM) processor family.
- AVX May generate Intel(R) Advanced Vector Extensions (Intel(R)
- AVX), Intel(R) SSE4.2, SSE4.1, SSSE3, SSE3,
- SSE2, and SSE instructions for Intel(R) processors.
- CORE-AVX2
- May generate Intel(R) Advanced Vector Extensions 2
- (Intel(R) AVX2), Intel(R) AVX, SSE4.2, SSE4.1, SSSE3, SSE3,
- SSE2, and SSE instructions for Intel(R) processors.
- CORE-AVX-I
- May generate Intel(R) Advanced Vector Extensions (Intel(R)
- AVX), including instructions in Intel(R) Core 2(TM)
- processors in process technology smaller than 32nm,
- Intel(R) SSE4.2, SSE4.1, SSSE3, SSE3, SSE2, and SSE
- instructions for Intel(R) processors.
- ATOM_SSE4.2
- May generate MOVBE instructions for Intel(R) processors,
- depending on the setting of option -minstruction.
- May also generate Intel(R) SSE4.2, SSE3, SSE2, and SSE
- instructions for Intel processors. Optimizes for Intel(R)
- Atom(TM) processors that support Intel(R) SSE4.2 and MOVBE
- instructions.
- ATOM_SSSE3
- May generate MOVBE instructions for Intel(R) processors,
- depending on the setting of option -minstruction.
- May also generate Intel(R) SSSE3, SSE3, SSE2, and SSE
- instructions for Intel processors. Optimizes for the
- Intel(R) Atom(TM) processor that support Intel(R) SSE
- and MOVBE instructions.
- MIC-AVX512
- May generate Intel(R) Advanced Vector Extensions 512
- (Intel(R) AVX-512) Foundation instructions, Intel(R)
- AVX-512 Conflict Detection instructions, Intel(R) AVX-512
- Exponential and Reciprocal instructions, Intel(R) AVX-512
- Prefetch instructions for Intel(R) processors, and the
- instructions enabled with CORE-AVX2. Optimizes for Intel(R)
- processors that support Intel(R) AVX-512 instructions.
- KNM
- May generate Quad Fused Multiply Add (QFMA) and Quad
- Virtual Neural Network Instruction (QVNNI) and the
- instructions enabled with MIC-AVX512. Optimizes for
- Intel(R) Xeon Phi(TM) product family processor code named
- Knights Mill.
- CORE-AVX512
- May generate Intel(R) Advanced Vector Extensions 512
- (Intel(R) AVX-512) Foundation instructions, Intel(R)
- AVX-512 Conflict Detection instructions, Intel(R) AVX-512
- Doubleword and Quadword instructions, Intel(R) AVX-512
- Byte and Word instructions and Intel(R) AVX-512 Vector
- Length Extensions for Intel(R) processors, and the
- instructions enabled with CORE-AVX2. Optimizes for Intel(R)
- processors that support Intel(R) AVX-512 instructions.
- COMMON-AVX512
- May generate Intel(R) Advanced Vector Extensions 512
- (Intel(R) AVX-512) Foundation instructions, Intel(R)
- AVX-512 Conflict Detection instructions, as well as the
- instructions enabled with CORE-AVX2. Optimizes for Intel(R)
- processors that support Intel(R) AVX-512 instructions.
- BROADWELL
- CANNONLAKE
- HASWELL
- ICELAKE-CLIENT (or ICELAKE)
- ICELAKE-SERVER
- IVYBRIDGE
- KNL
- KNM
- SANDYBRIDGE
- SILVERMONT
- GOLDMONT
- GOLDMONT-PLUS
- TREMONT
- SKYLAKE
- SKYLAKE-AVX512
- CASCADELAKE
- KABYLAKE
- COFFEELAKE
- AMBERLAKE
- WHISKEYLAKE
- TIGERLAKE
- SAPPHIRERAPIDS
- May generate instructions for processors that support the
- specified Intel(R) microarchitecture code name. Optimizes
- for Intel(R) processors that support the specified Intel(R)
- microarchitecture code name.
- Keywords KNL and SILVERMONT are only available on Windows*
- and Linux* systems.
- -xHost generate instructions for the highest instruction set and processor
- available on the compilation host machine
- -ax<code1>[,<code2>,...]
- generate code specialized for processors specified by <codes>
- while also generating generic IA-32 instructions.
- <codes> includes one or more of the following:
- SSE2 May generate Intel(R) SSE2 and SSE instructions for Intel
- processors.
- SSE3 May generate Intel(R) SSE3, SSE2, and SSE instructions for
- Intel processors.
- SSSE3 May generate Intel(R) SSSE3, SSE3, SSE2, and SSE
- instructions for Intel processors.
- SSE4.1 May generate Intel(R) SSE4.1, SSSE3, SSE3, SSE2, and SSE
- instructions for Intel processors.
- SSE4.2 May generate Intel(R) SSE4.2, SSE4.1, SSSE3, SSE3, SSE2,
- and SSE instructions for Intel processors.
- AVX May generate Intel(R) Advanced Vector Extensions (Intel(R)
- AVX), Intel(R) SSE4.2, SSE4.1, SSSE3, SSE3,
- SSE2, and SSE instructions for Intel(R) processors.
- CORE-AVX2
- May generate Intel(R) Advanced Vector Extensions 2
- (Intel(R) AVX2), Intel(R) AVX, SSE4.2, SSE4.1, SSSE3, SSE3,
- SSE2, and SSE instructions for Intel(R) processors.
- CORE-AVX-I
- May generate Intel(R) Advanced Vector Extensions (Intel(R)
- AVX), including instructions in Intel(R) Core 2(TM)
- processors in process technology smaller than 32nm,
- Intel(R) SSE4.2, SSE4.1, SSSE3, SSE3, SSE2, and SSE
- instructions for Intel(R) processors.
- CORE-AVX512
- May generate Intel(R) Advanced Vector Extensions 512
- (Intel(R) AVX-512) Foundation instructions, Intel(R)
- AVX-512 Conflict Detection instructions, Intel(R) AVX-512
- Doubleword and Quadword instructions, Intel(R) AVX-512
- Byte and Word instructions and Intel(R) AVX-512 Vector
- Length Extensions for Intel(R) processors, and the
- instructions enabled with CORE-AVX2.
- BROADWELL
- CANNONLAKE
- HASWELL
- ICELAKE-CLIENT (or ICELAKE)
- ICELAKE-SERVER
- IVYBRIDGE
- KNL
- KNM
- SANDYBRIDGE
- SILVERMONT
- GOLDMONT
- GOLDMONT-PLUS
- TREMONT
- SKYLAKE
- SKYLAKE-AVX512
- CASCADELAKE
- KABYLAKE
- COFFEELAKE
- AMBERLAKE
- WHISKEYLAKE
- TIGERLAKE
- SAPPHIRERAPIDS
- May generate instructions for processors that support the
- specified Intel(R) microarchitecture code name. Optimizes
- for Intel(R) processors that support the specified Intel(R)
- microarchitecture code name.
- Keywords KNL and SILVERMONT are only available on Windows*
- and Linux* systems.
- MIC-AVX512
- May generate Intel(R) Advanced Vector Extensions 512
- (Intel(R) AVX-512) Foundation instructions, Intel(R)
- AVX-512 Conflict Detection instructions, Intel(R) AVX-512
- Exponential and Reciprocal instructions, Intel(R) AVX-512
- Prefetch instructions for Intel(R) processors, and the
- instructions enabled with CORE-AVX2.
- KNM
- May generate Quad Fused Multiply Add (QFMA) and Quad
- Virtual Neural Network Instruction (QVNNI) and the
- instructions enabled with MIC-AVX512
- -mcpu=<cpu>
- same as -mtune=<cpu>
- -mtune=<cpu>
- optimize for a specific <cpu>
- generic - Optimizes code for the compiler's default behavior
- broadwell
- haswell
- ivybridge
- knl
- knm
- sandybridge
- silvermont
- cannonlake
- icelake
- skylake-avx512
- skylake - Optimizes code for processors that support the
- specified Intel(R) microarchitecture code name.
- knl and silvermont are only available on Windows* and
- Linux* systems
- core-avx2 - Optimizes code for processors that support Intel(R)
- Advanced Vector Extensions 2 (Intel(R) AVX2), Intel(R)
- AVX, SSE4.2 SSE4.1, SSE3, SSE2, SSE, and SSSE3
- instructions
- core-avx-i - Optimizes code for processors that support Float-16
- conversion instructions and the RDRND instruction,
- Intel(R) Advanced Vector Extensions (Intel(R) AVX),
- Intel(R) SSE4.2, SSE4.1, SSE3, SSE2, SSE, and SSSE3
- instructions
- corei7-avx - Optimizes code for processors that support Intel(R)
- Advanced Vector Extensions (Intel(R) AVX), Intel(R)
- SSE4.2, SSE4.1, SSE3, SSE2, SSE, and SSSE3
- instructions
- corei7 - Optimizes code for processors that support Intel(R)
- SSE4 Efficient Accelerated String and Text Processing
- instructions. May also generate code for Intel(R) SSE4
- Vectorizing Compiler and Media Accelerator, Intel(R)
- SSE3, SSE2, SSE, and SSSE3 instructions
- atom - Optimizes code for processors that support MOVBE
- instructions, depending on the setting of option
- -minstruction (Linux and macOS*) or /Qinstruction
- (Windows). May also generate code for SSSE3
- instructions and Intel(R) SSE3, SSE2, and SSE
- instructions
- core2 - Optimizes for the Intel(R) Core(TM) 2 processor
- family, including support for MMX(TM), Intel(R) SSE,
- SSE2, SSE3, and SSSE3 instruction sets.
- pentium-mmx - Optimizes for Intel(R) Pentium(R) with MMX technology
- pentiumpro - Optimizes for Intel(R) Pentium(R) Pro, Intel Pentium
- II, and Intel Pentium III processors
- pentium4m - Optimizes for Intel(R) Pentium(R) 4 processors with
- MMX technology
- pentium-m
- pentium4
- pentium3
- pentium - Optimizes code for Intel(R) Pentium(R) processors.
- Value pentium3 is only available on Linux systems
- -march=<cpu>
- generate code exclusively for a given <cpu>
- broadwell
- cannonlake
- haswell
- icelake
- ivybridge
- knl
- knm
- sandybridge
- silvermont
- skylake-avx512
- skylake - Generates code for processors that support the
- specified Intel(R) microarchitecture code name.
- Keywords knl and silvermont are only available on
- Linux* systems.
- core-avx2 - Generates code for processors that support Intel(R)
- Advanced Vector Extensions 2 (Intel(R) AVX2), Intel(R)
- AVX, SSE4.2 SSE4.1, SSE3, SSE2, SSE, and SSSE3
- instructions
- core-avx-i - Generates code for processors that support Float-16
- conversion instructions and the RDRND instruction,
- Intel(R) Advanced Vector Extensions (Intel(R) AVX),
- Intel(R) SSE4.2, SSE4.1, SSE3, SSE2, SSE, and SSSE3
- instructions
- corei7-avx - Generates code for processors that support Intel(R)
- Advanced Vector Extensions (Intel(R) AVX), Intel(R)
- SSE4.2, SSE4.1, SSE3, SSE2, SSE, and SSSE3
- instructions
- corei7 - Generates code for processors that support Intel(R)
- SSE4 Efficient Accelerated String and Text Processing
- instructions. May also generate code for Intel(R) SSE4
- Vectorizing Compiler and Media Accelerator, Intel(R)
- SSE3, SSE2, SSE, and SSSE3 instructions
- atom - Generates code for processors that support MOVBE
- instructions, depending on the setting of option
- -minstruction (Linux and macOS*) or /Qinstruction
- (Windows). May also generate code for SSSE3
- instructions and Intel(R) SSE3, SSE2, and SSE
- instructions
- core2 - Generates for the Intel(R) Core(TM) 2 processor
- family
- pentium4m - Generates for Intel(R) Pentium(R) 4 processors with
- MMX technology
- pentium-m
- pentium4
- pentium3
- pentium - Generates code for Intel(R) Pentium(R) processors.
- Value pentium3 is only available on Linux systems
- -msse3 May generate Intel(R) SSE3, SSE2, and SSE instructions
- -mssse3 May generate Intel(R) SSSE3, SSE3, SSE2, and SSE instructions
- -msse4 Enable -msse4.2
- -msse4.1 May generate Intel(R) SSE4.1, SSSE3, SSE3, SSE2, and SSE instructions
- -msse4.2 May generate Intel(R) SSE4.2, SSE4.1, SSSE3, SSE3, SSE2, and SSE
- instructions
- -mavx May generate Intel(R) AVX, SSE4.2, SSE4.1, SSSE3, SSE3, SSE2, and SSE
- instructions
- -masm=<dialect>
- generate asm instructions specified by <dialect>, which may be
- att (DEFAULT) or intel
- -minstruction=<keyword>
- Refine instruction set output for the selected target processor
- [no]movbe - Do/do not generate MOVBE instructions with ATOM_SSSE3
- (requires -xATOM_SSSE3)
- -f[no-]omit-frame-pointer
- enable(DEFAULT)/disable use of EBP as general purpose register.
- -fno-omit-frame-pointer replaces -fp
- -f[no-]exceptions
- enable/disable exception handling table generation
- The default for C++ is -fexceptions (enabled)
- The default for C is -fno-exceptions (disabled)
- -f[no-]fat-lto-objects
- enable/disable generation of true code/data when generating an
- IL object using -ipo -c. Objects generated with -ffat-lto-objects
- or -fno-fat-lto-objects are added unmodified to an archive when
- using xiar. xiar behavior remains unchanged for an IL object
- generated without specifying -f[no-]fat-lto-objects.
- -fnon-call-exceptions
- enable/disable(DEFAULT) code that allows exceptions from trapping
- instructions to be caught
- -regcall make __regcall the default calling convention
- -mno-sse disable the generation of SSE instructions
- -hotpatch[=n]
- generate padding bytes for function entries to enable image
- hotpatching. If specified, use 'n' as the padding.
- -fasynchronous-unwind-tables
- determines whether unwind information is precise at an instruction
- boundary or at a call boundary. -fno-asynchronous-unwind-tables is
- the default for IA-32 architecture.
- -fextend-arguments=[32|64]
- By default, unprototyped scalar integer arguments are passed
- in 32-bits (sign-extended if necessary).
- On Intel(R) 64, unprototyped scalar integer arguments may be
- extended to 64-bits.
- -m32 generate code for IA-32 architecture
- -m64 generate code for Intel(R) 64 architecture
- -m[no-]omit-leaf-frame-pointer
- determines whether the frame pointer is omitted or kept in leaf
- functions
- -m80387 Specify whether the compiler can use x87 instructions.
- Use -mno-80387 to disable.
- -mx87 Same as -m80387
- -mstringop-strategy=<alg>
- Override the internal decision heuristic for the particular algorithm
- to use for inlining string operations. The allowed values for <alg>:
- rep - Expand using i386 "rep" prefix (DEFAULT for -Os)
- const_size_loop - Expand into an inline loop when size is known at
- compile time (DEFAULT)
- libcall - Always use a library call.
- -mstringop-inline-threshold=<val>
- inline calls to memcall-like (memcpy, memset) functions when the
- number of bytes the functions handle are known at compile time and
- less than <val>
- -fcf-protection[=<arg>]
- Enables Control-flow Enforcement Technology (CET) protection, which
- defends your program from certain attacks that exploit
- vulnerabilities.
- branch - do control-flow instrumentation for indirect branches
- return - do control-flow instrumentation for function returns
- full - alias to specify both branch and return (same as no <arg>)
- none - turn off instrumentation
- -mauto-arch=<code1>[,<code2>,...]
- generate multiple, feature-specific auto-dispatch code paths for x86
- architecture processors if there is a performance benefit. The
- accepted arguments match those of option '-ax'
- Interprocedural Optimization (IPO)
- ----------------------------------
- -[no-]ip enable(DEFAULT)/disable single-file IP optimization
- within files
- -ipo[n] enable multi-file IP optimization between files
- -ipo-c generate a multi-file object file (ipo_out.o)
- -ipo-S generate a multi-file assembly file (ipo_out.S)
- -ip-no-inlining
- disable full and partial inlining
- -ip-no-pinlining
- disable partial inlining
- -ipo-separate
- create one object file for every source file (overrides -ipo[n])
- -ipo-jobs<n>
- specify the number of jobs to be executed simultaneously during the
- IPO link phase
- Advanced Optimizations
- ----------------------
- -unroll[n]
- set maximum number of times to unroll loops. Omit n to use default
- heuristics. Use n=0 to disable the loop unroller
- -[no-]unroll-aggressive
- enables more aggressive unrolling heuristics
- -funroll-loops
- unroll loops based on default heuristics
- -[no-]scalar-rep
- enable(DEFAULT)/disable scalar replacement (requires -O3)
- -[no-]ansi-alias
- enable(DEFAULT)/disable use of ANSI aliasing rules optimizations;
- user asserts that the program adheres to these rules
- -[no-]ansi-alias-check
- enable(DEFAULT)/disable ANSI alias checking when using -ansi-alias
- -[no-]complex-limited-range
- enable/disable(DEFAULT) the use of the basic algebraic expansions of
- some complex arithmetic operations. This can allow for some
- performance improvement in programs which use a lot of complex
- arithmetic at the loss of some exponent range.
- -[no-]alias-const
- enable/disable(DEFAULT) a heuristic stating that if two arguments to
- a function have pointer type, a pointer to const does not alias a
- pointer to non-const. Also known as the input/output buffer rule, it
- assumes that input and output buffer arguments do not overlap.
- -fargument-alias
- arguments may alias each other and may alias global storage
- -fargument-noalias
- arguments do not alias each other but may alias global storage
- -fargument-noalias-global
- arguments do not alias each other and do not alias global storage
- -ftls-model=<model>
- change thread-local storage model, where <model> can be the
- following: global-dynamic, local-dynamic, initial-exec or local-exec
- -q[no-]opt-multi-version-aggressive
- enables more aggressive multi-versioning to check for pointer
- aliasing and scalar replacement
- -qopt-ra-region-strategy[=<keyword>]
- select the method that the register allocator uses to partition each
- routine into regions
- routine - one region per routine
- block - one region per block
- trace - one region per trace
- loop - one region per loop
- default - compiler selects best option
- -[no-]vec
- enables(DEFAULT)/disables vectorization
- -[no-]vec-guard-write
- enables cache/bandwidth optimization for stores under conditionals
- within vector loops
- -vec-threshold[n]
- sets a threshold for the vectorization of loops based on the
- probability of profitable execution of the vectorized loop in
- parallel
- -vecabi=<arg>
- select vector function ABI
- legacy - use the legacy vector function ABI
- compat - use the compatibility vector function ABI (DEFAULT)
- cmdtarget - generate an extended set of vector functions
- gcc - use GCC compatible ABI
- -qopt-malloc-options={0|1|2|3|4}
- specify malloc configuration parameters. Specifying a non-zero <n>
- value will cause alternate configuration parameters to be set for
- how malloc allocates and frees memory
- -qopt-calloc
- enable/disable(DEFAULT) calls to fast calloc function
- -qopt-jump-tables=<arg>
- control the generation of jump tables
- default - let the compiler decide when a jump table, a series of
- if-then-else constructs or a combination is generated
- large - generate jump tables up to a certain pre-defined size
- (64K entries)
- <n> - generate jump tables up to <n> in size
- use -qno-opt-jump-tables to lower switch statements as chains of
- if-then-else constructs
- -fno-jump-tables
- do not generate jump tables for switches and if-then-else statements
- -qopt-block-factor=<n>
- specify blocking factor for loop blocking
- -ffreestanding
- compile in a freestanding environment where the standard library
- may not be present
- -qopt-streaming-stores=<arg>
- specifies whether streaming stores are generated
- always - enables generation of streaming stores under the
- assumption that the application is memory bound. Also,
- the user is responsible for inserting the right memory
- fences for synchronization
- auto - compiler decides when streaming stores are used (DEFAULT)
- never - disables generation of streaming stores
- -ipp[=<arg>]
- link some or all of the Intel(R) Integrated Performance Primitives
- (Intel(R) IPP) libraries and bring in the associated headers
- common - link using the main libraries set. This is the
- default value when -ipp is specified
- crypto - link using the main libraries set and the crypto
- library
- -ipp-link=<arg>
- choose whether to link with static or dynamic libraries to support
- Intel(R) Integrated Performance Primitives (Intel(R) IPP)
- dynamic - link using the dynamic libraries set. This is the
- default value when -ipp is specified on Windows
- static - link using the static libraries set. This is the
- default value when -ipp is specified on Linux
- nonpic - link using the version of the libraries that do not
- have position independent code
- nonpic_crypto - link using the crypto library and the version of
- the libraries that do not have position independent
- code
- -mkl[=<arg>]
- link to the Intel(R) Math Kernel Library (Intel(R) MKL) and bring
- in the associated headers
- parallel - link using the threaded Intel(R) MKL libraries. This
- is the default when -mkl is specified
- sequential - link using the non-threaded Intel(R) MKL libraries
- cluster - link using the Intel(R) MKL Cluster libraries plus
- the sequential Intel(R) MKL libraries
- -tbb link to the Intel(R) Threading Building Blocks (Intel(R) TBB)
- libraries and bring in the associated headers
- -daal[=<arg>]
- link to the Intel(R) Data Analytics Acceleration Library (Intel(R)
- DAAL) libraries and bring in the associated headers
- parallel - link using the threaded Intel(R) DAAL (DEFAULT)
- sequential - link using the non-threaded Intel(R) DAAL
- -q[no-]opt-subscript-in-range
- assumes no overflows in the intermediate computation of the
- subscripts
- -[no-]use-intel-optimized-headers
- take advantage of the optimized header files
- -[no-]intel-extensions
- enable(DEFAULT)/disable C/C++ language extensions such as array
- notation, Intel(R) Cilk(TM) Plus language extensions, and
- support for decimal floating-point types.
- -q[no-]opt-matmul
- replace matrix multiplication with calls to intrinsics and threading
- libraries for improved performance (DEFAULT at -O3 -parallel)
- -[no-]simd
- enables(DEFAULT)/disables vectorization using simd pragma
- -[no-]simd-function-pointers
- enables/disables(DEFAULT) pointers to simd-enabled functions
- -guide-opts=<arg>
- tells the compiler to analyze certain code and generate
- recommendations that may improve optimizations
- -guide-file[=<filename>]
- causes the results of guide to be output to a file
- -guide-file-append[=<filename>]
- causes the results of guide to be appended to a file
- -guide[=<level>]
- lets you set a level (1 - 4) of guidance for auto-vectorization,
- auto-parallelization, and data transformation (DEFAULT is 4 when the
- option is specified)
- -guide-data-trans[=<level>]
- lets you set a level (1 - 4) of guidance for data transformation
- (DEFAULT is 4 when the option is specified)
- -guide-par[=<level>]
- lets you set a level (1 - 4) of guidance for auto-parallelization
- (DEFAULT is 4 when the option is specified)
- -guide-vec[=<level>]
- lets you set a level (1 - 4) of guidance for auto-vectorization
- (DEFAULT is 4 when the option is specified)
- -qopt-mem-layout-trans[=<level>]
- controls the level of memory layout transformations performed by the
- compiler
- 0 - disable memory layout transformations (same as
- -qno-opt-mem-layout-trans)
- 1 - enable basic memory layout transformations
- 2 - enable more memory layout transformations (DEFAULT when the
- option is specified)
- 3 - enable aggressive memory layout transformations
- -qopt-prefetch[=n]
- enable levels of prefetch insertion, where 0 disables.
- n may be 0 through 5 inclusive. Default is 2.
- -qno-opt-prefetch
- disable(DEFAULT) prefetch insertion. Equivalent to -qopt-prefetch=0
- -qopt-prefetch-distance=n1[,n2]
- specify the prefetch distance (how many iterations ahead, use n1 and
- n2 values such that n1>=n2) to be used for compiler generated
- prefetches inside loops. n1 indicates distance from memory to L2
- cache and n2 indicates distance from L2 to L1.
- -qopt-prefetch-issue-excl-hint
- generates PrefetchW instruction for Intel(R) microarchitecture
- code name Broadwell processors and beyond when -qopt-prefetch
- is also used
- -qopt-threads-per-core=n
- specifies the number of threads (1 - 4) per core to be used for an
- application (Intel(R) MIC Architecture specific)
- -qopt-streaming-cache-evict=n
- specifies the cache line eviction level (0 - 3) when streaming
- loads/stores are used. (Intel(R) MIC Architecture specific)
- -qopt-gather-scatter-unroll=n
- specify an alternative loop unroll sequence for gather and scatter
- loops (Intel(R) MIC Architecture specific). Disable with
- -qno-opt-gather-scatter-unroll (equivalent to n=0)
- -qopt-dynamic-align
- enable(DEFAULT) dynamic data alignment optimizations. Specify
- -qno-opt-dynamic-align to disable
- -falign-loops[=n]
- specify code alignment of loops to improve performance.
- n is the number of bytes for the minimum alignment boundary. It must
- be a power of 2 between 1 and 4096. If n is not present, an
- alignment of 16 bytes is used.
- Use of -fno-align-loops (DEFAULT) sets alignment to 1.
- -qopt-zmm-usage=<keyword>
- Specifies the level of zmm registers usage. You can specify one of
- the following:
- low - Tells the compiler that the compiled program is unlikely to
- benefit from zmm registers usage. It specifies that the
- compiler should avoid using zmm registers unless it can
- prove the gain from their usage.
- high - Tells the compiler to generate zmm code without restrictions
- -qoverride-limits
- provides a way to override certain internal compiler limits that are
- intended to prevent excessive memory usage or compile times for very
- large, complex compilation units.
- -q[no-]opt-multiple-gather-scatter-by-shuffles
- Enables or disables the optimization for multiple adjacent
- gather/scatter type vector memory references.
- -m[no-]branches-within-32B-boundaries
- enable/disable(DEFAULT) aligning branches and fused branches on
- 32-byte boundaries
- Profile Guided Optimization (PGO)
- ---------------------------------
- -prof-dir <dir>
- specify directory for profiling output files (*.dyn and *.dpi)
- -prof-src-root <dir>
- specify project root directory for application source files to
- enable relative path resolution during profile feedback on sources
- below that directory
- -prof-src-root-cwd
- specify the current directory as the project root directory for
- application source files to enable relative path resolution during
- profile feedback on sources below that directory
- -[no-]prof-src-dir
- specify whether directory names of sources should be
- considered when looking up profile records within the .dpi file
- -prof-file <file>
- specify file name for profiling summary file
- -[no-]prof-data-order
- enable/disable(DEFAULT) static data ordering with profiling
- -[no-]prof-func-order
- enable/disable(DEFAULT) function ordering with profiling
- -[no-]prof-func-groups
- enable(DEFAULT with PGO)/disable function grouping
- -prof-gen[=keyword[,keyword]]
- instrument program for profiling. Optional keywords are as follows.
- default - Produces an instrumented object file. This is the same
- as specifying the -prof-gen option with no keyword.
- srcpos - Produces an instrumented object file and information
- needed for using the code coverage tool.
- globdata - Produces an instrumented object file that includes
- information for global data layout.
- threadsafe - Collects PGO data with guards for threaded
- applications.
- -no-prof-gen
- disable profiling instrumentation
- -prof-use[=<arg>]
- enable use of profiling information during optimization
- weighted - invokes profmerge with -weighted option to scale data
- based on run durations
- [no]merge - enable(default)/disable the invocation of the profmerge
- tool
- -no-prof-use
- disable use of profiling information during optimization
- -fnsplit[=<n>]
- enable function splitting (enabled with /Qprof-use for IA-32 Windows)
- n - positive integer indicating the threshold number. The blocks
- can be placed into a different code segment if their
- execution probability is less than the specified value of
- range 0 <= n <= 100
- use -no-fnsplit to disable
- -p compile and link for function profiling with UNIX gprof tool
- On IA32 and Intel(r)64, -pg is also valid
- -f[no-]instrument-functions
- determine whether function entry and exit points are instrumented
- -prof-hotness-threshold=<val>
- set the hotness threshold for function grouping and function ordering
- val indicates percentage of functions to be placed in hot region.
- This option requires -prof-use
- and -prof-func-groups or -prof-func-order
- -prof-value-profiling=<arg>[,<arg>,...]
- limit value profiling
- none - inhibit all types of value profiling
- nodivide - inhibit value profiling of non-compile time constants
- used in division or remainder operations
- noindcall - inhibit value profiling of function addresses at
- indirect call sites
- -prof-gen-sampling
- prepares application executables for hardware profiling (sampling)
- and causes the compiler to generate source code mapping information
- -prof-use-sampling=file[:file:...]
- enable use of hardware profiling (sampling) information during
- optimization. Argument provides list of one or more profiling data
- files to apply
- Optimization Reports
- --------------------
- -qopt-report[=n]
- generate an optimization report. Default destination is
- <target>.optrpt. Levels of 0 - 5 are valid.
- Please see documentation for additional details of
- information provided by phase per level.
- 0 disable optimization report output
- 2 DEFAULT when enabled
- -qopt-report-file=[stdout | stderr | <file>]
- specify the filename or output stream for the generated report
- -qopt-report-stdout
- specify the generated report should be directed to stdout
- -qopt-report-per-object
- specify the generated report should be directed to a .optrpt file
- in the output directory (DEFAULT when another destination for the
- report is not specified)
- -qopt-report-phase=<phase>[,<phase>,...]
- specify one or more phases that reports are generated against
- -qopt-report-routine=<name>[,<name>,...]
- restrict the report to routines containing the given name
- -qopt-report-filter=<string>
- restricts the opt-report to specific files, routines or line
- number ranges. Refer to the documentation for the specific
- syntax of parameter string.
- -qopt-report-format=[text|vs]
- specify the output format to be used for the opt-report as either
- plain text or a format for use in the Microsoft* Visual Studio IDE
- -q[no-]opt-report-embed
- When enabled, if an assembly file is being generated, special loop
- info annotations will be emitted in the assembly file. If an object
- file/executable is being generated, these will be emitted into the
- object file/executable for use by the Intel VTune Amplifier
- application. Automatically enabled when symbolic debug information
- is enabled.
- -qopt-report-help
- display the optimization phases available for reporting
- -qopt-report-names=<keyword>
- Specifies whether mangled or unmangled names should appear in the
- optimization report.
- mangled - use mangled names
- unmangled - use unmangled names (DEFAULT)
- -qopt-report-annotate[=<keyword>]
- Annotate source files with optimization reports in specified format
- html - annotate in HTML format
- text - annotate in text format (DEFAULT)
- -qopt-report-annotate-position=<keyword>
- Specify the site where loop related optimization reports appear in
- the annotated source for inlined routines
- caller - annotate at caller site
- callee - annotate at callee site
- both - annotate at both caller and callee site
- -tcheck [mode]
- enable analysis of threaded applications (requires Intel(R) Thread
- Checker; cannot be used with compiler alone)
- tci - instruments a program to perform a thread-count-independent
- analysis
- tcd - instruments a program to perform a thread-count-dependent
- analysis (DEFAULT when mode is not used)
- api - instruments a program at the api-imports level
- -tcollect[=<lib>]
- inserts instrumentation probes calling the Intel(R) Trace Collector
- API. The library -l<lib> is linked in the default being -lVT
- (requires Intel(R) Trace Collector)
- -tcollect-filter file
- Enable or disable the instrumentation of specified functions.
- (requires Intel(R) Trace Collector)
- OpenMP* and Parallel Processing
- ------------------------------
- -qopenmp enable the compiler to generate multi-threaded code based on the
- OpenMP* directives (same as -fopenmp)
- Use -qno-openmp to disable
- -qopenmp-stubs
- enables the user to compile OpenMP programs in sequential mode. The
- OpenMP directives are ignored and a stub OpenMP library is linked
- (sequential)
- -qopenmp-lib=<ver>
- choose which OpenMP library version to link with
- compat - use the GNU compatible OpenMP run-time libraries
- (DEFAULT)
- -qopenmp-link=<library>
- choose whether to link with the static or dynamic OpenMP
- libraries. Default is dynamic.
- -qopenmp-threadprivate=<ver>
- choose which threadprivate implementation to use
- compat - use the GNU compatible thread local storage
- legacy - use the Intel compatible implementation
- (DEFAULT)
- -parallel
- enable the auto-parallelizer to generate multi-threaded code for
- loops that can be safely executed in parallel
- -par-threshold[n]
- set threshold for the auto-parallelization of loops where n is an
- integer from 0 to 100
- -par-runtime-control[n]
- Control parallelizer to generate runtime check code for effective
- automatic parallelization.
- n=0 no runtime check based auto-parallelization
- n=1 generate runtime check code under conservative mode
- (DEFAULT when enabled)
- n=2 generate runtime check code under heuristic mode
- n=3 generate runtime check code under aggressive mode
- -par-schedule-static[=n]
- Specifies a scheduling algorithm for DO loop iteration.
- Divides iterations into contiguous pieces. Size n if
- specified, equal sized pieces if not.
- -par-schedule-static-balanced[=n]
- Divides iterations into even-sized chunks. Size n if
- specified, equal sized pieces if not.
- -par-schedule-static-steal[=n]
- Divides iterations into even-sized chunks, but allows
- threads to steal parts of chunks from neighboring threads
- -par-schedule-dynamic[=n]
- Specifies a scheduling algorithm for DO loop iteration.
- Assigns iterations to threads in chunks dynamically.
- Chunk size is n iterations if specified, otherwise 1.
- -par-schedule-guided[=n]
- Specifies a scheduling algorithm for DO loop iteration.
- Indicates a minimum number of iterations. If specified,
- n is the minimum number, otherwise 1.
- -par-schedule-guided-analytical[=n]
- Divides iterations by using exponential distribution or
- dynamic distributions.
- -par-schedule-runtime
- Specifies a scheduling algorithm for DO loop iteration.
- Defers the scheduling decision until runtime.
- -par-schedule-auto
- Lets the compiler or run-time system determine the
- scheduling algorithm.
- -par-affinity=[<modifier>,...]<type>[,<permute>][,<offset>]
- tune application performance by setting different thread affinity
- -par-num-threads=<n>
- tune application performance by setting different number of threads
- -parallel-source-info[=n]
- enable(DEFAULT)/disable the emission of source location information
- for parallel code generation with OpenMP and auto-parallelization
- 0 - disable (same as -no-parallel-source-info)
- 1 - emit routine name and line information (DEFAULT)
- 2 - emit path, file, routine name and line information
- -qopenmp-simd
- Enables OpenMP* SIMD compilation. Enabled by default with
- -qopenmp. Use -qno-openmp-simd to disable.
- -qopenmp-offload[=<kind>]
- Enables OpenMP* offloading compilation for target pragmas.
- Enabled by default with -qopenmp.
- Use -qno-openmp-offload to disable.
- Specify kind to specify the default device for target pragmas
- host - allow target code to run on host system while still doing
- the outlining for offload
- -f[no-]mpc_privatize
- Enables privatization of all static data for the MPC
- unified parallel runtime. This will cause calls to
- extended thread local storage resolution run-time routines
- which are not supported on standard linux distributions.
- This option is only usable in conjunction with the MPC
- unified parallel runtime. The default is -fno-mpc-privatize.
- -par-loops=<arg>
- Select between old or new implementations of parallel loop support.
- The default is -par-loops=new
- Floating Point
- --------------
- -fp-model <name>
- enable <name> floating point model variation
- [no-]except - enable/disable floating point exception semantics
- fast[=1|2] - enables more aggressive floating point optimizations
- precise - allows value-safe optimizations
- source - enables intermediates in source precision
- sets -assume protect_parens for Fortran
- strict - enables -fp-model precise -fp-model except, disables
- contractions and enables pragma stdc fenv_access
- consistent - enables consistent, reproducible results for
- different optimization levels or between different
- processors of the same architecture
- double - rounds intermediates in 53-bit (double) precision
- extended - rounds intermediates in 64-bit (extended) precision
- -fp-speculation=<mode>
- enable floating point speculations with the following <mode>
- conditions:
- fast - speculate floating point operations (DEFAULT)
- safe - speculate only when safe
- strict - same as off
- off - disables speculation of floating-point operations
- -pc32 set internal FPU precision to 24 bit significand
- -pc64 set internal FPU precision to 53 bit significand
- -pc80 set internal FPU precision to 64 bit significand (DEFAULT)
- -mp1 improve floating-point precision
- -mieee-fp
- maintain floating point precision (disables some optimizations)
- can be disabled with -mno-ieee-fp
- -[no-]prec-sqrt
- determine if certain square root optimizations are enabled
- -[no-]prec-div
- improve precision of FP divides (some speed impact)
- -[no-]fast-transcendentals
- generate a faster version of the transcendental functions
- -[no-]fp-port
- round fp results at assignments and casts (some speed impact)
- -fp-stack-check
- enable fp stack checking after every function/procedure call
- -rcd rounding mode to enable fast float-to-int conversions
- -[no-]ftz
- enable/disable flush denormal results to zero
- -[no-]fma
- enable/disable the combining of floating point multiplies and
- add/subtract operations
- -fp-trap=<arg>[,<arg>,...]
- control floating point traps at program start. <arg> can be of the
- following values
- [no]divzero - [Do not] trap on division by zero
- [no]inexact - [Do not] trap on inexact result
- [no]invalid - [Do not] trap on invalid operation
- [no]overflow - [Do not] trap on overflow
- [no]underflow - [Do not] trap on underflow
- [no]denormal - [Do not] trap on denormal
- all - enable trap on all of the above
- none - trap on none of the above
- common - trap on most commonly used IEEE traps
- (invalid, division by zero, overflow)
- -fp-trap-all=<arg>[,<arg>,...]
- control floating point traps in every routine. <arg> can be of the
- values specified in -fp-trap
- -fimf-absolute-error=value[:funclist]
- define the maximum allowable absolute error for math library
- function results
- value - a positive, floating-point number conforming to the
- format [digits][.digits][{e|E}[sign]digits]
- funclist - optional comma separated list of one or more math
- library functions to which the attribute should be
- applied
- -fimf-accuracy-bits=bits[:funclist]
- define the relative error, measured by the number of correct bits,
- for math library function results
- bits - a positive, floating-point number
- funclist - optional comma separated list of one or more math
- library functions to which the attribute should be
- applied
- -fimf-arch-consistency=value[:funclist]
- ensures that the math library functions produce consistent results
- across different implementations of the same architecture
- value - true or false
- funclist - optional comma separated list of one or more math
- library functions to which the attribute should be
- applied
- -fimf-max-error=ulps[:funclist]
- defines the maximum allowable relative error, measured in ulps, for
- math library function results
- ulps - a positive, floating-point number conforming to the
- format [digits][.digits][{e|E}[sign]digits]
- funclist - optional comma separated list of one or more math
- library functions to which the attribute should be
- applied
- -fimf-precision=value[:funclist]
- defines the accuracy (precision) for math library functions
- value - defined as one of the following values
- high - equivalent to max-error = 1.0
- medium - equivalent to max-error = 4 (DEFAULT)
- low - equivalent to accuracy-bits = 11 (single
- precision); accuracy-bits = 26 (double
- precision)
- reference - equivalent to 'high' accuracy with correct
- signaling of exceptional conditions through
- the errno and status flags settings. This
- setting is initially available only on Linux*
- systems
- funclist - optional comma separated list of one or more math
- library functions to which the attribute should be
- applied
- -fimf-domain-exclusion=classlist[:funclist]
- indicates the input arguments domain on which math functions
- must provide correct results.
- classlist - defined as one of the following values:
- nans, infinities, denormals, zeros
- all, none, common
- funclist - optional list of one or more math library functions to
- which the attribute should be applied.
- -fimf-force-dynamic-target[=funclist]
- Instructs the compiler to use run-time dispatch in calls to math
- functions
- funclist - optional list of one or more math library functions to
- which the attribute should be applied.
- -fimf-use-svml=value[:funclist]
- Instructs the compiler to implement math library functions using
- the Short Vector Math Library(SVML)
- value - true or false
- funclist - optional comma separated list of one or more math
- library functions to which the attribute should be
- applied
- -ffinite-math-only
- Allow optimizations for floating point arithmetic that assume
- arguments and results are not NaNs or Infinities
- Inlining
- --------
- -inline-level=<n>
- control inline expansion:
- n=0 disable inlining
- n=1 inline functions declared with __inline, and perform C++
- inlining
- n=2 inline any function, at the compiler's discretion
- -f[no-]inline
- inline functions declared with __inline, and perform C++ inlining
- -f[no-]inline-functions
- inline any function at the compiler's discretion
- -finline-limit=<n>
- set maximum number of statements a function can have and still be
- considered for inlining
- -fgnu89-inline
- use C89 semantics for "inline" functions when in C99 mode
- -inline-min-size=<n>
- set size limit for inlining small routines
- -no-inline-min-size
- no size limit for inlining small routines
- -inline-max-size=<n>
- set size limit for inlining large routines
- -no-inline-max-size
- no size limit for inlining large routines
- -inline-max-total-size=<n>
- maximum increase in size for inline function expansion
- -no-inline-max-total-size
- no size limit for inline function expansion
- -inline-max-per-routine=<n>
- maximum number of inline instances in any function
- -no-inline-max-per-routine
- no maximum number of inline instances in any function
- -inline-max-per-compile=<n>
- maximum number of inline instances in the current compilation
- -no-inline-max-per-compile
- no maximum number of inline instances in the current compilation
- -inline-factor=<n>
- set inlining upper limits by n percentage
- -no-inline-factor
- do not set set inlining upper limits
- -inline-forceinline
- treat inline routines as forceinline
- -inline-calloc
- directs the compiler to inline calloc() calls as malloc()/memset()
- -inline-min_caller-growth=<n>
- set lower limit on caller growth due to inlining a single routine
- -no-inline-min-caller-growth
- no lower limit on caller growth due to inlining a single routine
- Output, Debug, PCH
- ------------------
- -c compile to object (.o) only, do not link
- -S compile to assembly (.s) only, do not link
- -fsource-asm
- produce assembly file with optional source annotations (requires -S)
- -f[no-]verbose-asm
- produce assembly file with compiler comments (DEFAULT) (requires -S)
- -fcode-asm
- produce assembly file with optional code annotations (requires -S)
- -use-msasm
- support Microsoft* style assembly language insertion using MASM style
- syntax
- -fasm-blocks
- enables the use of blocks and entire functions of assembly code
- within a C or C++ file
- -Fa[file]
- name assembly file (or directory for multiple files; i.e. /FaMYDIR\)
- -Fo[file]
- name object file (or directory for multiple files; i.e. /FoMYDIR\)
- -o <file>
- name output file
- -g[level]
- Produce symbolic debug information.
- Valid [level] values:
- 0 - Disable generation of symbolic debug information.
- 1 - Emit minimal debug information for performing stack traces.
- 2 - Emit complete debug information. (default for -g)
- 3 - Emit extra information which may be useful for some tools.
- -gdwarf-<version>
- Enable generation of debug information using the specified DWARF
- version. These options may require additional tools such as linkers
- and debuggers which support these formats.
- Valid <version> values:
- 2 - DWARF Debug Information Format Version 2.
- 3 - DWARF Debug Information Format Version 3. (default for -g)
- 4 - DWARF Debug Information Format Version 4.
- -gsplit-dwarf
- Generates an additional output file containing most of the debug
- information. This reduces the size of objects processed by the
- linker. The additional output file will be given a .dwo file
- extension. This option may require additional tools which support
- DWARF object files.
- -debug [keyword]
- Control the emission of debug information.
- Valid [keyword] values:
- none
- Disables debug generation.
- all, full (default if no keyword was specified)
- Generates complete debug information.
- minimal
- Generates line number information.
- extended
- Generates complete debug information with semantic stepping
- and variable locations enabled.
- [no]variable-locations
- Controls additional debug information useful for tracking
- variable values in optimized code.
- [no]semantic-stepping
- Controls additional debug information useful for stepping
- through optimized code.
- [no]pubnames
- Controls generation of the DWARF .debug_pubnames section.
- [no]emit-column
- Controls additional line number information with columns.
- [no]inline-debug-info
- Controls additional debug information for inlined code.
- [no]expr-source-pos
- Controls output of source positions for expressions.
- [no]macros
- Controls output of debug information for preprocessor macros.
- [no-]biendian
- Controls output of additional debug information for endianity.
- parallel
- Emit code instrumentation useful for thread data sharing and
- reentrant call detection.
- -grecord-gcc-switches
- Record command line options in the DW_AT_producer attribute in
- the DWARF debugging information.
- -fvar-tracking
- Same as "-debug variable-locations".
- -fvar-tracking-assignments
- Same as "-debug semantic-stepping".
- -f[no-]dwarf2-cfi-asm
- Control whether the compiler should generate CFI directives which
- the assembler can use to generate unwind information, or if the
- compiler should emit the unwind information directly.
- -fno-merge-debug-strings
- Do not merge identical debug strings in different object files.
- -fno-merge-constants
- Do not merge identical string constants in different object files.
- -ftrapuv trap uninitialized variables
- -map-opts
- enable option mapping tool
- -print-multi-lib
- print information about libraries being used
- -pch-create <file>
- create precompiled header file
- -pch-use <file>
- use precompiled header file
- -pch enable automatic precompiled header file creation/usage
- -pch-dir <dir>
- name precompiled header directory
- -check-pointers=<arg>
- Specifies what type of bounds checking occurs. Possible values are:
- none - Disables bounds checking. This is the default.
- rw - Checks bounds for reads and writes through pointers.
- write - Checks bounds for writes through pointers only.
- -check-pointers-mpx=<arg>
- Enables bounds checking using Intel(R) MPX support. Possible
- values are:
- none - Disables bounds checking. This is the default.
- rw - Checks bounds for reads and writes through pointers.
- write - Checks bounds for writes through pointers only.
- This switch is only valid on targets with Intel(R) MPX support.
- -check-pointers-dangling=<arg>
- Specifies what type of dangling pointer checking occurs. Possible
- values are:
- none - Disables dangling pointer checking. This is the default.
- heap - Check dangling references on heap.
- stack - Check dangling references on stack.
- all - Check dangling references on both heap and stack.
- -[no-]check-pointers-undimensioned
- Bounds checking occurs for memory access through arrays that are
- declared without dimensions. This checking occurs for both
- dimensioned and undimensioned arrays.
- -[no-]check-pointers-narrowing
- When this is disabled, Pointer Checker will not give an error when
- pointers to a structure field are moved to fields in the same
- structure.
- -f[no-]emit-class-debug-always
- Emit debug information for a C++ class into each object file where
- the class is used. This flag is useful for tools which are unable
- to resolve incomplete type descriptions. Using this option may
- cause a large increase in the size of the debug information.
- -f[no-]eliminate-unused-debug-types
- When disabled, debug information for all types present in the
- sources will be emitted. Using this option may cause a large
- increase in the size of the debug information.
- -qemit-build-options
- Output the options used during the compilation to a corresponding
- .dashboard file. This file is to be consumed by the dbmerge tool
- and used by the dashboard tool.
- -qemit-messages
- Output the diagnostics emitted during the compilation to a
- corresponding .dashboard file. This file is to be consumed by the
- dbmerge tool and used by the dashboard tool.
- Preprocessor
- ------------
- -A<name>[<val>]
- create an assertion <name> having value <val>
- -C do not strip comments
- -D<name>[=<text>]
- define macro
- -U<name> remove predefined macro
- -E preprocess to stdout
- -EP preprocess to stdout, omitting #line directives
- -P preprocess to file, omitting #line directives
- -I<dir> add directory to include file search path
- -idirafter<dir>
- add directory to the second include file search path (after -I)
- -isystem<dir>
- add directory to the start of the system include path
- -X, -nostdinc
- remove standard directories from include file search path
- -nostdinc++
- remove standard C++ directories from include file search path
- -iprefix <prefix>
- use <prefix> with -iwithprefix as a prefix
- -iwithprefix <dir>
- append <dir> to the prefix passed in by -iprefix and put it on the
- include search path at the end of the include directories
- -iwithprefixbefore <dir>
- similar to -iwithprefix except the include directory is placed in the
- same place as -I command line include directories
- -iquote <dir>
- add directory to the front of the include file search path for files
- included with quotes, but not brackets
- -imacros <file>
- treat <file> as an #include file, but throw away all preprocessing
- while macros defined remain defined
- -H print include file order
- -B<prefix>
- find libraries, headers and executables in <prefix>
- -M generate makefile dependency information
- -MM similar to -M, but do not include system header files
- -MG similar to -M, but treat missing header files as generated files
- -MD preprocess and compile, generating output file containing dependency
- information ending with extension .d
- -MMD similar to -MD, but do not include system header files
- -MF<file>
- generate makefile dependency information in file (must specify -M
- or -MM)
- -MP add a phony target for each dependency
- -MT<target>
- change the default target rule for dependency generation
- -MQ<target>
- same as -MT, but quotes special Make characters
- -dM output macro definitions in effect after preprocessing (use with -E)
- -dD same as -dM, but output #define directives in preprocessed source
- -dN same as -dD, but #define directives contain only macro names
- -gcc Predefine the "__GNUC__", "__GNUC_MINOR__", and
- "__GNUC_PATCHLEVEL__" macros (DEFAULT)
- -no-gcc Do not predefine GNUC macros listed in -gcc mode. Warning: can
- prevent correct system header compilation, see -gcc-sys
- -gcc-sys same as -no-gcc, except that the GNU macros are defined only while
- preprocessing the system include headers
- -no-icc do not predefine the "__ICC" and "__INTEL_COMPILER" macros.
- Warning: can prevent correct Intel header compilation
- -no-gcc-include-dir
- Do not add the gcc version specific system include directory
- -pragma-optimization-level=[Intel|GCC]
- process #pragma optimize using Intel (DEFAULT) or GCC syntax
- Component Control
- -----------------
- -Qoption,<tool>,<opts>
- pass options <opts> to tool specified by <tool>
- -Qlocation,<tool>,<dir>
- set <dir> as the location of tool specified by <tool>
- -Qinstall <dir>
- set <dir> as root of compiler installation
- Language
- --------
- -std=<std>
- enable language support for <std>, as described below
- c99 conforms to ISO/IEC 9899:1999 standard for C programs
- c11 conforms to ISO/IEC 9899:2011 standard for C programs
- c17 conforms to ISO/IEC 9899:2017 standard for C programs
- c18 conforms to ISO/IEC 9899:2018 standard for C programs
- c++11 enables C++11 support for C++ programs
- c++14 enables C++14 support for C++ programs
- c++17 enables C++17 support for C++ programs
- c++20 enables C++20 support for C++ programs
- c89 conforms to ISO/IEC 9899:1990 standard for C programs
- gnu89 conforms to ISO C90 plus GNU extensions
- gnu99 conforms to ISO C99 plus GNU extensions
- gnu++98 conforms to 1998 ISO C++ standard plus GNU extensions
- gnu++11 conforms to 2011 ISO C++ standard plus GNU extensions
- gnu++14 conforms to 2014 ISO C++ standard plus GNU extensions
- gnu++17 conforms to 2017 ISO C++ standard plus GNU extensions
- gnu++20 conforms to 2020 ISO C++ standard plus GNU extensions
- -x <type>
- all source files found subsequent to -x <type> will be recognized
- as one of the following types:
- c - C source file
- c++ - C++ source file
- c-header - C header file
- cpp-output - C pre-processed file
- c++-cpp-output - C++ pre-processed file
- assembler - assembly file
- assembler-with-cpp - assembly file that needs to be preprocessed
- none - revert to original file extension
- -ansi equivalent to GNU -ansi
- -strict-ansi
- strict ANSI conformance dialect
- -Zp[n] specify alignment constraint for structures where
- n=1,2,4,8,16. 16 is the default
- -fsyntax-only
- perform syntax and semantic checking only (no object file produced)
- -trigraphs
- support ISO C trigraphs (enabled in -ansi mode)
- -fpermissive
- allows extensions for some non-conformant code
- -funsigned-char
- change default char type to unsigned
- -fshort-enums
- allocate as many bytes as needed for enumerated types
- -f[no-]unsigned-bitfields
- change default bitfield type to unsigned
- -fno-rtti
- disable RTTI support
- -fno-implicit-templates
- never emit code for non-inline templates which are instantiated
- implicitly; only emit code for explicit instantiations
- -fno-implicit-inline-templates
- do not emit code for implicit instantiations of inline templates
- -ftemplate-depth=n
- control the depth in which recursive templates are expanded
- -[no]align
- analyze and reorder memory layout for variables and arrays
- -[no-]restrict
- enable/disable the 'restrict' keyword for disambiguating pointers
- -[no-]early-template-check
- enable/disable (DEFAULT) semantic checking of function template
- prototypes (before instantiation).
- -help-pragma
- output supported pragmas and their usage syntax
- -ffriend-injection
- inject friend functions into the enclosing namespace. Use
- -fno-friend-injection to disable
- -check=<keyword>[,<keyword>,...]
- check run-time conditions.
- keywords: [no]conversions, [no]stack, [no]uninit
- -qopt-assume-safe-padding
- assume that variables and dynamically allocated memory are padded
- (Intel(R) MIC Architecture specific)
- Compiler Diagnostics
- --------------------
- -w disable all warnings
- -w<n> control diagnostics
- n = 0 enable errors only (same as -w)
- n = 1 enable warnings and errors (DEFAULT)
- n = 2 enable verbose warnings, warnings and errors
- n = 3 enable remarks, verbose warnings, warnings and errors
- -Wbrief print brief one-line diagnostics
- -Werror force warnings to be reported as errors
- -Werror-all
- force warnings and currently enabled remarks to be reported as errors
- -Wall enable all warnings
- -Wremarks
- enable all remarks and comments
- -Wcheck enable more strict diagnostics
- -Weffc++ enable effective C++ diagnostic warnings
- -wo<L1>[,<L2>,...]
- issue diagnostics L1 through LN only once
- -W[no-]fatal-errors
- ends compilation after the first error encountered
- -W[no-]format
- enable argument checking for calls to printf, scanf, etc
- -W[no-]format-security
- warn for uses of format strings and specifiers in printf,
- scanf, etc that may introduce security problems
- -W[no-]missing-declarations
- warn for global functions and variables without prior declaration
- -W[no-]missing-prototypes
- warn for missing prototypes
- -W[no-]strict-aliasing
- warn for code that might violate the optimizer's strict aliasing
- rules. Warnings are issued only when using -fstrict-aliasing or
- -ansi-alias.
- -W[no-]strict-prototypes
- warn for functions declared or defined without specified argument
- types
- -W[no-]pointer-arith
- warn for questionable pointer arithmetic
- -W[no-]uninitialized
- warn if a variable is used before being initialized
- -Winline enable inline diagnostics
- -W[no-]deprecated
- print warnings related to deprecated features
- -W[no-]abi
- warn if generated code is not C++ ABI compliant
- -Wcontext-limit=<n>
- set maximum number of template instantiation contexts shown in
- diagnostic
- -Wcast-qual
- warn if cast is used to override pointer type qualifier
- -W[no-]unused-function
- warn if declared function is not used
- -W[no-]unused-parameter
- warn if declared function parameter is not used
- -W[no-]unknown-pragmas
- warn if an unknown #pragma directive is used (DEFAULT)
- -W[no-]main
- warn if return type of main is not expected
- -W[no-]comment[s]
- warn when comment
- -W[no-]conversion
- warn for implicit conversions that may alter a value
- -W[no-]return-type
- Issue warnings when a function is declared without a return type or
- when the definition of a function returning void contains a return
- statement with an expression
- -W[no-]extra-tokens
- warn about extra tokens after preprocessor directives
- -W[no-]invalid-pch
- warn about problems with existing precompiled headers
- -W[no-]shadow
- warn when a variable declaration hides a previous declaration
- -Woverloaded-virtual
- warn when a function declaration hides virtual functions from a base
- class
- -W[no-]trigraphs
- warn about the recognition and conversion of trigraphs
- -W[no-]multichar
- warn if a multicharacter constant ('ABC') is used
- -W[no-]overflow
- warn for operations that could result in integer overflow
- -Wwrite-strings
- Issues a diagnostic message if const char * is converted
- to (non-const) char *.
- -W[no-]sign-compare
- warn for comparisons between signed and unsigned values that
- could produce unintended results after sign conversion
- -W[no-]ic-pointer
- warn for conversions between pointers to distinct scalar types
- with the same representation
- -Wp64 print diagnostics for 64-bit porting
- -W[no-]shorten-64-to-32
- warn for values implicitly converted from a 64-bit to a 32-bit type.
- Similar to -Wp64
- -[no]traceback
- specify whether the compiler generates data to allow for source file
- traceback information at runtime (only to be used when linking with
- Fortran programs)
- -diag-enable=<v1>[,<v2>,...]
- enable the specified diagnostics or diagnostic groups
- -diag-disable=<v1>[,<v2>,...]
- disable the specified diagnostics or diagnostic groups
- where <vN> may be individual diagnostic numbers or group names.
- where group names include:
- thread - diagnostics to aid in thread-enabling source
- power - controls whether diagnostics are enabled for
- possibly inefficient code that may affect power
- consumption when running on Intel(R) processors
- port-win - diagnostics for GNU extensions that may
- cause errors when porting to Windows
- openmp - diagnostics issued by the OpenMP* parallelizer
- warn - diagnostics that have "warning" severity level
- error - diagnostics that have "error" severity level
- remark - diagnostics that are remarks or comments
- vec - diagnostics issued by the vectorizer
- par - diagnostics issued by the auto-parallelizer
- cpu-dispatch
- - specifies the CPU dispatch remarks
- biendian-verbose
- - advanced bi-endian specific diagnostics
- -diag-error=<v1>[,<v2>,...]
- output the specified diagnostics or diagnostic groups as errors
- -diag-warning=<v1>[,<v2>,...]
- output the specified diagnostics or diagnostic groups as warnings
- -diag-remark=<v1>[,<v2>,...]
- output the the specified diagnostics or diagnostic groups as remarks
- -diag-dump
- display the currently enabled diagnostic messages to stdout
- -diag-file[=<file>]
- <file> where diagnostics are emitted to. Not specifying this causes
- messages to be output to stderr
- -diag-file-append[=<file>]
- <file> where diagnostics are emitted to. When <file> already exists,
- output is appended to the file
- -[no-]diag-id-numbers
- enable(DEFAULT)/disable the diagnostic specifiers to be output in
- numeric form
- -diag-error-limit=<num>
- specify the maximum number of errors emitted
- -diag-once=<v1>[,<v2>,...]
- issue diagnostics v1 through vN only once
- -W[no-]pch-messages
- enable(DEFAULT)/disable PCH information messages
- Miscellaneous
- -------------
- -V display compiler version information
- -dumpversion
- display the compiler version number only
- -dumpmachine
- display the target machine only
- --version
- display GCC style version information
- -sox[=<keyword>[,keyword]]
- enable saving of compiler options, version and additional information
- in the executable. Use -no-sox to disable(DEFAULT)
- profile - include profiling data
- inline - include inlining information
- -save-temps
- store the intermediate files in current directory and name them
- based on the source file. Only saves files that are generated by
- default
- -dryrun show driver tool commands but do not execute tools
- -v show driver tool commands and execute tools
- -watch=<keyword>
- tells the driver to output processing information
- keywords: all, none (same as -nowatch), [no]source,
- [no]cmd (same as -v)
- [no]offload-cmd
- -nowatch suppress processing information output (DEFAULT)
- -[no-]multibyte-chars
- provide support for multi-byte characters
- -multiple-processes[=<n>]
- create multiple processes that can be used to compile large numbers
- of source files at the same time
- -standalone
- create standalone compilation environment, helpful for bootstrap
- environments where gcc is not available during the build
- -qnextgen
- invokes the Intel Compiler for LLVM*
- -qnextgen-diag
- This option causes the Intel Compiler for LLVM* to display a list
- of compiler options that are currently not supported.
- Offload
- -------
- -qoffload=<arg>
- define whether offload is enabled, and if enabled, whether CPU
- fallback is permitted
- keywords: none, optional, mandatory
- -qno-offload
- disable any offload usage
- Data
- ----
- -Zp[n] specify alignment constraint for structures (n=1,2,4,8,16
- -Zp16 DEFAULT)
- -fminshared
- Compilation is for the main executable. Absolute addressing can be
- used and non-position independent code generated for symbols that
- are at least protected
- -fcommon Enables the compiler to treat common variables as if they were
- defined. That in turn allows the use of gprel addressing of common
- data variables. -fno-common disables
- -freg-struct-return
- return struct and union values in registers when possible
- -fstack-security-check
- enable overflow security checks.
- -fno-stack-security-check disables (DEFAULT)
- -fstack-protector
- enable stack overflow security checks.
- -fno-stack-protector disables (DEFAULT)
- -fstack-protector-strong
- enable stack overflow security checks for routines with any buffer.
- -fno-stack-protector-strong disables (DEFAULT)
- -fstack-protector-all
- enable stack overflow security checks including functions.
- -fno-stack-protector-all disables (DEFAULT)
- -fpic, -fPIC
- generate position independent code (-fno-pic/-fno-PIC is DEFAULT)
- -fpie, -fPIE
- generate position independent code that will be linked into an
- executable (-fno-pie/-fno-PIE is DEFAULT)
- -auto-ilp32
- specify that the application cannot exceed a 32-bit address space
- (-ipo[n] required)
- -auto-p32 instructs the compiler to analyze the program to determine if there
- are 64-bit pointers that can be safely shrunk to 32-bit pointers.
- (-ipo required)
- -[no-]global-hoist
- enable(DEFAULT)/disable external globals are load safe
- -f[no-]keep-static-consts
- enable/disable(DEFAULT) the ability to preserve allocation of
- variables that are not referenced in the source
- -fpack-struct
- pack structure members together
- -f[no-]math-errno
- set ERRNO after calling standard math library functions
- -no-bss-init
- disable placement of zero-initialized variables in BSS (use DATA)
- -f[no-]zero-initialized-in-bss
- put explicitly zero initialized variables into the DATA section
- instead of the BSS section
- -mcmodel=<size>
- use a specific memory model to generate code and store data
- small - Restricts code and data to the first 2GB of address
- space (DEFAULT)
- medium - Restricts code to the first 2GB; it places no memory
- restriction on data
- large - Places no memory restriction on code or data
- -falign-functions=<n>
- align the start of functions on a 2 (DEFAULT) or <n> byte boundary
- where <n> is a power of 2
- -falign-functions
- align the start of functions to an optimal machine-dependent value.
- -fno-align-functions (DEFAULT) aligns on a 2-byte boundary
- -fvisibility=[extern|default|protected|hidden|internal]
- Global symbols (data and functions) will get the visibility
- attribute given by default. Symbol visibility attributes explicitly
- set in the source code or using the symbol visibility attribute
- file options will override the -fvisibility setting
- -fvisibility-extern=<file>
- Space separated symbols listed in the <file> argument will get
- visibility set to extern
- -fvisibility-default=<file>
- Space separated symbols listed in the <file> argument will get
- visibility set to default
- -fvisibility-protected=<file>
- Space separated symbols listed in the <file> argument will get
- visibility set to protected
- -fvisibility-hidden=<file>
- Space separated symbols listed in the <file> argument will get
- visibility set to hidden
- -fvisibility-internal=<file>
- Space separated symbols listed in the <file> argument will get
- visibility set to internal
- -fvisibility-inlines-hidden
- mark inline member functions as hidden
- -mlong-double-64
- enable 64-bit 'long double'
- 80-bit floating-point type is available as __float80.
- -mlong-double-80
- enable 80-bit 'long double'
- Compatibility
- -------------
- -gcc-name=<name>
- name and location of gcc if not where expected
- -gxx-name=<name>
- name and location of g++ if not where expected
- -fabi-version=<val>
- directs the compiler to select a specific ABI implementation
- 0 - most recent ABI implementation
- 1 - g++ 3.2 compatible ABI implementation
- 2 - most conformant ABI implementation
- -fms-dialect[=<arg>]
- enable compatibility with a specific Microsoft* Visual Studio
- version
- 11 - Microsoft* Visual Studio 2012 compatibility
- 12 - Microsoft* Visual Studio 2013 compatibility
- 14 - Microsoft* Visual Studio 2015 compatibility
- 14.1 - Microsoft* Visual Studio 2017 compatibility
- 14.2 - Microsoft* Visual Studio 2019 compatibility
- -param-byte-order=<val>
- Defines byte order used to pass parameters
- legacy - parameters are passed in the declared byte order
- (compatibility mode)
- little-endian - parameters are passed in the little-endian form
- (recommended)
- -platform=<target platform>
- specify the <target platform> target for cross compilation.
- Default value for target platform is the same as host platform.
- Example: -platform=qnx640 -> generated code is for
- QNX* Neutrino* RTOS 6.4.0
- -little-endian
- specify that the compilation assumes little endian conventions
- -big-endian
- specify that the compilation assumes big endian conventions
- -q[no-]enable-biendian-extended-cxx
- enable/disable(DEFAULT) extended C++ support mode
- -[no-]pe-file-primary
- prolog/epilog mechanism for bracketing source files
- -pe-file-prefix=<path>
- <path> is prefixed to prolog/epilog files specified
- by pe-(i|u)dir-rule
- -extern-prefix=<string>
- specify a <string> to be prepended to external C symbols
- -use-decl-byte-order
- compile the function definition with the byte order specified in
- the function declaration
- -pe-udir-rule="<regular expression> <prolog file> <epilog file>"
- associate user header file(s) with prolog and epilog files.
- For user header files the following search order is applied:
- -pe-udir-rule settings, -pe-idir-rule settings
- -pe-idir-rule="<regular expression> <prolog file> <epilog file>"
- associate system header file(s) with prolog and epilog files.
- For system header files the following search order is applied:
- -pe-idir-rule settings, the platform include directory is used
- for __intel_prolog.h and __intel_epilog.h
- -pe-dir-rule="<regular expression> <prolog file> <epilog file>"
- same as -pe-idir-rule
- -[no-]add-response-file-dependencies
- include response files in dependency generation output
- -[no-]swap-pointers
- specify whether objects of pointer type are byte swapped
- -symcheck
- enable checking of global symbol types
- -[no-]little-endian-defaultlibs
- Treat default libraries as little-endian during type checking.
- This option should be used in conjunction with -symcheck which
- enables type checking mechanism.
- -little-endian-libs=<libname1>[,<libname2>...]
- Sets list of little-endian libraries for type checking. Library
- name can be either regular expression or start with -l prefix. For
- example, -little-endian-libs=-lmy makes libmy.a/libmy.so
- little-endian. This option should be used in conjunction with
- -symcheck which enables type checking mechanism.
- -[no-]multiline-strings
- allows the inclusion of new lines within strings
- -size-llp64
- enable LLP64 compilation mode
- -promote-varargs-to-64bit
- promote big-endian arguments passed to varargs functions to 64-bit
- -[no-]resolve-byte-order-mismatch
- automatically adjust byte order of local variables to resolve
- mismatch during pointer conversion (disabled by default)
- -gnu-prefix=prefix
- specify a prefix that will be added to the names of GNU utilities
- called from the compiler
- Linking/Linker
- --------------
- -L<dir> instruct linker to search <dir> for libraries
- -l<string>
- instruct the linker to link in the -l<string> library
- -shared-intel
- link Intel provided libraries dynamically
- -static-intel
- link Intel provided libraries statically
- -shared-libgcc
- link libgcc dynamically
- -static-libgcc
- link libgcc statically
- -static-libstdc++
- link libstdc++ statically
- -dynamic-linker<file>
- select dynamic linker other than the default
- -no-cxxlib
- do not link in C++ runtime libraries
- -cxxlib[=dir]
- link using C++ run-time libraries provided with gcc dir is an
- optional top-level location for the gcc binaries and libraries
- -nodefaultlibs
- do not use standard libraries when linking
- -nostartfiles
- do not use standard startup files when linking
- -nostdlib
- do not use standard libraries and startup files when linking
- -static prevents linking with shared libraries
- -shared produce a shared object
- -Bstatic specify following libraries are linked statically
- -Bdynamic
- specify following libraries are linked dynamically
- -pthread use POSIX* thread library for multithreading support
- -cxxlib-<mode>
- tell the compiler which C++ run-time libraries to use
- nostd - do not link in standard C++ library
- -u <symbol>
- pretend the <symbol> is undefined
- -T <file>
- direct linker to read link commands from <file>
- -Xassembler <val>
- pass <val> directly to the assembler for processing
- -Xlinker <val>
- pass <val> directly to the linker for processing
- -Wa,<o1>[,<o2>,...]
- pass options o1, o2, etc. to the assembler
- -Wl,<o1>[,<o2>,...]
- pass options o1, o2, etc. to the linker for processing
- -Wp,<o1>[,<o2>,...]
- pass options o1, o2, etc. to the preprocessor
- -pie,-no_pie
- generate position independent code that will be linked into an
- executable (-pie is DEFAULT for macOS* 10.7 and later)
- -no-pie/-no_pie disables position independent code
- -fuse-ld=<arg>
- Use different linker instead of default linker (ld)
- bfd - use bfd linker
- gold - use gold linker
- Linker Specific Options
- -----------------------
- These options are specific to the linker. Details can be found in the linker
- documentation and man page
- -L<dir>
- -T<arg>
- -h<arg>
- -u<arg>
- -z<arg>
- -i
- -r
- -s
- -N
- -Bsymbolic
- -Bdynamic
- -Bstatic
- Deprecated Options
- ------------------
- -use-asm No replacement
- -qopt-report [n] use -qopt-report[=n]
- -cilk-serialize No replacement
- -qcf-protection=shadow_stack use -fcf-protection=return
- -qcf-protection=branch_tracking use -fcf-protection=branch
- -qcf-protection=[full|none] use -fcf-protection=[full|none]
- -march=icelake use -march=icelake-client
- -mtune=icelake use -mtune=icelake-client
- -mcpu=icelake use -mcpu=icelake-client
- -xICELAKE use -xICELAKE-CLIENT
- -axICELAKE use -axICELAKE-CLIENT
- -Kc++ use -x c++
- -wn use -diag-error-limit
- -wd use -diag-disable
- -we use -diag-error
- -ww use -diag-warning
- -wr use -diag-remark
- -wo use -diag-once
- -std=c9x use -std=c99
- -rcd No replacement
- -help [category] print full or category help message
- Valid categories include
- advanced - Advanced Optimizations
- codegen - Code Generation
- compatibility - Compatibility
- component - Component Control
- data - Data
- deprecated - Deprecated Options
- diagnostics - Compiler Diagnostics
- float - Floating Point
- help - Help
- inline - Inlining
- ipo - Interprocedural Optimization (IPO)
- language - Language
- link - Linking/Linker
- misc - Miscellaneous
- opt - Optimization
- output - Output
- pgo - Profile Guided Optimization (PGO)
- preproc - Preprocessor
- reports - Optimization Reports
- openmp - OpenMP and Parallel Processing
- Copyright (C) 1985-2021, Intel Corporation. All rights reserved.
- * Other names and brands may be claimed as the property of others.
|