Initial bulk commit for "Git on MSys"
[msysgit/historical-msysgit.git] / mingw / man / man1 / gcc.1
blobc6e0fd14a033eac91a81060234fa33fa4e784d18
1 .\" Automatically generated by Pod::Man version 1.15
2 .\" Mon Sep 20 19:56:47 2004
3 .\"
4 .\" Standard preamble:
5 .\" ======================================================================
6 .de Sh \" Subsection heading
7 .br
8 .if t .Sp
9 .ne 5
10 .PP
11 \fB\\$1\fR
12 .PP
14 .de Sp \" Vertical space (when we can't use .PP)
15 .if t .sp .5v
16 .if n .sp
18 .de Ip \" List item
19 .br
20 .ie \\n(.$>=3 .ne \\$3
21 .el .ne 3
22 .IP "\\$1" \\$2
24 .de Vb \" Begin verbatim text
25 .ft CW
26 .nf
27 .ne \\$1
29 .de Ve \" End verbatim text
30 .ft R
32 .fi
34 .\" Set up some character translations and predefined strings.  \*(-- will
35 .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
36 .\" double quote, and \*(R" will give a right double quote.  | will give a
37 .\" real vertical bar.  \*(C+ will give a nicer C++.  Capital omega is used
38 .\" to do unbreakable dashes and therefore won't be available.  \*(C` and
39 .\" \*(C' expand to `' in nroff, nothing in troff, for use with C<>
40 .tr \(*W-|\(bv\*(Tr
41 .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
42 .ie n \{\
43 .    ds -- \(*W-
44 .    ds PI pi
45 .    if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
46 .    if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\"  diablo 12 pitch
47 .    ds L" ""
48 .    ds R" ""
49 .    ds C` ""
50 .    ds C' ""
51 'br\}
52 .el\{\
53 .    ds -- \|\(em\|
54 .    ds PI \(*p
55 .    ds L" ``
56 .    ds R" ''
57 'br\}
58 .\"
59 .\" If the F register is turned on, we'll generate index entries on stderr
60 .\" for titles (.TH), headers (.SH), subsections (.Sh), items (.Ip), and
61 .\" index entries marked with X<> in POD.  Of course, you'll have to process
62 .\" the output yourself in some meaningful fashion.
63 .if \nF \{\
64 .    de IX
65 .    tm Index:\\$1\t\\n%\t"\\$2"
67 .    nr % 0
68 .    rr F
69 .\}
70 .\"
71 .\" For nroff, turn off justification.  Always turn off hyphenation; it
72 .\" makes way too many mistakes in technical documents.
73 .hy 0
74 .if n .na
75 .\"
76 .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
77 .\" Fear.  Run.  Save yourself.  No user-serviceable parts.
78 .bd B 3
79 .    \" fudge factors for nroff and troff
80 .if n \{\
81 .    ds #H 0
82 .    ds #V .8m
83 .    ds #F .3m
84 .    ds #[ \f1
85 .    ds #] \fP
86 .\}
87 .if t \{\
88 .    ds #H ((1u-(\\\\n(.fu%2u))*.13m)
89 .    ds #V .6m
90 .    ds #F 0
91 .    ds #[ \&
92 .    ds #] \&
93 .\}
94 .    \" simple accents for nroff and troff
95 .if n \{\
96 .    ds ' \&
97 .    ds ` \&
98 .    ds ^ \&
99 .    ds , \&
100 .    ds ~ ~
101 .    ds /
103 .if t \{\
104 .    ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
105 .    ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
106 .    ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
107 .    ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
108 .    ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
109 .    ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
111 .    \" troff and (daisy-wheel) nroff accents
112 .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
113 .ds 8 \h'\*(#H'\(*b\h'-\*(#H'
114 .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
115 .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
116 .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
117 .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
118 .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
119 .ds ae a\h'-(\w'a'u*4/10)'e
120 .ds Ae A\h'-(\w'A'u*4/10)'E
121 .    \" corrections for vroff
122 .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
123 .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
124 .    \" for low resolution devices (crt and lpr)
125 .if \n(.H>23 .if \n(.V>19 \
127 .    ds : e
128 .    ds 8 ss
129 .    ds o a
130 .    ds d- d\h'-1'\(ga
131 .    ds D- D\h'-1'\(hy
132 .    ds th \o'bp'
133 .    ds Th \o'LP'
134 .    ds ae ae
135 .    ds Ae AE
137 .rm #[ #] #H #V #F C
138 .\" ======================================================================
140 .IX Title "GCC 1"
141 .TH GCC 1 "gcc-3.4.2" "2004-09-20" "GNU"
143 .SH "NAME"
144 gcc \- \s-1GNU\s0 project C and \*(C+ compiler
145 .SH "SYNOPSIS"
146 .IX Header "SYNOPSIS"
147 gcc [\fB\-c\fR|\fB\-S\fR|\fB\-E\fR] [\fB\-std=\fR\fIstandard\fR]
148     [\fB\-g\fR] [\fB\-pg\fR] [\fB\-O\fR\fIlevel\fR]
149     [\fB\-W\fR\fIwarn\fR...] [\fB\-pedantic\fR]
150     [\fB\-I\fR\fIdir\fR...] [\fB\-L\fR\fIdir\fR...]
151     [\fB\-D\fR\fImacro\fR[=\fIdefn\fR]...] [\fB\-U\fR\fImacro\fR]
152     [\fB\-f\fR\fIoption\fR...] [\fB\-m\fR\fImachine-option\fR...]
153     [\fB\-o\fR \fIoutfile\fR] \fIinfile\fR...
155 Only the most useful options are listed here; see below for the
156 remainder.  \fBg++\fR accepts mostly the same options as \fBgcc\fR.
157 .SH "DESCRIPTION"
158 .IX Header "DESCRIPTION"
159 When you invoke \s-1GCC\s0, it normally does preprocessing, compilation,
160 assembly and linking.  The ``overall options'' allow you to stop this
161 process at an intermediate stage.  For example, the \fB\-c\fR option
162 says not to run the linker.  Then the output consists of object files
163 output by the assembler.
165 Other options are passed on to one stage of processing.  Some options
166 control the preprocessor and others the compiler itself.  Yet other
167 options control the assembler and linker; most of these are not
168 documented here, since you rarely need to use any of them.
170 Most of the command line options that you can use with \s-1GCC\s0 are useful
171 for C programs; when an option is only useful with another language
172 (usually \*(C+), the explanation says so explicitly.  If the description
173 for a particular option does not mention a source language, you can use
174 that option with all supported languages.
176 The \fBgcc\fR program accepts options and file names as operands.  Many
177 options have multi-letter names; therefore multiple single-letter options
178 may \fInot\fR be grouped: \fB\-dr\fR is very different from \fB\-d\ \-r\fR.
180 You can mix options and other arguments.  For the most part, the order
181 you use doesn't matter.  Order does matter when you use several options
182 of the same kind; for example, if you specify \fB\-L\fR more than once,
183 the directories are searched in the order specified.
185 Many options have long names starting with \fB\-f\fR or with
186 \&\fB\-W\fR\-\-\-for example, \fB\-fforce-mem\fR,
187 \&\fB\-fstrength-reduce\fR, \fB\-Wformat\fR and so on.  Most of
188 these have both positive and negative forms; the negative form of
189 \&\fB\-ffoo\fR would be \fB\-fno-foo\fR.  This manual documents
190 only one of these two forms, whichever one is not the default.
191 .SH "OPTIONS"
192 .IX Header "OPTIONS"
193 .Sh "Option Summary"
194 .IX Subsection "Option Summary"
195 Here is a summary of all the options, grouped by type.  Explanations are
196 in the following sections.
197 .Ip "\fIOverall Options\fR" 4
198 .IX Item "Overall Options"
199 \&\fB\-c  \-S  \-E  \-o\fR \fIfile\fR  \fB\-pipe  \-pass-exit-codes  
200 \&\-x\fR \fIlanguage\fR  \fB\-v  \-###  \-\-help  \-\-target-help  \-\-version\fR
201 .Ip "\fIC Language Options\fR" 4
202 .IX Item "C Language Options"
203 \&\fB\-ansi  \-std=\fR\fIstandard\fR  \fB\-aux-info\fR \fIfilename\fR 
204 \&\fB\-fno-asm  \-fno-builtin  \-fno-builtin-\fR\fIfunction\fR 
205 \&\fB\-fhosted  \-ffreestanding  \-fms-extensions 
206 \&\-trigraphs  \-no-integrated-cpp  \-traditional  \-traditional-cpp 
207 \&\-fallow-single-precision  \-fcond-mismatch 
208 \&\-fsigned-bitfields  \-fsigned-char 
209 \&\-funsigned-bitfields  \-funsigned-char 
210 \&\-fwritable-strings\fR
211 .Ip "\fI\*(C+ Language Options\fR" 4
212 .IX Item " Language Options"
213 \&\fB\-fabi-version=\fR\fIn\fR  \fB\-fno-access-control  \-fcheck-new 
214 \&\-fconserve-space  \-fno-const-strings 
215 \&\-fno-elide-constructors 
216 \&\-fno-enforce-eh-specs 
217 \&\-ffor-scope  \-fno-for-scope  \-fno-gnu-keywords 
218 \&\-fno-implicit-templates 
219 \&\-fno-implicit-inline-templates 
220 \&\-fno-implement-inlines  \-fms-extensions 
221 \&\-fno-nonansi-builtins  \-fno-operator-names 
222 \&\-fno-optional-diags  \-fpermissive 
223 \&\-frepo  \-fno-rtti  \-fstats  \-ftemplate-depth-\fR\fIn\fR 
224 \&\fB\-fuse-cxa-atexit  \-fno-weak  \-nostdinc++ 
225 \&\-fno-default-inline  \-Wabi  \-Wctor-dtor-privacy 
226 \&\-Wnon-virtual-dtor  \-Wreorder 
227 \&\-Weffc++  \-Wno-deprecated 
228 \&\-Wno-non-template-friend  \-Wold-style-cast 
229 \&\-Woverloaded-virtual  \-Wno-pmf-conversions 
230 \&\-Wsign-promo  \-Wsynth\fR
231 .Ip "\fIObjective-C Language Options\fR" 4
232 .IX Item "Objective-C Language Options"
233 \&\fB\-fconstant-string-class=\fR\fIclass-name\fR 
234 \&\fB\-fgnu-runtime  \-fnext-runtime 
235 \&\-fno-nil-receivers 
236 \&\-fobjc-exceptions 
237 \&\-freplace-objc-classes 
238 \&\-fzero-link 
239 \&\-gen-decls 
240 \&\-Wno-protocol  \-Wselector \-Wundeclared-selector\fR
241 .Ip "\fILanguage Independent Options\fR" 4
242 .IX Item "Language Independent Options"
243 \&\fB\-fmessage-length=\fR\fIn\fR  
244 \&\fB\-fdiagnostics-show-location=\fR[\fBonce\fR|\fBevery-line\fR]
245 .Ip "\fIWarning Options\fR" 4
246 .IX Item "Warning Options"
247 \&\fB\-fsyntax-only  \-pedantic  \-pedantic-errors 
248 \&\-w  \-Wextra  \-Wall  \-Waggregate-return 
249 \&\-Wcast-align  \-Wcast-qual  \-Wchar-subscripts  \-Wcomment 
250 \&\-Wconversion  \-Wno-deprecated-declarations 
251 \&\-Wdisabled-optimization  \-Wno-div-by-zero  \-Wendif-labels 
252 \&\-Werror  \-Werror-implicit-function-declaration 
253 \&\-Wfloat-equal  \-Wformat  \-Wformat=2 
254 \&\-Wno-format-extra-args \-Wformat-nonliteral 
255 \&\-Wformat-security  \-Wformat-y2k 
256 \&\-Wimplicit  \-Wimplicit-function-declaration  \-Wimplicit-int 
257 \&\-Wimport  \-Wno-import  \-Winit-self  \-Winline 
258 \&\-Wno-invalid-offsetof  \-Winvalid-pch 
259 \&\-Wlarger-than-\fR\fIlen\fR  \fB\-Wlong-long 
260 \&\-Wmain  \-Wmissing-braces 
261 \&\-Wmissing-format-attribute  \-Wmissing-noreturn 
262 \&\-Wno-multichar  \-Wnonnull  \-Wpacked  \-Wpadded 
263 \&\-Wparentheses  \-Wpointer-arith  \-Wredundant-decls 
264 \&\-Wreturn-type  \-Wsequence-point  \-Wshadow 
265 \&\-Wsign-compare  \-Wstrict-aliasing 
266 \&\-Wswitch  \-Wswitch-default  \-Wswitch-enum 
267 \&\-Wsystem-headers  \-Wtrigraphs  \-Wundef  \-Wuninitialized 
268 \&\-Wunknown-pragmas  \-Wunreachable-code 
269 \&\-Wunused  \-Wunused-function  \-Wunused-label  \-Wunused-parameter 
270 \&\-Wunused-value  \-Wunused-variable  \-Wwrite-strings\fR
271 .Ip "\fIC-only Warning Options\fR" 4
272 .IX Item "C-only Warning Options"
273 \&\fB\-Wbad-function-cast  \-Wmissing-declarations 
274 \&\-Wmissing-prototypes  \-Wnested-externs  \-Wold-style-definition 
275 \&\-Wstrict-prototypes  \-Wtraditional 
276 \&\-Wdeclaration-after-statement\fR
277 .Ip "\fIDebugging Options\fR" 4
278 .IX Item "Debugging Options"
279 \&\fB\-d\fR\fIletters\fR  \fB\-dumpspecs  \-dumpmachine  \-dumpversion 
280 \&\-fdump-unnumbered  \-fdump-translation-unit\fR[\fB-\fR\fIn\fR] 
281 \&\fB\-fdump-class-hierarchy\fR[\fB-\fR\fIn\fR] 
282 \&\fB\-fdump-tree-original\fR[\fB-\fR\fIn\fR]  
283 \&\fB\-fdump-tree-optimized\fR[\fB-\fR\fIn\fR] 
284 \&\fB\-fdump-tree-inlined\fR[\fB-\fR\fIn\fR] 
285 \&\fB\-feliminate-dwarf2\-dups \-feliminate-unused-debug-types 
286 \&\-feliminate-unused-debug-symbols \-fmem-report \-fprofile-arcs 
287 \&\-frandom-seed=\fR\fIstring\fR \fB\-fsched-verbose=\fR\fIn\fR 
288 \&\fB\-ftest-coverage  \-ftime-report 
289 \&\-g  \-g\fR\fIlevel\fR  \fB\-gcoff \-gdwarf-2 
290 \&\-ggdb  \-gstabs  \-gstabs+  \-gvms  \-gxcoff  \-gxcoff+ 
291 \&\-p  \-pg  \-print-file-name=\fR\fIlibrary\fR  \fB\-print-libgcc-file-name 
292 \&\-print-multi-directory  \-print-multi-lib 
293 \&\-print-prog-name=\fR\fIprogram\fR  \fB\-print-search-dirs  \-Q 
294 \&\-save-temps  \-time\fR
295 .Ip "\fIOptimization Options\fR" 4
296 .IX Item "Optimization Options"
297 \&\fB\-falign-functions=\fR\fIn\fR  \fB\-falign-jumps=\fR\fIn\fR 
298 \&\fB\-falign-labels=\fR\fIn\fR  \fB\-falign-loops=\fR\fIn\fR  
299 \&\fB\-fbranch-probabilities \-fprofile-values \-fvpt \-fbranch-target-load-optimize 
300 \&\-fbranch-target-load-optimize2 \-fcaller-saves  \-fcprop-registers 
301 \&\-fcse-follow-jumps  \-fcse-skip-blocks  \-fdata-sections 
302 \&\-fdelayed-branch  \-fdelete-null-pointer-checks 
303 \&\-fexpensive-optimizations  \-ffast-math  \-ffloat-store 
304 \&\-fforce-addr  \-fforce-mem  \-ffunction-sections 
305 \&\-fgcse  \-fgcse-lm  \-fgcse-sm  \-fgcse-las  \-floop-optimize 
306 \&\-fcrossjumping  \-fif-conversion  \-fif-conversion2 
307 \&\-finline-functions  \-finline-limit=\fR\fIn\fR  \fB\-fkeep-inline-functions 
308 \&\-fkeep-static-consts  \-fmerge-constants  \-fmerge-all-constants 
309 \&\-fmove-all-movables  \-fnew-ra  \-fno-branch-count-reg 
310 \&\-fno-default-inline  \-fno-defer-pop 
311 \&\-fno-function-cse  \-fno-guess-branch-probability 
312 \&\-fno-inline  \-fno-math-errno  \-fno-peephole  \-fno-peephole2 
313 \&\-funsafe-math-optimizations  \-ffinite-math-only 
314 \&\-fno-trapping-math  \-fno-zero-initialized-in-bss 
315 \&\-fomit-frame-pointer  \-foptimize-register-move 
316 \&\-foptimize-sibling-calls  \-fprefetch-loop-arrays 
317 \&\-fprofile-generate \-fprofile-use 
318 \&\-freduce-all-givs  \-fregmove  \-frename-registers 
319 \&\-freorder-blocks  \-freorder-functions 
320 \&\-frerun-cse-after-loop  \-frerun-loop-opt 
321 \&\-frounding-math \-fschedule-insns  \-fschedule-insns2 
322 \&\-fno-sched-interblock  \-fno-sched-spec  \-fsched-spec-load 
323 \&\-fsched-spec-load-dangerous  
324 \&\-fsched-stalled-insns=\fR\fIn\fR \fB\-sched-stalled-insns-dep=\fR\fIn\fR 
325 \&\fB\-fsched2\-use-superblocks 
326 \&\-fsched2\-use-traces  \-fsignaling-nans 
327 \&\-fsingle-precision-constant  
328 \&\-fstrength-reduce  \-fstrict-aliasing  \-ftracer  \-fthread-jumps 
329 \&\-funroll-all-loops  \-funroll-loops  \-fpeel-loops 
330 \&\-funswitch-loops  \-fold-unroll-loops  \-fold-unroll-all-loops 
331 \&\-\-param\fR \fIname\fR\fB=\fR\fIvalue\fR
332 \&\fB\-O  \-O0  \-O1  \-O2  \-O3  \-Os\fR
333 .Ip "\fIPreprocessor Options\fR" 4
334 .IX Item "Preprocessor Options"
335 \&\fB\-A\fR\fIquestion\fR\fB=\fR\fIanswer\fR 
336 \&\fB\-A-\fR\fIquestion\fR[\fB=\fR\fIanswer\fR] 
337 \&\fB\-C  \-dD  \-dI  \-dM  \-dN 
338 \&\-D\fR\fImacro\fR[\fB=\fR\fIdefn\fR]  \fB\-E  \-H 
339 \&\-idirafter\fR \fIdir\fR 
340 \&\fB\-include\fR \fIfile\fR  \fB\-imacros\fR \fIfile\fR 
341 \&\fB\-iprefix\fR \fIfile\fR  \fB\-iwithprefix\fR \fIdir\fR 
342 \&\fB\-iwithprefixbefore\fR \fIdir\fR  \fB\-isystem\fR \fIdir\fR 
343 \&\fB\-M  \-MM  \-MF  \-MG  \-MP  \-MQ  \-MT  \-nostdinc  
344 \&\-P  \-fworking-directory  \-remap 
345 \&\-trigraphs  \-undef  \-U\fR\fImacro\fR  \fB\-Wp,\fR\fIoption\fR 
346 \&\fB\-Xpreprocessor\fR \fIoption\fR
347 .Ip "\fIAssembler Option\fR" 4
348 .IX Item "Assembler Option"
349 \&\fB\-Wa,\fR\fIoption\fR  \fB\-Xassembler\fR \fIoption\fR
350 .Ip "\fILinker Options\fR" 4
351 .IX Item "Linker Options"
352 \&\fIobject-file-name\fR  \fB\-l\fR\fIlibrary\fR 
353 \&\fB\-nostartfiles  \-nodefaultlibs  \-nostdlib \-pie 
354 \&\-s  \-static  \-static-libgcc  \-shared  \-shared-libgcc  \-symbolic 
355 \&\-Wl,\fR\fIoption\fR  \fB\-Xlinker\fR \fIoption\fR 
356 \&\fB\-u\fR \fIsymbol\fR
357 .Ip "\fIDirectory Options\fR" 4
358 .IX Item "Directory Options"
359 \&\fB\-B\fR\fIprefix\fR  \fB\-I\fR\fIdir\fR  \fB\-I-  \-L\fR\fIdir\fR  \fB\-specs=\fR\fIfile\fR
360 .Ip "\fITarget Options\fR" 4
361 .IX Item "Target Options"
362 \&\fB\-V\fR \fIversion\fR  \fB\-b\fR \fImachine\fR
363 .Ip "\fIMachine Dependent Options\fR" 4
364 .IX Item "Machine Dependent Options"
365 \&\fIM680x0 Options\fR
366 \&\fB\-m68000  \-m68020  \-m68020\-40  \-m68020\-60  \-m68030  \-m68040 
367 \&\-m68060  \-mcpu32  \-m5200  \-m68881  \-mbitfield  \-mc68000  \-mc68020   
368 \&\-mnobitfield  \-mrtd  \-mshort  \-msoft-float  \-mpcrel 
369 \&\-malign-int  \-mstrict-align  \-msep-data  \-mno-sep-data 
370 \&\-mshared-library-id=n  \-mid-shared-library  \-mno-id-shared-library\fR
372 \&\fIM68hc1x Options\fR
373 \&\fB\-m6811  \-m6812  \-m68hc11  \-m68hc12   \-m68hcs12 
374 \&\-mauto-incdec  \-minmax  \-mlong-calls  \-mshort 
375 \&\-msoft-reg-count=\fR\fIcount\fR
377 \&\fI\s-1VAX\s0 Options\fR
378 \&\fB\-mg  \-mgnu  \-munix\fR
380 \&\fI\s-1SPARC\s0 Options\fR
381 \&\fB\-mcpu=\fR\fIcpu-type\fR 
382 \&\fB\-mtune=\fR\fIcpu-type\fR 
383 \&\fB\-mcmodel=\fR\fIcode-model\fR 
384 \&\fB\-m32  \-m64  \-mapp-regs  \-mno-app-regs 
385 \&\-mfaster-structs  \-mno-faster-structs 
386 \&\-mflat  \-mno-flat  \-mfpu  \-mno-fpu 
387 \&\-mhard-float  \-msoft-float 
388 \&\-mhard-quad-float  \-msoft-quad-float 
389 \&\-mimpure-text  \-mno-impure-text  \-mlittle-endian 
390 \&\-mstack-bias  \-mno-stack-bias 
391 \&\-munaligned-doubles  \-mno-unaligned-doubles 
392 \&\-mv8plus  \-mno-v8plus  \-mvis  \-mno-vis 
393 \&\-mcypress  \-mf930  \-mf934 
394 \&\-msparclite  \-msupersparc  \-mv8
395 \&\-threads \-pthreads\fR
397 \&\fI\s-1ARM\s0 Options\fR
398 \&\fB\-mapcs-frame  \-mno-apcs-frame 
399 \&\-mapcs-26  \-mapcs-32 
400 \&\-mapcs-stack-check  \-mno-apcs-stack-check 
401 \&\-mapcs-float  \-mno-apcs-float 
402 \&\-mapcs-reentrant  \-mno-apcs-reentrant 
403 \&\-msched-prolog  \-mno-sched-prolog 
404 \&\-mlittle-endian  \-mbig-endian  \-mwords-little-endian 
405 \&\-malignment-traps  \-mno-alignment-traps 
406 \&\-msoft-float  \-mhard-float  \-mfpe 
407 \&\-mthumb-interwork  \-mno-thumb-interwork 
408 \&\-mcpu=\fR\fIname\fR  \fB\-march=\fR\fIname\fR  \fB\-mfpe=\fR\fIname\fR  
409 \&\fB\-mstructure-size-boundary=\fR\fIn\fR 
410 \&\fB\-mabort-on-noreturn 
411 \&\-mlong-calls  \-mno-long-calls 
412 \&\-msingle-pic-base  \-mno-single-pic-base 
413 \&\-mpic-register=\fR\fIreg\fR 
414 \&\fB\-mnop-fun-dllimport 
415 \&\-mcirrus-fix-invalid-insns \-mno-cirrus-fix-invalid-insns 
416 \&\-mpoke-function-name 
417 \&\-mthumb  \-marm 
418 \&\-mtpcs-frame  \-mtpcs-leaf-frame 
419 \&\-mcaller-super-interworking  \-mcallee-super-interworking\fR
421 \&\fI\s-1MN10300\s0 Options\fR
422 \&\fB\-mmult-bug  \-mno-mult-bug 
423 \&\-mam33  \-mno-am33 
424 \&\-mam33\-2  \-mno-am33\-2 
425 \&\-mno-crt0  \-mrelax\fR
427 \&\fIM32R/D Options\fR
428 \&\fB\-m32r2 \-m32rx \-m32r 
429 \&\-mdebug 
430 \&\-malign-loops \-mno-align-loops 
431 \&\-missue-rate=\fR\fInumber\fR 
432 \&\fB\-mbranch-cost=\fR\fInumber\fR 
433 \&\fB\-mmodel=\fR\fIcode-size-model-type\fR 
434 \&\fB\-msdata=\fR\fIsdata-type\fR 
435 \&\fB\-mno-flush-func \-mflush-func=\fR\fIname\fR 
436 \&\fB\-mno-flush-trap \-mflush-trap=\fR\fInumber\fR 
437 \&\fB\-G\fR \fInum\fR
439 \&\fI\s-1RS/6000\s0 and PowerPC Options\fR
440 \&\fB\-mcpu=\fR\fIcpu-type\fR 
441 \&\fB\-mtune=\fR\fIcpu-type\fR 
442 \&\fB\-mpower  \-mno-power  \-mpower2  \-mno-power2 
443 \&\-mpowerpc  \-mpowerpc64  \-mno-powerpc 
444 \&\-maltivec  \-mno-altivec 
445 \&\-mpowerpc-gpopt  \-mno-powerpc-gpopt 
446 \&\-mpowerpc-gfxopt  \-mno-powerpc-gfxopt 
447 \&\-mnew-mnemonics  \-mold-mnemonics 
448 \&\-mfull-toc   \-mminimal-toc  \-mno-fp-in-toc  \-mno-sum-in-toc 
449 \&\-m64  \-m32  \-mxl-call  \-mno-xl-call  \-mpe 
450 \&\-malign-power  \-malign-natural 
451 \&\-msoft-float  \-mhard-float  \-mmultiple  \-mno-multiple 
452 \&\-mstring  \-mno-string  \-mupdate  \-mno-update 
453 \&\-mfused-madd  \-mno-fused-madd  \-mbit-align  \-mno-bit-align 
454 \&\-mstrict-align  \-mno-strict-align  \-mrelocatable 
455 \&\-mno-relocatable  \-mrelocatable-lib  \-mno-relocatable-lib 
456 \&\-mtoc  \-mno-toc  \-mlittle  \-mlittle-endian  \-mbig  \-mbig-endian 
457 \&\-mdynamic-no-pic 
458 \&\-mprioritize-restricted-insns=\fR\fIpriority\fR 
459 \&\fB\-msched-costly-dep=\fR\fIdependence_type\fR 
460 \&\fB\-minsert-sched-nops=\fR\fIscheme\fR 
461 \&\fB\-mcall-sysv  \-mcall-netbsd 
462 \&\-maix-struct-return  \-msvr4\-struct-return 
463 \&\-mabi=altivec  \-mabi=no-altivec 
464 \&\-mabi=spe  \-mabi=no-spe 
465 \&\-misel=yes  \-misel=no 
466 \&\-mspe=yes  \-mspe=no 
467 \&\-mfloat-gprs=yes  \-mfloat-gprs=no 
468 \&\-mprototype  \-mno-prototype 
469 \&\-msim  \-mmvme  \-mads  \-myellowknife  \-memb  \-msdata 
470 \&\-msdata=\fR\fIopt\fR  \fB\-mvxworks  \-mwindiss  \-G\fR \fInum\fR  \fB\-pthread\fR
472 \&\fIDarwin Options\fR
473 \&\fB\-all_load  \-allowable_client  \-arch  \-arch_errors_fatal 
474 \&\-arch_only  \-bind_at_load  \-bundle  \-bundle_loader 
475 \&\-client_name  \-compatibility_version  \-current_version 
476 \&\-dependency-file  \-dylib_file  \-dylinker_install_name 
477 \&\-dynamic  \-dynamiclib  \-exported_symbols_list 
478 \&\-filelist  \-flat_namespace  \-force_cpusubtype_ALL 
479 \&\-force_flat_namespace  \-headerpad_max_install_names 
480 \&\-image_base  \-init  \-install_name  \-keep_private_externs 
481 \&\-multi_module  \-multiply_defined  \-multiply_defined_unused 
482 \&\-noall_load  \-nofixprebinding \-nomultidefs  \-noprebind  \-noseglinkedit 
483 \&\-pagezero_size  \-prebind  \-prebind_all_twolevel_modules 
484 \&\-private_bundle  \-read_only_relocs  \-sectalign 
485 \&\-sectobjectsymbols  \-whyload  \-seg1addr 
486 \&\-sectcreate  \-sectobjectsymbols  \-sectorder 
487 \&\-seg_addr_table  \-seg_addr_table_filename  \-seglinkedit 
488 \&\-segprot  \-segs_read_only_addr  \-segs_read_write_addr 
489 \&\-single_module  \-static  \-sub_library  \-sub_umbrella 
490 \&\-twolevel_namespace  \-umbrella  \-undefined 
491 \&\-unexported_symbols_list  \-weak_reference_mismatches 
492 \&\-whatsloaded\fR
494 \&\fI\s-1MIPS\s0 Options\fR
495 \&\fB\-EL  \-EB  \-march=\fR\fIarch\fR  \fB\-mtune=\fR\fIarch\fR 
496 \&\fB\-mips1  \-mips2  \-mips3  \-mips4  \-mips32  \-mips32r2  \-mips64 
497 \&\-mips16  \-mno-mips16  \-mabi=\fR\fIabi\fR  \fB\-mabicalls  \-mno-abicalls 
498 \&\-mxgot  \-mno-xgot  \-membedded-pic  \-mno-embedded-pic 
499 \&\-mgp32  \-mgp64  \-mfp32  \-mfp64  \-mhard-float  \-msoft-float 
500 \&\-msingle-float  \-mdouble-float  \-mint64  \-mlong64  \-mlong32 
501 \&\-G\fR\fInum\fR  \fB\-membedded-data  \-mno-embedded-data 
502 \&\-muninit-const-in-rodata  \-mno-uninit-const-in-rodata 
503 \&\-msplit-addresses  \-mno-split-addresses  
504 \&\-mexplicit-relocs  \-mno-explicit-relocs  
505 \&\-mrnames  \-mno-rnames 
506 \&\-mcheck-zero-division  \-mno-check-zero-division 
507 \&\-mmemcpy  \-mno-memcpy  \-mlong-calls  \-mno-long-calls 
508 \&\-mmad  \-mno-mad  \-mfused-madd  \-mno-fused-madd  \-nocpp 
509 \&\-mfix-sb1  \-mno-fix-sb1  \-mflush-func=\fR\fIfunc\fR 
510 \&\fB\-mno-flush-func  \-mbranch-likely  \-mno-branch-likely\fR
512 \&\fIi386 and x86\-64 Options\fR
513 \&\fB\-mtune=\fR\fIcpu-type\fR  \fB\-march=\fR\fIcpu-type\fR 
514 \&\fB\-mfpmath=\fR\fIunit\fR 
515 \&\fB\-masm=\fR\fIdialect\fR  \fB\-mno-fancy-math-387 
516 \&\-mno-fp-ret-in-387  \-msoft-float  \-msvr3\-shlib 
517 \&\-mno-wide-multiply  \-mrtd  \-malign-double 
518 \&\-mpreferred-stack-boundary=\fR\fInum\fR 
519 \&\fB\-mmmx  \-msse  \-msse2 \-msse3 \-m3dnow 
520 \&\-mthreads  \-mno-align-stringops  \-minline-all-stringops 
521 \&\-mpush-args  \-maccumulate-outgoing-args  \-m128bit-long-double 
522 \&\-m96bit-long-double  \-mregparm=\fR\fInum\fR  \fB\-momit-leaf-frame-pointer 
523 \&\-mno-red-zone \-mno-tls-direct-seg-refs 
524 \&\-mcmodel=\fR\fIcode-model\fR 
525 \&\fB\-m32  \-m64 \-mstack-arg-probe\fR
527 \&\fI\s-1HPPA\s0 Options\fR
528 \&\fB\-march=\fR\fIarchitecture-type\fR 
529 \&\fB\-mbig-switch  \-mdisable-fpregs  \-mdisable-indexing 
530 \&\-mfast-indirect-calls  \-mgas  \-mgnu-ld   \-mhp-ld 
531 \&\-mjump-in-delay \-mlinker-opt \-mlong-calls 
532 \&\-mlong-load-store  \-mno-big-switch  \-mno-disable-fpregs 
533 \&\-mno-disable-indexing  \-mno-fast-indirect-calls  \-mno-gas 
534 \&\-mno-jump-in-delay  \-mno-long-load-store 
535 \&\-mno-portable-runtime  \-mno-soft-float 
536 \&\-mno-space-regs  \-msoft-float  \-mpa-risc-1\-0 
537 \&\-mpa-risc-1\-1  \-mpa-risc-2\-0  \-mportable-runtime 
538 \&\-mschedule=\fR\fIcpu-type\fR  \fB\-mspace-regs  \-msio  \-mwsio 
539 \&\-nolibdld  \-static  \-threads\fR
541 \&\fIIntel 960 Options\fR
542 \&\fB\-m\fR\fIcpu-type\fR  \fB\-masm-compat  \-mclean-linkage 
543 \&\-mcode-align  \-mcomplex-addr  \-mleaf-procedures 
544 \&\-mic-compat  \-mic2.0\-compat  \-mic3.0\-compat 
545 \&\-mintel-asm  \-mno-clean-linkage  \-mno-code-align 
546 \&\-mno-complex-addr  \-mno-leaf-procedures 
547 \&\-mno-old-align  \-mno-strict-align  \-mno-tail-call 
548 \&\-mnumerics  \-mold-align  \-msoft-float  \-mstrict-align 
549 \&\-mtail-call\fR
551 \&\fI\s-1DEC\s0 Alpha Options\fR
552 \&\fB\-mno-fp-regs  \-msoft-float  \-malpha-as  \-mgas 
553 \&\-mieee  \-mieee-with-inexact  \-mieee-conformant 
554 \&\-mfp-trap-mode=\fR\fImode\fR  \fB\-mfp-rounding-mode=\fR\fImode\fR 
555 \&\fB\-mtrap-precision=\fR\fImode\fR  \fB\-mbuild-constants 
556 \&\-mcpu=\fR\fIcpu-type\fR  \fB\-mtune=\fR\fIcpu-type\fR 
557 \&\fB\-mbwx  \-mmax  \-mfix  \-mcix 
558 \&\-mfloat-vax  \-mfloat-ieee 
559 \&\-mexplicit-relocs  \-msmall-data  \-mlarge-data 
560 \&\-msmall-text  \-mlarge-text 
561 \&\-mmemory-latency=\fR\fItime\fR
563 \&\fI\s-1DEC\s0 Alpha/VMS Options\fR
564 \&\fB\-mvms-return-codes\fR
566 \&\fIH8/300 Options\fR
567 \&\fB\-mrelax  \-mh  \-ms  \-mn  \-mint32  \-malign-300\fR
569 \&\fI\s-1SH\s0 Options\fR
570 \&\fB\-m1  \-m2  \-m2e  \-m3  \-m3e 
571 \&\-m4\-nofpu  \-m4\-single-only  \-m4\-single  \-m4 
572 \&\-m5\-64media  \-m5\-64media-nofpu 
573 \&\-m5\-32media  \-m5\-32media-nofpu 
574 \&\-m5\-compact  \-m5\-compact-nofpu 
575 \&\-mb  \-ml  \-mdalign  \-mrelax 
576 \&\-mbigtable  \-mfmovd  \-mhitachi  \-mnomacsave 
577 \&\-mieee  \-misize  \-mpadstruct  \-mspace 
578 \&\-mprefergot  \-musermode\fR
580 \&\fISystem V Options\fR
581 \&\fB\-Qy  \-Qn  \-YP,\fR\fIpaths\fR  \fB\-Ym,\fR\fIdir\fR
583 \&\fI\s-1ARC\s0 Options\fR
584 \&\fB\-EB  \-EL 
585 \&\-mmangle-cpu  \-mcpu=\fR\fIcpu\fR  \fB\-mtext=\fR\fItext-section\fR 
586 \&\fB\-mdata=\fR\fIdata-section\fR  \fB\-mrodata=\fR\fIreadonly-data-section\fR
588 \&\fITMS320C3x/C4x Options\fR
589 \&\fB\-mcpu=\fR\fIcpu\fR  \fB\-mbig  \-msmall  \-mregparm  \-mmemparm 
590 \&\-mfast-fix  \-mmpyi  \-mbk  \-mti  \-mdp-isr-reload 
591 \&\-mrpts=\fR\fIcount\fR  \fB\-mrptb  \-mdb  \-mloop-unsigned 
592 \&\-mparallel-insns  \-mparallel-mpy  \-mpreserve-float\fR
594 \&\fIV850 Options\fR
595 \&\fB\-mlong-calls  \-mno-long-calls  \-mep  \-mno-ep 
596 \&\-mprolog-function  \-mno-prolog-function  \-mspace 
597 \&\-mtda=\fR\fIn\fR  \fB\-msda=\fR\fIn\fR  \fB\-mzda=\fR\fIn\fR 
598 \&\fB\-mapp-regs  \-mno-app-regs 
599 \&\-mdisable-callt  \-mno-disable-callt 
600 \&\-mv850e1 
601 \&\-mv850e 
602 \&\-mv850  \-mbig-switch\fR
604 \&\fI\s-1NS32K\s0 Options\fR
605 \&\fB\-m32032  \-m32332  \-m32532  \-m32081  \-m32381 
606 \&\-mmult-add  \-mnomult-add  \-msoft-float  \-mrtd  \-mnortd 
607 \&\-mregparam  \-mnoregparam  \-msb  \-mnosb 
608 \&\-mbitfield  \-mnobitfield  \-mhimem  \-mnohimem\fR
610 \&\fI\s-1AVR\s0 Options\fR
611 \&\fB\-mmcu=\fR\fImcu\fR  \fB\-msize  \-minit-stack=\fR\fIn\fR  \fB\-mno-interrupts 
612 \&\-mcall-prologues  \-mno-tablejump  \-mtiny-stack\fR
614 \&\fIMCore Options\fR
615 \&\fB\-mhardlit  \-mno-hardlit  \-mdiv  \-mno-div  \-mrelax-immediates 
616 \&\-mno-relax-immediates  \-mwide-bitfields  \-mno-wide-bitfields 
617 \&\-m4byte-functions  \-mno-4byte-functions  \-mcallgraph-data 
618 \&\-mno-callgraph-data  \-mslow-bytes  \-mno-slow-bytes  \-mno-lsim 
619 \&\-mlittle-endian  \-mbig-endian  \-m210  \-m340  \-mstack-increment\fR
621 \&\fI\s-1MMIX\s0 Options\fR
622 \&\fB\-mlibfuncs  \-mno-libfuncs  \-mepsilon  \-mno-epsilon  \-mabi=gnu 
623 \&\-mabi=mmixware  \-mzero-extend  \-mknuthdiv  \-mtoplevel-symbols 
624 \&\-melf  \-mbranch-predict  \-mno-branch-predict  \-mbase-addresses 
625 \&\-mno-base-addresses  \-msingle-exit  \-mno-single-exit\fR
627 \&\fI\s-1IA-64\s0 Options\fR
628 \&\fB\-mbig-endian  \-mlittle-endian  \-mgnu-as  \-mgnu-ld  \-mno-pic 
629 \&\-mvolatile-asm-stop  \-mb-step  \-mregister-names  \-mno-sdata 
630 \&\-mconstant-gp  \-mauto-pic  \-minline-float-divide-min-latency 
631 \&\-minline-float-divide-max-throughput 
632 \&\-minline-int-divide-min-latency 
633 \&\-minline-int-divide-max-throughput  \-mno-dwarf2\-asm 
634 \&\-mfixed-range=\fR\fIregister-range\fR
636 \&\fID30V Options\fR
637 \&\fB\-mextmem  \-mextmemory  \-monchip  \-mno-asm-optimize 
638 \&\-masm-optimize  \-mbranch-cost=\fR\fIn\fR  \fB\-mcond-exec=\fR\fIn\fR
640 \&\fIS/390 and zSeries Options\fR
641 \&\fB\-mtune=\fR\fIcpu-type\fR  \fB\-march=\fR\fIcpu-type\fR 
642 \&\fB\-mhard-float  \-msoft-float  \-mbackchain  \-mno-backchain 
643 \&\-msmall-exec  \-mno-small-exec  \-mmvcle \-mno-mvcle 
644 \&\-m64  \-m31  \-mdebug  \-mno-debug  \-mesa  \-mzarch  \-mfused-madd  \-mno-fused-madd\fR
646 \&\fI\s-1CRIS\s0 Options\fR
647 \&\fB\-mcpu=\fR\fIcpu\fR  \fB\-march=\fR\fIcpu\fR  \fB\-mtune=\fR\fIcpu\fR 
648 \&\fB\-mmax-stack-frame=\fR\fIn\fR  \fB\-melinux-stacksize=\fR\fIn\fR 
649 \&\fB\-metrax4  \-metrax100  \-mpdebug  \-mcc-init  \-mno-side-effects 
650 \&\-mstack-align  \-mdata-align  \-mconst-align 
651 \&\-m32\-bit  \-m16\-bit  \-m8\-bit  \-mno-prologue-epilogue  \-mno-gotplt 
652 \&\-melf  \-maout  \-melinux  \-mlinux  \-sim  \-sim2 
653 \&\-mmul-bug-workaround  \-mno-mul-bug-workaround\fR
655 \&\fI\s-1PDP-11\s0 Options\fR
656 \&\fB\-mfpu  \-msoft-float  \-mac0  \-mno-ac0  \-m40  \-m45  \-m10 
657 \&\-mbcopy  \-mbcopy-builtin  \-mint32  \-mno-int16 
658 \&\-mint16  \-mno-int32  \-mfloat32  \-mno-float64 
659 \&\-mfloat64  \-mno-float32  \-mabshi  \-mno-abshi 
660 \&\-mbranch-expensive  \-mbranch-cheap 
661 \&\-msplit  \-mno-split  \-munix-asm  \-mdec-asm\fR
663 \&\fIXstormy16 Options\fR
664 \&\fB\-msim\fR
666 \&\fIXtensa Options\fR
667 \&\fB\-mconst16 \-mno-const16 
668 \&\-mfused-madd  \-mno-fused-madd 
669 \&\-mtext-section-literals  \-mno-text-section-literals 
670 \&\-mtarget-align  \-mno-target-align 
671 \&\-mlongcalls  \-mno-longcalls\fR
673 \&\fI\s-1FRV\s0 Options\fR
674 \&\fB\-mgpr-32  \-mgpr-64  \-mfpr-32  \-mfpr-64 
675 \&\-mhard-float  \-msoft-float 
676 \&\-malloc-cc  \-mfixed-cc  \-mdword  \-mno-dword 
677 \&\-mdouble  \-mno-double 
678 \&\-mmedia  \-mno-media  \-mmuladd  \-mno-muladd 
679 \&\-mlibrary-pic  \-macc-4 \-macc-8 
680 \&\-mpack  \-mno-pack  \-mno-eflags  \-mcond-move  \-mno-cond-move 
681 \&\-mscc  \-mno-scc  \-mcond-exec  \-mno-cond-exec 
682 \&\-mvliw-branch  \-mno-vliw-branch 
683 \&\-mmulti-cond-exec  \-mno-multi-cond-exec  \-mnested-cond-exec 
684 \&\-mno-nested-cond-exec  \-mtomcat-stats 
685 \&\-mcpu=\fR\fIcpu\fR
686 .Ip "\fICode Generation Options\fR" 4
687 .IX Item "Code Generation Options"
688 \&\fB\-fcall-saved-\fR\fIreg\fR  \fB\-fcall-used-\fR\fIreg\fR 
689 \&\fB\-ffixed-\fR\fIreg\fR  \fB\-fexceptions 
690 \&\-fnon-call-exceptions  \-funwind-tables 
691 \&\-fasynchronous-unwind-tables 
692 \&\-finhibit-size-directive  \-finstrument-functions 
693 \&\-fno-common  \-fno-ident 
694 \&\-fpcc-struct-return  \-fpic  \-fPIC \-fpie \-fPIE 
695 \&\-freg-struct-return  \-fshared-data  \-fshort-enums 
696 \&\-fshort-double  \-fshort-wchar 
697 \&\-fverbose-asm  \-fpack-struct  \-fstack-check 
698 \&\-fstack-limit-register=\fR\fIreg\fR  \fB\-fstack-limit-symbol=\fR\fIsym\fR 
699 \&\fB\-fargument-alias  \-fargument-noalias 
700 \&\-fargument-noalias-global  \-fleading-underscore 
701 \&\-ftls-model=\fR\fImodel\fR 
702 \&\fB\-ftrapv  \-fwrapv  \-fbounds-check\fR
703 .Sh "Options Controlling the Kind of Output"
704 .IX Subsection "Options Controlling the Kind of Output"
705 Compilation can involve up to four stages: preprocessing, compilation
706 proper, assembly and linking, always in that order.  \s-1GCC\s0 is capable of
707 preprocessing and compiling several files either into several
708 assembler input files, or into one assembler input file; then each
709 assembler input file produces an object file, and linking combines all
710 the object files (those newly compiled, and those specified as input)
711 into an executable file.
713 For any given input file, the file name suffix determines what kind of
714 compilation is done:
715 .Ip "\fIfile\fR\fB.c\fR" 4
716 .IX Item "file.c"
717 C source code which must be preprocessed.
718 .Ip "\fIfile\fR\fB.i\fR" 4
719 .IX Item "file.i"
720 C source code which should not be preprocessed.
721 .Ip "\fIfile\fR\fB.ii\fR" 4
722 .IX Item "file.ii"
723 \&\*(C+ source code which should not be preprocessed.
724 .Ip "\fIfile\fR\fB.m\fR" 4
725 .IX Item "file.m"
726 Objective-C source code.  Note that you must link with the library
727 \&\fIlibobjc.a\fR to make an Objective-C program work.
728 .Ip "\fIfile\fR\fB.mi\fR" 4
729 .IX Item "file.mi"
730 Objective-C source code which should not be preprocessed.
731 .Ip "\fIfile\fR\fB.h\fR" 4
732 .IX Item "file.h"
733 C or \*(C+ header file to be turned into a precompiled header.
734 .Ip "\fIfile\fR\fB.cc\fR" 4
735 .IX Item "file.cc"
736 .PD 0
737 .Ip "\fIfile\fR\fB.cp\fR" 4
738 .IX Item "file.cp"
739 .Ip "\fIfile\fR\fB.cxx\fR" 4
740 .IX Item "file.cxx"
741 .Ip "\fIfile\fR\fB.cpp\fR" 4
742 .IX Item "file.cpp"
743 .Ip "\fIfile\fR\fB.CPP\fR" 4
744 .IX Item "file.CPP"
745 .Ip "\fIfile\fR\fB.c++\fR" 4
746 .IX Item "file.c++"
747 .Ip "\fIfile\fR\fB.C\fR" 4
748 .IX Item "file.C"
750 \&\*(C+ source code which must be preprocessed.  Note that in \fB.cxx\fR,
751 the last two letters must both be literally \fBx\fR.  Likewise,
752 \&\fB.C\fR refers to a literal capital C.
753 .Ip "\fIfile\fR\fB.hh\fR" 4
754 .IX Item "file.hh"
755 .PD 0
756 .Ip "\fIfile\fR\fB.H\fR" 4
757 .IX Item "file.H"
759 \&\*(C+ header file to be turned into a precompiled header.
760 .Ip "\fIfile\fR\fB.f\fR" 4
761 .IX Item "file.f"
762 .PD 0
763 .Ip "\fIfile\fR\fB.for\fR" 4
764 .IX Item "file.for"
765 .Ip "\fIfile\fR\fB.FOR\fR" 4
766 .IX Item "file.FOR"
768 Fortran source code which should not be preprocessed.
769 .Ip "\fIfile\fR\fB.F\fR" 4
770 .IX Item "file.F"
771 .PD 0
772 .Ip "\fIfile\fR\fB.fpp\fR" 4
773 .IX Item "file.fpp"
774 .Ip "\fIfile\fR\fB.FPP\fR" 4
775 .IX Item "file.FPP"
777 Fortran source code which must be preprocessed (with the traditional
778 preprocessor).
779 .Ip "\fIfile\fR\fB.r\fR" 4
780 .IX Item "file.r"
781 Fortran source code which must be preprocessed with a \s-1RATFOR\s0
782 preprocessor (not included with \s-1GCC\s0).
783 .Ip "\fIfile\fR\fB.ads\fR" 4
784 .IX Item "file.ads"
785 Ada source code file which contains a library unit declaration (a
786 declaration of a package, subprogram, or generic, or a generic
787 instantiation), or a library unit renaming declaration (a package,
788 generic, or subprogram renaming declaration).  Such files are also
789 called \fIspecs\fR.
790 .Ip "\fIfile\fR\fB.adb\fR" 4
791 .IX Item "file.adb"
792 Ada source code file containing a library unit body (a subprogram or
793 package body).  Such files are also called \fIbodies\fR.
794 .Ip "\fIfile\fR\fB.s\fR" 4
795 .IX Item "file.s"
796 Assembler code.
797 .Ip "\fIfile\fR\fB.S\fR" 4
798 .IX Item "file.S"
799 Assembler code which must be preprocessed.
800 .Ip "\fIother\fR" 4
801 .IX Item "other"
802 An object file to be fed straight into linking.
803 Any file name with no recognized suffix is treated this way.
805 You can specify the input language explicitly with the \fB\-x\fR option:
806 .Ip "\fB\-x\fR \fIlanguage\fR" 4
807 .IX Item "-x language"
808 Specify explicitly the \fIlanguage\fR for the following input files
809 (rather than letting the compiler choose a default based on the file
810 name suffix).  This option applies to all following input files until
811 the next \fB\-x\fR option.  Possible values for \fIlanguage\fR are:
813 .Vb 8
814 \&        c  c-header  cpp-output
815 \&        c++  c++-header  c++-cpp-output
816 \&        objective-c  objective-c-header  objc-cpp-output
817 \&        assembler  assembler-with-cpp
818 \&        ada
819 \&        f77  f77-cpp-input  ratfor
820 \&        java
821 \&        treelang
823 .Ip "\fB\-x none\fR" 4
824 .IX Item "-x none"
825 Turn off any specification of a language, so that subsequent files are
826 handled according to their file name suffixes (as they are if \fB\-x\fR
827 has not been used at all).
828 .Ip "\fB\-pass-exit-codes\fR" 4
829 .IX Item "-pass-exit-codes"
830 Normally the \fBgcc\fR program will exit with the code of 1 if any
831 phase of the compiler returns a non-success return code.  If you specify
832 \&\fB\-pass-exit-codes\fR, the \fBgcc\fR program will instead return with
833 numerically highest error produced by any phase that returned an error
834 indication.
836 If you only want some of the stages of compilation, you can use
837 \&\fB\-x\fR (or filename suffixes) to tell \fBgcc\fR where to start, and
838 one of the options \fB\-c\fR, \fB\-S\fR, or \fB\-E\fR to say where
839 \&\fBgcc\fR is to stop.  Note that some combinations (for example,
840 \&\fB\-x cpp-output \-E\fR) instruct \fBgcc\fR to do nothing at all.
841 .Ip "\fB\-c\fR" 4
842 .IX Item "-c"
843 Compile or assemble the source files, but do not link.  The linking
844 stage simply is not done.  The ultimate output is in the form of an
845 object file for each source file.
847 By default, the object file name for a source file is made by replacing
848 the suffix \fB.c\fR, \fB.i\fR, \fB.s\fR, etc., with \fB.o\fR.
850 Unrecognized input files, not requiring compilation or assembly, are
851 ignored.
852 .Ip "\fB\-S\fR" 4
853 .IX Item "-S"
854 Stop after the stage of compilation proper; do not assemble.  The output
855 is in the form of an assembler code file for each non-assembler input
856 file specified.
858 By default, the assembler file name for a source file is made by
859 replacing the suffix \fB.c\fR, \fB.i\fR, etc., with \fB.s\fR.
861 Input files that don't require compilation are ignored.
862 .Ip "\fB\-E\fR" 4
863 .IX Item "-E"
864 Stop after the preprocessing stage; do not run the compiler proper.  The
865 output is in the form of preprocessed source code, which is sent to the
866 standard output.
868 Input files which don't require preprocessing are ignored.
869 .Ip "\fB\-o\fR \fIfile\fR" 4
870 .IX Item "-o file"
871 Place output in file \fIfile\fR.  This applies regardless to whatever
872 sort of output is being produced, whether it be an executable file,
873 an object file, an assembler file or preprocessed C code.
875 If you specify \fB\-o\fR when compiling more than one input file, or
876 you are producing an executable file as output, all the source files
877 on the command line will be compiled at once.
879 If \fB\-o\fR is not specified, the default is to put an executable file
880 in \fIa.out\fR, the object file for \fI\fIsource\fI.\fIsuffix\fI\fR in
881 \&\fI\fIsource\fI.o\fR, its assembler file in \fI\fIsource\fI.s\fR, and
882 all preprocessed C source on standard output.
883 .Ip "\fB\-v\fR" 4
884 .IX Item "-v"
885 Print (on standard error output) the commands executed to run the stages
886 of compilation.  Also print the version number of the compiler driver
887 program and of the preprocessor and the compiler proper.
888 .Ip "\fB\-###\fR" 4
889 .IX Item "-###"
890 Like \fB\-v\fR except the commands are not executed and all command
891 arguments are quoted.  This is useful for shell scripts to capture the
892 driver-generated command lines.
893 .Ip "\fB\-pipe\fR" 4
894 .IX Item "-pipe"
895 Use pipes rather than temporary files for communication between the
896 various stages of compilation.  This fails to work on some systems where
897 the assembler is unable to read from a pipe; but the \s-1GNU\s0 assembler has
898 no trouble.
899 .Ip "\fB\*(--help\fR" 4
900 .IX Item "help"
901 Print (on the standard output) a description of the command line options
902 understood by \fBgcc\fR.  If the \fB\-v\fR option is also specified
903 then \fB\*(--help\fR will also be passed on to the various processes
904 invoked by \fBgcc\fR, so that they can display the command line options
905 they accept.  If the \fB\-Wextra\fR option is also specified then command
906 line options which have no documentation associated with them will also
907 be displayed.
908 .Ip "\fB\*(--target-help\fR" 4
909 .IX Item "target-help"
910 Print (on the standard output) a description of target specific command
911 line options for each tool.
912 .Ip "\fB\*(--version\fR" 4
913 .IX Item "version"
914 Display the version number and copyrights of the invoked \s-1GCC\s0.
915 .Sh "Compiling \*(C+ Programs"
916 .IX Subsection "Compiling  Programs"
917 \&\*(C+ source files conventionally use one of the suffixes \fB.C\fR,
918 \&\fB.cc\fR, \fB.cpp\fR, \fB.CPP\fR, \fB.c++\fR, \fB.cp\fR, or
919 \&\fB.cxx\fR; \*(C+ header files often use \fB.hh\fR or \fB.H\fR; and
920 preprocessed \*(C+ files use the suffix \fB.ii\fR.  \s-1GCC\s0 recognizes
921 files with these names and compiles them as \*(C+ programs even if you
922 call the compiler the same way as for compiling C programs (usually
923 with the name \fBgcc\fR).
925 However, \*(C+ programs often require class libraries as well as a
926 compiler that understands the \*(C+ language\-\-\-and under some
927 circumstances, you might want to compile programs or header files from
928 standard input, or otherwise without a suffix that flags them as \*(C+
929 programs.  You might also like to precompile a C header file with a
930 \&\fB.h\fR extension to be used in \*(C+ compilations.  \fBg++\fR is a
931 program that calls \s-1GCC\s0 with the default language set to \*(C+, and
932 automatically specifies linking against the \*(C+ library.  On many
933 systems, \fBg++\fR is also installed with the name \fBc++\fR.
935 When you compile \*(C+ programs, you may specify many of the same
936 command-line options that you use for compiling programs in any
937 language; or command-line options meaningful for C and related
938 languages; or options that are meaningful only for \*(C+ programs.
939 .Sh "Options Controlling C Dialect"
940 .IX Subsection "Options Controlling C Dialect"
941 The following options control the dialect of C (or languages derived
942 from C, such as \*(C+ and Objective-C) that the compiler accepts:
943 .Ip "\fB\-ansi\fR" 4
944 .IX Item "-ansi"
945 In C mode, support all \s-1ISO\s0 C90 programs.  In \*(C+ mode,
946 remove \s-1GNU\s0 extensions that conflict with \s-1ISO\s0 \*(C+.
948 This turns off certain features of \s-1GCC\s0 that are incompatible with \s-1ISO\s0
949 C90 (when compiling C code), or of standard \*(C+ (when compiling \*(C+ code),
950 such as the \f(CW\*(C`asm\*(C'\fR and \f(CW\*(C`typeof\*(C'\fR keywords, and
951 predefined macros such as \f(CW\*(C`unix\*(C'\fR and \f(CW\*(C`vax\*(C'\fR that identify the
952 type of system you are using.  It also enables the undesirable and
953 rarely used \s-1ISO\s0 trigraph feature.  For the C compiler,
954 it disables recognition of \*(C+ style \fB//\fR comments as well as
955 the \f(CW\*(C`inline\*(C'\fR keyword.
957 The alternate keywords \f(CW\*(C`_\|_asm_\|_\*(C'\fR, \f(CW\*(C`_\|_extension_\|_\*(C'\fR,
958 \&\f(CW\*(C`_\|_inline_\|_\*(C'\fR and \f(CW\*(C`_\|_typeof_\|_\*(C'\fR continue to work despite
959 \&\fB\-ansi\fR.  You would not want to use them in an \s-1ISO\s0 C program, of
960 course, but it is useful to put them in header files that might be included
961 in compilations done with \fB\-ansi\fR.  Alternate predefined macros
962 such as \f(CW\*(C`_\|_unix_\|_\*(C'\fR and \f(CW\*(C`_\|_vax_\|_\*(C'\fR are also available, with or
963 without \fB\-ansi\fR.
965 The \fB\-ansi\fR option does not cause non-ISO programs to be
966 rejected gratuitously.  For that, \fB\-pedantic\fR is required in
967 addition to \fB\-ansi\fR.  
969 The macro \f(CW\*(C`_\|_STRICT_ANSI_\|_\*(C'\fR is predefined when the \fB\-ansi\fR
970 option is used.  Some header files may notice this macro and refrain
971 from declaring certain functions or defining certain macros that the
972 \&\s-1ISO\s0 standard doesn't call for; this is to avoid interfering with any
973 programs that might use these names for other things.
975 Functions which would normally be built in but do not have semantics
976 defined by \s-1ISO\s0 C (such as \f(CW\*(C`alloca\*(C'\fR and \f(CW\*(C`ffs\*(C'\fR) are not built-in
977 functions with \fB\-ansi\fR is used.  
978 .Ip "\fB\-std=\fR" 4
979 .IX Item "-std="
980 Determine the language standard.  This option is currently only
981 supported when compiling C or \*(C+.  A value for this option must be
982 provided; possible values are
983 .RS 4
984 .Ip "\fBc89\fR" 4
985 .IX Item "c89"
986 .PD 0
987 .Ip "\fBiso9899:1990\fR" 4
988 .IX Item "iso9899:1990"
990 \&\s-1ISO\s0 C90 (same as \fB\-ansi\fR).
991 .Ip "\fBiso9899:199409\fR" 4
992 .IX Item "iso9899:199409"
993 \&\s-1ISO\s0 C90 as modified in amendment 1.
994 .Ip "\fBc99\fR" 4
995 .IX Item "c99"
996 .PD 0
997 .Ip "\fBc9x\fR" 4
998 .IX Item "c9x"
999 .Ip "\fBiso9899:1999\fR" 4
1000 .IX Item "iso9899:1999"
1001 .Ip "\fBiso9899:199x\fR" 4
1002 .IX Item "iso9899:199x"
1004 \&\s-1ISO\s0 C99.  Note that this standard is not yet fully supported; see
1005 <\fBhttp://gcc.gnu.org/gcc-3.4/c99status.html\fR> for more information.  The
1006 names \fBc9x\fR and \fBiso9899:199x\fR are deprecated.
1007 .Ip "\fBgnu89\fR" 4
1008 .IX Item "gnu89"
1009 Default, \s-1ISO\s0 C90 plus \s-1GNU\s0 extensions (including some C99 features).
1010 .Ip "\fBgnu99\fR" 4
1011 .IX Item "gnu99"
1012 .PD 0
1013 .Ip "\fBgnu9x\fR" 4
1014 .IX Item "gnu9x"
1016 \&\s-1ISO\s0 C99 plus \s-1GNU\s0 extensions.  When \s-1ISO\s0 C99 is fully implemented in \s-1GCC\s0,
1017 this will become the default.  The name \fBgnu9x\fR is deprecated.
1018 .Ip "\fBc++98\fR" 4
1019 .IX Item "c++98"
1020 The 1998 \s-1ISO\s0 \*(C+ standard plus amendments.
1021 .Ip "\fBgnu++98\fR" 4
1022 .IX Item "gnu++98"
1023 The same as \fB\-std=c++98\fR plus \s-1GNU\s0 extensions.  This is the
1024 default for \*(C+ code.
1026 .RS 4
1028 Even when this option is not specified, you can still use some of the
1029 features of newer standards in so far as they do not conflict with
1030 previous C standards.  For example, you may use \f(CW\*(C`_\|_restrict_\|_\*(C'\fR even
1031 when \fB\-std=c99\fR is not specified.
1033 The \fB\-std\fR options specifying some version of \s-1ISO\s0 C have the same
1034 effects as \fB\-ansi\fR, except that features that were not in \s-1ISO\s0 C90
1035 but are in the specified version (for example, \fB//\fR comments and
1036 the \f(CW\*(C`inline\*(C'\fR keyword in \s-1ISO\s0 C99) are not disabled.
1038 .Ip "\fB\-aux-info\fR \fIfilename\fR" 4
1039 .IX Item "-aux-info filename"
1040 Output to the given filename prototyped declarations for all functions
1041 declared and/or defined in a translation unit, including those in header
1042 files.  This option is silently ignored in any language other than C.
1044 Besides declarations, the file indicates, in comments, the origin of
1045 each declaration (source file and line), whether the declaration was
1046 implicit, prototyped or unprototyped (\fBI\fR, \fBN\fR for new or
1047 \&\fBO\fR for old, respectively, in the first character after the line
1048 number and the colon), and whether it came from a declaration or a
1049 definition (\fBC\fR or \fBF\fR, respectively, in the following
1050 character).  In the case of function definitions, a K&R-style list of
1051 arguments followed by their declarations is also provided, inside
1052 comments, after the declaration.
1053 .Ip "\fB\-fno-asm\fR" 4
1054 .IX Item "-fno-asm"
1055 Do not recognize \f(CW\*(C`asm\*(C'\fR, \f(CW\*(C`inline\*(C'\fR or \f(CW\*(C`typeof\*(C'\fR as a
1056 keyword, so that code can use these words as identifiers.  You can use
1057 the keywords \f(CW\*(C`_\|_asm_\|_\*(C'\fR, \f(CW\*(C`_\|_inline_\|_\*(C'\fR and \f(CW\*(C`_\|_typeof_\|_\*(C'\fR
1058 instead.  \fB\-ansi\fR implies \fB\-fno-asm\fR.
1060 In \*(C+, this switch only affects the \f(CW\*(C`typeof\*(C'\fR keyword, since
1061 \&\f(CW\*(C`asm\*(C'\fR and \f(CW\*(C`inline\*(C'\fR are standard keywords.  You may want to
1062 use the \fB\-fno-gnu-keywords\fR flag instead, which has the same
1063 effect.  In C99 mode (\fB\-std=c99\fR or \fB\-std=gnu99\fR), this
1064 switch only affects the \f(CW\*(C`asm\*(C'\fR and \f(CW\*(C`typeof\*(C'\fR keywords, since
1065 \&\f(CW\*(C`inline\*(C'\fR is a standard keyword in \s-1ISO\s0 C99.
1066 .Ip "\fB\-fno-builtin\fR" 4
1067 .IX Item "-fno-builtin"
1068 .PD 0
1069 .Ip "\fB\-fno-builtin-\fR\fIfunction\fR" 4
1070 .IX Item "-fno-builtin-function"
1072 Don't recognize built-in functions that do not begin with
1073 \&\fB_\|_builtin_\fR as prefix.  
1075 \&\s-1GCC\s0 normally generates special code to handle certain built-in functions
1076 more efficiently; for instance, calls to \f(CW\*(C`alloca\*(C'\fR may become single
1077 instructions that adjust the stack directly, and calls to \f(CW\*(C`memcpy\*(C'\fR
1078 may become inline copy loops.  The resulting code is often both smaller
1079 and faster, but since the function calls no longer appear as such, you
1080 cannot set a breakpoint on those calls, nor can you change the behavior
1081 of the functions by linking with a different library.
1083 With the \fB\-fno-builtin-\fR\fIfunction\fR option
1084 only the built-in function \fIfunction\fR is
1085 disabled.  \fIfunction\fR must not begin with \fB_\|_builtin_\fR.  If a
1086 function is named this is not built-in in this version of \s-1GCC\s0, this
1087 option is ignored.  There is no corresponding
1088 \&\fB\-fbuiltin-\fR\fIfunction\fR option; if you wish to enable
1089 built-in functions selectively when using \fB\-fno-builtin\fR or
1090 \&\fB\-ffreestanding\fR, you may define macros such as:
1092 .Vb 2
1093 \&        #define abs(n)          __builtin_abs ((n))
1094 \&        #define strcpy(d, s)    __builtin_strcpy ((d), (s))
1096 .Ip "\fB\-fhosted\fR" 4
1097 .IX Item "-fhosted"
1098 Assert that compilation takes place in a hosted environment.  This implies
1099 \&\fB\-fbuiltin\fR.  A hosted environment is one in which the
1100 entire standard library is available, and in which \f(CW\*(C`main\*(C'\fR has a return
1101 type of \f(CW\*(C`int\*(C'\fR.  Examples are nearly everything except a kernel.
1102 This is equivalent to \fB\-fno-freestanding\fR.
1103 .Ip "\fB\-ffreestanding\fR" 4
1104 .IX Item "-ffreestanding"
1105 Assert that compilation takes place in a freestanding environment.  This
1106 implies \fB\-fno-builtin\fR.  A freestanding environment
1107 is one in which the standard library may not exist, and program startup may
1108 not necessarily be at \f(CW\*(C`main\*(C'\fR.  The most obvious example is an \s-1OS\s0 kernel.
1109 This is equivalent to \fB\-fno-hosted\fR.
1110 .Ip "\fB\-fms-extensions\fR" 4
1111 .IX Item "-fms-extensions"
1112 Accept some non-standard constructs used in Microsoft header files.
1113 .Ip "\fB\-trigraphs\fR" 4
1114 .IX Item "-trigraphs"
1115 Support \s-1ISO\s0 C trigraphs.  The \fB\-ansi\fR option (and \fB\-std\fR
1116 options for strict \s-1ISO\s0 C conformance) implies \fB\-trigraphs\fR.
1117 .Ip "\fB\-no-integrated-cpp\fR" 4
1118 .IX Item "-no-integrated-cpp"
1119 Performs a compilation in two passes: preprocessing and compiling.  This
1120 option allows a user supplied \*(L"cc1\*(R", \*(L"cc1plus\*(R", or \*(L"cc1obj\*(R" via the
1121 \&\fB\-B\fR option. The user supplied compilation step can then add in
1122 an additional preprocessing step after normal preprocessing but before
1123 compiling. The default is to use the integrated cpp (internal cpp)
1125 The semantics of this option will change if \*(L"cc1\*(R", \*(L"cc1plus\*(R", and
1126 \&\*(L"cc1obj\*(R" are merged.
1127 .Ip "\fB\-traditional\fR" 4
1128 .IX Item "-traditional"
1129 .PD 0
1130 .Ip "\fB\-traditional-cpp\fR" 4
1131 .IX Item "-traditional-cpp"
1133 Formerly, these options caused \s-1GCC\s0 to attempt to emulate a pre-standard
1134 C compiler.  They are now only supported with the \fB\-E\fR switch.
1135 The preprocessor continues to support a pre-standard mode.  See the \s-1GNU\s0
1136 \&\s-1CPP\s0 manual for details.
1137 .Ip "\fB\-fcond-mismatch\fR" 4
1138 .IX Item "-fcond-mismatch"
1139 Allow conditional expressions with mismatched types in the second and
1140 third arguments.  The value of such an expression is void.  This option
1141 is not supported for \*(C+.
1142 .Ip "\fB\-funsigned-char\fR" 4
1143 .IX Item "-funsigned-char"
1144 Let the type \f(CW\*(C`char\*(C'\fR be unsigned, like \f(CW\*(C`unsigned char\*(C'\fR.
1146 Each kind of machine has a default for what \f(CW\*(C`char\*(C'\fR should
1147 be.  It is either like \f(CW\*(C`unsigned char\*(C'\fR by default or like
1148 \&\f(CW\*(C`signed char\*(C'\fR by default.
1150 Ideally, a portable program should always use \f(CW\*(C`signed char\*(C'\fR or
1151 \&\f(CW\*(C`unsigned char\*(C'\fR when it depends on the signedness of an object.
1152 But many programs have been written to use plain \f(CW\*(C`char\*(C'\fR and
1153 expect it to be signed, or expect it to be unsigned, depending on the
1154 machines they were written for.  This option, and its inverse, let you
1155 make such a program work with the opposite default.
1157 The type \f(CW\*(C`char\*(C'\fR is always a distinct type from each of
1158 \&\f(CW\*(C`signed char\*(C'\fR or \f(CW\*(C`unsigned char\*(C'\fR, even though its behavior
1159 is always just like one of those two.
1160 .Ip "\fB\-fsigned-char\fR" 4
1161 .IX Item "-fsigned-char"
1162 Let the type \f(CW\*(C`char\*(C'\fR be signed, like \f(CW\*(C`signed char\*(C'\fR.
1164 Note that this is equivalent to \fB\-fno-unsigned-char\fR, which is
1165 the negative form of \fB\-funsigned-char\fR.  Likewise, the option
1166 \&\fB\-fno-signed-char\fR is equivalent to \fB\-funsigned-char\fR.
1167 .Ip "\fB\-fsigned-bitfields\fR" 4
1168 .IX Item "-fsigned-bitfields"
1169 .PD 0
1170 .Ip "\fB\-funsigned-bitfields\fR" 4
1171 .IX Item "-funsigned-bitfields"
1172 .Ip "\fB\-fno-signed-bitfields\fR" 4
1173 .IX Item "-fno-signed-bitfields"
1174 .Ip "\fB\-fno-unsigned-bitfields\fR" 4
1175 .IX Item "-fno-unsigned-bitfields"
1177 These options control whether a bit-field is signed or unsigned, when the
1178 declaration does not use either \f(CW\*(C`signed\*(C'\fR or \f(CW\*(C`unsigned\*(C'\fR.  By
1179 default, such a bit-field is signed, because this is consistent: the
1180 basic integer types such as \f(CW\*(C`int\*(C'\fR are signed types.
1181 .Ip "\fB\-fwritable-strings\fR" 4
1182 .IX Item "-fwritable-strings"
1183 Store string constants in the writable data segment and don't uniquize
1184 them.  This is for compatibility with old programs which assume they can
1185 write into string constants.
1187 Writing into string constants is a very bad idea; ``constants'' should
1188 be constant.
1190 This option is deprecated.
1191 .Sh "Options Controlling \*(C+ Dialect"
1192 .IX Subsection "Options Controlling  Dialect"
1193 This section describes the command-line options that are only meaningful
1194 for \*(C+ programs; but you can also use most of the \s-1GNU\s0 compiler options
1195 regardless of what language your program is in.  For example, you
1196 might compile a file \f(CW\*(C`firstClass.C\*(C'\fR like this:
1198 .Vb 1
1199 \&        g++ -g -frepo -O -c firstClass.C
1201 In this example, only \fB\-frepo\fR is an option meant
1202 only for \*(C+ programs; you can use the other options with any
1203 language supported by \s-1GCC\s0.
1205 Here is a list of options that are \fIonly\fR for compiling \*(C+ programs:
1206 .Ip "\fB\-fabi-version=\fR\fIn\fR" 4
1207 .IX Item "-fabi-version=n"
1208 Use version \fIn\fR of the \*(C+ \s-1ABI\s0.  Version 2 is the version of the
1209 \&\*(C+ \s-1ABI\s0 that first appeared in G++ 3.4.  Version 1 is the version of
1210 the \*(C+ \s-1ABI\s0 that first appeared in G++ 3.2.  Version 0 will always be
1211 the version that conforms most closely to the \*(C+ \s-1ABI\s0 specification.
1212 Therefore, the \s-1ABI\s0 obtained using version 0 will change as \s-1ABI\s0 bugs
1213 are fixed.
1215 The default is version 2.
1216 .Ip "\fB\-fno-access-control\fR" 4
1217 .IX Item "-fno-access-control"
1218 Turn off all access checking.  This switch is mainly useful for working
1219 around bugs in the access control code.
1220 .Ip "\fB\-fcheck-new\fR" 4
1221 .IX Item "-fcheck-new"
1222 Check that the pointer returned by \f(CW\*(C`operator new\*(C'\fR is non-null
1223 before attempting to modify the storage allocated.  This check is
1224 normally unnecessary because the \*(C+ standard specifies that
1225 \&\f(CW\*(C`operator new\*(C'\fR will only return \f(CW\*(C`0\*(C'\fR if it is declared
1226 \&\fB\f(BIthrow()\fB\fR, in which case the compiler will always check the
1227 return value even without this option.  In all other cases, when
1228 \&\f(CW\*(C`operator new\*(C'\fR has a non-empty exception specification, memory
1229 exhaustion is signalled by throwing \f(CW\*(C`std::bad_alloc\*(C'\fR.  See also
1230 \&\fBnew (nothrow)\fR.
1231 .Ip "\fB\-fconserve-space\fR" 4
1232 .IX Item "-fconserve-space"
1233 Put uninitialized or runtime-initialized global variables into the
1234 common segment, as C does.  This saves space in the executable at the
1235 cost of not diagnosing duplicate definitions.  If you compile with this
1236 flag and your program mysteriously crashes after \f(CW\*(C`main()\*(C'\fR has
1237 completed, you may have an object that is being destroyed twice because
1238 two definitions were merged.
1240 This option is no longer useful on most targets, now that support has
1241 been added for putting variables into \s-1BSS\s0 without making them common.
1242 .Ip "\fB\-fno-const-strings\fR" 4
1243 .IX Item "-fno-const-strings"
1244 Give string constants type \f(CW\*(C`char *\*(C'\fR instead of type \f(CW\*(C`const
1245 char *\*(C'\fR.  By default, G++ uses type \f(CW\*(C`const char *\*(C'\fR as required by
1246 the standard.  Even if you use \fB\-fno-const-strings\fR, you cannot
1247 actually modify the value of a string constant, unless you also use
1248 \&\fB\-fwritable-strings\fR.
1250 This option might be removed in a future release of G++.  For maximum
1251 portability, you should structure your code so that it works with
1252 string constants that have type \f(CW\*(C`const char *\*(C'\fR.
1253 .Ip "\fB\-fno-elide-constructors\fR" 4
1254 .IX Item "-fno-elide-constructors"
1255 The \*(C+ standard allows an implementation to omit creating a temporary
1256 which is only used to initialize another object of the same type.
1257 Specifying this option disables that optimization, and forces G++ to
1258 call the copy constructor in all cases.
1259 .Ip "\fB\-fno-enforce-eh-specs\fR" 4
1260 .IX Item "-fno-enforce-eh-specs"
1261 Don't check for violation of exception specifications at runtime.  This
1262 option violates the \*(C+ standard, but may be useful for reducing code
1263 size in production builds, much like defining \fB\s-1NDEBUG\s0\fR.  The compiler
1264 will still optimize based on the exception specifications.
1265 .Ip "\fB\-ffor-scope\fR" 4
1266 .IX Item "-ffor-scope"
1267 .PD 0
1268 .Ip "\fB\-fno-for-scope\fR" 4
1269 .IX Item "-fno-for-scope"
1271 If \fB\-ffor-scope\fR is specified, the scope of variables declared in
1272 a \fIfor-init-statement\fR is limited to the \fBfor\fR loop itself,
1273 as specified by the \*(C+ standard.
1274 If \fB\-fno-for-scope\fR is specified, the scope of variables declared in
1275 a \fIfor-init-statement\fR extends to the end of the enclosing scope,
1276 as was the case in old versions of G++, and other (traditional)
1277 implementations of \*(C+.
1279 The default if neither flag is given to follow the standard,
1280 but to allow and give a warning for old-style code that would
1281 otherwise be invalid, or have different behavior.
1282 .Ip "\fB\-fno-gnu-keywords\fR" 4
1283 .IX Item "-fno-gnu-keywords"
1284 Do not recognize \f(CW\*(C`typeof\*(C'\fR as a keyword, so that code can use this
1285 word as an identifier.  You can use the keyword \f(CW\*(C`_\|_typeof_\|_\*(C'\fR instead.
1286 \&\fB\-ansi\fR implies \fB\-fno-gnu-keywords\fR.
1287 .Ip "\fB\-fno-implicit-templates\fR" 4
1288 .IX Item "-fno-implicit-templates"
1289 Never emit code for non-inline templates which are instantiated
1290 implicitly (i.e. by use); only emit code for explicit instantiations.
1291 .Ip "\fB\-fno-implicit-inline-templates\fR" 4
1292 .IX Item "-fno-implicit-inline-templates"
1293 Don't emit code for implicit instantiations of inline templates, either.
1294 The default is to handle inlines differently so that compiles with and
1295 without optimization will need the same set of explicit instantiations.
1296 .Ip "\fB\-fno-implement-inlines\fR" 4
1297 .IX Item "-fno-implement-inlines"
1298 To save space, do not emit out-of-line copies of inline functions
1299 controlled by \fB#pragma implementation\fR.  This will cause linker
1300 errors if these functions are not inlined everywhere they are called.
1301 .Ip "\fB\-fms-extensions\fR" 4
1302 .IX Item "-fms-extensions"
1303 Disable pedantic warnings about constructs used in \s-1MFC\s0, such as implicit
1304 int and getting a pointer to member function via non-standard syntax.
1305 .Ip "\fB\-fno-nonansi-builtins\fR" 4
1306 .IX Item "-fno-nonansi-builtins"
1307 Disable built-in declarations of functions that are not mandated by
1308 \&\s-1ANSI/ISO\s0 C.  These include \f(CW\*(C`ffs\*(C'\fR, \f(CW\*(C`alloca\*(C'\fR, \f(CW\*(C`_exit\*(C'\fR,
1309 \&\f(CW\*(C`index\*(C'\fR, \f(CW\*(C`bzero\*(C'\fR, \f(CW\*(C`conjf\*(C'\fR, and other related functions.
1310 .Ip "\fB\-fno-operator-names\fR" 4
1311 .IX Item "-fno-operator-names"
1312 Do not treat the operator name keywords \f(CW\*(C`and\*(C'\fR, \f(CW\*(C`bitand\*(C'\fR,
1313 \&\f(CW\*(C`bitor\*(C'\fR, \f(CW\*(C`compl\*(C'\fR, \f(CW\*(C`not\*(C'\fR, \f(CW\*(C`or\*(C'\fR and \f(CW\*(C`xor\*(C'\fR as
1314 synonyms as keywords.
1315 .Ip "\fB\-fno-optional-diags\fR" 4
1316 .IX Item "-fno-optional-diags"
1317 Disable diagnostics that the standard says a compiler does not need to
1318 issue.  Currently, the only such diagnostic issued by G++ is the one for
1319 a name having multiple meanings within a class.
1320 .Ip "\fB\-fpermissive\fR" 4
1321 .IX Item "-fpermissive"
1322 Downgrade some diagnostics about nonconformant code from errors to
1323 warnings.  Thus, using \fB\-fpermissive\fR will allow some
1324 nonconforming code to compile.
1325 .Ip "\fB\-frepo\fR" 4
1326 .IX Item "-frepo"
1327 Enable automatic template instantiation at link time.  This option also
1328 implies \fB\-fno-implicit-templates\fR.  
1329 .Ip "\fB\-fno-rtti\fR" 4
1330 .IX Item "-fno-rtti"
1331 Disable generation of information about every class with virtual
1332 functions for use by the \*(C+ runtime type identification features
1333 (\fBdynamic_cast\fR and \fBtypeid\fR).  If you don't use those parts
1334 of the language, you can save some space by using this flag.  Note that
1335 exception handling uses the same information, but it will generate it as
1336 needed.
1337 .Ip "\fB\-fstats\fR" 4
1338 .IX Item "-fstats"
1339 Emit statistics about front-end processing at the end of the compilation.
1340 This information is generally only useful to the G++ development team.
1341 .Ip "\fB\-ftemplate-depth-\fR\fIn\fR" 4
1342 .IX Item "-ftemplate-depth-n"
1343 Set the maximum instantiation depth for template classes to \fIn\fR.
1344 A limit on the template instantiation depth is needed to detect
1345 endless recursions during template class instantiation.  \s-1ANSI/ISO\s0 \*(C+
1346 conforming programs must not rely on a maximum depth greater than 17.
1347 .Ip "\fB\-fuse-cxa-atexit\fR" 4
1348 .IX Item "-fuse-cxa-atexit"
1349 Register destructors for objects with static storage duration with the
1350 \&\f(CW\*(C`_\|_cxa_atexit\*(C'\fR function rather than the \f(CW\*(C`atexit\*(C'\fR function.
1351 This option is required for fully standards-compliant handling of static
1352 destructors, but will only work if your C library supports
1353 \&\f(CW\*(C`_\|_cxa_atexit\*(C'\fR.
1354 .Ip "\fB\-fno-weak\fR" 4
1355 .IX Item "-fno-weak"
1356 Do not use weak symbol support, even if it is provided by the linker.
1357 By default, G++ will use weak symbols if they are available.  This
1358 option exists only for testing, and should not be used by end-users;
1359 it will result in inferior code and has no benefits.  This option may
1360 be removed in a future release of G++.
1361 .Ip "\fB\-nostdinc++\fR" 4
1362 .IX Item "-nostdinc++"
1363 Do not search for header files in the standard directories specific to
1364 \&\*(C+, but do still search the other standard directories.  (This option
1365 is used when building the \*(C+ library.)
1367 In addition, these optimization, warning, and code generation options
1368 have meanings only for \*(C+ programs:
1369 .Ip "\fB\-fno-default-inline\fR" 4
1370 .IX Item "-fno-default-inline"
1371 Do not assume \fBinline\fR for functions defined inside a class scope.
1372   Note that these
1373 functions will have linkage like inline functions; they just won't be
1374 inlined by default.
1375 .Ip "\fB\-Wabi\fR (\*(C+ only)" 4
1376 .IX Item "-Wabi ( only)"
1377 Warn when G++ generates code that is probably not compatible with the
1378 vendor-neutral \*(C+ \s-1ABI\s0.  Although an effort has been made to warn about
1379 all such cases, there are probably some cases that are not warned about,
1380 even though G++ is generating incompatible code.  There may also be
1381 cases where warnings are emitted even though the code that is generated
1382 will be compatible.
1384 You should rewrite your code to avoid these warnings if you are
1385 concerned about the fact that code generated by G++ may not be binary
1386 compatible with code generated by other compilers.
1388 The known incompatibilities at this point include:
1389 .RS 4
1390 .Ip "\(bu" 4
1391 Incorrect handling of tail-padding for bit-fields.  G++ may attempt to
1392 pack data into the same byte as a base class.  For example:
1394 .Vb 2
1395 \&        struct A { virtual void f(); int f1 : 1; };
1396 \&        struct B : public A { int f2 : 1; };
1398 In this case, G++ will place \f(CW\*(C`B::f2\*(C'\fR into the same byte
1399 as\f(CW\*(C`A::f1\*(C'\fR; other compilers will not.  You can avoid this problem
1400 by explicitly padding \f(CW\*(C`A\*(C'\fR so that its size is a multiple of the
1401 byte size on your platform; that will cause G++ and other compilers to
1402 layout \f(CW\*(C`B\*(C'\fR identically.
1403 .Ip "\(bu" 4
1404 Incorrect handling of tail-padding for virtual bases.  G++ does not use
1405 tail padding when laying out virtual bases.  For example:
1407 .Vb 3
1408 \&        struct A { virtual void f(); char c1; };
1409 \&        struct B { B(); char c2; };
1410 \&        struct C : public A, public virtual B {};
1412 In this case, G++ will not place \f(CW\*(C`B\*(C'\fR into the tail-padding for
1413 \&\f(CW\*(C`A\*(C'\fR; other compilers will.  You can avoid this problem by
1414 explicitly padding \f(CW\*(C`A\*(C'\fR so that its size is a multiple of its
1415 alignment (ignoring virtual base classes); that will cause G++ and other
1416 compilers to layout \f(CW\*(C`C\*(C'\fR identically.
1417 .Ip "\(bu" 4
1418 Incorrect handling of bit-fields with declared widths greater than that
1419 of their underlying types, when the bit-fields appear in a union.  For
1420 example:
1422 .Vb 1
1423 \&        union U { int i : 4096; };
1425 Assuming that an \f(CW\*(C`int\*(C'\fR does not have 4096 bits, G++ will make the
1426 union too small by the number of bits in an \f(CW\*(C`int\*(C'\fR.
1427 .Ip "\(bu" 4
1428 Empty classes can be placed at incorrect offsets.  For example:
1430 .Vb 1
1431 \&        struct A {};
1433 .Vb 4
1434 \&        struct B {
1435 \&          A a;
1436 \&          virtual void f ();
1437 \&        };
1439 .Vb 1
1440 \&        struct C : public B, public A {};
1442 G++ will place the \f(CW\*(C`A\*(C'\fR base class of \f(CW\*(C`C\*(C'\fR at a nonzero offset;
1443 it should be placed at offset zero.  G++ mistakenly believes that the
1444 \&\f(CW\*(C`A\*(C'\fR data member of \f(CW\*(C`B\*(C'\fR is already at offset zero.
1445 .Ip "\(bu" 4
1446 Names of template functions whose types involve \f(CW\*(C`typename\*(C'\fR or
1447 template template parameters can be mangled incorrectly.
1449 .Vb 2
1450 \&        template <typename Q>
1451 \&        void f(typename Q::X) {}
1453 .Vb 2
1454 \&        template <template <typename> class Q>
1455 \&        void f(typename Q<int>::X) {}
1457 Instantiations of these templates may be mangled incorrectly.
1459 .RS 4
1461 .Ip "\fB\-Wctor-dtor-privacy\fR (\*(C+ only)" 4
1462 .IX Item "-Wctor-dtor-privacy ( only)"
1463 Warn when a class seems unusable because all the constructors or
1464 destructors in that class are private, and it has neither friends nor
1465 public static member functions.
1466 .Ip "\fB\-Wnon-virtual-dtor\fR (\*(C+ only)" 4
1467 .IX Item "-Wnon-virtual-dtor ( only)"
1468 Warn when a class appears to be polymorphic, thereby requiring a virtual
1469 destructor, yet it declares a non-virtual one.
1470 This warning is enabled by \fB\-Wall\fR.
1471 .Ip "\fB\-Wreorder\fR (\*(C+ only)" 4
1472 .IX Item "-Wreorder ( only)"
1473 Warn when the order of member initializers given in the code does not
1474 match the order in which they must be executed.  For instance:
1476 .Vb 5
1477 \&        struct A {
1478 \&          int i;
1479 \&          int j;
1480 \&          A(): j (0), i (1) { }
1481 \&        };
1483 The compiler will rearrange the member initializers for \fBi\fR
1484 and \fBj\fR to match the declaration order of the members, emitting
1485 a warning to that effect.  This warning is enabled by \fB\-Wall\fR.
1487 The following \fB\-W...\fR options are not affected by \fB\-Wall\fR.
1488 .Ip "\fB\-Weffc++\fR (\*(C+ only)" 4
1489 .IX Item "-Weffc++ ( only)"
1490 Warn about violations of the following style guidelines from Scott Meyers'
1491 \&\fIEffective \*(C+\fR book:
1492 .RS 4
1493 .Ip "\(bu" 4
1494 Item 11:  Define a copy constructor and an assignment operator for classes
1495 with dynamically allocated memory.
1496 .Ip "\(bu" 4
1497 Item 12:  Prefer initialization to assignment in constructors.
1498 .Ip "\(bu" 4
1499 Item 14:  Make destructors virtual in base classes.
1500 .Ip "\(bu" 4
1501 Item 15:  Have \f(CW\*(C`operator=\*(C'\fR return a reference to \f(CW\*(C`*this\*(C'\fR.
1502 .Ip "\(bu" 4
1503 Item 23:  Don't try to return a reference when you must return an object.
1505 .RS 4
1507 Also warn about violations of the following style guidelines from
1508 Scott Meyers' \fIMore Effective \*(C+\fR book:
1509 .RS 4
1511 .Ip "\(bu" 4
1512 Item 6:  Distinguish between prefix and postfix forms of increment and
1513 decrement operators.
1514 .Ip "\(bu" 4
1515 Item 7:  Never overload \f(CW\*(C`&&\*(C'\fR, \f(CW\*(C`||\*(C'\fR, or \f(CW\*(C`,\*(C'\fR.
1517 .RS 4
1519 When selecting this option, be aware that the standard library
1520 headers do not obey all of these guidelines; use \fBgrep \-v\fR
1521 to filter out those warnings.
1523 .Ip "\fB\-Wno-deprecated\fR (\*(C+ only)" 4
1524 .IX Item "-Wno-deprecated ( only)"
1525 Do not warn about usage of deprecated features.  
1526 .Ip "\fB\-Wno-non-template-friend\fR (\*(C+ only)" 4
1527 .IX Item "-Wno-non-template-friend ( only)"
1528 Disable warnings when non-templatized friend functions are declared
1529 within a template.  Since the advent of explicit template specification
1530 support in G++, if the name of the friend is an unqualified-id (i.e.,
1531 \&\fBfriend foo(int)\fR), the \*(C+ language specification demands that the
1532 friend declare or define an ordinary, nontemplate function.  (Section
1533 14.5.3).  Before G++ implemented explicit specification, unqualified-ids
1534 could be interpreted as a particular specialization of a templatized
1535 function.  Because this non-conforming behavior is no longer the default
1536 behavior for G++, \fB\-Wnon-template-friend\fR allows the compiler to
1537 check existing code for potential trouble spots and is on by default.
1538 This new compiler behavior can be turned off with
1539 \&\fB\-Wno-non-template-friend\fR which keeps the conformant compiler code
1540 but disables the helpful warning.
1541 .Ip "\fB\-Wold-style-cast\fR (\*(C+ only)" 4
1542 .IX Item "-Wold-style-cast ( only)"
1543 Warn if an old-style (C-style) cast to a non-void type is used within
1544 a \*(C+ program.  The new-style casts (\fBstatic_cast\fR,
1545 \&\fBreinterpret_cast\fR, and \fBconst_cast\fR) are less vulnerable to
1546 unintended effects and much easier to search for.
1547 .Ip "\fB\-Woverloaded-virtual\fR (\*(C+ only)" 4
1548 .IX Item "-Woverloaded-virtual ( only)"
1549 Warn when a function declaration hides virtual functions from a
1550 base class.  For example, in:
1552 .Vb 3
1553 \&        struct A {
1554 \&          virtual void f();
1555 \&        };
1557 .Vb 3
1558 \&        struct B: public A {
1559 \&          void f(int);
1560 \&        };
1562 the \f(CW\*(C`A\*(C'\fR class version of \f(CW\*(C`f\*(C'\fR is hidden in \f(CW\*(C`B\*(C'\fR, and code
1563 like:
1565 .Vb 2
1566 \&        B* b;
1567 \&        b->f();
1569 will fail to compile.
1570 .Ip "\fB\-Wno-pmf-conversions\fR (\*(C+ only)" 4
1571 .IX Item "-Wno-pmf-conversions ( only)"
1572 Disable the diagnostic for converting a bound pointer to member function
1573 to a plain pointer.
1574 .Ip "\fB\-Wsign-promo\fR (\*(C+ only)" 4
1575 .IX Item "-Wsign-promo ( only)"
1576 Warn when overload resolution chooses a promotion from unsigned or
1577 enumerated type to a signed type, over a conversion to an unsigned type of
1578 the same size.  Previous versions of G++ would try to preserve
1579 unsignedness, but the standard mandates the current behavior.
1580 .Ip "\fB\-Wsynth\fR (\*(C+ only)" 4
1581 .IX Item "-Wsynth ( only)"
1582 Warn when G++'s synthesis behavior does not match that of cfront.  For
1583 instance:
1585 .Vb 4
1586 \&        struct A {
1587 \&          operator int ();
1588 \&          A& operator = (int);
1589 \&        };
1591 .Vb 5
1592 \&        main ()
1593 \&        {
1594 \&          A a,b;
1595 \&          a = b;
1596 \&        }
1598 In this example, G++ will synthesize a default \fBA& operator =
1599 (const A&);\fR, while cfront will use the user-defined \fBoperator =\fR.
1600 .Sh "Options Controlling Objective-C Dialect"
1601 .IX Subsection "Options Controlling Objective-C Dialect"
1602 (\s-1NOTE:\s0 This manual does not describe the Objective-C language itself.  See
1603 <\fBhttp://gcc.gnu.org/readings.html\fR> for references.)
1605 This section describes the command-line options that are only meaningful
1606 for Objective-C programs, but you can also use most of the \s-1GNU\s0 compiler
1607 options regardless of what language your program is in.  For example,
1608 you might compile a file \f(CW\*(C`some_class.m\*(C'\fR like this:
1610 .Vb 1
1611 \&        gcc -g -fgnu-runtime -O -c some_class.m
1613 In this example, \fB\-fgnu-runtime\fR is an option meant only for
1614 Objective-C programs; you can use the other options with any language
1615 supported by \s-1GCC\s0.
1617 Here is a list of options that are \fIonly\fR for compiling Objective-C
1618 programs:
1619 .Ip "\fB\-fconstant-string-class=\fR\fIclass-name\fR" 4
1620 .IX Item "-fconstant-string-class=class-name"
1621 Use \fIclass-name\fR as the name of the class to instantiate for each
1622 literal string specified with the syntax \f(CW\*(C`@"..."\*(C'\fR.  The default
1623 class name is \f(CW\*(C`NXConstantString\*(C'\fR if the \s-1GNU\s0 runtime is being used, and
1624 \&\f(CW\*(C`NSConstantString\*(C'\fR if the NeXT runtime is being used (see below).  The
1625 \&\fB\-fconstant-cfstrings\fR option, if also present, will override the
1626 \&\fB\-fconstant-string-class\fR setting and cause \f(CW\*(C`@"..."\*(C'\fR literals
1627 to be laid out as constant CoreFoundation strings.
1628 .Ip "\fB\-fgnu-runtime\fR" 4
1629 .IX Item "-fgnu-runtime"
1630 Generate object code compatible with the standard \s-1GNU\s0 Objective-C
1631 runtime.  This is the default for most types of systems.
1632 .Ip "\fB\-fnext-runtime\fR" 4
1633 .IX Item "-fnext-runtime"
1634 Generate output compatible with the NeXT runtime.  This is the default
1635 for NeXT-based systems, including Darwin and Mac \s-1OS\s0 X.  The macro
1636 \&\f(CW\*(C`_\|_NEXT_RUNTIME_\|_\*(C'\fR is predefined if (and only if) this option is
1637 used.
1638 .Ip "\fB\-fno-nil-receivers\fR" 4
1639 .IX Item "-fno-nil-receivers"
1640 Assume that all Objective-C message dispatches (e.g.,
1641 \&\f(CW\*(C`[receiver message:arg]\*(C'\fR) in this translation unit ensure that the receiver
1642 is not \f(CW\*(C`nil\*(C'\fR.  This allows for more efficient entry points in the runtime to be
1643 used.  Currently, this option is only available in conjunction with
1644 the NeXT runtime on Mac \s-1OS\s0 X 10.3 and later.
1645 .Ip "\fB\-fobjc-exceptions\fR" 4
1646 .IX Item "-fobjc-exceptions"
1647 Enable syntactic support for structured exception handling in Objective-C,
1648 similar to what is offered by \*(C+ and Java.  Currently, this option is only
1649 available in conjunction with the NeXT runtime on Mac \s-1OS\s0 X 10.3 and later.
1651 .Vb 23
1652 \&          @try {
1653 \&            ...
1654 \&               @throw expr;
1655 \&            ...
1656 \&          }
1657 \&          @catch (AnObjCClass *exc) {
1658 \&            ...
1659 \&              @throw expr;
1660 \&            ...
1661 \&              @throw;
1662 \&            ...
1663 \&          }
1664 \&          @catch (AnotherClass *exc) {
1665 \&            ...
1666 \&          }
1667 \&          @catch (id allOthers) {
1668 \&            ...
1669 \&          }
1670 \&          @finally {
1671 \&            ...
1672 \&              @throw expr;
1673 \&            ...
1674 \&          }
1676 The \f(CW\*(C`@throw\*(C'\fR statement may appear anywhere in an Objective-C or
1677 Objective-\*(C+ program; when used inside of a \f(CW\*(C`@catch\*(C'\fR block, the
1678 \&\f(CW\*(C`@throw\*(C'\fR may appear without an argument (as shown above), in which case
1679 the object caught by the \f(CW\*(C`@catch\*(C'\fR will be rethrown.
1681 Note that only (pointers to) Objective-C objects may be thrown and
1682 caught using this scheme.  When an object is thrown, it will be caught
1683 by the nearest \f(CW\*(C`@catch\*(C'\fR clause capable of handling objects of that type,
1684 analogously to how \f(CW\*(C`catch\*(C'\fR blocks work in \*(C+ and Java.  A
1685 \&\f(CW\*(C`@catch(id ...)\*(C'\fR clause (as shown above) may also be provided to catch
1686 any and all Objective-C exceptions not caught by previous \f(CW\*(C`@catch\*(C'\fR
1687 clauses (if any).
1689 The \f(CW\*(C`@finally\*(C'\fR clause, if present, will be executed upon exit from the
1690 immediately preceding \f(CW\*(C`@try ... @catch\*(C'\fR section.  This will happen
1691 regardless of whether any exceptions are thrown, caught or rethrown
1692 inside the \f(CW\*(C`@try ... @catch\*(C'\fR section, analogously to the behavior
1693 of the \f(CW\*(C`finally\*(C'\fR clause in Java.
1695 There are several caveats to using the new exception mechanism:
1696 .RS 4
1697 .Ip "\(bu" 4
1698 Although currently designed to be binary compatible with \f(CW\*(C`NS_HANDLER\*(C'\fR\-style
1699 idioms provided by the \f(CW\*(C`NSException\*(C'\fR class, the new
1700 exceptions can only be used on Mac \s-1OS\s0 X 10.3 (Panther) and later
1701 systems, due to additional functionality needed in the (NeXT) Objective-C
1702 runtime.
1703 .Ip "\(bu" 4
1704 As mentioned above, the new exceptions do not support handling
1705 types other than Objective-C objects.   Furthermore, when used from
1706 Objective-\*(C+, the Objective-C exception model does not interoperate with \*(C+
1707 exceptions at this time.  This means you cannot \f(CW\*(C`@throw\*(C'\fR an exception
1708 from Objective-C and \f(CW\*(C`catch\*(C'\fR it in \*(C+, or vice versa
1709 (i.e., \f(CW\*(C`throw ... @catch\*(C'\fR).
1711 .RS 4
1713 The \fB\-fobjc-exceptions\fR switch also enables the use of synchronization
1714 blocks for thread-safe execution:
1716 .Vb 3
1717 \&          @synchronized (ObjCClass *guard) {
1718 \&            ...
1719 \&          }
1721 Upon entering the \f(CW\*(C`@synchronized\*(C'\fR block, a thread of execution shall
1722 first check whether a lock has been placed on the corresponding \f(CW\*(C`guard\*(C'\fR
1723 object by another thread.  If it has, the current thread shall wait until
1724 the other thread relinquishes its lock.  Once \f(CW\*(C`guard\*(C'\fR becomes available,
1725 the current thread will place its own lock on it, execute the code contained in
1726 the \f(CW\*(C`@synchronized\*(C'\fR block, and finally relinquish the lock (thereby
1727 making \f(CW\*(C`guard\*(C'\fR available to other threads).
1729 Unlike Java, Objective-C does not allow for entire methods to be marked
1730 \&\f(CW\*(C`@synchronized\*(C'\fR.  Note that throwing exceptions out of
1731 \&\f(CW\*(C`@synchronized\*(C'\fR blocks is allowed, and will cause the guarding object
1732 to be unlocked properly.
1734 .Ip "\fB\-freplace-objc-classes\fR" 4
1735 .IX Item "-freplace-objc-classes"
1736 Emit a special marker instructing \fB\f(BIld\fB\|(1)\fR not to statically link in
1737 the resulting object file, and allow \fB\f(BIdyld\fB\|(1)\fR to load it in at
1738 run time instead.  This is used in conjunction with the Fix-and-Continue
1739 debugging mode, where the object file in question may be recompiled and
1740 dynamically reloaded in the course of program execution, without the need
1741 to restart the program itself.  Currently, Fix-and-Continue functionality
1742 is only available in conjunction with the NeXT runtime on Mac \s-1OS\s0 X 10.3
1743 and later.
1744 .Ip "\fB\-fzero-link\fR" 4
1745 .IX Item "-fzero-link"
1746 When compiling for the NeXT runtime, the compiler ordinarily replaces calls
1747 to \f(CW\*(C`objc_getClass("...")\*(C'\fR (when the name of the class is known at
1748 compile time) with static class references that get initialized at load time,
1749 which improves run-time performance.  Specifying the \fB\-fzero-link\fR flag
1750 suppresses this behavior and causes calls to \f(CW\*(C`objc_getClass("...")\*(C'\fR
1751 to be retained.  This is useful in Zero-Link debugging mode, since it allows
1752 for individual class implementations to be modified during program execution.
1753 .Ip "\fB\-gen-decls\fR" 4
1754 .IX Item "-gen-decls"
1755 Dump interface declarations for all classes seen in the source file to a
1756 file named \fI\fIsourcename\fI.decl\fR.
1757 .Ip "\fB\-Wno-protocol\fR" 4
1758 .IX Item "-Wno-protocol"
1759 If a class is declared to implement a protocol, a warning is issued for
1760 every method in the protocol that is not implemented by the class.  The
1761 default behavior is to issue a warning for every method not explicitly
1762 implemented in the class, even if a method implementation is inherited
1763 from the superclass.  If you use the \f(CW\*(C`\-Wno\-protocol\*(C'\fR option, then
1764 methods inherited from the superclass are considered to be implemented,
1765 and no warning is issued for them.
1766 .Ip "\fB\-Wselector\fR" 4
1767 .IX Item "-Wselector"
1768 Warn if multiple methods of different types for the same selector are
1769 found during compilation.  The check is performed on the list of methods
1770 in the final stage of compilation.  Additionally, a check is performed
1771 for each selector appearing in a \f(CW\*(C`@selector(...)\*(C'\fR
1772 expression, and a corresponding method for that selector has been found
1773 during compilation.  Because these checks scan the method table only at
1774 the end of compilation, these warnings are not produced if the final
1775 stage of compilation is not reached, for example because an error is
1776 found during compilation, or because the \f(CW\*(C`\-fsyntax\-only\*(C'\fR option is
1777 being used.
1778 .Ip "\fB\-Wundeclared-selector\fR" 4
1779 .IX Item "-Wundeclared-selector"
1780 Warn if a \f(CW\*(C`@selector(...)\*(C'\fR expression referring to an
1781 undeclared selector is found.  A selector is considered undeclared if no
1782 method with that name has been declared before the
1783 \&\f(CW\*(C`@selector(...)\*(C'\fR expression, either explicitly in an
1784 \&\f(CW\*(C`@interface\*(C'\fR or \f(CW\*(C`@protocol\*(C'\fR declaration, or implicitly in
1785 an \f(CW\*(C`@implementation\*(C'\fR section.  This option always performs its
1786 checks as soon as a \f(CW\*(C`@selector(...)\*(C'\fR expression is found,
1787 while \f(CW\*(C`\-Wselector\*(C'\fR only performs its checks in the final stage of
1788 compilation.  This also enforces the coding style convention
1789 that methods and selectors must be declared before being used.
1790 .Ip "\fB\-print-objc-runtime-info\fR" 4
1791 .IX Item "-print-objc-runtime-info"
1792 Generate C header describing the largest structure that is passed by
1793 value, if any.
1794 .Sh "Options to Control Diagnostic Messages Formatting"
1795 .IX Subsection "Options to Control Diagnostic Messages Formatting"
1796 Traditionally, diagnostic messages have been formatted irrespective of
1797 the output device's aspect (e.g. its width, ...).  The options described
1798 below can be used to control the diagnostic messages formatting
1799 algorithm, e.g. how many characters per line, how often source location
1800 information should be reported.  Right now, only the \*(C+ front end can
1801 honor these options.  However it is expected, in the near future, that
1802 the remaining front ends would be able to digest them correctly.
1803 .Ip "\fB\-fmessage-length=\fR\fIn\fR" 4
1804 .IX Item "-fmessage-length=n"
1805 Try to format error messages so that they fit on lines of about \fIn\fR
1806 characters.  The default is 72 characters for \fBg++\fR and 0 for the rest of
1807 the front ends supported by \s-1GCC\s0.  If \fIn\fR is zero, then no
1808 line-wrapping will be done; each error message will appear on a single
1809 line.
1810 .Ip "\fB\-fdiagnostics-show-location=once\fR" 4
1811 .IX Item "-fdiagnostics-show-location=once"
1812 Only meaningful in line-wrapping mode.  Instructs the diagnostic messages
1813 reporter to emit \fIonce\fR source location information; that is, in
1814 case the message is too long to fit on a single physical line and has to
1815 be wrapped, the source location won't be emitted (as prefix) again,
1816 over and over, in subsequent continuation lines.  This is the default
1817 behavior.
1818 .Ip "\fB\-fdiagnostics-show-location=every-line\fR" 4
1819 .IX Item "-fdiagnostics-show-location=every-line"
1820 Only meaningful in line-wrapping mode.  Instructs the diagnostic
1821 messages reporter to emit the same source location information (as
1822 prefix) for physical lines that result from the process of breaking
1823 a message which is too long to fit on a single line.
1824 .Sh "Options to Request or Suppress Warnings"
1825 .IX Subsection "Options to Request or Suppress Warnings"
1826 Warnings are diagnostic messages that report constructions which
1827 are not inherently erroneous but which are risky or suggest there
1828 may have been an error.
1830 You can request many specific warnings with options beginning \fB\-W\fR,
1831 for example \fB\-Wimplicit\fR to request warnings on implicit
1832 declarations.  Each of these specific warning options also has a
1833 negative form beginning \fB\-Wno-\fR to turn off warnings;
1834 for example, \fB\-Wno-implicit\fR.  This manual lists only one of the
1835 two forms, whichever is not the default.
1837 The following options control the amount and kinds of warnings produced
1838 by \s-1GCC\s0; for further, language-specific options also refer to
1839 \&\fB\*(C+ Dialect Options\fR and \fBObjective-C Dialect Options\fR.
1840 .Ip "\fB\-fsyntax-only\fR" 4
1841 .IX Item "-fsyntax-only"
1842 Check the code for syntax errors, but don't do anything beyond that.
1843 .Ip "\fB\-pedantic\fR" 4
1844 .IX Item "-pedantic"
1845 Issue all the warnings demanded by strict \s-1ISO\s0 C and \s-1ISO\s0 \*(C+;
1846 reject all programs that use forbidden extensions, and some other
1847 programs that do not follow \s-1ISO\s0 C and \s-1ISO\s0 \*(C+.  For \s-1ISO\s0 C, follows the
1848 version of the \s-1ISO\s0 C standard specified by any \fB\-std\fR option used.
1850 Valid \s-1ISO\s0 C and \s-1ISO\s0 \*(C+ programs should compile properly with or without
1851 this option (though a rare few will require \fB\-ansi\fR or a
1852 \&\fB\-std\fR option specifying the required version of \s-1ISO\s0 C).  However,
1853 without this option, certain \s-1GNU\s0 extensions and traditional C and \*(C+
1854 features are supported as well.  With this option, they are rejected.
1856 \&\fB\-pedantic\fR does not cause warning messages for use of the
1857 alternate keywords whose names begin and end with \fB_\|_\fR.  Pedantic
1858 warnings are also disabled in the expression that follows
1859 \&\f(CW\*(C`_\|_extension_\|_\*(C'\fR.  However, only system header files should use
1860 these escape routes; application programs should avoid them.
1862 Some users try to use \fB\-pedantic\fR to check programs for strict \s-1ISO\s0
1863 C conformance.  They soon find that it does not do quite what they want:
1864 it finds some non-ISO practices, but not all\-\-\-only those for which
1865 \&\s-1ISO\s0 C \fIrequires\fR a diagnostic, and some others for which
1866 diagnostics have been added.
1868 A feature to report any failure to conform to \s-1ISO\s0 C might be useful in
1869 some instances, but would require considerable additional work and would
1870 be quite different from \fB\-pedantic\fR.  We don't have plans to
1871 support such a feature in the near future.
1873 Where the standard specified with \fB\-std\fR represents a \s-1GNU\s0
1874 extended dialect of C, such as \fBgnu89\fR or \fBgnu99\fR, there is a
1875 corresponding \fIbase standard\fR, the version of \s-1ISO\s0 C on which the \s-1GNU\s0
1876 extended dialect is based.  Warnings from \fB\-pedantic\fR are given
1877 where they are required by the base standard.  (It would not make sense
1878 for such warnings to be given only for features not in the specified \s-1GNU\s0
1879 C dialect, since by definition the \s-1GNU\s0 dialects of C include all
1880 features the compiler supports with the given option, and there would be
1881 nothing to warn about.)
1882 .Ip "\fB\-pedantic-errors\fR" 4
1883 .IX Item "-pedantic-errors"
1884 Like \fB\-pedantic\fR, except that errors are produced rather than
1885 warnings.
1886 .Ip "\fB\-w\fR" 4
1887 .IX Item "-w"
1888 Inhibit all warning messages.
1889 .Ip "\fB\-Wno-import\fR" 4
1890 .IX Item "-Wno-import"
1891 Inhibit warning messages about the use of \fB#import\fR.
1892 .Ip "\fB\-Wchar-subscripts\fR" 4
1893 .IX Item "-Wchar-subscripts"
1894 Warn if an array subscript has type \f(CW\*(C`char\*(C'\fR.  This is a common cause
1895 of error, as programmers often forget that this type is signed on some
1896 machines.
1897 .Ip "\fB\-Wcomment\fR" 4
1898 .IX Item "-Wcomment"
1899 Warn whenever a comment-start sequence \fB/*\fR appears in a \fB/*\fR
1900 comment, or whenever a Backslash-Newline appears in a \fB//\fR comment.
1901 .Ip "\fB\-Wformat\fR" 4
1902 .IX Item "-Wformat"
1903 Check calls to \f(CW\*(C`printf\*(C'\fR and \f(CW\*(C`scanf\*(C'\fR, etc., to make sure that
1904 the arguments supplied have types appropriate to the format string
1905 specified, and that the conversions specified in the format string make
1906 sense.  This includes standard functions, and others specified by format
1907 attributes, in the \f(CW\*(C`printf\*(C'\fR,
1908 \&\f(CW\*(C`scanf\*(C'\fR, \f(CW\*(C`strftime\*(C'\fR and \f(CW\*(C`strfmon\*(C'\fR (an X/Open extension,
1909 not in the C standard) families.
1911 The formats are checked against the format features supported by \s-1GNU\s0
1912 libc version 2.2.  These include all \s-1ISO\s0 C90 and C99 features, as well
1913 as features from the Single Unix Specification and some \s-1BSD\s0 and \s-1GNU\s0
1914 extensions.  Other library implementations may not support all these
1915 features; \s-1GCC\s0 does not support warning about features that go beyond a
1916 particular library's limitations.  However, if \fB\-pedantic\fR is used
1917 with \fB\-Wformat\fR, warnings will be given about format features not
1918 in the selected standard version (but not for \f(CW\*(C`strfmon\*(C'\fR formats,
1919 since those are not in any version of the C standard).  
1921 Since \fB\-Wformat\fR also checks for null format arguments for
1922 several functions, \fB\-Wformat\fR also implies \fB\-Wnonnull\fR.
1924 \&\fB\-Wformat\fR is included in \fB\-Wall\fR.  For more control over some
1925 aspects of format checking, the options \fB\-Wformat-y2k\fR,
1926 \&\fB\-Wno-format-extra-args\fR, \fB\-Wno-format-zero-length\fR,
1927 \&\fB\-Wformat-nonliteral\fR, \fB\-Wformat-security\fR, and
1928 \&\fB\-Wformat=2\fR are available, but are not included in \fB\-Wall\fR.
1929 .Ip "\fB\-Wformat-y2k\fR" 4
1930 .IX Item "-Wformat-y2k"
1931 If \fB\-Wformat\fR is specified, also warn about \f(CW\*(C`strftime\*(C'\fR
1932 formats which may yield only a two-digit year.
1933 .Ip "\fB\-Wno-format-extra-args\fR" 4
1934 .IX Item "-Wno-format-extra-args"
1935 If \fB\-Wformat\fR is specified, do not warn about excess arguments to a
1936 \&\f(CW\*(C`printf\*(C'\fR or \f(CW\*(C`scanf\*(C'\fR format function.  The C standard specifies
1937 that such arguments are ignored.
1939 Where the unused arguments lie between used arguments that are
1940 specified with \fB$\fR operand number specifications, normally
1941 warnings are still given, since the implementation could not know what
1942 type to pass to \f(CW\*(C`va_arg\*(C'\fR to skip the unused arguments.  However,
1943 in the case of \f(CW\*(C`scanf\*(C'\fR formats, this option will suppress the
1944 warning if the unused arguments are all pointers, since the Single
1945 Unix Specification says that such unused arguments are allowed.
1946 .Ip "\fB\-Wno-format-zero-length\fR" 4
1947 .IX Item "-Wno-format-zero-length"
1948 If \fB\-Wformat\fR is specified, do not warn about zero-length formats.
1949 The C standard specifies that zero-length formats are allowed.
1950 .Ip "\fB\-Wformat-nonliteral\fR" 4
1951 .IX Item "-Wformat-nonliteral"
1952 If \fB\-Wformat\fR is specified, also warn if the format string is not a
1953 string literal and so cannot be checked, unless the format function
1954 takes its format arguments as a \f(CW\*(C`va_list\*(C'\fR.
1955 .Ip "\fB\-Wformat-security\fR" 4
1956 .IX Item "-Wformat-security"
1957 If \fB\-Wformat\fR is specified, also warn about uses of format
1958 functions that represent possible security problems.  At present, this
1959 warns about calls to \f(CW\*(C`printf\*(C'\fR and \f(CW\*(C`scanf\*(C'\fR functions where the
1960 format string is not a string literal and there are no format arguments,
1961 as in \f(CW\*(C`printf (foo);\*(C'\fR.  This may be a security hole if the format
1962 string came from untrusted input and contains \fB%n\fR.  (This is
1963 currently a subset of what \fB\-Wformat-nonliteral\fR warns about, but
1964 in future warnings may be added to \fB\-Wformat-security\fR that are not
1965 included in \fB\-Wformat-nonliteral\fR.)
1966 .Ip "\fB\-Wformat=2\fR" 4
1967 .IX Item "-Wformat=2"
1968 Enable \fB\-Wformat\fR plus format checks not included in
1969 \&\fB\-Wformat\fR.  Currently equivalent to \fB\-Wformat
1970 \&\-Wformat-nonliteral \-Wformat-security \-Wformat-y2k\fR.
1971 .Ip "\fB\-Wnonnull\fR" 4
1972 .IX Item "-Wnonnull"
1973 Warn about passing a null pointer for arguments marked as
1974 requiring a non-null value by the \f(CW\*(C`nonnull\*(C'\fR function attribute.
1976 \&\fB\-Wnonnull\fR is included in \fB\-Wall\fR and \fB\-Wformat\fR.  It
1977 can be disabled with the \fB\-Wno-nonnull\fR option.
1978 .Ip "\fB\-Winit-self\fR (C, \*(C+, and Objective-C only)" 4
1979 .IX Item "-Winit-self (C, , and Objective-C only)"
1980 Warn about uninitialized variables which are initialized with themselves.
1981 Note this option can only be used with the \fB\-Wuninitialized\fR option,
1982 which in turn only works with \fB\-O1\fR and above.
1984 For example, \s-1GCC\s0 will warn about \f(CW\*(C`i\*(C'\fR being uninitialized in the
1985 following snippet only when \fB\-Winit-self\fR has been specified:
1987 .Vb 5
1988 \&        int f()
1989 \&        {
1990 \&          int i = i;
1991 \&          return i;
1992 \&        }
1994 .Ip "\fB\-Wimplicit-int\fR" 4
1995 .IX Item "-Wimplicit-int"
1996 Warn when a declaration does not specify a type.
1997 .Ip "\fB\-Wimplicit-function-declaration\fR" 4
1998 .IX Item "-Wimplicit-function-declaration"
1999 .PD 0
2000 .Ip "\fB\-Werror-implicit-function-declaration\fR" 4
2001 .IX Item "-Werror-implicit-function-declaration"
2003 Give a warning (or error) whenever a function is used before being
2004 declared.
2005 .Ip "\fB\-Wimplicit\fR" 4
2006 .IX Item "-Wimplicit"
2007 Same as \fB\-Wimplicit-int\fR and \fB\-Wimplicit-function-declaration\fR.
2008 .Ip "\fB\-Wmain\fR" 4
2009 .IX Item "-Wmain"
2010 Warn if the type of \fBmain\fR is suspicious.  \fBmain\fR should be a
2011 function with external linkage, returning int, taking either zero
2012 arguments, two, or three arguments of appropriate types.
2013 .Ip "\fB\-Wmissing-braces\fR" 4
2014 .IX Item "-Wmissing-braces"
2015 Warn if an aggregate or union initializer is not fully bracketed.  In
2016 the following example, the initializer for \fBa\fR is not fully
2017 bracketed, but that for \fBb\fR is fully bracketed.
2019 .Vb 2
2020 \&        int a[2][2] = { 0, 1, 2, 3 };
2021 \&        int b[2][2] = { { 0, 1 }, { 2, 3 } };
2023 .Ip "\fB\-Wparentheses\fR" 4
2024 .IX Item "-Wparentheses"
2025 Warn if parentheses are omitted in certain contexts, such
2026 as when there is an assignment in a context where a truth value
2027 is expected, or when operators are nested whose precedence people
2028 often get confused about.
2030 Also warn about constructions where there may be confusion to which
2031 \&\f(CW\*(C`if\*(C'\fR statement an \f(CW\*(C`else\*(C'\fR branch belongs.  Here is an example of
2032 such a case:
2034 .Vb 7
2035 \&        {
2036 \&          if (a)
2037 \&            if (b)
2038 \&              foo ();
2039 \&          else
2040 \&            bar ();
2041 \&        }
2043 In C, every \f(CW\*(C`else\*(C'\fR branch belongs to the innermost possible \f(CW\*(C`if\*(C'\fR
2044 statement, which in this example is \f(CW\*(C`if (b)\*(C'\fR.  This is often not
2045 what the programmer expected, as illustrated in the above example by
2046 indentation the programmer chose.  When there is the potential for this
2047 confusion, \s-1GCC\s0 will issue a warning when this flag is specified.
2048 To eliminate the warning, add explicit braces around the innermost
2049 \&\f(CW\*(C`if\*(C'\fR statement so there is no way the \f(CW\*(C`else\*(C'\fR could belong to
2050 the enclosing \f(CW\*(C`if\*(C'\fR.  The resulting code would look like this:
2052 .Vb 9
2053 \&        {
2054 \&          if (a)
2055 \&            {
2056 \&              if (b)
2057 \&                foo ();
2058 \&              else
2059 \&                bar ();
2060 \&            }
2061 \&        }
2063 .Ip "\fB\-Wsequence-point\fR" 4
2064 .IX Item "-Wsequence-point"
2065 Warn about code that may have undefined semantics because of violations
2066 of sequence point rules in the C standard.
2068 The C standard defines the order in which expressions in a C program are
2069 evaluated in terms of \fIsequence points\fR, which represent a partial
2070 ordering between the execution of parts of the program: those executed
2071 before the sequence point, and those executed after it.  These occur
2072 after the evaluation of a full expression (one which is not part of a
2073 larger expression), after the evaluation of the first operand of a
2074 \&\f(CW\*(C`&&\*(C'\fR, \f(CW\*(C`||\*(C'\fR, \f(CW\*(C`? :\*(C'\fR or \f(CW\*(C`,\*(C'\fR (comma) operator, before a
2075 function is called (but after the evaluation of its arguments and the
2076 expression denoting the called function), and in certain other places.
2077 Other than as expressed by the sequence point rules, the order of
2078 evaluation of subexpressions of an expression is not specified.  All
2079 these rules describe only a partial order rather than a total order,
2080 since, for example, if two functions are called within one expression
2081 with no sequence point between them, the order in which the functions
2082 are called is not specified.  However, the standards committee have
2083 ruled that function calls do not overlap.
2085 It is not specified when between sequence points modifications to the
2086 values of objects take effect.  Programs whose behavior depends on this
2087 have undefined behavior; the C standard specifies that ``Between the
2088 previous and next sequence point an object shall have its stored value
2089 modified at most once by the evaluation of an expression.  Furthermore,
2090 the prior value shall be read only to determine the value to be
2091 stored.''.  If a program breaks these rules, the results on any
2092 particular implementation are entirely unpredictable.
2094 Examples of code with undefined behavior are \f(CW\*(C`a = a++;\*(C'\fR, \f(CW\*(C`a[n]
2095 = b[n++]\*(C'\fR and \f(CW\*(C`a[i++] = i;\*(C'\fR.  Some more complicated cases are not
2096 diagnosed by this option, and it may give an occasional false positive
2097 result, but in general it has been found fairly effective at detecting
2098 this sort of problem in programs.
2100 The present implementation of this option only works for C programs.  A
2101 future implementation may also work for \*(C+ programs.
2103 The C standard is worded confusingly, therefore there is some debate
2104 over the precise meaning of the sequence point rules in subtle cases.
2105 Links to discussions of the problem, including proposed formal
2106 definitions, may be found on the \s-1GCC\s0 readings page, at
2107 <\fBhttp://gcc.gnu.org/readings.html\fR>.
2108 .Ip "\fB\-Wreturn-type\fR" 4
2109 .IX Item "-Wreturn-type"
2110 Warn whenever a function is defined with a return-type that defaults to
2111 \&\f(CW\*(C`int\*(C'\fR.  Also warn about any \f(CW\*(C`return\*(C'\fR statement with no
2112 return-value in a function whose return-type is not \f(CW\*(C`void\*(C'\fR.
2114 For \*(C+, a function without return type always produces a diagnostic
2115 message, even when \fB\-Wno-return-type\fR is specified.  The only
2116 exceptions are \fBmain\fR and functions defined in system headers.
2117 .Ip "\fB\-Wswitch\fR" 4
2118 .IX Item "-Wswitch"
2119 Warn whenever a \f(CW\*(C`switch\*(C'\fR statement has an index of enumerated type
2120 and lacks a \f(CW\*(C`case\*(C'\fR for one or more of the named codes of that
2121 enumeration.  (The presence of a \f(CW\*(C`default\*(C'\fR label prevents this
2122 warning.)  \f(CW\*(C`case\*(C'\fR labels outside the enumeration range also
2123 provoke warnings when this option is used.
2124 .Ip "\fB\-Wswitch-default\fR" 4
2125 .IX Item "-Wswitch-default"
2126 Warn whenever a \f(CW\*(C`switch\*(C'\fR statement does not have a \f(CW\*(C`default\*(C'\fR
2127 case.
2128 .Ip "\fB\-Wswitch-enum\fR" 4
2129 .IX Item "-Wswitch-enum"
2130 Warn whenever a \f(CW\*(C`switch\*(C'\fR statement has an index of enumerated type
2131 and lacks a \f(CW\*(C`case\*(C'\fR for one or more of the named codes of that
2132 enumeration.  \f(CW\*(C`case\*(C'\fR labels outside the enumeration range also
2133 provoke warnings when this option is used.
2134 .Ip "\fB\-Wtrigraphs\fR" 4
2135 .IX Item "-Wtrigraphs"
2136 Warn if any trigraphs are encountered that might change the meaning of
2137 the program (trigraphs within comments are not warned about).
2138 .Ip "\fB\-Wunused-function\fR" 4
2139 .IX Item "-Wunused-function"
2140 Warn whenever a static function is declared but not defined or a
2141 non\e-inline static function is unused.
2142 .Ip "\fB\-Wunused-label\fR" 4
2143 .IX Item "-Wunused-label"
2144 Warn whenever a label is declared but not used.
2146 To suppress this warning use the \fBunused\fR attribute.
2147 .Ip "\fB\-Wunused-parameter\fR" 4
2148 .IX Item "-Wunused-parameter"
2149 Warn whenever a function parameter is unused aside from its declaration.
2151 To suppress this warning use the \fBunused\fR attribute.
2152 .Ip "\fB\-Wunused-variable\fR" 4
2153 .IX Item "-Wunused-variable"
2154 Warn whenever a local variable or non-constant static variable is unused
2155 aside from its declaration
2157 To suppress this warning use the \fBunused\fR attribute.
2158 .Ip "\fB\-Wunused-value\fR" 4
2159 .IX Item "-Wunused-value"
2160 Warn whenever a statement computes a result that is explicitly not used.
2162 To suppress this warning cast the expression to \fBvoid\fR.
2163 .Ip "\fB\-Wunused\fR" 4
2164 .IX Item "-Wunused"
2165 All the above \fB\-Wunused\fR options combined.
2167 In order to get a warning about an unused function parameter, you must
2168 either specify \fB\-Wextra \-Wunused\fR (note that \fB\-Wall\fR implies
2169 \&\fB\-Wunused\fR), or separately specify \fB\-Wunused-parameter\fR.
2170 .Ip "\fB\-Wuninitialized\fR" 4
2171 .IX Item "-Wuninitialized"
2172 Warn if an automatic variable is used without first being initialized or
2173 if a variable may be clobbered by a \f(CW\*(C`setjmp\*(C'\fR call.
2175 These warnings are possible only in optimizing compilation,
2176 because they require data flow information that is computed only
2177 when optimizing.  If you don't specify \fB\-O\fR, you simply won't
2178 get these warnings.
2180 If you want to warn about code which uses the uninitialized value of the
2181 variable in its own initializer, use the \fB\-Winit-self\fR option.
2183 These warnings occur only for variables that are candidates for
2184 register allocation.  Therefore, they do not occur for a variable that
2185 is declared \f(CW\*(C`volatile\*(C'\fR, or whose address is taken, or whose size
2186 is other than 1, 2, 4 or 8 bytes.  Also, they do not occur for
2187 structures, unions or arrays, even when they are in registers.
2189 Note that there may be no warning about a variable that is used only
2190 to compute a value that itself is never used, because such
2191 computations may be deleted by data flow analysis before the warnings
2192 are printed.
2194 These warnings are made optional because \s-1GCC\s0 is not smart
2195 enough to see all the reasons why the code might be correct
2196 despite appearing to have an error.  Here is one example of how
2197 this can happen:
2199 .Vb 12
2200 \&        {
2201 \&          int x;
2202 \&          switch (y)
2203 \&            {
2204 \&            case 1: x = 1;
2205 \&              break;
2206 \&            case 2: x = 4;
2207 \&              break;
2208 \&            case 3: x = 5;
2209 \&            }
2210 \&          foo (x);
2211 \&        }
2213 If the value of \f(CW\*(C`y\*(C'\fR is always 1, 2 or 3, then \f(CW\*(C`x\*(C'\fR is
2214 always initialized, but \s-1GCC\s0 doesn't know this.  Here is
2215 another common case:
2217 .Vb 6
2218 \&        {
2219 \&          int save_y;
2220 \&          if (change_y) save_y = y, y = new_y;
2221 \&          ...
2222 \&          if (change_y) y = save_y;
2223 \&        }
2225 This has no bug because \f(CW\*(C`save_y\*(C'\fR is used only if it is set.
2227 This option also warns when a non-volatile automatic variable might be
2228 changed by a call to \f(CW\*(C`longjmp\*(C'\fR.  These warnings as well are possible
2229 only in optimizing compilation.
2231 The compiler sees only the calls to \f(CW\*(C`setjmp\*(C'\fR.  It cannot know
2232 where \f(CW\*(C`longjmp\*(C'\fR will be called; in fact, a signal handler could
2233 call it at any point in the code.  As a result, you may get a warning
2234 even when there is in fact no problem because \f(CW\*(C`longjmp\*(C'\fR cannot
2235 in fact be called at the place which would cause a problem.
2237 Some spurious warnings can be avoided if you declare all the functions
2238 you use that never return as \f(CW\*(C`noreturn\*(C'\fR.  
2239 .Ip "\fB\-Wunknown-pragmas\fR" 4
2240 .IX Item "-Wunknown-pragmas"
2241 Warn when a #pragma directive is encountered which is not understood by
2242 \&\s-1GCC\s0.  If this command line option is used, warnings will even be issued
2243 for unknown pragmas in system header files.  This is not the case if
2244 the warnings were only enabled by the \fB\-Wall\fR command line option.
2245 .Ip "\fB\-Wstrict-aliasing\fR" 4
2246 .IX Item "-Wstrict-aliasing"
2247 This option is only active when \fB\-fstrict-aliasing\fR is active.
2248 It warns about code which might break the strict aliasing rules that the
2249 compiler is using for optimization. The warning does not catch all
2250 cases, but does attempt to catch the more common pitfalls. It is
2251 included in \fB\-Wall\fR.
2252 .Ip "\fB\-Wall\fR" 4
2253 .IX Item "-Wall"
2254 All of the above \fB\-W\fR options combined.  This enables all the
2255 warnings about constructions that some users consider questionable, and
2256 that are easy to avoid (or modify to prevent the warning), even in
2257 conjunction with macros.  This also enables some language-specific
2258 warnings described in \fB\*(C+ Dialect Options\fR and
2259 \&\fBObjective-C Dialect Options\fR.
2261 The following \fB\-W...\fR options are not implied by \fB\-Wall\fR.
2262 Some of them warn about constructions that users generally do not
2263 consider questionable, but which occasionally you might wish to check
2264 for; others warn about constructions that are necessary or hard to avoid
2265 in some cases, and there is no simple way to modify the code to suppress
2266 the warning.
2267 .Ip "\fB\-Wextra\fR" 4
2268 .IX Item "-Wextra"
2269 (This option used to be called \fB\-W\fR.  The older name is still
2270 supported, but the newer name is more descriptive.)  Print extra warning
2271 messages for these events:
2272 .RS 4
2273 .Ip "\(bu" 4
2274 A function can return either with or without a value.  (Falling
2275 off the end of the function body is considered returning without
2276 a value.)  For example, this function would evoke such a
2277 warning:
2279 .Vb 5
2280 \&        foo (a)
2281 \&        {
2282 \&          if (a > 0)
2283 \&            return a;
2284 \&        }
2286 .Ip "\(bu" 4
2287 An expression-statement or the left-hand side of a comma expression
2288 contains no side effects.
2289 To suppress the warning, cast the unused expression to void.
2290 For example, an expression such as \fBx[i,j]\fR will cause a warning,
2291 but \fBx[(void)i,j]\fR will not.
2292 .Ip "\(bu" 4
2293 An unsigned value is compared against zero with \fB<\fR or \fB>=\fR.
2294 .Ip "\(bu" 4
2295 A comparison like \fBx<=y<=z\fR appears; this is equivalent to
2296 \&\fB(x<=y ? 1 : 0) <= z\fR, which is a different interpretation from
2297 that of ordinary mathematical notation.
2298 .Ip "\(bu" 4
2299 Storage-class specifiers like \f(CW\*(C`static\*(C'\fR are not the first things in
2300 a declaration.  According to the C Standard, this usage is obsolescent.
2301 .Ip "\(bu" 4
2302 The return type of a function has a type qualifier such as \f(CW\*(C`const\*(C'\fR.
2303 Such a type qualifier has no effect, since the value returned by a
2304 function is not an lvalue.  (But don't warn about the \s-1GNU\s0 extension of
2305 \&\f(CW\*(C`volatile void\*(C'\fR return types.  That extension will be warned about
2306 if \fB\-pedantic\fR is specified.)
2307 .Ip "\(bu" 4
2308 If \fB\-Wall\fR or \fB\-Wunused\fR is also specified, warn about unused
2309 arguments.
2310 .Ip "\(bu" 4
2311 A comparison between signed and unsigned values could produce an
2312 incorrect result when the signed value is converted to unsigned.
2313 (But don't warn if \fB\-Wno-sign-compare\fR is also specified.)
2314 .Ip "\(bu" 4
2315 An aggregate has an initializer which does not initialize all members.
2316 For example, the following code would cause such a warning, because
2317 \&\f(CW\*(C`x.h\*(C'\fR would be implicitly initialized to zero:
2319 .Vb 2
2320 \&        struct s { int f, g, h; };
2321 \&        struct s x = { 3, 4 };
2323 .Ip "\(bu" 4
2324 A function parameter is declared without a type specifier in K&R-style
2325 functions:
2327 .Vb 1
2328 \&        void foo(bar) { }
2330 .Ip "\(bu" 4
2331 An empty body occurs in an \fBif\fR or \fBelse\fR statement.
2332 .Ip "\(bu" 4
2333 A pointer is compared against integer zero with \fB<\fR, \fB<=\fR,
2334 \&\fB>\fR, or \fB>=\fR.
2335 .Ip "\(bu" 4
2336 A variable might be changed by \fBlongjmp\fR or \fBvfork\fR.
2337 .Ip "\(bu" 4
2338 Any of several floating-point events that often indicate errors, such as
2339 overflow, underflow, loss of precision, etc.
2340 .Ip "*<(\*(C+ only)>" 4
2341 .IX Item "*<( only)>"
2342 An enumerator and a non-enumerator both appear in a conditional expression.
2343 .Ip "*<(\*(C+ only)>" 4
2344 .IX Item "*<( only)>"
2345 A non-static reference or non-static \fBconst\fR member appears in a
2346 class without constructors.
2347 .Ip "*<(\*(C+ only)>" 4
2348 .IX Item "*<( only)>"
2349 Ambiguous virtual bases.
2350 .Ip "*<(\*(C+ only)>" 4
2351 .IX Item "*<( only)>"
2352 Subscripting an array which has been declared \fBregister\fR.
2353 .Ip "*<(\*(C+ only)>" 4
2354 .IX Item "*<( only)>"
2355 Taking the address of a variable which has been declared \fBregister\fR.
2356 .Ip "*<(\*(C+ only)>" 4
2357 .IX Item "*<( only)>"
2358 A base class is not initialized in a derived class' copy constructor.
2360 .RS 4
2362 .Ip "\fB\-Wno-div-by-zero\fR" 4
2363 .IX Item "-Wno-div-by-zero"
2364 Do not warn about compile-time integer division by zero.  Floating point
2365 division by zero is not warned about, as it can be a legitimate way of
2366 obtaining infinities and NaNs.
2367 .Ip "\fB\-Wsystem-headers\fR" 4
2368 .IX Item "-Wsystem-headers"
2369 Print warning messages for constructs found in system header files.
2370 Warnings from system headers are normally suppressed, on the assumption
2371 that they usually do not indicate real problems and would only make the
2372 compiler output harder to read.  Using this command line option tells
2373 \&\s-1GCC\s0 to emit warnings from system headers as if they occurred in user
2374 code.  However, note that using \fB\-Wall\fR in conjunction with this
2375 option will \fInot\fR warn about unknown pragmas in system
2376 headers\-\-\-for that, \fB\-Wunknown-pragmas\fR must also be used.
2377 .Ip "\fB\-Wfloat-equal\fR" 4
2378 .IX Item "-Wfloat-equal"
2379 Warn if floating point values are used in equality comparisons.
2381 The idea behind this is that sometimes it is convenient (for the
2382 programmer) to consider floating-point values as approximations to
2383 infinitely precise real numbers.  If you are doing this, then you need
2384 to compute (by analyzing the code, or in some other way) the maximum or
2385 likely maximum error that the computation introduces, and allow for it
2386 when performing comparisons (and when producing output, but that's a
2387 different problem).  In particular, instead of testing for equality, you
2388 would check to see whether the two values have ranges that overlap; and
2389 this is done with the relational operators, so equality comparisons are
2390 probably mistaken.
2391 .Ip "\fB\-Wtraditional\fR (C only)" 4
2392 .IX Item "-Wtraditional (C only)"
2393 Warn about certain constructs that behave differently in traditional and
2394 \&\s-1ISO\s0 C.  Also warn about \s-1ISO\s0 C constructs that have no traditional C
2395 equivalent, and/or problematic constructs which should be avoided.
2396 .RS 4
2397 .Ip "\(bu" 4
2398 Macro parameters that appear within string literals in the macro body.
2399 In traditional C macro replacement takes place within string literals,
2400 but does not in \s-1ISO\s0 C.
2401 .Ip "\(bu" 4
2402 In traditional C, some preprocessor directives did not exist.
2403 Traditional preprocessors would only consider a line to be a directive
2404 if the \fB#\fR appeared in column 1 on the line.  Therefore
2405 \&\fB\-Wtraditional\fR warns about directives that traditional C
2406 understands but would ignore because the \fB#\fR does not appear as the
2407 first character on the line.  It also suggests you hide directives like
2408 \&\fB#pragma\fR not understood by traditional C by indenting them.  Some
2409 traditional implementations would not recognize \fB#elif\fR, so it
2410 suggests avoiding it altogether.
2411 .Ip "\(bu" 4
2412 A function-like macro that appears without arguments.
2413 .Ip "\(bu" 4
2414 The unary plus operator.
2415 .Ip "\(bu" 4
2416 The \fBU\fR integer constant suffix, or the \fBF\fR or \fBL\fR floating point
2417 constant suffixes.  (Traditional C does support the \fBL\fR suffix on integer
2418 constants.)  Note, these suffixes appear in macros defined in the system
2419 headers of most modern systems, e.g. the \fB_MIN\fR/\fB_MAX\fR macros in \f(CW\*(C`<limits.h>\*(C'\fR.
2420 Use of these macros in user code might normally lead to spurious
2421 warnings, however \s-1GCC\s0's integrated preprocessor has enough context to
2422 avoid warning in these cases.
2423 .Ip "\(bu" 4
2424 A function declared external in one block and then used after the end of
2425 the block.
2426 .Ip "\(bu" 4
2427 A \f(CW\*(C`switch\*(C'\fR statement has an operand of type \f(CW\*(C`long\*(C'\fR.
2428 .Ip "\(bu" 4
2429 A non-\f(CW\*(C`static\*(C'\fR function declaration follows a \f(CW\*(C`static\*(C'\fR one.
2430 This construct is not accepted by some traditional C compilers.
2431 .Ip "\(bu" 4
2432 The \s-1ISO\s0 type of an integer constant has a different width or
2433 signedness from its traditional type.  This warning is only issued if
2434 the base of the constant is ten.  I.e. hexadecimal or octal values, which
2435 typically represent bit patterns, are not warned about.
2436 .Ip "\(bu" 4
2437 Usage of \s-1ISO\s0 string concatenation is detected.
2438 .Ip "\(bu" 4
2439 Initialization of automatic aggregates.
2440 .Ip "\(bu" 4
2441 Identifier conflicts with labels.  Traditional C lacks a separate
2442 namespace for labels.
2443 .Ip "\(bu" 4
2444 Initialization of unions.  If the initializer is zero, the warning is
2445 omitted.  This is done under the assumption that the zero initializer in
2446 user code appears conditioned on e.g. \f(CW\*(C`_\|_STDC_\|_\*(C'\fR to avoid missing
2447 initializer warnings and relies on default initialization to zero in the
2448 traditional C case.
2449 .Ip "\(bu" 4
2450 Conversions by prototypes between fixed/floating point values and vice
2451 versa.  The absence of these prototypes when compiling with traditional
2452 C would cause serious problems.  This is a subset of the possible
2453 conversion warnings, for the full set use \fB\-Wconversion\fR.
2454 .Ip "\(bu" 4
2455 Use of \s-1ISO\s0 C style function definitions.  This warning intentionally is
2456 \&\fInot\fR issued for prototype declarations or variadic functions
2457 because these \s-1ISO\s0 C features will appear in your code when using
2458 libiberty's traditional C compatibility macros, \f(CW\*(C`PARAMS\*(C'\fR and
2459 \&\f(CW\*(C`VPARAMS\*(C'\fR.  This warning is also bypassed for nested functions
2460 because that feature is already a \s-1GCC\s0 extension and thus not relevant to
2461 traditional C compatibility.
2463 .RS 4
2465 .Ip "\fB\-Wdeclaration-after-statement\fR (C only)" 4
2466 .IX Item "-Wdeclaration-after-statement (C only)"
2467 Warn when a declaration is found after a statement in a block.  This
2468 construct, known from \*(C+, was introduced with \s-1ISO\s0 C99 and is by default
2469 allowed in \s-1GCC\s0.  It is not supported by \s-1ISO\s0 C90 and was not supported by
2470 \&\s-1GCC\s0 versions before \s-1GCC\s0 3.0.  
2471 .Ip "\fB\-Wundef\fR" 4
2472 .IX Item "-Wundef"
2473 Warn if an undefined identifier is evaluated in an \fB#if\fR directive.
2474 .Ip "\fB\-Wendif-labels\fR" 4
2475 .IX Item "-Wendif-labels"
2476 Warn whenever an \fB#else\fR or an \fB#endif\fR are followed by text.
2477 .Ip "\fB\-Wshadow\fR" 4
2478 .IX Item "-Wshadow"
2479 Warn whenever a local variable shadows another local variable, parameter or
2480 global variable or whenever a built-in function is shadowed.
2481 .Ip "\fB\-Wlarger-than-\fR\fIlen\fR" 4
2482 .IX Item "-Wlarger-than-len"
2483 Warn whenever an object of larger than \fIlen\fR bytes is defined.
2484 .Ip "\fB\-Wpointer-arith\fR" 4
2485 .IX Item "-Wpointer-arith"
2486 Warn about anything that depends on the ``size of'' a function type or
2487 of \f(CW\*(C`void\*(C'\fR.  \s-1GNU\s0 C assigns these types a size of 1, for
2488 convenience in calculations with \f(CW\*(C`void *\*(C'\fR pointers and pointers
2489 to functions.
2490 .Ip "\fB\-Wbad-function-cast\fR (C only)" 4
2491 .IX Item "-Wbad-function-cast (C only)"
2492 Warn whenever a function call is cast to a non-matching type.
2493 For example, warn if \f(CW\*(C`int malloc()\*(C'\fR is cast to \f(CW\*(C`anything *\*(C'\fR.
2494 .Ip "\fB\-Wcast-qual\fR" 4
2495 .IX Item "-Wcast-qual"
2496 Warn whenever a pointer is cast so as to remove a type qualifier from
2497 the target type.  For example, warn if a \f(CW\*(C`const char *\*(C'\fR is cast
2498 to an ordinary \f(CW\*(C`char *\*(C'\fR.
2499 .Ip "\fB\-Wcast-align\fR" 4
2500 .IX Item "-Wcast-align"
2501 Warn whenever a pointer is cast such that the required alignment of the
2502 target is increased.  For example, warn if a \f(CW\*(C`char *\*(C'\fR is cast to
2503 an \f(CW\*(C`int *\*(C'\fR on machines where integers can only be accessed at
2504 two- or four-byte boundaries.
2505 .Ip "\fB\-Wwrite-strings\fR" 4
2506 .IX Item "-Wwrite-strings"
2507 When compiling C, give string constants the type \f(CW\*(C`const
2508 char[\f(CIlength\f(CW]\*(C'\fR so that
2509 copying the address of one into a non-\f(CW\*(C`const\*(C'\fR \f(CW\*(C`char *\*(C'\fR
2510 pointer will get a warning; when compiling \*(C+, warn about the
2511 deprecated conversion from string constants to \f(CW\*(C`char *\*(C'\fR.
2512 These warnings will help you find at
2513 compile time code that can try to write into a string constant, but
2514 only if you have been very careful about using \f(CW\*(C`const\*(C'\fR in
2515 declarations and prototypes.  Otherwise, it will just be a nuisance;
2516 this is why we did not make \fB\-Wall\fR request these warnings.
2517 .Ip "\fB\-Wconversion\fR" 4
2518 .IX Item "-Wconversion"
2519 Warn if a prototype causes a type conversion that is different from what
2520 would happen to the same argument in the absence of a prototype.  This
2521 includes conversions of fixed point to floating and vice versa, and
2522 conversions changing the width or signedness of a fixed point argument
2523 except when the same as the default promotion.
2525 Also, warn if a negative integer constant expression is implicitly
2526 converted to an unsigned type.  For example, warn about the assignment
2527 \&\f(CW\*(C`x = \-1\*(C'\fR if \f(CW\*(C`x\*(C'\fR is unsigned.  But do not warn about explicit
2528 casts like \f(CW\*(C`(unsigned) \-1\*(C'\fR.
2529 .Ip "\fB\-Wsign-compare\fR" 4
2530 .IX Item "-Wsign-compare"
2531 Warn when a comparison between signed and unsigned values could produce
2532 an incorrect result when the signed value is converted to unsigned.
2533 This warning is also enabled by \fB\-Wextra\fR; to get the other warnings
2534 of \fB\-Wextra\fR without this warning, use \fB\-Wextra \-Wno-sign-compare\fR.
2535 .Ip "\fB\-Waggregate-return\fR" 4
2536 .IX Item "-Waggregate-return"
2537 Warn if any functions that return structures or unions are defined or
2538 called.  (In languages where you can return an array, this also elicits
2539 a warning.)
2540 .Ip "\fB\-Wstrict-prototypes\fR (C only)" 4
2541 .IX Item "-Wstrict-prototypes (C only)"
2542 Warn if a function is declared or defined without specifying the
2543 argument types.  (An old-style function definition is permitted without
2544 a warning if preceded by a declaration which specifies the argument
2545 types.)
2546 .Ip "\fB\-Wold-style-definition\fR (C only)" 4
2547 .IX Item "-Wold-style-definition (C only)"
2548 Warn if an old-style function definition is used.  A warning is given
2549 even if there is a previous prototype.
2550 .Ip "\fB\-Wmissing-prototypes\fR (C only)" 4
2551 .IX Item "-Wmissing-prototypes (C only)"
2552 Warn if a global function is defined without a previous prototype
2553 declaration.  This warning is issued even if the definition itself
2554 provides a prototype.  The aim is to detect global functions that fail
2555 to be declared in header files.
2556 .Ip "\fB\-Wmissing-declarations\fR (C only)" 4
2557 .IX Item "-Wmissing-declarations (C only)"
2558 Warn if a global function is defined without a previous declaration.
2559 Do so even if the definition itself provides a prototype.
2560 Use this option to detect global functions that are not declared in
2561 header files.
2562 .Ip "\fB\-Wmissing-noreturn\fR" 4
2563 .IX Item "-Wmissing-noreturn"
2564 Warn about functions which might be candidates for attribute \f(CW\*(C`noreturn\*(C'\fR.
2565 Note these are only possible candidates, not absolute ones.  Care should
2566 be taken to manually verify functions actually do not ever return before
2567 adding the \f(CW\*(C`noreturn\*(C'\fR attribute, otherwise subtle code generation
2568 bugs could be introduced.  You will not get a warning for \f(CW\*(C`main\*(C'\fR in
2569 hosted C environments.
2570 .Ip "\fB\-Wmissing-format-attribute\fR" 4
2571 .IX Item "-Wmissing-format-attribute"
2572 If \fB\-Wformat\fR is enabled, also warn about functions which might be
2573 candidates for \f(CW\*(C`format\*(C'\fR attributes.  Note these are only possible
2574 candidates, not absolute ones.  \s-1GCC\s0 will guess that \f(CW\*(C`format\*(C'\fR
2575 attributes might be appropriate for any function that calls a function
2576 like \f(CW\*(C`vprintf\*(C'\fR or \f(CW\*(C`vscanf\*(C'\fR, but this might not always be the
2577 case, and some functions for which \f(CW\*(C`format\*(C'\fR attributes are
2578 appropriate may not be detected.  This option has no effect unless
2579 \&\fB\-Wformat\fR is enabled (possibly by \fB\-Wall\fR).
2580 .Ip "\fB\-Wno-multichar\fR" 4
2581 .IX Item "-Wno-multichar"
2582 Do not warn if a multicharacter constant (\fB'\s-1FOOF\s0'\fR) is used.
2583 Usually they indicate a typo in the user's code, as they have
2584 implementation-defined values, and should not be used in portable code.
2585 .Ip "\fB\-Wno-deprecated-declarations\fR" 4
2586 .IX Item "-Wno-deprecated-declarations"
2587 Do not warn about uses of functions, variables, and types marked as
2588 deprecated by using the \f(CW\*(C`deprecated\*(C'\fR attribute.
2589 (@pxref{Function Attributes}, \f(CW@pxref\fR{Variable Attributes},
2590 \&\f(CW@pxref\fR{Type Attributes}.)
2591 .Ip "\fB\-Wpacked\fR" 4
2592 .IX Item "-Wpacked"
2593 Warn if a structure is given the packed attribute, but the packed
2594 attribute has no effect on the layout or size of the structure.
2595 Such structures may be mis-aligned for little benefit.  For
2596 instance, in this code, the variable \f(CW\*(C`f.x\*(C'\fR in \f(CW\*(C`struct bar\*(C'\fR
2597 will be misaligned even though \f(CW\*(C`struct bar\*(C'\fR does not itself
2598 have the packed attribute:
2600 .Vb 8
2601 \&        struct foo {
2602 \&          int x;
2603 \&          char a, b, c, d;
2604 \&        } __attribute__((packed));
2605 \&        struct bar {
2606 \&          char z;
2607 \&          struct foo f;
2608 \&        };
2610 .Ip "\fB\-Wpadded\fR" 4
2611 .IX Item "-Wpadded"
2612 Warn if padding is included in a structure, either to align an element
2613 of the structure or to align the whole structure.  Sometimes when this
2614 happens it is possible to rearrange the fields of the structure to
2615 reduce the padding and so make the structure smaller.
2616 .Ip "\fB\-Wredundant-decls\fR" 4
2617 .IX Item "-Wredundant-decls"
2618 Warn if anything is declared more than once in the same scope, even in
2619 cases where multiple declaration is valid and changes nothing.
2620 .Ip "\fB\-Wnested-externs\fR (C only)" 4
2621 .IX Item "-Wnested-externs (C only)"
2622 Warn if an \f(CW\*(C`extern\*(C'\fR declaration is encountered within a function.
2623 .Ip "\fB\-Wunreachable-code\fR" 4
2624 .IX Item "-Wunreachable-code"
2625 Warn if the compiler detects that code will never be executed.
2627 This option is intended to warn when the compiler detects that at
2628 least a whole line of source code will never be executed, because
2629 some condition is never satisfied or because it is after a
2630 procedure that never returns.
2632 It is possible for this option to produce a warning even though there
2633 are circumstances under which part of the affected line can be executed,
2634 so care should be taken when removing apparently-unreachable code.
2636 For instance, when a function is inlined, a warning may mean that the
2637 line is unreachable in only one inlined copy of the function.
2639 This option is not made part of \fB\-Wall\fR because in a debugging
2640 version of a program there is often substantial code which checks
2641 correct functioning of the program and is, hopefully, unreachable
2642 because the program does work.  Another common use of unreachable
2643 code is to provide behavior which is selectable at compile-time.
2644 .Ip "\fB\-Winline\fR" 4
2645 .IX Item "-Winline"
2646 Warn if a function can not be inlined and it was declared as inline.
2647 Even with this option, the compiler will not warn about failures to
2648 inline functions declared in system headers.
2650 The compiler uses a variety of heuristics to determine whether or not
2651 to inline a function.  For example, the compiler takes into account
2652 the size of the function being inlined and the the amount of inlining
2653 that has already been done in the current function.  Therefore,
2654 seemingly insignificant changes in the source program can cause the
2655 warnings produced by \fB\-Winline\fR to appear or disappear.
2656 .Ip "\fB\-Wno-invalid-offsetof\fR (\*(C+ only)" 4
2657 .IX Item "-Wno-invalid-offsetof ( only)"
2658 Suppress warnings from applying the \fBoffsetof\fR macro to a non-POD
2659 type.  According to the 1998 \s-1ISO\s0 \*(C+ standard, applying \fBoffsetof\fR
2660 to a non-POD type is undefined.  In existing \*(C+ implementations,
2661 however, \fBoffsetof\fR typically gives meaningful results even when
2662 applied to certain kinds of non-POD types. (Such as a simple
2663 \&\fBstruct\fR that fails to be a \s-1POD\s0 type only by virtue of having a
2664 constructor.)  This flag is for users who are aware that they are
2665 writing nonportable code and who have deliberately chosen to ignore the
2666 warning about it.
2668 The restrictions on \fBoffsetof\fR may be relaxed in a future version
2669 of the \*(C+ standard.
2670 .Ip "\fB\-Winvalid-pch\fR" 4
2671 .IX Item "-Winvalid-pch"
2672 Warn if a precompiled header is found in
2673 the search path but can't be used.
2674 .Ip "\fB\-Wlong-long\fR" 4
2675 .IX Item "-Wlong-long"
2676 Warn if \fBlong long\fR type is used.  This is default.  To inhibit
2677 the warning messages, use \fB\-Wno-long-long\fR.  Flags
2678 \&\fB\-Wlong-long\fR and \fB\-Wno-long-long\fR are taken into account
2679 only when \fB\-pedantic\fR flag is used.
2680 .Ip "\fB\-Wdisabled-optimization\fR" 4
2681 .IX Item "-Wdisabled-optimization"
2682 Warn if a requested optimization pass is disabled.  This warning does
2683 not generally indicate that there is anything wrong with your code; it
2684 merely indicates that \s-1GCC\s0's optimizers were unable to handle the code
2685 effectively.  Often, the problem is that your code is too big or too
2686 complex; \s-1GCC\s0 will refuse to optimize programs when the optimization
2687 itself is likely to take inordinate amounts of time.
2688 .Ip "\fB\-Werror\fR" 4
2689 .IX Item "-Werror"
2690 Make all warnings into errors.
2691 .Sh "Options for Debugging Your Program or \s-1GCC\s0"
2692 .IX Subsection "Options for Debugging Your Program or GCC"
2693 \&\s-1GCC\s0 has various special options that are used for debugging
2694 either your program or \s-1GCC:\s0
2695 .Ip "\fB\-g\fR" 4
2696 .IX Item "-g"
2697 Produce debugging information in the operating system's native format
2698 (stabs, \s-1COFF\s0, \s-1XCOFF\s0, or \s-1DWARF\s0).  \s-1GDB\s0 can work with this debugging
2699 information.
2701 On most systems that use stabs format, \fB\-g\fR enables use of extra
2702 debugging information that only \s-1GDB\s0 can use; this extra information
2703 makes debugging work better in \s-1GDB\s0 but will probably make other debuggers
2704 crash or
2705 refuse to read the program.  If you want to control for certain whether
2706 to generate the extra information, use \fB\-gstabs+\fR, \fB\-gstabs\fR,
2707 \&\fB\-gxcoff+\fR, \fB\-gxcoff\fR, or \fB\-gvms\fR (see below).
2709 Unlike most other C compilers, \s-1GCC\s0 allows you to use \fB\-g\fR with
2710 \&\fB\-O\fR.  The shortcuts taken by optimized code may occasionally
2711 produce surprising results: some variables you declared may not exist
2712 at all; flow of control may briefly move where you did not expect it;
2713 some statements may not be executed because they compute constant
2714 results or their values were already at hand; some statements may
2715 execute in different places because they were moved out of loops.
2717 Nevertheless it proves possible to debug optimized output.  This makes
2718 it reasonable to use the optimizer for programs that might have bugs.
2720 The following options are useful when \s-1GCC\s0 is generated with the
2721 capability for more than one debugging format.
2722 .Ip "\fB\-ggdb\fR" 4
2723 .IX Item "-ggdb"
2724 Produce debugging information for use by \s-1GDB\s0.  This means to use the
2725 most expressive format available (\s-1DWARF\s0 2, stabs, or the native format
2726 if neither of those are supported), including \s-1GDB\s0 extensions if at all
2727 possible.
2728 .Ip "\fB\-gstabs\fR" 4
2729 .IX Item "-gstabs"
2730 Produce debugging information in stabs format (if that is supported),
2731 without \s-1GDB\s0 extensions.  This is the format used by \s-1DBX\s0 on most \s-1BSD\s0
2732 systems.  On \s-1MIPS\s0, Alpha and System V Release 4 systems this option
2733 produces stabs debugging output which is not understood by \s-1DBX\s0 or \s-1SDB\s0.
2734 On System V Release 4 systems this option requires the \s-1GNU\s0 assembler.
2735 .Ip "\fB\-feliminate-unused-debug-symbols\fR" 4
2736 .IX Item "-feliminate-unused-debug-symbols"
2737 Produce debugging information in stabs format (if that is supported),
2738 for only symbols that are actually used.
2739 .Ip "\fB\-gstabs+\fR" 4
2740 .IX Item "-gstabs+"
2741 Produce debugging information in stabs format (if that is supported),
2742 using \s-1GNU\s0 extensions understood only by the \s-1GNU\s0 debugger (\s-1GDB\s0).  The
2743 use of these extensions is likely to make other debuggers crash or
2744 refuse to read the program.
2745 .Ip "\fB\-gcoff\fR" 4
2746 .IX Item "-gcoff"
2747 Produce debugging information in \s-1COFF\s0 format (if that is supported).
2748 This is the format used by \s-1SDB\s0 on most System V systems prior to
2749 System V Release 4.
2750 .Ip "\fB\-gxcoff\fR" 4
2751 .IX Item "-gxcoff"
2752 Produce debugging information in \s-1XCOFF\s0 format (if that is supported).
2753 This is the format used by the \s-1DBX\s0 debugger on \s-1IBM\s0 \s-1RS/6000\s0 systems.
2754 .Ip "\fB\-gxcoff+\fR" 4
2755 .IX Item "-gxcoff+"
2756 Produce debugging information in \s-1XCOFF\s0 format (if that is supported),
2757 using \s-1GNU\s0 extensions understood only by the \s-1GNU\s0 debugger (\s-1GDB\s0).  The
2758 use of these extensions is likely to make other debuggers crash or
2759 refuse to read the program, and may cause assemblers other than the \s-1GNU\s0
2760 assembler (\s-1GAS\s0) to fail with an error.
2761 .Ip "\fB\-gdwarf-2\fR" 4
2762 .IX Item "-gdwarf-2"
2763 Produce debugging information in \s-1DWARF\s0 version 2 format (if that is
2764 supported).  This is the format used by \s-1DBX\s0 on \s-1IRIX\s0 6.
2765 .Ip "\fB\-gvms\fR" 4
2766 .IX Item "-gvms"
2767 Produce debugging information in \s-1VMS\s0 debug format (if that is
2768 supported).  This is the format used by \s-1DEBUG\s0 on \s-1VMS\s0 systems.
2769 .Ip "\fB\-g\fR\fIlevel\fR" 4
2770 .IX Item "-glevel"
2771 .PD 0
2772 .Ip "\fB\-ggdb\fR\fIlevel\fR" 4
2773 .IX Item "-ggdblevel"
2774 .Ip "\fB\-gstabs\fR\fIlevel\fR" 4
2775 .IX Item "-gstabslevel"
2776 .Ip "\fB\-gcoff\fR\fIlevel\fR" 4
2777 .IX Item "-gcofflevel"
2778 .Ip "\fB\-gxcoff\fR\fIlevel\fR" 4
2779 .IX Item "-gxcofflevel"
2780 .Ip "\fB\-gvms\fR\fIlevel\fR" 4
2781 .IX Item "-gvmslevel"
2783 Request debugging information and also use \fIlevel\fR to specify how
2784 much information.  The default level is 2.
2786 Level 1 produces minimal information, enough for making backtraces in
2787 parts of the program that you don't plan to debug.  This includes
2788 descriptions of functions and external variables, but no information
2789 about local variables and no line numbers.
2791 Level 3 includes extra information, such as all the macro definitions
2792 present in the program.  Some debuggers support macro expansion when
2793 you use \fB\-g3\fR.
2795 Note that in order to avoid confusion between \s-1DWARF1\s0 debug level 2,
2796 and \s-1DWARF2\s0 \fB\-gdwarf-2\fR does not accept a concatenated debug
2797 level.  Instead use an additional \fB\-g\fR\fIlevel\fR option to
2798 change the debug level for \s-1DWARF2\s0.
2799 .Ip "\fB\-feliminate-dwarf2\-dups\fR" 4
2800 .IX Item "-feliminate-dwarf2-dups"
2801 Compress \s-1DWARF2\s0 debugging information by eliminating duplicated
2802 information about each symbol.  This option only makes sense when
2803 generating \s-1DWARF2\s0 debugging information with \fB\-gdwarf-2\fR.
2804 .Ip "\fB\-p\fR" 4
2805 .IX Item "-p"
2806 Generate extra code to write profile information suitable for the
2807 analysis program \fBprof\fR.  You must use this option when compiling
2808 the source files you want data about, and you must also use it when
2809 linking.
2810 .Ip "\fB\-pg\fR" 4
2811 .IX Item "-pg"
2812 Generate extra code to write profile information suitable for the
2813 analysis program \fBgprof\fR.  You must use this option when compiling
2814 the source files you want data about, and you must also use it when
2815 linking.
2816 .Ip "\fB\-Q\fR" 4
2817 .IX Item "-Q"
2818 Makes the compiler print out each function name as it is compiled, and
2819 print some statistics about each pass when it finishes.
2820 .Ip "\fB\-ftime-report\fR" 4
2821 .IX Item "-ftime-report"
2822 Makes the compiler print some statistics about the time consumed by each
2823 pass when it finishes.
2824 .Ip "\fB\-fmem-report\fR" 4
2825 .IX Item "-fmem-report"
2826 Makes the compiler print some statistics about permanent memory
2827 allocation when it finishes.
2828 .Ip "\fB\-fprofile-arcs\fR" 4
2829 .IX Item "-fprofile-arcs"
2830 Add code so that program flow \fIarcs\fR are instrumented.  During
2831 execution the program records how many times each branch and call is
2832 executed and how many times it is taken or returns.  When the compiled
2833 program exits it saves this data to a file called
2834 \&\fI\fIauxname\fI.gcda\fR for each source file. The data may be used for
2835 profile-directed optimizations (\fB\-fbranch-probabilities\fR), or for
2836 test coverage analysis (\fB\-ftest-coverage\fR). Each object file's
2837 \&\fIauxname\fR is generated from the name of the output file, if
2838 explicitly specified and it is not the final executable, otherwise it is
2839 the basename of the source file. In both cases any suffix is removed
2840 (e.g.  \fIfoo.gcda\fR for input file \fIdir/foo.c\fR, or
2841 \&\fIdir/foo.gcda\fR for output file specified as \fB\-o dir/foo.o\fR).
2842 .RS 4
2843 .Ip "@bullet" 4
2844 .IX Item "@bullet"
2845 Compile the source files with \fB\-fprofile-arcs\fR plus optimization
2846 and code generation options. For test coverage analysis, use the
2847 additional \fB\-ftest-coverage\fR option. You do not need to profile
2848 every source file in a program.
2849 .Ip "@cvmmfu" 4
2850 .IX Item "@cvmmfu"
2851 Link your object files with \fB\-lgcov\fR or \fB\-fprofile-arcs\fR
2852 (the latter implies the former).
2853 .Ip "@dwnngv" 4
2854 .IX Item "@dwnngv"
2855 Run the program on a representative workload to generate the arc profile
2856 information. This may be repeated any number of times. You can run
2857 concurrent instances of your program, and provided that the file system
2858 supports locking, the data files will be correctly updated. Also
2859 \&\f(CW\*(C`fork\*(C'\fR calls are detected and correctly handled (double counting
2860 will not happen).
2861 .Ip "@exoohw" 4
2862 .IX Item "@exoohw"
2863 For profile-directed optimizations, compile the source files again with
2864 the same optimization and code generation options plus
2865 \&\fB\-fbranch-probabilities\fR.
2866 .Ip "@fyppix" 4
2867 .IX Item "@fyppix"
2868 For test coverage analysis, use \fBgcov\fR to produce human readable
2869 information from the \fI.gcno\fR and \fI.gcda\fR files. Refer to the
2870 \&\fBgcov\fR documentation for further information.
2872 .RS 4
2874 With \fB\-fprofile-arcs\fR, for each function of your program \s-1GCC\s0
2875 creates a program flow graph, then finds a spanning tree for the graph.
2876 Only arcs that are not on the spanning tree have to be instrumented: the
2877 compiler adds code to count the number of times that these arcs are
2878 executed.  When an arc is the only exit or only entrance to a block, the
2879 instrumentation code can be added to the block; otherwise, a new basic
2880 block must be created to hold the instrumentation code.
2882 .Ip "\fB\-ftest-coverage\fR" 4
2883 .IX Item "-ftest-coverage"
2884 Produce a notes file that the \fBgcov\fR code-coverage utility can use to
2885 show program coverage. Each source file's note file is called
2886 \&\fI\fIauxname\fI.gcno\fR. Refer to the \fB\-fprofile-arcs\fR option
2887 above for a description of \fIauxname\fR and instructions on how to
2888 generate test coverage data. Coverage data will match the source files
2889 more closely, if you do not optimize.
2890 .Ip "\fB\-d\fR\fIletters\fR" 4
2891 .IX Item "-dletters"
2892 Says to make debugging dumps during compilation at times specified by
2893 \&\fIletters\fR.  This is used for debugging the compiler.  The file names
2894 for most of the dumps are made by appending a pass number and a word to
2895 the \fIdumpname\fR. \fIdumpname\fR is generated from the name of the
2896 output file, if explicitly specified and it is not an executable,
2897 otherwise it is the basename of the source file. In both cases any
2898 suffix is removed (e.g.  \fIfoo.01.rtl\fR or \fIfoo.02.sibling\fR).
2899 Here are the possible letters for use in \fIletters\fR, and their
2900 meanings:
2901 .RS 4
2902 .Ip "\fBA\fR" 4
2903 .IX Item "A"
2904 Annotate the assembler output with miscellaneous debugging information.
2905 .Ip "\fBb\fR" 4
2906 .IX Item "b"
2907 Dump after computing branch probabilities, to \fI\fIfile\fI.12.bp\fR.
2908 .Ip "\fBB\fR" 4
2909 .IX Item "B"
2910 Dump after block reordering, to \fI\fIfile\fI.31.bbro\fR.
2911 .Ip "\fBc\fR" 4
2912 .IX Item "c"
2913 Dump after instruction combination, to the file \fI\fIfile\fI.20.combine\fR.
2914 .Ip "\fBC\fR" 4
2915 .IX Item "C"
2916 Dump after the first if conversion, to the file \fI\fIfile\fI.14.ce1\fR.
2917 Also dump after the second if conversion, to the file \fI\fIfile\fI.21.ce2\fR.
2918 .Ip "\fBd\fR" 4
2919 .IX Item "d"
2920 Dump after branch target load optimization, to to \fI\fIfile\fI.32.btl\fR.
2921 Also dump after delayed branch scheduling, to \fI\fIfile\fI.36.dbr\fR.
2922 .Ip "\fBD\fR" 4
2923 .IX Item "D"
2924 Dump all macro definitions, at the end of preprocessing, in addition to
2925 normal output.
2926 .Ip "\fBE\fR" 4
2927 .IX Item "E"
2928 Dump after the third if conversion, to \fI\fIfile\fI.30.ce3\fR.
2929 .Ip "\fBf\fR" 4
2930 .IX Item "f"
2931 Dump after control and data flow analysis, to \fI\fIfile\fI.11.cfg\fR.
2932 Also dump after life analysis, to \fI\fIfile\fI.19.life\fR.
2933 .Ip "\fBF\fR" 4
2934 .IX Item "F"
2935 Dump after purging \f(CW\*(C`ADDRESSOF\*(C'\fR codes, to \fI\fIfile\fI.07.addressof\fR.
2936 .Ip "\fBg\fR" 4
2937 .IX Item "g"
2938 Dump after global register allocation, to \fI\fIfile\fI.25.greg\fR.
2939 .Ip "\fBG\fR" 4
2940 .IX Item "G"
2941 Dump after \s-1GCSE\s0, to \fI\fIfile\fI.08.gcse\fR.
2942 Also dump after jump bypassing and control flow optimizations, to
2943 \&\fI\fIfile\fI.10.bypass\fR.
2944 .Ip "\fBh\fR" 4
2945 .IX Item "h"
2946 Dump after finalization of \s-1EH\s0 handling code, to \fI\fIfile\fI.03.eh\fR.
2947 .Ip "\fBi\fR" 4
2948 .IX Item "i"
2949 Dump after sibling call optimizations, to \fI\fIfile\fI.02.sibling\fR.
2950 .Ip "\fBj\fR" 4
2951 .IX Item "j"
2952 Dump after the first jump optimization, to \fI\fIfile\fI.04.jump\fR.
2953 .Ip "\fBk\fR" 4
2954 .IX Item "k"
2955 Dump after conversion from registers to stack, to \fI\fIfile\fI.34.stack\fR.
2956 .Ip "\fBl\fR" 4
2957 .IX Item "l"
2958 Dump after local register allocation, to \fI\fIfile\fI.24.lreg\fR.
2959 .Ip "\fBL\fR" 4
2960 .IX Item "L"
2961 Dump after loop optimization passes, to \fI\fIfile\fI.09.loop\fR and
2962 \&\fI\fIfile\fI.16.loop2\fR.
2963 .Ip "\fBM\fR" 4
2964 .IX Item "M"
2965 Dump after performing the machine dependent reorganization pass, to
2966 \&\fI\fIfile\fI.35.mach\fR.
2967 .Ip "\fBn\fR" 4
2968 .IX Item "n"
2969 Dump after register renumbering, to \fI\fIfile\fI.29.rnreg\fR.
2970 .Ip "\fBN\fR" 4
2971 .IX Item "N"
2972 Dump after the register move pass, to \fI\fIfile\fI.22.regmove\fR.
2973 .Ip "\fBo\fR" 4
2974 .IX Item "o"
2975 Dump after post-reload optimizations, to \fI\fIfile\fI.26.postreload\fR.
2976 .Ip "\fBr\fR" 4
2977 .IX Item "r"
2978 Dump after \s-1RTL\s0 generation, to \fI\fIfile\fI.01.rtl\fR.
2979 .Ip "\fBR\fR" 4
2980 .IX Item "R"
2981 Dump after the second scheduling pass, to \fI\fIfile\fI.33.sched2\fR.
2982 .Ip "\fBs\fR" 4
2983 .IX Item "s"
2984 Dump after \s-1CSE\s0 (including the jump optimization that sometimes follows
2985 \&\s-1CSE\s0), to \fI\fIfile\fI.06.cse\fR.
2986 .Ip "\fBS\fR" 4
2987 .IX Item "S"
2988 Dump after the first scheduling pass, to \fI\fIfile\fI.23.sched\fR.
2989 .Ip "\fBt\fR" 4
2990 .IX Item "t"
2991 Dump after the second \s-1CSE\s0 pass (including the jump optimization that
2992 sometimes follows \s-1CSE\s0), to \fI\fIfile\fI.18.cse2\fR.
2993 .Ip "\fBT\fR" 4
2994 .IX Item "T"
2995 Dump after running tracer, to \fI\fIfile\fI.15.tracer\fR.
2996 .Ip "\fBu\fR" 4
2997 .IX Item "u"
2998 Dump after null pointer elimination pass to \fI\fIfile\fI.05.null\fR.
2999 .Ip "\fBU\fR" 4
3000 .IX Item "U"
3001 Dump callgraph and unit-at-a-time optimization \fI\fIfile\fI.00.unit\fR.
3002 .Ip "\fBV\fR" 4
3003 .IX Item "V"
3004 Dump after the value profile transformations, to \fI\fIfile\fI.13.vpt\fR.
3005 .Ip "\fBw\fR" 4
3006 .IX Item "w"
3007 Dump after the second flow pass, to \fI\fIfile\fI.27.flow2\fR.
3008 .Ip "\fBz\fR" 4
3009 .IX Item "z"
3010 Dump after the peephole pass, to \fI\fIfile\fI.28.peephole2\fR.
3011 .Ip "\fBZ\fR" 4
3012 .IX Item "Z"
3013 Dump after constructing the web, to \fI\fIfile\fI.17.web\fR.
3014 .Ip "\fBa\fR" 4
3015 .IX Item "a"
3016 Produce all the dumps listed above.
3017 .Ip "\fBH\fR" 4
3018 .IX Item "H"
3019 Produce a core dump whenever an error occurs.
3020 .Ip "\fBm\fR" 4
3021 .IX Item "m"
3022 Print statistics on memory usage, at the end of the run, to
3023 standard error.
3024 .Ip "\fBp\fR" 4
3025 .IX Item "p"
3026 Annotate the assembler output with a comment indicating which
3027 pattern and alternative was used.  The length of each instruction is
3028 also printed.
3029 .Ip "\fBP\fR" 4
3030 .IX Item "P"
3031 Dump the \s-1RTL\s0 in the assembler output as a comment before each instruction.
3032 Also turns on \fB\-dp\fR annotation.
3033 .Ip "\fBv\fR" 4
3034 .IX Item "v"
3035 For each of the other indicated dump files (except for
3036 \&\fI\fIfile\fI.01.rtl\fR), dump a representation of the control flow graph
3037 suitable for viewing with \s-1VCG\s0 to \fI\fIfile\fI.\fIpass\fI.vcg\fR.
3038 .Ip "\fBx\fR" 4
3039 .IX Item "x"
3040 Just generate \s-1RTL\s0 for a function instead of compiling it.  Usually used
3041 with \fBr\fR.
3042 .Ip "\fBy\fR" 4
3043 .IX Item "y"
3044 Dump debugging information during parsing, to standard error.
3046 .RS 4
3048 .Ip "\fB\-fdump-unnumbered\fR" 4
3049 .IX Item "-fdump-unnumbered"
3050 When doing debugging dumps (see \fB\-d\fR option above), suppress instruction
3051 numbers and line number note output.  This makes it more feasible to
3052 use diff on debugging dumps for compiler invocations with different
3053 options, in particular with and without \fB\-g\fR.
3054 .Ip "\fB\-fdump-translation-unit\fR (C and \*(C+ only)" 4
3055 .IX Item "-fdump-translation-unit (C and  only)"
3056 .PD 0
3057 .Ip "\fB\-fdump-translation-unit-\fR\fIoptions\fR\fB \fR(C and \*(C+ only)" 4
3058 .IX Item "-fdump-translation-unit-options (C and  only)"
3060 Dump a representation of the tree structure for the entire translation
3061 unit to a file.  The file name is made by appending \fI.tu\fR to the
3062 source file name.  If the \fB-\fR\fIoptions\fR form is used, \fIoptions\fR
3063 controls the details of the dump as described for the
3064 \&\fB\-fdump-tree\fR options.
3065 .Ip "\fB\-fdump-class-hierarchy\fR (\*(C+ only)" 4
3066 .IX Item "-fdump-class-hierarchy ( only)"
3067 .PD 0
3068 .Ip "\fB\-fdump-class-hierarchy-\fR\fIoptions\fR\fB \fR(\*(C+ only)" 4
3069 .IX Item "-fdump-class-hierarchy-options ( only)"
3071 Dump a representation of each class's hierarchy and virtual function
3072 table layout to a file.  The file name is made by appending \fI.class\fR
3073 to the source file name.  If the \fB-\fR\fIoptions\fR form is used,
3074 \&\fIoptions\fR controls the details of the dump as described for the
3075 \&\fB\-fdump-tree\fR options.
3076 .Ip "\fB\-fdump-tree-\fR\fIswitch\fR\fB \fR(\*(C+ only)" 4
3077 .IX Item "-fdump-tree-switch ( only)"
3078 .PD 0
3079 .Ip "\fB\-fdump-tree-\fR\fIswitch\fR\fB-\fR\fIoptions\fR\fB \fR(\*(C+ only)" 4
3080 .IX Item "-fdump-tree-switch-options ( only)"
3082 Control the dumping at various stages of processing the intermediate
3083 language tree to a file.  The file name is generated by appending a switch
3084 specific suffix to the source file name.  If the \fB-\fR\fIoptions\fR
3085 form is used, \fIoptions\fR is a list of \fB-\fR separated options that
3086 control the details of the dump. Not all options are applicable to all
3087 dumps, those which are not meaningful will be ignored. The following
3088 options are available
3089 .RS 4
3090 .Ip "\fBaddress\fR" 4
3091 .IX Item "address"
3092 Print the address of each node.  Usually this is not meaningful as it
3093 changes according to the environment and source file. Its primary use
3094 is for tying up a dump file with a debug environment.
3095 .Ip "\fBslim\fR" 4
3096 .IX Item "slim"
3097 Inhibit dumping of members of a scope or body of a function merely
3098 because that scope has been reached. Only dump such items when they
3099 are directly reachable by some other path.
3100 .Ip "\fBall\fR" 4
3101 .IX Item "all"
3102 Turn on all options.
3104 .RS 4
3106 The following tree dumps are possible:
3107 .RS 4
3109 .Ip "\fBoriginal\fR" 4
3110 .IX Item "original"
3111 Dump before any tree based optimization, to \fI\fIfile\fI.original\fR.
3112 .Ip "\fBoptimized\fR" 4
3113 .IX Item "optimized"
3114 Dump after all tree based optimization, to \fI\fIfile\fI.optimized\fR.
3115 .Ip "\fBinlined\fR" 4
3116 .IX Item "inlined"
3117 Dump after function inlining, to \fI\fIfile\fI.inlined\fR.
3119 .RS 4
3121 .Ip "\fB\-frandom-seed=\fR\fIstring\fR" 4
3122 .IX Item "-frandom-seed=string"
3123 This option provides a seed that \s-1GCC\s0 uses when it would otherwise use
3124 random numbers.  It is used to generate certain symbol names
3125 that have to be different in every compiled file. It is also used to
3126 place unique stamps in coverage data files and the object files that
3127 produce them. You can use the \fB\-frandom-seed\fR option to produce
3128 reproducibly identical object files.
3130 The \fIstring\fR should be different for every file you compile.
3131 .Ip "\fB\-fsched-verbose=\fR\fIn\fR" 4
3132 .IX Item "-fsched-verbose=n"
3133 On targets that use instruction scheduling, this option controls the
3134 amount of debugging output the scheduler prints.  This information is
3135 written to standard error, unless \fB\-dS\fR or \fB\-dR\fR is
3136 specified, in which case it is output to the usual dump
3137 listing file, \fI.sched\fR or \fI.sched2\fR respectively.  However
3138 for \fIn\fR greater than nine, the output is always printed to standard
3139 error.
3141 For \fIn\fR greater than zero, \fB\-fsched-verbose\fR outputs the
3142 same information as \fB\-dRS\fR.  For \fIn\fR greater than one, it
3143 also output basic block probabilities, detailed ready list information
3144 and unit/insn info.  For \fIn\fR greater than two, it includes \s-1RTL\s0
3145 at abort point, control-flow and regions info.  And for \fIn\fR over
3146 four, \fB\-fsched-verbose\fR also includes dependence info.
3147 .Ip "\fB\-save-temps\fR" 4
3148 .IX Item "-save-temps"
3149 Store the usual ``temporary'' intermediate files permanently; place them
3150 in the current directory and name them based on the source file.  Thus,
3151 compiling \fIfoo.c\fR with \fB\-c \-save-temps\fR would produce files
3152 \&\fIfoo.i\fR and \fIfoo.s\fR, as well as \fIfoo.o\fR.  This creates a
3153 preprocessed \fIfoo.i\fR output file even though the compiler now
3154 normally uses an integrated preprocessor.
3155 .Ip "\fB\-time\fR" 4
3156 .IX Item "-time"
3157 Report the \s-1CPU\s0 time taken by each subprocess in the compilation
3158 sequence.  For C source files, this is the compiler proper and assembler
3159 (plus the linker if linking is done).  The output looks like this:
3161 .Vb 2
3162 \&        # cc1 0.12 0.01
3163 \&        # as 0.00 0.01
3165 The first number on each line is the ``user time,'' that is time spent
3166 executing the program itself.  The second number is ``system time,''
3167 time spent executing operating system routines on behalf of the program.
3168 Both numbers are in seconds.
3169 .Ip "\fB\-print-file-name=\fR\fIlibrary\fR" 4
3170 .IX Item "-print-file-name=library"
3171 Print the full absolute name of the library file \fIlibrary\fR that
3172 would be used when linking\-\-\-and don't do anything else.  With this
3173 option, \s-1GCC\s0 does not compile or link anything; it just prints the
3174 file name.
3175 .Ip "\fB\-print-multi-directory\fR" 4
3176 .IX Item "-print-multi-directory"
3177 Print the directory name corresponding to the multilib selected by any
3178 other switches present in the command line.  This directory is supposed
3179 to exist in \fB\s-1GCC_EXEC_PREFIX\s0\fR.
3180 .Ip "\fB\-print-multi-lib\fR" 4
3181 .IX Item "-print-multi-lib"
3182 Print the mapping from multilib directory names to compiler switches
3183 that enable them.  The directory name is separated from the switches by
3184 \&\fB;\fR, and each switch starts with an \fB@} instead of the
3185 \&\f(CB@samp\fB{-\fR, without spaces between multiple switches.  This is supposed to
3186 ease shell-processing.
3187 .Ip "\fB\-print-prog-name=\fR\fIprogram\fR" 4
3188 .IX Item "-print-prog-name=program"
3189 Like \fB\-print-file-name\fR, but searches for a program such as \fBcpp\fR.
3190 .Ip "\fB\-print-libgcc-file-name\fR" 4
3191 .IX Item "-print-libgcc-file-name"
3192 Same as \fB\-print-file-name=libgcc.a\fR.
3194 This is useful when you use \fB\-nostdlib\fR or \fB\-nodefaultlibs\fR
3195 but you do want to link with \fIlibgcc.a\fR.  You can do
3197 .Vb 1
3198 \&        gcc -nostdlib <files>... `gcc -print-libgcc-file-name`
3200 .Ip "\fB\-print-search-dirs\fR" 4
3201 .IX Item "-print-search-dirs"
3202 Print the name of the configured installation directory and a list of
3203 program and library directories \fBgcc\fR will search\-\-\-and don't do anything else.
3205 This is useful when \fBgcc\fR prints the error message
3206 \&\fBinstallation problem, cannot exec cpp0: No such file or directory\fR.
3207 To resolve this you either need to put \fIcpp0\fR and the other compiler
3208 components where \fBgcc\fR expects to find them, or you can set the environment
3209 variable \fB\s-1GCC_EXEC_PREFIX\s0\fR to the directory where you installed them.
3210 Don't forget the trailing '/'.
3211 .Ip "\fB\-dumpmachine\fR" 4
3212 .IX Item "-dumpmachine"
3213 Print the compiler's target machine (for example,
3214 \&\fBi686\-pc-linux-gnu\fR)\-\-\-and don't do anything else.
3215 .Ip "\fB\-dumpversion\fR" 4
3216 .IX Item "-dumpversion"
3217 Print the compiler version (for example, \fB3.0\fR)\-\-\-and don't do
3218 anything else.
3219 .Ip "\fB\-dumpspecs\fR" 4
3220 .IX Item "-dumpspecs"
3221 Print the compiler's built-in specs\-\-\-and don't do anything else.  (This
3222 is used when \s-1GCC\s0 itself is being built.)  
3223 .Ip "\fB\-feliminate-unused-debug-types\fR" 4
3224 .IX Item "-feliminate-unused-debug-types"
3225 Normally, when producing \s-1DWARF2\s0 output, \s-1GCC\s0 will emit debugging
3226 information for all types declared in a compilation
3227 unit, regardless of whether or not they are actually used
3228 in that compilation unit.  Sometimes this is useful, such as
3229 if, in the debugger, you want to cast a value to a type that is
3230 not actually used in your program (but is declared).  More often,
3231 however, this results in a significant amount of wasted space.
3232 With this option, \s-1GCC\s0 will avoid producing debug symbol output
3233 for types that are nowhere used in the source file being compiled.
3234 .Sh "Options That Control Optimization"
3235 .IX Subsection "Options That Control Optimization"
3236 These options control various sorts of optimizations.
3238 Without any optimization option, the compiler's goal is to reduce the
3239 cost of compilation and to make debugging produce the expected
3240 results.  Statements are independent: if you stop the program with a
3241 breakpoint between statements, you can then assign a new value to any
3242 variable or change the program counter to any other statement in the
3243 function and get exactly the results you would expect from the source
3244 code.
3246 Turning on optimization flags makes the compiler attempt to improve
3247 the performance and/or code size at the expense of compilation time
3248 and possibly the ability to debug the program.
3250 The compiler performs optimization based on the knowledge it has of
3251 the program.  Using the \fB\-funit-at-a-time\fR flag will allow the
3252 compiler to consider information gained from later functions in the
3253 file when compiling a function.  Compiling multiple files at once to a
3254 single output file (and using \fB\-funit-at-a-time\fR) will allow
3255 the compiler to use information gained from all of the files when
3256 compiling each of them.
3258 Not all optimizations are controlled directly by a flag.  Only
3259 optimizations that have a flag are listed.
3260 .Ip "\fB\-O\fR" 4
3261 .IX Item "-O"
3262 .PD 0
3263 .Ip "\fB\-O1\fR" 4
3264 .IX Item "-O1"
3266 Optimize.  Optimizing compilation takes somewhat more time, and a lot
3267 more memory for a large function.
3269 With \fB\-O\fR, the compiler tries to reduce code size and execution
3270 time, without performing any optimizations that take a great deal of
3271 compilation time.
3273 \&\fB\-O\fR turns on the following optimization flags:
3274 \&\fB\-fdefer-pop 
3275 \&\-fmerge-constants 
3276 \&\-fthread-jumps 
3277 \&\-floop-optimize 
3278 \&\-fif-conversion 
3279 \&\-fif-conversion2 
3280 \&\-fdelayed-branch 
3281 \&\-fguess-branch-probability 
3282 \&\-fcprop-registers\fR
3284 \&\fB\-O\fR also turns on \fB\-fomit-frame-pointer\fR on machines
3285 where doing so does not interfere with debugging.
3286 .Ip "\fB\-O2\fR" 4
3287 .IX Item "-O2"
3288 Optimize even more.  \s-1GCC\s0 performs nearly all supported optimizations
3289 that do not involve a space-speed tradeoff.  The compiler does not
3290 perform loop unrolling or function inlining when you specify \fB\-O2\fR.
3291 As compared to \fB\-O\fR, this option increases both compilation time
3292 and the performance of the generated code.
3294 \&\fB\-O2\fR turns on all optimization flags specified by \fB\-O\fR.  It
3295 also turns on the following optimization flags:
3296 \&\fB\-fforce-mem 
3297 \&\-foptimize-sibling-calls 
3298 \&\-fstrength-reduce 
3299 \&\-fcse-follow-jumps  \-fcse-skip-blocks 
3300 \&\-frerun-cse-after-loop  \-frerun-loop-opt 
3301 \&\-fgcse  \-fgcse-lm  \-fgcse-sm  \-fgcse-las 
3302 \&\-fdelete-null-pointer-checks 
3303 \&\-fexpensive-optimizations 
3304 \&\-fregmove 
3305 \&\-fschedule-insns  \-fschedule-insns2 
3306 \&\-fsched-interblock  \-fsched-spec 
3307 \&\-fcaller-saves 
3308 \&\-fpeephole2 
3309 \&\-freorder-blocks  \-freorder-functions 
3310 \&\-fstrict-aliasing 
3311 \&\-funit-at-a-time 
3312 \&\-falign-functions  \-falign-jumps 
3313 \&\-falign-loops  \-falign-labels 
3314 \&\-fcrossjumping\fR
3316 Please note the warning under \fB\-fgcse\fR about
3317 invoking \fB\-O2\fR on programs that use computed gotos.
3318 .Ip "\fB\-O3\fR" 4
3319 .IX Item "-O3"
3320 Optimize yet more.  \fB\-O3\fR turns on all optimizations specified by
3321 \&\fB\-O2\fR and also turns on the \fB\-finline-functions\fR,
3322 \&\fB\-fweb\fR and \fB\-frename-registers\fR options.
3323 .Ip "\fB\-O0\fR" 4
3324 .IX Item "-O0"
3325 Do not optimize.  This is the default.
3326 .Ip "\fB\-Os\fR" 4
3327 .IX Item "-Os"
3328 Optimize for size.  \fB\-Os\fR enables all \fB\-O2\fR optimizations that
3329 do not typically increase code size.  It also performs further
3330 optimizations designed to reduce code size.
3332 \&\fB\-Os\fR disables the following optimization flags:
3333 \&\fB\-falign-functions  \-falign-jumps  \-falign-loops 
3334 \&\-falign-labels  \-freorder-blocks  \-fprefetch-loop-arrays\fR
3336 If you use multiple \fB\-O\fR options, with or without level numbers,
3337 the last such option is the one that is effective.
3339 Options of the form \fB\-f\fR\fIflag\fR specify machine-independent
3340 flags.  Most flags have both positive and negative forms; the negative
3341 form of \fB\-ffoo\fR would be \fB\-fno-foo\fR.  In the table
3342 below, only one of the forms is listed\-\-\-the one you typically will
3343 use.  You can figure out the other form by either removing \fBno-\fR
3344 or adding it.
3346 The following options control specific optimizations.  They are either
3347 activated by \fB\-O\fR options or are related to ones that are.  You
3348 can use the following flags in the rare cases when ``fine-tuning'' of
3349 optimizations to be performed is desired.
3350 .Ip "\fB\-fno-default-inline\fR" 4
3351 .IX Item "-fno-default-inline"
3352 Do not make member functions inline by default merely because they are
3353 defined inside the class scope (\*(C+ only).  Otherwise, when you specify
3354 \&\fB\-O\fR, member functions defined inside class scope are compiled
3355 inline by default; i.e., you don't need to add \fBinline\fR in front of
3356 the member function name.
3357 .Ip "\fB\-fno-defer-pop\fR" 4
3358 .IX Item "-fno-defer-pop"
3359 Always pop the arguments to each function call as soon as that function
3360 returns.  For machines which must pop arguments after a function call,
3361 the compiler normally lets arguments accumulate on the stack for several
3362 function calls and pops them all at once.
3364 Disabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3365 .Ip "\fB\-fforce-mem\fR" 4
3366 .IX Item "-fforce-mem"
3367 Force memory operands to be copied into registers before doing
3368 arithmetic on them.  This produces better code by making all memory
3369 references potential common subexpressions.  When they are not common
3370 subexpressions, instruction combination should eliminate the separate
3371 register-load.
3373 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3374 .Ip "\fB\-fforce-addr\fR" 4
3375 .IX Item "-fforce-addr"
3376 Force memory address constants to be copied into registers before
3377 doing arithmetic on them.  This may produce better code just as
3378 \&\fB\-fforce-mem\fR may.
3379 .Ip "\fB\-fomit-frame-pointer\fR" 4
3380 .IX Item "-fomit-frame-pointer"
3381 Don't keep the frame pointer in a register for functions that
3382 don't need one.  This avoids the instructions to save, set up and
3383 restore frame pointers; it also makes an extra register available
3384 in many functions.  \fBIt also makes debugging impossible on
3385 some machines.\fR
3387 On some machines, such as the \s-1VAX\s0, this flag has no effect, because
3388 the standard calling sequence automatically handles the frame pointer
3389 and nothing is saved by pretending it doesn't exist.  The
3390 machine-description macro \f(CW\*(C`FRAME_POINTER_REQUIRED\*(C'\fR controls
3391 whether a target machine supports this flag.  
3393 Enabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3394 .Ip "\fB\-foptimize-sibling-calls\fR" 4
3395 .IX Item "-foptimize-sibling-calls"
3396 Optimize sibling and tail recursive calls.
3398 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3399 .Ip "\fB\-fno-inline\fR" 4
3400 .IX Item "-fno-inline"
3401 Don't pay attention to the \f(CW\*(C`inline\*(C'\fR keyword.  Normally this option
3402 is used to keep the compiler from expanding any functions inline.
3403 Note that if you are not optimizing, no functions can be expanded inline.
3404 .Ip "\fB\-finline-functions\fR" 4
3405 .IX Item "-finline-functions"
3406 Integrate all simple functions into their callers.  The compiler
3407 heuristically decides which functions are simple enough to be worth
3408 integrating in this way.
3410 If all calls to a given function are integrated, and the function is
3411 declared \f(CW\*(C`static\*(C'\fR, then the function is normally not output as
3412 assembler code in its own right.
3414 Enabled at level \fB\-O3\fR.
3415 .Ip "\fB\-finline-limit=\fR\fIn\fR" 4
3416 .IX Item "-finline-limit=n"
3417 By default, \s-1GCC\s0 limits the size of functions that can be inlined.  This flag
3418 allows the control of this limit for functions that are explicitly marked as
3419 inline (i.e., marked with the inline keyword or defined within the class
3420 definition in c++).  \fIn\fR is the size of functions that can be inlined in
3421 number of pseudo instructions (not counting parameter handling).  The default
3422 value of \fIn\fR is 600.
3423 Increasing this value can result in more inlined code at
3424 the cost of compilation time and memory consumption.  Decreasing usually makes
3425 the compilation faster and less code will be inlined (which presumably
3426 means slower programs).  This option is particularly useful for programs that
3427 use inlining heavily such as those based on recursive templates with \*(C+.
3429 Inlining is actually controlled by a number of parameters, which may be
3430 specified individually by using \fB\*(--param\fR \fIname\fR\fB=\fR\fIvalue\fR.
3431 The \fB\-finline-limit=\fR\fIn\fR option sets some of these parameters
3432 as follows:
3433 .RS 4
3435 .Vb 8
3436 \& @item max-inline-insns-single
3437 \&  is set to I<n>/2.
3438 \& @item max-inline-insns-auto
3439 \&  is set to I<n>/2.
3440 \& @item min-inline-insns
3441 \&  is set to 130 or I<n>/4, whichever is smaller.
3442 \& @item max-inline-insns-rtl
3443 \&  is set to I<n>.
3446 .RS 4
3448 See below for a documentation of the individual
3449 parameters controlling inlining.
3451 \&\fINote:\fR pseudo instruction represents, in this particular context, an
3452 abstract measurement of function's size.  In no way, it represents a count
3453 of assembly instructions and as such its exact meaning might change from one
3454 release to an another.
3456 .Ip "\fB\-fkeep-inline-functions\fR" 4
3457 .IX Item "-fkeep-inline-functions"
3458 Even if all calls to a given function are integrated, and the function
3459 is declared \f(CW\*(C`static\*(C'\fR, nevertheless output a separate run-time
3460 callable version of the function.  This switch does not affect
3461 \&\f(CW\*(C`extern inline\*(C'\fR functions.
3462 .Ip "\fB\-fkeep-static-consts\fR" 4
3463 .IX Item "-fkeep-static-consts"
3464 Emit variables declared \f(CW\*(C`static const\*(C'\fR when optimization isn't turned
3465 on, even if the variables aren't referenced.
3467 \&\s-1GCC\s0 enables this option by default.  If you want to force the compiler to
3468 check if the variable was referenced, regardless of whether or not
3469 optimization is turned on, use the \fB\-fno-keep-static-consts\fR option.
3470 .Ip "\fB\-fmerge-constants\fR" 4
3471 .IX Item "-fmerge-constants"
3472 Attempt to merge identical constants (string constants and floating point
3473 constants) across compilation units.
3475 This option is the default for optimized compilation if the assembler and
3476 linker support it.  Use \fB\-fno-merge-constants\fR to inhibit this
3477 behavior.
3479 Enabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3480 .Ip "\fB\-fmerge-all-constants\fR" 4
3481 .IX Item "-fmerge-all-constants"
3482 Attempt to merge identical constants and identical variables.
3484 This option implies \fB\-fmerge-constants\fR.  In addition to
3485 \&\fB\-fmerge-constants\fR this considers e.g. even constant initialized
3486 arrays or initialized constant variables with integral or floating point
3487 types.  Languages like C or \*(C+ require each non-automatic variable to
3488 have distinct location, so using this option will result in non-conforming
3489 behavior.
3490 .Ip "\fB\-fnew-ra\fR" 4
3491 .IX Item "-fnew-ra"
3492 Use a graph coloring register allocator.  Currently this option is meant
3493 only for testing.  Users should not specify this option, since it is not
3494 yet ready for production use.
3495 .Ip "\fB\-fno-branch-count-reg\fR" 4
3496 .IX Item "-fno-branch-count-reg"
3497 Do not use ``decrement and branch'' instructions on a count register,
3498 but instead generate a sequence of instructions that decrement a
3499 register, compare it against zero, then branch based upon the result.
3500 This option is only meaningful on architectures that support such
3501 instructions, which include x86, PowerPC, \s-1IA-64\s0 and S/390.
3503 The default is \fB\-fbranch-count-reg\fR, enabled when
3504 \&\fB\-fstrength-reduce\fR is enabled.
3505 .Ip "\fB\-fno-function-cse\fR" 4
3506 .IX Item "-fno-function-cse"
3507 Do not put function addresses in registers; make each instruction that
3508 calls a constant function contain the function's address explicitly.
3510 This option results in less efficient code, but some strange hacks
3511 that alter the assembler output may be confused by the optimizations
3512 performed when this option is not used.
3514 The default is \fB\-ffunction-cse\fR
3515 .Ip "\fB\-fno-zero-initialized-in-bss\fR" 4
3516 .IX Item "-fno-zero-initialized-in-bss"
3517 If the target supports a \s-1BSS\s0 section, \s-1GCC\s0 by default puts variables that
3518 are initialized to zero into \s-1BSS\s0.  This can save space in the resulting
3519 code.
3521 This option turns off this behavior because some programs explicitly
3522 rely on variables going to the data section.  E.g., so that the
3523 resulting executable can find the beginning of that section and/or make
3524 assumptions based on that.
3526 The default is \fB\-fzero-initialized-in-bss\fR.
3527 .Ip "\fB\-fstrength-reduce\fR" 4
3528 .IX Item "-fstrength-reduce"
3529 Perform the optimizations of loop strength reduction and
3530 elimination of iteration variables.
3532 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3533 .Ip "\fB\-fthread-jumps\fR" 4
3534 .IX Item "-fthread-jumps"
3535 Perform optimizations where we check to see if a jump branches to a
3536 location where another comparison subsumed by the first is found.  If
3537 so, the first branch is redirected to either the destination of the
3538 second branch or a point immediately following it, depending on whether
3539 the condition is known to be true or false.
3541 Enabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3542 .Ip "\fB\-fcse-follow-jumps\fR" 4
3543 .IX Item "-fcse-follow-jumps"
3544 In common subexpression elimination, scan through jump instructions
3545 when the target of the jump is not reached by any other path.  For
3546 example, when \s-1CSE\s0 encounters an \f(CW\*(C`if\*(C'\fR statement with an
3547 \&\f(CW\*(C`else\*(C'\fR clause, \s-1CSE\s0 will follow the jump when the condition
3548 tested is false.
3550 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3551 .Ip "\fB\-fcse-skip-blocks\fR" 4
3552 .IX Item "-fcse-skip-blocks"
3553 This is similar to \fB\-fcse-follow-jumps\fR, but causes \s-1CSE\s0 to
3554 follow jumps which conditionally skip over blocks.  When \s-1CSE\s0
3555 encounters a simple \f(CW\*(C`if\*(C'\fR statement with no else clause,
3556 \&\fB\-fcse-skip-blocks\fR causes \s-1CSE\s0 to follow the jump around the
3557 body of the \f(CW\*(C`if\*(C'\fR.
3559 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3560 .Ip "\fB\-frerun-cse-after-loop\fR" 4
3561 .IX Item "-frerun-cse-after-loop"
3562 Re-run common subexpression elimination after loop optimizations has been
3563 performed.
3565 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3566 .Ip "\fB\-frerun-loop-opt\fR" 4
3567 .IX Item "-frerun-loop-opt"
3568 Run the loop optimizer twice.
3570 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3571 .Ip "\fB\-fgcse\fR" 4
3572 .IX Item "-fgcse"
3573 Perform a global common subexpression elimination pass.
3574 This pass also performs global constant and copy propagation.
3576 \&\fINote:\fR When compiling a program using computed gotos, a \s-1GCC\s0
3577 extension, you may get better runtime performance if you disable
3578 the global common subexpression elimination pass by adding
3579 \&\fB\-fno-gcse\fR to the command line.
3581 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3582 .Ip "\fB\-fgcse-lm\fR" 4
3583 .IX Item "-fgcse-lm"
3584 When \fB\-fgcse-lm\fR is enabled, global common subexpression elimination will
3585 attempt to move loads which are only killed by stores into themselves.  This
3586 allows a loop containing a load/store sequence to be changed to a load outside
3587 the loop, and a copy/store within the loop.
3589 Enabled by default when gcse is enabled.
3590 .Ip "\fB\-fgcse-sm\fR" 4
3591 .IX Item "-fgcse-sm"
3592 When \fB\-fgcse-sm\fR is enabled, a store motion pass is run after
3593 global common subexpression elimination.  This pass will attempt to move
3594 stores out of loops.  When used in conjunction with \fB\-fgcse-lm\fR,
3595 loops containing a load/store sequence can be changed to a load before
3596 the loop and a store after the loop.
3598 Enabled by default when gcse is enabled.
3599 .Ip "\fB\-fgcse-las\fR" 4
3600 .IX Item "-fgcse-las"
3601 When \fB\-fgcse-las\fR is enabled, the global common subexpression
3602 elimination pass eliminates redundant loads that come after stores to the
3603 same memory location (both partial and full redundancies).
3605 Enabled by default when gcse is enabled.
3606 .Ip "\fB\-floop-optimize\fR" 4
3607 .IX Item "-floop-optimize"
3608 Perform loop optimizations: move constant expressions out of loops, simplify
3609 exit test conditions and optionally do strength-reduction and loop unrolling as
3610 well.
3612 Enabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3613 .Ip "\fB\-fcrossjumping\fR" 4
3614 .IX Item "-fcrossjumping"
3615 Perform cross-jumping transformation. This transformation unifies equivalent code and save code size. The
3616 resulting code may or may not perform better than without cross-jumping.
3618 Enabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3619 .Ip "\fB\-fif-conversion\fR" 4
3620 .IX Item "-fif-conversion"
3621 Attempt to transform conditional jumps into branch-less equivalents.  This
3622 include use of conditional moves, min, max, set flags and abs instructions, and
3623 some tricks doable by standard arithmetics.  The use of conditional execution
3624 on chips where it is available is controlled by \f(CW\*(C`if\-conversion2\*(C'\fR.
3626 Enabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3627 .Ip "\fB\-fif-conversion2\fR" 4
3628 .IX Item "-fif-conversion2"
3629 Use conditional execution (where available) to transform conditional jumps into
3630 branch-less equivalents.
3632 Enabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3633 .Ip "\fB\-fdelete-null-pointer-checks\fR" 4
3634 .IX Item "-fdelete-null-pointer-checks"
3635 Use global dataflow analysis to identify and eliminate useless checks
3636 for null pointers.  The compiler assumes that dereferencing a null
3637 pointer would have halted the program.  If a pointer is checked after
3638 it has already been dereferenced, it cannot be null.
3640 In some environments, this assumption is not true, and programs can
3641 safely dereference null pointers.  Use
3642 \&\fB\-fno-delete-null-pointer-checks\fR to disable this optimization
3643 for programs which depend on that behavior.
3645 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3646 .Ip "\fB\-fexpensive-optimizations\fR" 4
3647 .IX Item "-fexpensive-optimizations"
3648 Perform a number of minor optimizations that are relatively expensive.
3650 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3651 .Ip "\fB\-foptimize-register-move\fR" 4
3652 .IX Item "-foptimize-register-move"
3653 .PD 0
3654 .Ip "\fB\-fregmove\fR" 4
3655 .IX Item "-fregmove"
3657 Attempt to reassign register numbers in move instructions and as
3658 operands of other simple instructions in order to maximize the amount of
3659 register tying.  This is especially helpful on machines with two-operand
3660 instructions.
3662 Note \fB\-fregmove\fR and \fB\-foptimize-register-move\fR are the same
3663 optimization.
3665 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3666 .Ip "\fB\-fdelayed-branch\fR" 4
3667 .IX Item "-fdelayed-branch"
3668 If supported for the target machine, attempt to reorder instructions
3669 to exploit instruction slots available after delayed branch
3670 instructions.
3672 Enabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3673 .Ip "\fB\-fschedule-insns\fR" 4
3674 .IX Item "-fschedule-insns"
3675 If supported for the target machine, attempt to reorder instructions to
3676 eliminate execution stalls due to required data being unavailable.  This
3677 helps machines that have slow floating point or memory load instructions
3678 by allowing other instructions to be issued until the result of the load
3679 or floating point instruction is required.
3681 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3682 .Ip "\fB\-fschedule-insns2\fR" 4
3683 .IX Item "-fschedule-insns2"
3684 Similar to \fB\-fschedule-insns\fR, but requests an additional pass of
3685 instruction scheduling after register allocation has been done.  This is
3686 especially useful on machines with a relatively small number of
3687 registers and where memory load instructions take more than one cycle.
3689 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3690 .Ip "\fB\-fno-sched-interblock\fR" 4
3691 .IX Item "-fno-sched-interblock"
3692 Don't schedule instructions across basic blocks.  This is normally
3693 enabled by default when scheduling before register allocation, i.e.
3694 with \fB\-fschedule-insns\fR or at \fB\-O2\fR or higher.
3695 .Ip "\fB\-fno-sched-spec\fR" 4
3696 .IX Item "-fno-sched-spec"
3697 Don't allow speculative motion of non-load instructions.  This is normally
3698 enabled by default when scheduling before register allocation, i.e.
3699 with \fB\-fschedule-insns\fR or at \fB\-O2\fR or higher.
3700 .Ip "\fB\-fsched-spec-load\fR" 4
3701 .IX Item "-fsched-spec-load"
3702 Allow speculative motion of some load instructions.  This only makes
3703 sense when scheduling before register allocation, i.e. with
3704 \&\fB\-fschedule-insns\fR or at \fB\-O2\fR or higher.
3705 .Ip "\fB\-fsched-spec-load-dangerous\fR" 4
3706 .IX Item "-fsched-spec-load-dangerous"
3707 Allow speculative motion of more load instructions.  This only makes
3708 sense when scheduling before register allocation, i.e. with
3709 \&\fB\-fschedule-insns\fR or at \fB\-O2\fR or higher.
3710 .Ip "\fB\-fsched-stalled-insns=\fR\fIn\fR" 4
3711 .IX Item "-fsched-stalled-insns=n"
3712 Define how many insns (if any) can be moved prematurely from the queue
3713 of stalled insns into the ready list, during the second scheduling pass.
3714 .Ip "\fB\-fsched-stalled-insns-dep=\fR\fIn\fR" 4
3715 .IX Item "-fsched-stalled-insns-dep=n"
3716 Define how many insn groups (cycles) will be examined for a dependency
3717 on a stalled insn that is candidate for premature removal from the queue
3718 of stalled insns.  Has an effect only during the second scheduling pass,
3719 and only if \fB\-fsched-stalled-insns\fR is used and its value is not zero.
3720 .Ip "\fB\-fsched2\-use-superblocks\fR" 4
3721 .IX Item "-fsched2-use-superblocks"
3722 When scheduling after register allocation, do use superblock scheduling
3723 algorithm.  Superblock scheduling allows motion across basic block boundaries
3724 resulting on faster schedules.  This option is experimental, as not all machine
3725 descriptions used by \s-1GCC\s0 model the \s-1CPU\s0 closely enough to avoid unreliable
3726 results from the algorithm.
3728 This only makes sense when scheduling after register allocation, i.e. with
3729 \&\fB\-fschedule-insns2\fR or at \fB\-O2\fR or higher.
3730 .Ip "\fB\-fsched2\-use-traces\fR" 4
3731 .IX Item "-fsched2-use-traces"
3732 Use \fB\-fsched2\-use-superblocks\fR algorithm when scheduling after register
3733 allocation and additionally perform code duplication in order to increase the
3734 size of superblocks using tracer pass.  See \fB\-ftracer\fR for details on
3735 trace formation.
3737 This mode should produce faster but significantly longer programs.  Also
3738 without \f(CW\*(C`\-fbranch\-probabilities\*(C'\fR the traces constructed may not match the
3739 reality and hurt the performance.  This only makes
3740 sense when scheduling after register allocation, i.e. with
3741 \&\fB\-fschedule-insns2\fR or at \fB\-O2\fR or higher.
3742 .Ip "\fB\-fcaller-saves\fR" 4
3743 .IX Item "-fcaller-saves"
3744 Enable values to be allocated in registers that will be clobbered by
3745 function calls, by emitting extra instructions to save and restore the
3746 registers around such calls.  Such allocation is done only when it
3747 seems to result in better code than would otherwise be produced.
3749 This option is always enabled by default on certain machines, usually
3750 those which have no call-preserved registers to use instead.
3752 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3753 .Ip "\fB\-fmove-all-movables\fR" 4
3754 .IX Item "-fmove-all-movables"
3755 Forces all invariant computations in loops to be moved
3756 outside the loop.
3757 .Ip "\fB\-freduce-all-givs\fR" 4
3758 .IX Item "-freduce-all-givs"
3759 Forces all general-induction variables in loops to be
3760 strength-reduced.
3762 \&\fINote:\fR When compiling programs written in Fortran,
3763 \&\fB\-fmove-all-movables\fR and \fB\-freduce-all-givs\fR are enabled
3764 by default when you use the optimizer.
3766 These options may generate better or worse code; results are highly
3767 dependent on the structure of loops within the source code.
3769 These two options are intended to be removed someday, once
3770 they have helped determine the efficacy of various
3771 approaches to improving loop optimizations.
3773 Please contact <\fBgcc@gcc.gnu.org\fR>, and describe how use of
3774 these options affects the performance of your production code.
3775 Examples of code that runs \fIslower\fR when these options are
3776 \&\fIenabled\fR are very valuable.
3777 .Ip "\fB\-fno-peephole\fR" 4
3778 .IX Item "-fno-peephole"
3779 .PD 0
3780 .Ip "\fB\-fno-peephole2\fR" 4
3781 .IX Item "-fno-peephole2"
3783 Disable any machine-specific peephole optimizations.  The difference
3784 between \fB\-fno-peephole\fR and \fB\-fno-peephole2\fR is in how they
3785 are implemented in the compiler; some targets use one, some use the
3786 other, a few use both.
3788 \&\fB\-fpeephole\fR is enabled by default.
3789 \&\fB\-fpeephole2\fR enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3790 .Ip "\fB\-fno-guess-branch-probability\fR" 4
3791 .IX Item "-fno-guess-branch-probability"
3792 Do not guess branch probabilities using a randomized model.
3794 Sometimes \s-1GCC\s0 will opt to use a randomized model to guess branch
3795 probabilities, when none are available from either profiling feedback
3796 (\fB\-fprofile-arcs\fR) or \fB_\|_builtin_expect\fR.  This means that
3797 different runs of the compiler on the same program may produce different
3798 object code.
3800 In a hard real-time system, people don't want different runs of the
3801 compiler to produce code that has different behavior; minimizing
3802 non-determinism is of paramount import.  This switch allows users to
3803 reduce non-determinism, possibly at the expense of inferior
3804 optimization.
3806 The default is \fB\-fguess-branch-probability\fR at levels
3807 \&\fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3808 .Ip "\fB\-freorder-blocks\fR" 4
3809 .IX Item "-freorder-blocks"
3810 Reorder basic blocks in the compiled function in order to reduce number of
3811 taken branches and improve code locality.
3813 Enabled at levels \fB\-O2\fR, \fB\-O3\fR.
3814 .Ip "\fB\-freorder-functions\fR" 4
3815 .IX Item "-freorder-functions"
3816 Reorder basic blocks in the compiled function in order to reduce number of
3817 taken branches and improve code locality. This is implemented by using special
3818 subsections \f(CW\*(C`text.hot\*(C'\fR for most frequently executed functions and
3819 \&\f(CW\*(C`text.unlikely\*(C'\fR for unlikely executed functions.  Reordering is done by
3820 the linker so object file format must support named sections and linker must
3821 place them in a reasonable way.
3823 Also profile feedback must be available in to make this option effective.  See
3824 \&\fB\-fprofile-arcs\fR for details.
3826 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3827 .Ip "\fB\-fstrict-aliasing\fR" 4
3828 .IX Item "-fstrict-aliasing"
3829 Allows the compiler to assume the strictest aliasing rules applicable to
3830 the language being compiled.  For C (and \*(C+), this activates
3831 optimizations based on the type of expressions.  In particular, an
3832 object of one type is assumed never to reside at the same address as an
3833 object of a different type, unless the types are almost the same.  For
3834 example, an \f(CW\*(C`unsigned int\*(C'\fR can alias an \f(CW\*(C`int\*(C'\fR, but not a
3835 \&\f(CW\*(C`void*\*(C'\fR or a \f(CW\*(C`double\*(C'\fR.  A character type may alias any other
3836 type.
3838 Pay special attention to code like this:
3840 .Vb 4
3841 \&        union a_union {
3842 \&          int i;
3843 \&          double d;
3844 \&        };
3846 .Vb 5
3847 \&        int f() {
3848 \&          a_union t;
3849 \&          t.d = 3.0;
3850 \&          return t.i;
3851 \&        }
3853 The practice of reading from a different union member than the one most
3854 recently written to (called ``type-punning'') is common.  Even with
3855 \&\fB\-fstrict-aliasing\fR, type-punning is allowed, provided the memory
3856 is accessed through the union type.  So, the code above will work as
3857 expected.  However, this code might not:
3859 .Vb 7
3860 \&        int f() {
3861 \&          a_union t;
3862 \&          int* ip;
3863 \&          t.d = 3.0;
3864 \&          ip = &t.i;
3865 \&          return *ip;
3866 \&        }
3868 Every language that wishes to perform language-specific alias analysis
3869 should define a function that computes, given an \f(CW\*(C`tree\*(C'\fR
3870 node, an alias set for the node.  Nodes in different alias sets are not
3871 allowed to alias.  For an example, see the C front-end function
3872 \&\f(CW\*(C`c_get_alias_set\*(C'\fR.
3874 Enabled at levels \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3875 .Ip "\fB\-falign-functions\fR" 4
3876 .IX Item "-falign-functions"
3877 .PD 0
3878 .Ip "\fB\-falign-functions=\fR\fIn\fR" 4
3879 .IX Item "-falign-functions=n"
3881 Align the start of functions to the next power-of-two greater than
3882 \&\fIn\fR, skipping up to \fIn\fR bytes.  For instance,
3883 \&\fB\-falign-functions=32\fR aligns functions to the next 32\-byte
3884 boundary, but \fB\-falign-functions=24\fR would align to the next
3885 32\-byte boundary only if this can be done by skipping 23 bytes or less.
3887 \&\fB\-fno-align-functions\fR and \fB\-falign-functions=1\fR are
3888 equivalent and mean that functions will not be aligned.
3890 Some assemblers only support this flag when \fIn\fR is a power of two;
3891 in that case, it is rounded up.
3893 If \fIn\fR is not specified or is zero, use a machine-dependent default.
3895 Enabled at levels \fB\-O2\fR, \fB\-O3\fR.
3896 .Ip "\fB\-falign-labels\fR" 4
3897 .IX Item "-falign-labels"
3898 .PD 0
3899 .Ip "\fB\-falign-labels=\fR\fIn\fR" 4
3900 .IX Item "-falign-labels=n"
3902 Align all branch targets to a power-of-two boundary, skipping up to
3903 \&\fIn\fR bytes like \fB\-falign-functions\fR.  This option can easily
3904 make code slower, because it must insert dummy operations for when the
3905 branch target is reached in the usual flow of the code.
3907 \&\fB\-fno-align-labels\fR and \fB\-falign-labels=1\fR are
3908 equivalent and mean that labels will not be aligned.
3910 If \fB\-falign-loops\fR or \fB\-falign-jumps\fR are applicable and
3911 are greater than this value, then their values are used instead.
3913 If \fIn\fR is not specified or is zero, use a machine-dependent default
3914 which is very likely to be \fB1\fR, meaning no alignment.
3916 Enabled at levels \fB\-O2\fR, \fB\-O3\fR.
3917 .Ip "\fB\-falign-loops\fR" 4
3918 .IX Item "-falign-loops"
3919 .PD 0
3920 .Ip "\fB\-falign-loops=\fR\fIn\fR" 4
3921 .IX Item "-falign-loops=n"
3923 Align loops to a power-of-two boundary, skipping up to \fIn\fR bytes
3924 like \fB\-falign-functions\fR.  The hope is that the loop will be
3925 executed many times, which will make up for any execution of the dummy
3926 operations.
3928 \&\fB\-fno-align-loops\fR and \fB\-falign-loops=1\fR are
3929 equivalent and mean that loops will not be aligned.
3931 If \fIn\fR is not specified or is zero, use a machine-dependent default.
3933 Enabled at levels \fB\-O2\fR, \fB\-O3\fR.
3934 .Ip "\fB\-falign-jumps\fR" 4
3935 .IX Item "-falign-jumps"
3936 .PD 0
3937 .Ip "\fB\-falign-jumps=\fR\fIn\fR" 4
3938 .IX Item "-falign-jumps=n"
3940 Align branch targets to a power-of-two boundary, for branch targets
3941 where the targets can only be reached by jumping, skipping up to \fIn\fR
3942 bytes like \fB\-falign-functions\fR.  In this case, no dummy operations
3943 need be executed.
3945 \&\fB\-fno-align-jumps\fR and \fB\-falign-jumps=1\fR are
3946 equivalent and mean that loops will not be aligned.
3948 If \fIn\fR is not specified or is zero, use a machine-dependent default.
3950 Enabled at levels \fB\-O2\fR, \fB\-O3\fR.
3951 .Ip "\fB\-frename-registers\fR" 4
3952 .IX Item "-frename-registers"
3953 Attempt to avoid false dependencies in scheduled code by making use
3954 of registers left over after register allocation.  This optimization
3955 will most benefit processors with lots of registers.  It can, however,
3956 make debugging impossible, since variables will no longer stay in
3957 a ``home register''.
3958 .Ip "\fB\-fweb\fR" 4
3959 .IX Item "-fweb"
3960 Constructs webs as commonly used for register allocation purposes and assign
3961 each web individual pseudo register.  This allows the register allocation pass
3962 to operate on pseudos directly, but also strengthens several other optimization
3963 passes, such as \s-1CSE\s0, loop optimizer and trivial dead code remover.  It can,
3964 however, make debugging impossible, since variables will no longer stay in a
3965 ``home register''.
3967 Enabled at levels \fB\-O3\fR.
3968 .Ip "\fB\-fno-cprop-registers\fR" 4
3969 .IX Item "-fno-cprop-registers"
3970 After register allocation and post-register allocation instruction splitting,
3971 we perform a copy-propagation pass to try to reduce scheduling dependencies
3972 and occasionally eliminate the copy.
3974 Disabled at levels \fB\-O\fR, \fB\-O2\fR, \fB\-O3\fR, \fB\-Os\fR.
3975 .Ip "\fB\-fprofile-generate\fR" 4
3976 .IX Item "-fprofile-generate"
3977 Enable options usually used for instrumenting application to produce
3978 profile useful for later recompilation with profile feedback based
3979 optimization.  You must use \f(CW\*(C`\-fprofile\-generate\*(C'\fR both when
3980 compiling and when linking your program.
3982 The following options are enabled: \f(CW\*(C`\-fprofile\-arcs\*(C'\fR, \f(CW\*(C`\-fprofile\-values\*(C'\fR, \f(CW\*(C`\-fvpt\*(C'\fR.
3983 .Ip "\fB\-fprofile-use\fR" 4
3984 .IX Item "-fprofile-use"
3985 Enable profile feedback directed optimizations, and optimizations
3986 generally profitable only with profile feedback available.
3988 The following options are enabled: \f(CW\*(C`\-fbranch\-probabilities\*(C'\fR,
3989 \&\f(CW\*(C`\-fvpt\*(C'\fR, \f(CW\*(C`\-funroll\-loops\*(C'\fR, \f(CW\*(C`\-fpeel\-loops\*(C'\fR, \f(CW\*(C`\-ftracer\*(C'\fR.
3991 The following options control compiler behavior regarding floating
3992 point arithmetic.  These options trade off between speed and
3993 correctness.  All must be specifically enabled.
3994 .Ip "\fB\-ffloat-store\fR" 4
3995 .IX Item "-ffloat-store"
3996 Do not store floating point variables in registers, and inhibit other
3997 options that might change whether a floating point value is taken from a
3998 register or memory.
4000 This option prevents undesirable excess precision on machines such as
4001 the 68000 where the floating registers (of the 68881) keep more
4002 precision than a \f(CW\*(C`double\*(C'\fR is supposed to have.  Similarly for the
4003 x86 architecture.  For most programs, the excess precision does only
4004 good, but a few programs rely on the precise definition of \s-1IEEE\s0 floating
4005 point.  Use \fB\-ffloat-store\fR for such programs, after modifying
4006 them to store all pertinent intermediate computations into variables.
4007 .Ip "\fB\-ffast-math\fR" 4
4008 .IX Item "-ffast-math"
4009 Sets \fB\-fno-math-errno\fR, \fB\-funsafe-math-optimizations\fR, \fB\-fno-trapping-math\fR, \fB\-ffinite-math-only\fR,
4010 \&\fB\-fno-rounding-math\fR and \fB\-fno-signaling-nans\fR.
4012 This option causes the preprocessor macro \f(CW\*(C`_\|_FAST_MATH_\|_\*(C'\fR to be defined.
4014 This option should never be turned on by any \fB\-O\fR option since
4015 it can result in incorrect output for programs which depend on
4016 an exact implementation of \s-1IEEE\s0 or \s-1ISO\s0 rules/specifications for
4017 math functions.
4018 .Ip "\fB\-fno-math-errno\fR" 4
4019 .IX Item "-fno-math-errno"
4020 Do not set \s-1ERRNO\s0 after calling math functions that are executed
4021 with a single instruction, e.g., sqrt.  A program that relies on
4022 \&\s-1IEEE\s0 exceptions for math error handling may want to use this flag
4023 for speed while maintaining \s-1IEEE\s0 arithmetic compatibility.
4025 This option should never be turned on by any \fB\-O\fR option since
4026 it can result in incorrect output for programs which depend on
4027 an exact implementation of \s-1IEEE\s0 or \s-1ISO\s0 rules/specifications for
4028 math functions.
4030 The default is \fB\-fmath-errno\fR.
4031 .Ip "\fB\-funsafe-math-optimizations\fR" 4
4032 .IX Item "-funsafe-math-optimizations"
4033 Allow optimizations for floating-point arithmetic that (a) assume
4034 that arguments and results are valid and (b) may violate \s-1IEEE\s0 or
4035 \&\s-1ANSI\s0 standards.  When used at link-time, it may include libraries
4036 or startup files that change the default \s-1FPU\s0 control word or other
4037 similar optimizations.
4039 This option should never be turned on by any \fB\-O\fR option since
4040 it can result in incorrect output for programs which depend on
4041 an exact implementation of \s-1IEEE\s0 or \s-1ISO\s0 rules/specifications for
4042 math functions.
4044 The default is \fB\-fno-unsafe-math-optimizations\fR.
4045 .Ip "\fB\-ffinite-math-only\fR" 4
4046 .IX Item "-ffinite-math-only"
4047 Allow optimizations for floating-point arithmetic that assume
4048 that arguments and results are not NaNs or +\-Infs.
4050 This option should never be turned on by any \fB\-O\fR option since
4051 it can result in incorrect output for programs which depend on
4052 an exact implementation of \s-1IEEE\s0 or \s-1ISO\s0 rules/specifications.
4054 The default is \fB\-fno-finite-math-only\fR.
4055 .Ip "\fB\-fno-trapping-math\fR" 4
4056 .IX Item "-fno-trapping-math"
4057 Compile code assuming that floating-point operations cannot generate
4058 user-visible traps.  These traps include division by zero, overflow,
4059 underflow, inexact result and invalid operation.  This option implies
4060 \&\fB\-fno-signaling-nans\fR.  Setting this option may allow faster
4061 code if one relies on ``non-stop'' \s-1IEEE\s0 arithmetic, for example.
4063 This option should never be turned on by any \fB\-O\fR option since
4064 it can result in incorrect output for programs which depend on
4065 an exact implementation of \s-1IEEE\s0 or \s-1ISO\s0 rules/specifications for
4066 math functions.
4068 The default is \fB\-ftrapping-math\fR.
4069 .Ip "\fB\-frounding-math\fR" 4
4070 .IX Item "-frounding-math"
4071 Disable transformations and optimizations that assume default floating
4072 point rounding behavior.  This is round-to-zero for all floating point
4073 to integer conversions, and round-to-nearest for all other arithmetic
4074 truncations.  This option should be specified for programs that change
4075 the \s-1FP\s0 rounding mode dynamically, or that may be executed with a
4076 non-default rounding mode.  This option disables constant folding of
4077 floating point expressions at compile-time (which may be affected by
4078 rounding mode) and arithmetic transformations that are unsafe in the
4079 presence of sign-dependent rounding modes.
4081 The default is \fB\-fno-rounding-math\fR.
4083 This option is experimental and does not currently guarantee to
4084 disable all \s-1GCC\s0 optimizations that are affected by rounding mode.
4085 Future versions of \s-1GCC\s0 may provide finer control of this setting
4086 using C99's \f(CW\*(C`FENV_ACCESS\*(C'\fR pragma.  This command line option
4087 will be used to specify the default state for \f(CW\*(C`FENV_ACCESS\*(C'\fR.
4088 .Ip "\fB\-fsignaling-nans\fR" 4
4089 .IX Item "-fsignaling-nans"
4090 Compile code assuming that \s-1IEEE\s0 signaling NaNs may generate user-visible
4091 traps during floating-point operations.  Setting this option disables
4092 optimizations that may change the number of exceptions visible with
4093 signaling NaNs.  This option implies \fB\-ftrapping-math\fR.
4095 This option causes the preprocessor macro \f(CW\*(C`_\|_SUPPORT_SNAN_\|_\*(C'\fR to
4096 be defined.
4098 The default is \fB\-fno-signaling-nans\fR.
4100 This option is experimental and does not currently guarantee to
4101 disable all \s-1GCC\s0 optimizations that affect signaling NaN behavior.
4102 .Ip "\fB\-fsingle-precision-constant\fR" 4
4103 .IX Item "-fsingle-precision-constant"
4104 Treat floating point constant as single precision constant instead of
4105 implicitly converting it to double precision constant.
4107 The following options control optimizations that may improve
4108 performance, but are not enabled by any \fB\-O\fR options.  This
4109 section includes experimental options that may produce broken code.
4110 .Ip "\fB\-fbranch-probabilities\fR" 4
4111 .IX Item "-fbranch-probabilities"
4112 After running a program compiled with \fB\-fprofile-arcs\fR, you can compile it a second time using
4113 \&\fB\-fbranch-probabilities\fR, to improve optimizations based on
4114 the number of times each branch was taken.  When the program
4115 compiled with \fB\-fprofile-arcs\fR exits it saves arc execution
4116 counts to a file called \fI\fIsourcename\fI.gcda\fR for each source
4117 file  The information in this data file is very dependent on the
4118 structure of the generated code, so you must use the same source code
4119 and the same optimization options for both compilations.
4121 With \fB\-fbranch-probabilities\fR, \s-1GCC\s0 puts a
4122 \&\fB\s-1REG_BR_PROB\s0\fR note on each \fB\s-1JUMP_INSN\s0\fR and \fB\s-1CALL_INSN\s0\fR.
4123 These can be used to improve optimization.  Currently, they are only
4124 used in one place: in \fIreorg.c\fR, instead of guessing which path a
4125 branch is mostly to take, the \fB\s-1REG_BR_PROB\s0\fR values are used to
4126 exactly determine which path is taken more often.
4127 .Ip "\fB\-fprofile-values\fR" 4
4128 .IX Item "-fprofile-values"
4129 If combined with \fB\-fprofile-arcs\fR, it adds code so that some
4130 data about values of expressions in the program is gathered.
4132 With \fB\-fbranch-probabilities\fR, it reads back the data gathered
4133 from profiling values of expressions and adds \fB\s-1REG_VALUE_PROFILE\s0\fR
4134 notes to instructions for their later usage in optimizations.
4135 .Ip "\fB\-fvpt\fR" 4
4136 .IX Item "-fvpt"
4137 If combined with \fB\-fprofile-arcs\fR, it instructs the compiler to add
4138 a code to gather information about values of expressions.
4140 With \fB\-fbranch-probabilities\fR, it reads back the data gathered
4141 and actually performs the optimizations based on them.
4142 Currently the optimizations include specialization of division operation
4143 using the knowledge about the value of the denominator.
4144 .Ip "\fB\-fnew-ra\fR" 4
4145 .IX Item "-fnew-ra"
4146 Use a graph coloring register allocator.  Currently this option is meant
4147 for testing, so we are interested to hear about miscompilations with
4148 \&\fB\-fnew-ra\fR.
4149 .Ip "\fB\-ftracer\fR" 4
4150 .IX Item "-ftracer"
4151 Perform tail duplication to enlarge superblock size. This transformation
4152 simplifies the control flow of the function allowing other optimizations to do
4153 better job.
4154 .Ip "\fB\-funit-at-a-time\fR" 4
4155 .IX Item "-funit-at-a-time"
4156 Parse the whole compilation unit before starting to produce code.
4157 This allows some extra optimizations to take place but consumes more
4158 memory.
4159 .Ip "\fB\-funroll-loops\fR" 4
4160 .IX Item "-funroll-loops"
4161 Unroll loops whose number of iterations can be determined at compile time or
4162 upon entry to the loop.  \fB\-funroll-loops\fR implies
4163 \&\fB\-frerun-cse-after-loop\fR.  It also turns on complete loop peeling
4164 (i.e. complete removal of loops with small constant number of iterations).
4165 This option makes code larger, and may or may not make it run faster.
4166 .Ip "\fB\-funroll-all-loops\fR" 4
4167 .IX Item "-funroll-all-loops"
4168 Unroll all loops, even if their number of iterations is uncertain when
4169 the loop is entered.  This usually makes programs run more slowly.
4170 \&\fB\-funroll-all-loops\fR implies the same options as
4171 \&\fB\-funroll-loops\fR.
4172 .Ip "\fB\-fpeel-loops\fR" 4
4173 .IX Item "-fpeel-loops"
4174 Peels the loops for that there is enough information that they do not
4175 roll much (from profile feedback).  It also turns on complete loop peeling
4176 (i.e. complete removal of loops with small constant number of iterations).
4177 .Ip "\fB\-funswitch-loops\fR" 4
4178 .IX Item "-funswitch-loops"
4179 Move branches with loop invariant conditions out of the loop, with duplicates
4180 of the loop on both branches (modified according to result of the condition).
4181 .Ip "\fB\-fold-unroll-loops\fR" 4
4182 .IX Item "-fold-unroll-loops"
4183 Unroll loops whose number of iterations can be determined at compile
4184 time or upon entry to the loop, using the old loop unroller whose loop
4185 recognition is based on notes from frontend.  \fB\-fold-unroll-loops\fR implies
4186 both \fB\-fstrength-reduce\fR and \fB\-frerun-cse-after-loop\fR.  This
4187 option makes code larger, and may or may not make it run faster.
4188 .Ip "\fB\-fold-unroll-all-loops\fR" 4
4189 .IX Item "-fold-unroll-all-loops"
4190 Unroll all loops, even if their number of iterations is uncertain when
4191 the loop is entered. This is done using the old loop unroller whose loop
4192 recognition is based on notes from frontend.  This usually makes programs run more slowly.
4193 \&\fB\-fold-unroll-all-loops\fR implies the same options as
4194 \&\fB\-fold-unroll-loops\fR.
4195 .Ip "\fB\-funswitch-loops\fR" 4
4196 .IX Item "-funswitch-loops"
4197 Move branches with loop invariant conditions out of the loop, with duplicates
4198 of the loop on both branches (modified according to result of the condition).
4199 .Ip "\fB\-funswitch-loops\fR" 4
4200 .IX Item "-funswitch-loops"
4201 Move branches with loop invariant conditions out of the loop, with duplicates
4202 of the loop on both branches (modified according to result of the condition).
4203 .Ip "\fB\-fprefetch-loop-arrays\fR" 4
4204 .IX Item "-fprefetch-loop-arrays"
4205 If supported by the target machine, generate instructions to prefetch
4206 memory to improve the performance of loops that access large arrays.
4208 Disabled at level \fB\-Os\fR.
4209 .Ip "\fB\-ffunction-sections\fR" 4
4210 .IX Item "-ffunction-sections"
4211 .PD 0
4212 .Ip "\fB\-fdata-sections\fR" 4
4213 .IX Item "-fdata-sections"
4215 Place each function or data item into its own section in the output
4216 file if the target supports arbitrary sections.  The name of the
4217 function or the name of the data item determines the section's name
4218 in the output file.
4220 Use these options on systems where the linker can perform optimizations
4221 to improve locality of reference in the instruction space.  Most systems
4222 using the \s-1ELF\s0 object format and \s-1SPARC\s0 processors running Solaris 2 have
4223 linkers with such optimizations.  \s-1AIX\s0 may have these optimizations in
4224 the future.
4226 Only use these options when there are significant benefits from doing
4227 so.  When you specify these options, the assembler and linker will
4228 create larger object and executable files and will also be slower.
4229 You will not be able to use \f(CW\*(C`gprof\*(C'\fR on all systems if you
4230 specify this option and you may have problems with debugging if
4231 you specify both this option and \fB\-g\fR.
4232 .Ip "\fB\-fbranch-target-load-optimize\fR" 4
4233 .IX Item "-fbranch-target-load-optimize"
4234 Perform branch target register load optimization before prologue / epilogue
4235 threading.
4236 The use of target registers can typically be exposed only during reload,
4237 thus hoisting loads out of loops and doing inter-block scheduling needs
4238 a separate optimization pass.
4239 .Ip "\fB\-fbranch-target-load-optimize2\fR" 4
4240 .IX Item "-fbranch-target-load-optimize2"
4241 Perform branch target register load optimization after prologue / epilogue
4242 threading.
4243 .Ip "\fB\*(--param\fR \fIname\fR\fB=\fR\fIvalue\fR" 4
4244 .IX Item "param name=value"
4245 In some places, \s-1GCC\s0 uses various constants to control the amount of
4246 optimization that is done.  For example, \s-1GCC\s0 will not inline functions
4247 that contain more that a certain number of instructions.  You can
4248 control some of these constants on the command-line using the
4249 \&\fB\*(--param\fR option.
4251 The names of specific parameters, and the meaning of the values, are
4252 tied to the internals of the compiler, and are subject to change
4253 without notice in future releases.
4255 In each case, the \fIvalue\fR is an integer.  The allowable choices for
4256 \&\fIname\fR are given in the following table:
4257 .RS 4
4258 .Ip "\fBmax-crossjump-edges\fR" 4
4259 .IX Item "max-crossjump-edges"
4260 The maximum number of incoming edges to consider for crossjumping.
4261 The algorithm used by \fB\-fcrossjumping\fR is O(N^2) in
4262 the number of edges incoming to each block.  Increasing values mean
4263 more aggressive optimization, making the compile time increase with
4264 probably small improvement in executable size.
4265 .Ip "\fBmax-delay-slot-insn-search\fR" 4
4266 .IX Item "max-delay-slot-insn-search"
4267 The maximum number of instructions to consider when looking for an
4268 instruction to fill a delay slot.  If more than this arbitrary number of
4269 instructions is searched, the time savings from filling the delay slot
4270 will be minimal so stop searching.  Increasing values mean more
4271 aggressive optimization, making the compile time increase with probably
4272 small improvement in executable run time.
4273 .Ip "\fBmax-delay-slot-live-search\fR" 4
4274 .IX Item "max-delay-slot-live-search"
4275 When trying to fill delay slots, the maximum number of instructions to
4276 consider when searching for a block with valid live register
4277 information.  Increasing this arbitrarily chosen value means more
4278 aggressive optimization, increasing the compile time.  This parameter
4279 should be removed when the delay slot code is rewritten to maintain the
4280 control-flow graph.
4281 .Ip "\fBmax-gcse-memory\fR" 4
4282 .IX Item "max-gcse-memory"
4283 The approximate maximum amount of memory that will be allocated in
4284 order to perform the global common subexpression elimination
4285 optimization.  If more memory than specified is required, the
4286 optimization will not be done.
4287 .Ip "\fBmax-gcse-passes\fR" 4
4288 .IX Item "max-gcse-passes"
4289 The maximum number of passes of \s-1GCSE\s0 to run.
4290 .Ip "\fBmax-pending-list-length\fR" 4
4291 .IX Item "max-pending-list-length"
4292 The maximum number of pending dependencies scheduling will allow
4293 before flushing the current state and starting over.  Large functions
4294 with few branches or calls can create excessively large lists which
4295 needlessly consume memory and resources.
4296 .Ip "\fBmax-inline-insns-single\fR" 4
4297 .IX Item "max-inline-insns-single"
4298 Several parameters control the tree inliner used in gcc.
4299 This number sets the maximum number of instructions (counted in \s-1GCC\s0's
4300 internal representation) in a single function that the tree inliner
4301 will consider for inlining.  This only affects functions declared
4302 inline and methods implemented in a class declaration (\*(C+).
4303 The default value is 500.
4304 .Ip "\fBmax-inline-insns-auto\fR" 4
4305 .IX Item "max-inline-insns-auto"
4306 When you use \fB\-finline-functions\fR (included in \fB\-O3\fR),
4307 a lot of functions that would otherwise not be considered for inlining
4308 by the compiler will be investigated.  To those functions, a different
4309 (more restrictive) limit compared to functions declared inline can
4310 be applied.
4311 The default value is 100.
4312 .Ip "\fBlarge-function-insns\fR" 4
4313 .IX Item "large-function-insns"
4314 The limit specifying really large functions.  For functions greater than this
4315 limit inlining is constrained by \fB\*(--param large-function-growth\fR.
4316 This parameter is useful primarily to avoid extreme compilation time caused by non-linear
4317 algorithms used by the backend.
4318 This parameter is ignored when \fB\-funit-at-a-time\fR is not used.
4319 The default value is 3000.
4320 .Ip "\fBlarge-function-growth\fR" 4
4321 .IX Item "large-function-growth"
4322 Specifies maximal growth of large function caused by inlining in percents.
4323 This parameter is ignored when \fB\-funit-at-a-time\fR is not used.
4324 The default value is 200.
4325 .Ip "\fBinline-unit-growth\fR" 4
4326 .IX Item "inline-unit-growth"
4327 Specifies maximal overall growth of the compilation unit caused by inlining.
4328 This parameter is ignored when \fB\-funit-at-a-time\fR is not used.
4329 The default value is 150.
4330 .Ip "\fBmax-inline-insns-rtl\fR" 4
4331 .IX Item "max-inline-insns-rtl"
4332 For languages that use the \s-1RTL\s0 inliner (this happens at a later stage
4333 than tree inlining), you can set the maximum allowable size (counted
4334 in \s-1RTL\s0 instructions) for the \s-1RTL\s0 inliner with this parameter.
4335 The default value is 600.
4336 .Ip "\fBmax-unrolled-insns\fR" 4
4337 .IX Item "max-unrolled-insns"
4338 The maximum number of instructions that a loop should have if that loop
4339 is unrolled, and if the loop is unrolled, it determines how many times
4340 the loop code is unrolled.
4341 .Ip "\fBmax-average-unrolled-insns\fR" 4
4342 .IX Item "max-average-unrolled-insns"
4343 The maximum number of instructions biased by probabilities of their execution
4344 that a loop should have if that loop is unrolled, and if the loop is unrolled,
4345 it determines how many times the loop code is unrolled.
4346 .Ip "\fBmax-unroll-times\fR" 4
4347 .IX Item "max-unroll-times"
4348 The maximum number of unrollings of a single loop.
4349 .Ip "\fBmax-peeled-insns\fR" 4
4350 .IX Item "max-peeled-insns"
4351 The maximum number of instructions that a loop should have if that loop
4352 is peeled, and if the loop is peeled, it determines how many times
4353 the loop code is peeled.
4354 .Ip "\fBmax-peel-times\fR" 4
4355 .IX Item "max-peel-times"
4356 The maximum number of peelings of a single loop.
4357 .Ip "\fBmax-completely-peeled-insns\fR" 4
4358 .IX Item "max-completely-peeled-insns"
4359 The maximum number of insns of a completely peeled loop.
4360 .Ip "\fBmax-completely-peel-times\fR" 4
4361 .IX Item "max-completely-peel-times"
4362 The maximum number of iterations of a loop to be suitable for complete peeling.
4363 .Ip "\fBmax-unswitch-insns\fR" 4
4364 .IX Item "max-unswitch-insns"
4365 The maximum number of insns of an unswitched loop.
4366 .Ip "\fBmax-unswitch-level\fR" 4
4367 .IX Item "max-unswitch-level"
4368 The maximum number of branches unswitched in a single loop.
4369 .Ip "\fBhot-bb-count-fraction\fR" 4
4370 .IX Item "hot-bb-count-fraction"
4371 Select fraction of the maximal count of repetitions of basic block in program
4372 given basic block needs to have to be considered hot.
4373 .Ip "\fBhot-bb-frequency-fraction\fR" 4
4374 .IX Item "hot-bb-frequency-fraction"
4375 Select fraction of the maximal frequency of executions of basic block in
4376 function given basic block needs to have to be considered hot
4377 .Ip "\fBtracer-dynamic-coverage\fR" 4
4378 .IX Item "tracer-dynamic-coverage"
4379 .PD 0
4380 .Ip "\fBtracer-dynamic-coverage-feedback\fR" 4
4381 .IX Item "tracer-dynamic-coverage-feedback"
4383 This value is used to limit superblock formation once the given percentage of
4384 executed instructions is covered.  This limits unnecessary code size
4385 expansion.
4387 The \fBtracer-dynamic-coverage-feedback\fR is used only when profile
4388 feedback is available.  The real profiles (as opposed to statically estimated
4389 ones) are much less balanced allowing the threshold to be larger value.
4390 .Ip "\fBtracer-max-code-growth\fR" 4
4391 .IX Item "tracer-max-code-growth"
4392 Stop tail duplication once code growth has reached given percentage.  This is
4393 rather hokey argument, as most of the duplicates will be eliminated later in
4394 cross jumping, so it may be set to much higher values than is the desired code
4395 growth.
4396 .Ip "\fBtracer-min-branch-ratio\fR" 4
4397 .IX Item "tracer-min-branch-ratio"
4398 Stop reverse growth when the reverse probability of best edge is less than this
4399 threshold (in percent).
4400 .Ip "\fBtracer-min-branch-ratio\fR" 4
4401 .IX Item "tracer-min-branch-ratio"
4402 .PD 0
4403 .Ip "\fBtracer-min-branch-ratio-feedback\fR" 4
4404 .IX Item "tracer-min-branch-ratio-feedback"
4406 Stop forward growth if the best edge do have probability lower than this
4407 threshold.
4409 Similarly to \fBtracer-dynamic-coverage\fR two values are present, one for
4410 compilation for profile feedback and one for compilation without.  The value
4411 for compilation with profile feedback needs to be more conservative (higher) in
4412 order to make tracer effective.
4413 .Ip "\fBmax-cse-path-length\fR" 4
4414 .IX Item "max-cse-path-length"
4415 Maximum number of basic blocks on path that cse considers.
4416 .Ip "\fBggc-min-expand\fR" 4
4417 .IX Item "ggc-min-expand"
4418 \&\s-1GCC\s0 uses a garbage collector to manage its own memory allocation.  This
4419 parameter specifies the minimum percentage by which the garbage
4420 collector's heap should be allowed to expand between collections.
4421 Tuning this may improve compilation speed; it has no effect on code
4422 generation.
4424 The default is 30% + 70% * (\s-1RAM/1GB\s0) with an upper bound of 100% when
4425 \&\s-1RAM\s0 >= 1GB.  If \f(CW\*(C`getrlimit\*(C'\fR is available, the notion of \*(L"\s-1RAM\s0\*(R" is
4426 the smallest of actual \s-1RAM\s0, \s-1RLIMIT_RSS\s0, \s-1RLIMIT_DATA\s0 and \s-1RLIMIT_AS\s0.  If
4427 \&\s-1GCC\s0 is not able to calculate \s-1RAM\s0 on a particular platform, the lower
4428 bound of 30% is used.  Setting this parameter and
4429 \&\fBggc-min-heapsize\fR to zero causes a full collection to occur at
4430 every opportunity.  This is extremely slow, but can be useful for
4431 debugging.
4432 .Ip "\fBggc-min-heapsize\fR" 4
4433 .IX Item "ggc-min-heapsize"
4434 Minimum size of the garbage collector's heap before it begins bothering
4435 to collect garbage.  The first collection occurs after the heap expands
4436 by \fBggc-min-expand\fR% beyond \fBggc-min-heapsize\fR.  Again,
4437 tuning this may improve compilation speed, and has no effect on code
4438 generation.
4440 The default is \s-1RAM/8\s0, with a lower bound of 4096 (four megabytes) and an
4441 upper bound of 131072 (128 megabytes).  If \f(CW\*(C`getrlimit\*(C'\fR is
4442 available, the notion of \*(L"\s-1RAM\s0\*(R" is the smallest of actual \s-1RAM\s0,
4443 \&\s-1RLIMIT_RSS\s0, \s-1RLIMIT_DATA\s0 and \s-1RLIMIT_AS\s0.  If \s-1GCC\s0 is not able to calculate
4444 \&\s-1RAM\s0 on a particular platform, the lower bound is used.  Setting this
4445 parameter very large effectively disables garbage collection.  Setting
4446 this parameter and \fBggc-min-expand\fR to zero causes a full
4447 collection to occur at every opportunity.
4448 .Ip "\fBmax-reload-search-insns\fR" 4
4449 .IX Item "max-reload-search-insns"
4450 The maximum number of instruction reload should look backward for equivalent
4451 register.  Increasing values mean more aggressive optimization, making the
4452 compile time increase with probably slightly better performance.  The default
4453 value is 100.
4454 .Ip "\fBmax-cselib-memory-location\fR" 4
4455 .IX Item "max-cselib-memory-location"
4456 The maximum number of memory locations cselib should take into acount.
4457 Increasing values mean more aggressive optimization, making the compile time
4458 increase with probably slightly better performance.  The default value is 500.
4459 .Ip "\fBreorder-blocks-duplicate\fR" 4
4460 .IX Item "reorder-blocks-duplicate"
4461 .PD 0
4462 .Ip "\fBreorder-blocks-duplicate-feedback\fR" 4
4463 .IX Item "reorder-blocks-duplicate-feedback"
4465 Used by basic block reordering pass to decide whether to use unconditional
4466 branch or duplicate the code on its destination.  Code is duplicated when its
4467 estimated size is smaller than this value multiplied by the estimated size of
4468 unconditional jump in the hot spots of the program.
4470 The \fBreorder-block-duplicate-feedback\fR is used only when profile
4471 feedback is available and may be set to higher values than
4472 \&\fBreorder-block-duplicate\fR since information about the hot spots is more
4473 accurate.
4475 .RS 4
4477 .Sh "Options Controlling the Preprocessor"
4478 .IX Subsection "Options Controlling the Preprocessor"
4479 These options control the C preprocessor, which is run on each C source
4480 file before actual compilation.
4482 If you use the \fB\-E\fR option, nothing is done except preprocessing.
4483 Some of these options make sense only together with \fB\-E\fR because
4484 they cause the preprocessor output to be unsuitable for actual
4485 compilation.
4487 You can use \fB\-Wp,\fR\fIoption\fR to bypass the compiler driver
4488 and pass \fIoption\fR directly through to the preprocessor.  If
4489 \&\fIoption\fR contains commas, it is split into multiple options at the
4490 commas.  However, many options are modified, translated or interpreted
4491 by the compiler driver before being passed to the preprocessor, and
4492 \&\fB\-Wp\fR forcibly bypasses this phase.  The preprocessor's direct
4493 interface is undocumented and subject to change, so whenever possible
4494 you should avoid using \fB\-Wp\fR and let the driver handle the
4495 options instead.
4496 .Ip "\fB\-Xpreprocessor\fR \fIoption\fR" 4
4497 .IX Item "-Xpreprocessor option"
4498 Pass \fIoption\fR as an option to the preprocessor.  You can use this to
4499 supply system-specific preprocessor options which \s-1GCC\s0 does not know how to
4500 recognize.
4502 If you want to pass an option that takes an argument, you must use
4503 \&\fB\-Xpreprocessor\fR twice, once for the option and once for the argument.
4504 .Ip "\fB\-D\fR \fIname\fR" 4
4505 .IX Item "-D name"
4506 Predefine \fIname\fR as a macro, with definition \f(CW\*(C`1\*(C'\fR.
4507 .Ip "\fB\-D\fR \fIname\fR\fB=\fR\fIdefinition\fR" 4
4508 .IX Item "-D name=definition"
4509 Predefine \fIname\fR as a macro, with definition \fIdefinition\fR.
4510 The contents of \fIdefinition\fR are tokenized and processed as if
4511 they appeared during translation phase three in a \fB#define\fR
4512 directive.  In particular, the definition will be truncated by
4513 embedded newline characters.
4515 If you are invoking the preprocessor from a shell or shell-like
4516 program you may need to use the shell's quoting syntax to protect
4517 characters such as spaces that have a meaning in the shell syntax.
4519 If you wish to define a function-like macro on the command line, write
4520 its argument list with surrounding parentheses before the equals sign
4521 (if any).  Parentheses are meaningful to most shells, so you will need
4522 to quote the option.  With \fBsh\fR and \fBcsh\fR,
4523 \&\fB\-D'\fR\fIname\fR\fB(\fR\fIargs...\fR\fB)=\fR\fIdefinition\fR\fB'\fR works.
4525 \&\fB\-D\fR and \fB\-U\fR options are processed in the order they
4526 are given on the command line.  All \fB\-imacros\fR \fIfile\fR and
4527 \&\fB\-include\fR \fIfile\fR options are processed after all
4528 \&\fB\-D\fR and \fB\-U\fR options.
4529 .Ip "\fB\-U\fR \fIname\fR" 4
4530 .IX Item "-U name"
4531 Cancel any previous definition of \fIname\fR, either built in or
4532 provided with a \fB\-D\fR option.
4533 .Ip "\fB\-undef\fR" 4
4534 .IX Item "-undef"
4535 Do not predefine any system-specific or GCC-specific macros.  The
4536 standard predefined macros remain defined.
4537 .Ip "\fB\-I\fR \fIdir\fR" 4
4538 .IX Item "-I dir"
4539 Add the directory \fIdir\fR to the list of directories to be searched
4540 for header files.
4541 Directories named by \fB\-I\fR are searched before the standard
4542 system include directories.  If the directory \fIdir\fR is a standard
4543 system include directory, the option is ignored to ensure that the
4544 default search order for system directories and the special treatment
4545 of system headers are not defeated
4547 .Ip "\fB\-o\fR \fIfile\fR" 4
4548 .IX Item "-o file"
4549 Write output to \fIfile\fR.  This is the same as specifying \fIfile\fR
4550 as the second non-option argument to \fBcpp\fR.  \fBgcc\fR has a
4551 different interpretation of a second non-option argument, so you must
4552 use \fB\-o\fR to specify the output file.
4553 .Ip "\fB\-Wall\fR" 4
4554 .IX Item "-Wall"
4555 Turns on all optional warnings which are desirable for normal code.
4556 At present this is \fB\-Wcomment\fR, \fB\-Wtrigraphs\fR,
4557 \&\fB\-Wmultichar\fR and a warning about integer promotion causing a
4558 change of sign in \f(CW\*(C`#if\*(C'\fR expressions.  Note that many of the
4559 preprocessor's warnings are on by default and have no options to
4560 control them.
4561 .Ip "\fB\-Wcomment\fR" 4
4562 .IX Item "-Wcomment"
4563 .PD 0
4564 .Ip "\fB\-Wcomments\fR" 4
4565 .IX Item "-Wcomments"
4567 Warn whenever a comment-start sequence \fB/*\fR appears in a \fB/*\fR
4568 comment, or whenever a backslash-newline appears in a \fB//\fR comment.
4569 (Both forms have the same effect.)
4570 .Ip "\fB\-Wtrigraphs\fR" 4
4571 .IX Item "-Wtrigraphs"
4572 @anchor{Wtrigraphs}
4573 Most trigraphs in comments cannot affect the meaning of the program.
4574 However, a trigraph that would form an escaped newline (\fB??/\fR at
4575 the end of a line) can, by changing where the comment begins or ends.
4576 Therefore, only trigraphs that would form escaped newlines produce
4577 warnings inside a comment.
4579 This option is implied by \fB\-Wall\fR.  If \fB\-Wall\fR is not
4580 given, this option is still enabled unless trigraphs are enabled.  To
4581 get trigraph conversion without warnings, but get the other
4582 \&\fB\-Wall\fR warnings, use \fB\-trigraphs \-Wall \-Wno-trigraphs\fR.
4583 .Ip "\fB\-Wtraditional\fR" 4
4584 .IX Item "-Wtraditional"
4585 Warn about certain constructs that behave differently in traditional and
4586 \&\s-1ISO\s0 C.  Also warn about \s-1ISO\s0 C constructs that have no traditional C
4587 equivalent, and problematic constructs which should be avoided.
4588 .Ip "\fB\-Wimport\fR" 4
4589 .IX Item "-Wimport"
4590 Warn the first time \fB#import\fR is used.
4591 .Ip "\fB\-Wundef\fR" 4
4592 .IX Item "-Wundef"
4593 Warn whenever an identifier which is not a macro is encountered in an
4594 \&\fB#if\fR directive, outside of \fBdefined\fR.  Such identifiers are
4595 replaced with zero.
4596 .Ip "\fB\-Wunused-macros\fR" 4
4597 .IX Item "-Wunused-macros"
4598 Warn about macros defined in the main file that are unused.  A macro
4599 is \fIused\fR if it is expanded or tested for existence at least once.
4600 The preprocessor will also warn if the macro has not been used at the
4601 time it is redefined or undefined.
4603 Built-in macros, macros defined on the command line, and macros
4604 defined in include files are not warned about.
4606 \&\fBNote:\fR If a macro is actually used, but only used in skipped
4607 conditional blocks, then \s-1CPP\s0 will report it as unused.  To avoid the
4608 warning in such a case, you might improve the scope of the macro's
4609 definition by, for example, moving it into the first skipped block.
4610 Alternatively, you could provide a dummy use with something like:
4612 .Vb 2
4613 \&        #if defined the_macro_causing_the_warning
4614 \&        #endif
4616 .Ip "\fB\-Wendif-labels\fR" 4
4617 .IX Item "-Wendif-labels"
4618 Warn whenever an \fB#else\fR or an \fB#endif\fR are followed by text.
4619 This usually happens in code of the form
4621 .Vb 5
4622 \&        #if FOO
4623 \&        ...
4624 \&        #else FOO
4625 \&        ...
4626 \&        #endif FOO
4628 The second and third \f(CW\*(C`FOO\*(C'\fR should be in comments, but often are not
4629 in older programs.  This warning is on by default.
4630 .Ip "\fB\-Werror\fR" 4
4631 .IX Item "-Werror"
4632 Make all warnings into hard errors.  Source code which triggers warnings
4633 will be rejected.
4634 .Ip "\fB\-Wsystem-headers\fR" 4
4635 .IX Item "-Wsystem-headers"
4636 Issue warnings for code in system headers.  These are normally unhelpful
4637 in finding bugs in your own code, therefore suppressed.  If you are
4638 responsible for the system library, you may want to see them.
4639 .Ip "\fB\-w\fR" 4
4640 .IX Item "-w"
4641 Suppress all warnings, including those which \s-1GNU\s0 \s-1CPP\s0 issues by default.
4642 .Ip "\fB\-pedantic\fR" 4
4643 .IX Item "-pedantic"
4644 Issue all the mandatory diagnostics listed in the C standard.  Some of
4645 them are left out by default, since they trigger frequently on harmless
4646 code.
4647 .Ip "\fB\-pedantic-errors\fR" 4
4648 .IX Item "-pedantic-errors"
4649 Issue all the mandatory diagnostics, and make all mandatory diagnostics
4650 into errors.  This includes mandatory diagnostics that \s-1GCC\s0 issues
4651 without \fB\-pedantic\fR but treats as warnings.
4652 .Ip "\fB\-M\fR" 4
4653 .IX Item "-M"
4654 Instead of outputting the result of preprocessing, output a rule
4655 suitable for \fBmake\fR describing the dependencies of the main
4656 source file.  The preprocessor outputs one \fBmake\fR rule containing
4657 the object file name for that source file, a colon, and the names of all
4658 the included files, including those coming from \fB\-include\fR or
4659 \&\fB\-imacros\fR command line options.
4661 Unless specified explicitly (with \fB\-MT\fR or \fB\-MQ\fR), the
4662 object file name consists of the basename of the source file with any
4663 suffix replaced with object file suffix.  If there are many included
4664 files then the rule is split into several lines using \fB\e\fR\-newline.
4665 The rule has no commands.
4667 This option does not suppress the preprocessor's debug output, such as
4668 \&\fB\-dM\fR.  To avoid mixing such debug output with the dependency
4669 rules you should explicitly specify the dependency output file with
4670 \&\fB\-MF\fR, or use an environment variable like
4671 \&\fB\s-1DEPENDENCIES_OUTPUT\s0\fR.  Debug output
4672 will still be sent to the regular output stream as normal.
4674 Passing \fB\-M\fR to the driver implies \fB\-E\fR, and suppresses
4675 warnings with an implicit \fB\-w\fR.
4676 .Ip "\fB\-MM\fR" 4
4677 .IX Item "-MM"
4678 Like \fB\-M\fR but do not mention header files that are found in
4679 system header directories, nor header files that are included,
4680 directly or indirectly, from such a header.
4682 This implies that the choice of angle brackets or double quotes in an
4683 \&\fB#include\fR directive does not in itself determine whether that
4684 header will appear in \fB\-MM\fR dependency output.  This is a
4685 slight change in semantics from \s-1GCC\s0 versions 3.0 and earlier.
4687 @anchor{dashMF}
4688 .Ip "\fB\-MF\fR \fIfile\fR" 4
4689 .IX Item "-MF file"
4690 When used with \fB\-M\fR or \fB\-MM\fR, specifies a
4691 file to write the dependencies to.  If no \fB\-MF\fR switch is given
4692 the preprocessor sends the rules to the same place it would have sent
4693 preprocessed output.
4695 When used with the driver options \fB\-MD\fR or \fB\-MMD\fR,
4696 \&\fB\-MF\fR overrides the default dependency output file.
4697 .Ip "\fB\-MG\fR" 4
4698 .IX Item "-MG"
4699 In conjunction with an option such as \fB\-M\fR requesting
4700 dependency generation, \fB\-MG\fR assumes missing header files are
4701 generated files and adds them to the dependency list without raising
4702 an error.  The dependency filename is taken directly from the
4703 \&\f(CW\*(C`#include\*(C'\fR directive without prepending any path.  \fB\-MG\fR
4704 also suppresses preprocessed output, as a missing header file renders
4705 this useless.
4707 This feature is used in automatic updating of makefiles.
4708 .Ip "\fB\-MP\fR" 4
4709 .IX Item "-MP"
4710 This option instructs \s-1CPP\s0 to add a phony target for each dependency
4711 other than the main file, causing each to depend on nothing.  These
4712 dummy rules work around errors \fBmake\fR gives if you remove header
4713 files without updating the \fIMakefile\fR to match.
4715 This is typical output:
4717 .Vb 1
4718 \&        test.o: test.c test.h
4720 .Vb 1
4721 \&        test.h:
4723 .Ip "\fB\-MT\fR \fItarget\fR" 4
4724 .IX Item "-MT target"
4725 Change the target of the rule emitted by dependency generation.  By
4726 default \s-1CPP\s0 takes the name of the main input file, including any path,
4727 deletes any file suffix such as \fB.c\fR, and appends the platform's
4728 usual object suffix.  The result is the target.
4730 An \fB\-MT\fR option will set the target to be exactly the string you
4731 specify.  If you want multiple targets, you can specify them as a single
4732 argument to \fB\-MT\fR, or use multiple \fB\-MT\fR options.
4734 For example, \fB\-MT\ '$(objpfx)foo.o'\fR might give
4736 .Vb 1
4737 \&        $(objpfx)foo.o: foo.c
4739 .Ip "\fB\-MQ\fR \fItarget\fR" 4
4740 .IX Item "-MQ target"
4741 Same as \fB\-MT\fR, but it quotes any characters which are special to
4742 Make.  \fB\-MQ\ '$(objpfx)foo.o'\fR gives
4744 .Vb 1
4745 \&        $$(objpfx)foo.o: foo.c
4747 The default target is automatically quoted, as if it were given with
4748 \&\fB\-MQ\fR.
4749 .Ip "\fB\-MD\fR" 4
4750 .IX Item "-MD"
4751 \&\fB\-MD\fR is equivalent to \fB\-M \-MF\fR \fIfile\fR, except that
4752 \&\fB\-E\fR is not implied.  The driver determines \fIfile\fR based on
4753 whether an \fB\-o\fR option is given.  If it is, the driver uses its
4754 argument but with a suffix of \fI.d\fR, otherwise it take the
4755 basename of the input file and applies a \fI.d\fR suffix.
4757 If \fB\-MD\fR is used in conjunction with \fB\-E\fR, any
4758 \&\fB\-o\fR switch is understood to specify the dependency output file
4759 (but \f(CW@pxref\fR{dashMF,,\-MF}), but if used without \fB\-E\fR, each \fB\-o\fR
4760 is understood to specify a target object file.
4762 Since \fB\-E\fR is not implied, \fB\-MD\fR can be used to generate
4763 a dependency output file as a side-effect of the compilation process.
4764 .Ip "\fB\-MMD\fR" 4
4765 .IX Item "-MMD"
4766 Like \fB\-MD\fR except mention only user header files, not system
4767 \&\-header files.
4768 .Ip "\fB\-fpch-deps\fR" 4
4769 .IX Item "-fpch-deps"
4770 When using precompiled headers, this flag
4771 will cause the dependency-output flags to also list the files from the
4772 precompiled header's dependencies.  If not specified only the
4773 precompiled header would be listed and not the files that were used to
4774 create it because those files are not consulted when a precompiled
4775 header is used.
4776 .Ip "\fB\-x c\fR" 4
4777 .IX Item "-x c"
4778 .PD 0
4779 .Ip "\fB\-x c++\fR" 4
4780 .IX Item "-x c++"
4781 .Ip "\fB\-x objective-c\fR" 4
4782 .IX Item "-x objective-c"
4783 .Ip "\fB\-x assembler-with-cpp\fR" 4
4784 .IX Item "-x assembler-with-cpp"
4786 Specify the source language: C, \*(C+, Objective-C, or assembly.  This has
4787 nothing to do with standards conformance or extensions; it merely
4788 selects which base syntax to expect.  If you give none of these options,
4789 cpp will deduce the language from the extension of the source file:
4790 \&\fB.c\fR, \fB.cc\fR, \fB.m\fR, or \fB.S\fR.  Some other common
4791 extensions for \*(C+ and assembly are also recognized.  If cpp does not
4792 recognize the extension, it will treat the file as C; this is the most
4793 generic mode.
4795 \&\fBNote:\fR Previous versions of cpp accepted a \fB\-lang\fR option
4796 which selected both the language and the standards conformance level.
4797 This option has been removed, because it conflicts with the \fB\-l\fR
4798 option.
4799 .Ip "\fB\-std=\fR\fIstandard\fR" 4
4800 .IX Item "-std=standard"
4801 .PD 0
4802 .Ip "\fB\-ansi\fR" 4
4803 .IX Item "-ansi"
4805 Specify the standard to which the code should conform.  Currently \s-1CPP\s0
4806 knows about C and \*(C+ standards; others may be added in the future.
4808 \&\fIstandard\fR
4809 may be one of:
4810 .RS 4
4811 .if n .Ip "\f(CW""""iso9899:1990""""\fR" 4
4812 .el .Ip "\f(CWiso9899:1990\fR" 4
4813 .IX Item "iso9899:1990"
4814 .PD 0
4815 .if n .Ip "\f(CW""""c89""""\fR" 4
4816 .el .Ip "\f(CWc89\fR" 4
4817 .IX Item "c89"
4819 The \s-1ISO\s0 C standard from 1990.  \fBc89\fR is the customary shorthand for
4820 this version of the standard.
4822 The \fB\-ansi\fR option is equivalent to \fB\-std=c89\fR.
4823 .if n .Ip "\f(CW""""iso9899:199409""""\fR" 4
4824 .el .Ip "\f(CWiso9899:199409\fR" 4
4825 .IX Item "iso9899:199409"
4826 The 1990 C standard, as amended in 1994.
4827 .if n .Ip "\f(CW""""iso9899:1999""""\fR" 4
4828 .el .Ip "\f(CWiso9899:1999\fR" 4
4829 .IX Item "iso9899:1999"
4830 .PD 0
4831 .if n .Ip "\f(CW""""c99""""\fR" 4
4832 .el .Ip "\f(CWc99\fR" 4
4833 .IX Item "c99"
4834 .if n .Ip "\f(CW""""iso9899:199x""""\fR" 4
4835 .el .Ip "\f(CWiso9899:199x\fR" 4
4836 .IX Item "iso9899:199x"
4837 .if n .Ip "\f(CW""""c9x""""\fR" 4
4838 .el .Ip "\f(CWc9x\fR" 4
4839 .IX Item "c9x"
4841 The revised \s-1ISO\s0 C standard, published in December 1999.  Before
4842 publication, this was known as C9X.
4843 .if n .Ip "\f(CW""""gnu89""""\fR" 4
4844 .el .Ip "\f(CWgnu89\fR" 4
4845 .IX Item "gnu89"
4846 The 1990 C standard plus \s-1GNU\s0 extensions.  This is the default.
4847 .if n .Ip "\f(CW""""gnu99""""\fR" 4
4848 .el .Ip "\f(CWgnu99\fR" 4
4849 .IX Item "gnu99"
4850 .PD 0
4851 .if n .Ip "\f(CW""""gnu9x""""\fR" 4
4852 .el .Ip "\f(CWgnu9x\fR" 4
4853 .IX Item "gnu9x"
4855 The 1999 C standard plus \s-1GNU\s0 extensions.
4856 .if n .Ip "\f(CW""""c++98""""\fR" 4
4857 .el .Ip "\f(CWc++98\fR" 4
4858 .IX Item "c++98"
4859 The 1998 \s-1ISO\s0 \*(C+ standard plus amendments.
4860 .if n .Ip "\f(CW""""gnu++98""""\fR" 4
4861 .el .Ip "\f(CWgnu++98\fR" 4
4862 .IX Item "gnu++98"
4863 The same as \fB\-std=c++98\fR plus \s-1GNU\s0 extensions.  This is the
4864 default for \*(C+ code.
4866 .RS 4
4868 .Ip "\fB\-I-\fR" 4
4869 .IX Item "-I-"
4870 Split the include path.  Any directories specified with \fB\-I\fR
4871 options before \fB\-I-\fR are searched only for headers requested with
4872 \&\f(CW\*(C`#include\ "\f(CIfile\f(CW"\*(C'\fR; they are not searched for
4873 \&\f(CW\*(C`#include\ <\f(CIfile\f(CW>\*(C'\fR.  If additional directories are
4874 specified with \fB\-I\fR options after the \fB\-I-\fR, those
4875 directories are searched for all \fB#include\fR directives.
4877 In addition, \fB\-I-\fR inhibits the use of the directory of the current
4878 file directory as the first search directory for \f(CW\*(C`#include\ "\f(CIfile\f(CW"\*(C'\fR.
4879 .Ip "\fB\-nostdinc\fR" 4
4880 .IX Item "-nostdinc"
4881 Do not search the standard system directories for header files.
4882 Only the directories you have specified with \fB\-I\fR options
4883 (and the directory of the current file, if appropriate) are searched.
4884 .Ip "\fB\-nostdinc++\fR" 4
4885 .IX Item "-nostdinc++"
4886 Do not search for header files in the \*(C+\-specific standard directories,
4887 but do still search the other standard directories.  (This option is
4888 used when building the \*(C+ library.)
4889 .Ip "\fB\-include\fR \fIfile\fR" 4
4890 .IX Item "-include file"
4891 Process \fIfile\fR as if \f(CW\*(C`#include "file"\*(C'\fR appeared as the first
4892 line of the primary source file.  However, the first directory searched
4893 for \fIfile\fR is the preprocessor's working directory \fIinstead of\fR
4894 the directory containing the main source file.  If not found there, it
4895 is searched for in the remainder of the \f(CW\*(C`#include "..."\*(C'\fR search
4896 chain as normal.
4898 If multiple \fB\-include\fR options are given, the files are included
4899 in the order they appear on the command line.
4900 .Ip "\fB\-imacros\fR \fIfile\fR" 4
4901 .IX Item "-imacros file"
4902 Exactly like \fB\-include\fR, except that any output produced by
4903 scanning \fIfile\fR is thrown away.  Macros it defines remain defined.
4904 This allows you to acquire all the macros from a header without also
4905 processing its declarations.
4907 All files specified by \fB\-imacros\fR are processed before all files
4908 specified by \fB\-include\fR.
4909 .Ip "\fB\-idirafter\fR \fIdir\fR" 4
4910 .IX Item "-idirafter dir"
4911 Search \fIdir\fR for header files, but do it \fIafter\fR all
4912 directories specified with \fB\-I\fR and the standard system directories
4913 have been exhausted.  \fIdir\fR is treated as a system include directory.
4914 .Ip "\fB\-iprefix\fR \fIprefix\fR" 4
4915 .IX Item "-iprefix prefix"
4916 Specify \fIprefix\fR as the prefix for subsequent \fB\-iwithprefix\fR
4917 options.  If the prefix represents a directory, you should include the
4918 final \fB/\fR.
4919 .Ip "\fB\-iwithprefix\fR \fIdir\fR" 4
4920 .IX Item "-iwithprefix dir"
4921 .PD 0
4922 .Ip "\fB\-iwithprefixbefore\fR \fIdir\fR" 4
4923 .IX Item "-iwithprefixbefore dir"
4925 Append \fIdir\fR to the prefix specified previously with
4926 \&\fB\-iprefix\fR, and add the resulting directory to the include search
4927 path.  \fB\-iwithprefixbefore\fR puts it in the same place \fB\-I\fR
4928 would; \fB\-iwithprefix\fR puts it where \fB\-idirafter\fR would.
4929 .Ip "\fB\-isystem\fR \fIdir\fR" 4
4930 .IX Item "-isystem dir"
4931 Search \fIdir\fR for header files, after all directories specified by
4932 \&\fB\-I\fR but before the standard system directories.  Mark it
4933 as a system directory, so that it gets the same special treatment as
4934 is applied to the standard system directories.
4935 .Ip "\fB\-fdollars-in-identifiers\fR" 4
4936 .IX Item "-fdollars-in-identifiers"
4937 @anchor{fdollars-in-identifiers}
4938 Accept \fB$\fR in identifiers.
4939 .Ip "\fB\-fpreprocessed\fR" 4
4940 .IX Item "-fpreprocessed"
4941 Indicate to the preprocessor that the input file has already been
4942 preprocessed.  This suppresses things like macro expansion, trigraph
4943 conversion, escaped newline splicing, and processing of most directives.
4944 The preprocessor still recognizes and removes comments, so that you can
4945 pass a file preprocessed with \fB\-C\fR to the compiler without
4946 problems.  In this mode the integrated preprocessor is little more than
4947 a tokenizer for the front ends.
4949 \&\fB\-fpreprocessed\fR is implicit if the input file has one of the
4950 extensions \fB.i\fR, \fB.ii\fR or \fB.mi\fR.  These are the
4951 extensions that \s-1GCC\s0 uses for preprocessed files created by
4952 \&\fB\-save-temps\fR.
4953 .Ip "\fB\-ftabstop=\fR\fIwidth\fR" 4
4954 .IX Item "-ftabstop=width"
4955 Set the distance between tab stops.  This helps the preprocessor report
4956 correct column numbers in warnings or errors, even if tabs appear on the
4957 line.  If the value is less than 1 or greater than 100, the option is
4958 ignored.  The default is 8.
4959 .Ip "\fB\-fexec-charset=\fR\fIcharset\fR" 4
4960 .IX Item "-fexec-charset=charset"
4961 Set the execution character set, used for string and character
4962 constants.  The default is \s-1UTF-8\s0.  \fIcharset\fR can be any encoding
4963 supported by the system's \f(CW\*(C`iconv\*(C'\fR library routine.
4964 .Ip "\fB\-fwide-exec-charset=\fR\fIcharset\fR" 4
4965 .IX Item "-fwide-exec-charset=charset"
4966 Set the wide execution character set, used for wide string and
4967 character constants.  The default is \s-1UTF-32\s0 or \s-1UTF-16\s0, whichever
4968 corresponds to the width of \f(CW\*(C`wchar_t\*(C'\fR.  As with
4969 \&\fB\-ftarget-charset\fR, \fIcharset\fR can be any encoding supported
4970 by the system's \f(CW\*(C`iconv\*(C'\fR library routine; however, you will have
4971 problems with encodings that do not fit exactly in \f(CW\*(C`wchar_t\*(C'\fR.
4972 .Ip "\fB\-finput-charset=\fR\fIcharset\fR" 4
4973 .IX Item "-finput-charset=charset"
4974 Set the input character set, used for translation from the character
4975 set of the input file to the source character set used by \s-1GCC\s0. If the
4976 locale does not specify, or \s-1GCC\s0 cannot get this information from the
4977 locale, the default is \s-1UTF-8\s0. This can be overridden by either the locale
4978 or this command line option. Currently the command line option takes
4979 precedence if there's a conflict. \fIcharset\fR can be any encoding
4980 supported by the system's \f(CW\*(C`iconv\*(C'\fR library routine.
4981 .Ip "\fB\-fworking-directory\fR" 4
4982 .IX Item "-fworking-directory"
4983 Enable generation of linemarkers in the preprocessor output that will
4984 let the compiler know the current working directory at the time of
4985 preprocessing.  When this option is enabled, the preprocessor will
4986 emit, after the initial linemarker, a second linemarker with the
4987 current working directory followed by two slashes.  \s-1GCC\s0 will use this
4988 directory, when it's present in the preprocessed input, as the
4989 directory emitted as the current working directory in some debugging
4990 information formats.  This option is implicitly enabled if debugging
4991 information is enabled, but this can be inhibited with the negated
4992 form \fB\-fno-working-directory\fR.  If the \fB\-P\fR flag is
4993 present in the command line, this option has no effect, since no
4994 \&\f(CW\*(C`#line\*(C'\fR directives are emitted whatsoever.
4995 .Ip "\fB\-fno-show-column\fR" 4
4996 .IX Item "-fno-show-column"
4997 Do not print column numbers in diagnostics.  This may be necessary if
4998 diagnostics are being scanned by a program that does not understand the
4999 column numbers, such as \fBdejagnu\fR.
5000 .Ip "\fB\-A\fR \fIpredicate\fR\fB=\fR\fIanswer\fR" 4
5001 .IX Item "-A predicate=answer"
5002 Make an assertion with the predicate \fIpredicate\fR and answer
5003 \&\fIanswer\fR.  This form is preferred to the older form \fB\-A\fR
5004 \&\fIpredicate\fR\fB(\fR\fIanswer\fR\fB)\fR, which is still supported, because
5005 it does not use shell special characters.
5006 .Ip "\fB\-A -\fR\fIpredicate\fR\fB=\fR\fIanswer\fR" 4
5007 .IX Item "-A -predicate=answer"
5008 Cancel an assertion with the predicate \fIpredicate\fR and answer
5009 \&\fIanswer\fR.
5010 .Ip "\fB\-dCHARS\fR" 4
5011 .IX Item "-dCHARS"
5012 \&\fI\s-1CHARS\s0\fR is a sequence of one or more of the following characters,
5013 and must not be preceded by a space.  Other characters are interpreted
5014 by the compiler proper, or reserved for future versions of \s-1GCC\s0, and so
5015 are silently ignored.  If you specify characters whose behavior
5016 conflicts, the result is undefined.
5017 .RS 4
5018 .Ip "\fBM\fR" 4
5019 .IX Item "M"
5020 Instead of the normal output, generate a list of \fB#define\fR
5021 directives for all the macros defined during the execution of the
5022 preprocessor, including predefined macros.  This gives you a way of
5023 finding out what is predefined in your version of the preprocessor.
5024 Assuming you have no file \fIfoo.h\fR, the command
5026 .Vb 1
5027 \&        touch foo.h; cpp -dM foo.h
5029 will show all the predefined macros.
5030 .Ip "\fBD\fR" 4
5031 .IX Item "D"
5032 Like \fBM\fR except in two respects: it does \fInot\fR include the
5033 predefined macros, and it outputs \fIboth\fR the \fB#define\fR
5034 directives and the result of preprocessing.  Both kinds of output go to
5035 the standard output file.
5036 .Ip "\fBN\fR" 4
5037 .IX Item "N"
5038 Like \fBD\fR, but emit only the macro names, not their expansions.
5039 .Ip "\fBI\fR" 4
5040 .IX Item "I"
5041 Output \fB#include\fR directives in addition to the result of
5042 preprocessing.
5044 .RS 4
5046 .Ip "\fB\-P\fR" 4
5047 .IX Item "-P"
5048 Inhibit generation of linemarkers in the output from the preprocessor.
5049 This might be useful when running the preprocessor on something that is
5050 not C code, and will be sent to a program which might be confused by the
5051 linemarkers.
5052 .Ip "\fB\-C\fR" 4
5053 .IX Item "-C"
5054 Do not discard comments.  All comments are passed through to the output
5055 file, except for comments in processed directives, which are deleted
5056 along with the directive.
5058 You should be prepared for side effects when using \fB\-C\fR; it
5059 causes the preprocessor to treat comments as tokens in their own right.
5060 For example, comments appearing at the start of what would be a
5061 directive line have the effect of turning that line into an ordinary
5062 source line, since the first token on the line is no longer a \fB#\fR.
5063 .Ip "\fB\-CC\fR" 4
5064 .IX Item "-CC"
5065 Do not discard comments, including during macro expansion.  This is
5066 like \fB\-C\fR, except that comments contained within macros are
5067 also passed through to the output file where the macro is expanded.
5069 In addition to the side-effects of the \fB\-C\fR option, the
5070 \&\fB\-CC\fR option causes all \*(C+\-style comments inside a macro
5071 to be converted to C-style comments.  This is to prevent later use
5072 of that macro from inadvertently commenting out the remainder of
5073 the source line.
5075 The \fB\-CC\fR option is generally used to support lint comments.
5076 .Ip "\fB\-traditional-cpp\fR" 4
5077 .IX Item "-traditional-cpp"
5078 Try to imitate the behavior of old-fashioned C preprocessors, as
5079 opposed to \s-1ISO\s0 C preprocessors.
5080 .Ip "\fB\-trigraphs\fR" 4
5081 .IX Item "-trigraphs"
5082 Process trigraph sequences.
5083 These are three-character sequences, all starting with \fB??\fR, that
5084 are defined by \s-1ISO\s0 C to stand for single characters.  For example,
5085 \&\fB??/\fR stands for \fB\e\fR, so \fB'??/n'\fR is a character
5086 constant for a newline.  By default, \s-1GCC\s0 ignores trigraphs, but in
5087 standard-conforming modes it converts them.  See the \fB\-std\fR and
5088 \&\fB\-ansi\fR options.
5090 The nine trigraphs and their replacements are
5092 .Vb 2
5093 \&        Trigraph:       ??(  ??)  ??<  ??>  ??=  ??/  ??'  ??!  ??-
5094 \&        Replacement:      [    ]    {    }    #    \e    ^    |    ~
5096 .Ip "\fB\-remap\fR" 4
5097 .IX Item "-remap"
5098 Enable special code to work around file systems which only permit very
5099 short file names, such as \s-1MS-DOS\s0.
5100 .Ip "\fB\*(--help\fR" 4
5101 .IX Item "help"
5102 .PD 0
5103 .Ip "\fB\*(--target-help\fR" 4
5104 .IX Item "target-help"
5106 Print text describing all the command line options instead of
5107 preprocessing anything.
5108 .Ip "\fB\-v\fR" 4
5109 .IX Item "-v"
5110 Verbose mode.  Print out \s-1GNU\s0 \s-1CPP\s0's version number at the beginning of
5111 execution, and report the final form of the include path.
5112 .Ip "\fB\-H\fR" 4
5113 .IX Item "-H"
5114 Print the name of each header file used, in addition to other normal
5115 activities.  Each name is indented to show how deep in the
5116 \&\fB#include\fR stack it is.  Precompiled header files are also
5117 printed, even if they are found to be invalid; an invalid precompiled
5118 header file is printed with \fB...x\fR and a valid one with \fB...!\fR .
5119 .Ip "\fB\-version\fR" 4
5120 .IX Item "-version"
5121 .PD 0
5122 .Ip "\fB\*(--version\fR" 4
5123 .IX Item "version"
5125 Print out \s-1GNU\s0 \s-1CPP\s0's version number.  With one dash, proceed to
5126 preprocess as normal.  With two dashes, exit immediately.
5127 .Sh "Passing Options to the Assembler"
5128 .IX Subsection "Passing Options to the Assembler"
5129 You can pass options to the assembler.
5130 .Ip "\fB\-Wa,\fR\fIoption\fR" 4
5131 .IX Item "-Wa,option"
5132 Pass \fIoption\fR as an option to the assembler.  If \fIoption\fR
5133 contains commas, it is split into multiple options at the commas.
5134 .Ip "\fB\-Xassembler\fR \fIoption\fR" 4
5135 .IX Item "-Xassembler option"
5136 Pass \fIoption\fR as an option to the assembler.  You can use this to
5137 supply system-specific assembler options which \s-1GCC\s0 does not know how to
5138 recognize.
5140 If you want to pass an option that takes an argument, you must use
5141 \&\fB\-Xassembler\fR twice, once for the option and once for the argument.
5142 .Sh "Options for Linking"
5143 .IX Subsection "Options for Linking"
5144 These options come into play when the compiler links object files into
5145 an executable output file.  They are meaningless if the compiler is
5146 not doing a link step.
5147 .Ip "\fIobject-file-name\fR" 4
5148 .IX Item "object-file-name"
5149 A file name that does not end in a special recognized suffix is
5150 considered to name an object file or library.  (Object files are
5151 distinguished from libraries by the linker according to the file
5152 contents.)  If linking is done, these object files are used as input
5153 to the linker.
5154 .Ip "\fB\-c\fR" 4
5155 .IX Item "-c"
5156 .PD 0
5157 .Ip "\fB\-S\fR" 4
5158 .IX Item "-S"
5159 .Ip "\fB\-E\fR" 4
5160 .IX Item "-E"
5162 If any of these options is used, then the linker is not run, and
5163 object file names should not be used as arguments.  
5164 .Ip "\fB\-l\fR\fIlibrary\fR" 4
5165 .IX Item "-llibrary"
5166 .PD 0
5167 .Ip "\fB\-l\fR \fIlibrary\fR" 4
5168 .IX Item "-l library"
5170 Search the library named \fIlibrary\fR when linking.  (The second
5171 alternative with the library as a separate argument is only for
5172 \&\s-1POSIX\s0 compliance and is not recommended.)
5174 It makes a difference where in the command you write this option; the
5175 linker searches and processes libraries and object files in the order they
5176 are specified.  Thus, \fBfoo.o \-lz bar.o\fR searches library \fBz\fR
5177 after file \fIfoo.o\fR but before \fIbar.o\fR.  If \fIbar.o\fR refers
5178 to functions in \fBz\fR, those functions may not be loaded.
5180 The linker searches a standard list of directories for the library,
5181 which is actually a file named \fIlib\fIlibrary\fI.a\fR.  The linker
5182 then uses this file as if it had been specified precisely by name.
5184 The directories searched include several standard system directories
5185 plus any that you specify with \fB\-L\fR.
5187 Normally the files found this way are library files\-\-\-archive files
5188 whose members are object files.  The linker handles an archive file by
5189 scanning through it for members which define symbols that have so far
5190 been referenced but not defined.  But if the file that is found is an
5191 ordinary object file, it is linked in the usual fashion.  The only
5192 difference between using an \fB\-l\fR option and specifying a file name
5193 is that \fB\-l\fR surrounds \fIlibrary\fR with \fBlib\fR and \fB.a\fR
5194 and searches several directories.
5195 .Ip "\fB\-lobjc\fR" 4
5196 .IX Item "-lobjc"
5197 You need this special case of the \fB\-l\fR option in order to
5198 link an Objective-C program.
5199 .Ip "\fB\-nostartfiles\fR" 4
5200 .IX Item "-nostartfiles"
5201 Do not use the standard system startup files when linking.
5202 The standard system libraries are used normally, unless \fB\-nostdlib\fR
5203 or \fB\-nodefaultlibs\fR is used.
5204 .Ip "\fB\-nodefaultlibs\fR" 4
5205 .IX Item "-nodefaultlibs"
5206 Do not use the standard system libraries when linking.
5207 Only the libraries you specify will be passed to the linker.
5208 The standard startup files are used normally, unless \fB\-nostartfiles\fR
5209 is used.  The compiler may generate calls to memcmp, memset, and memcpy
5210 for System V (and \s-1ISO\s0 C) environments or to bcopy and bzero for
5211 \&\s-1BSD\s0 environments.  These entries are usually resolved by entries in
5212 libc.  These entry points should be supplied through some other
5213 mechanism when this option is specified.
5214 .Ip "\fB\-nostdlib\fR" 4
5215 .IX Item "-nostdlib"
5216 Do not use the standard system startup files or libraries when linking.
5217 No startup files and only the libraries you specify will be passed to
5218 the linker.  The compiler may generate calls to memcmp, memset, and memcpy
5219 for System V (and \s-1ISO\s0 C) environments or to bcopy and bzero for
5220 \&\s-1BSD\s0 environments.  These entries are usually resolved by entries in
5221 libc.  These entry points should be supplied through some other
5222 mechanism when this option is specified.
5224 One of the standard libraries bypassed by \fB\-nostdlib\fR and
5225 \&\fB\-nodefaultlibs\fR is \fIlibgcc.a\fR, a library of internal subroutines
5226 that \s-1GCC\s0 uses to overcome shortcomings of particular machines, or special
5227 needs for some languages.
5229 In most cases, you need \fIlibgcc.a\fR even when you want to avoid
5230 other standard libraries.  In other words, when you specify \fB\-nostdlib\fR
5231 or \fB\-nodefaultlibs\fR you should usually specify \fB\-lgcc\fR as well.
5232 This ensures that you have no unresolved references to internal \s-1GCC\s0
5233 library subroutines.  (For example, \fB_\|_main\fR, used to ensure \*(C+
5234 constructors will be called.)
5235 .Ip "\fB\-pie\fR" 4
5236 .IX Item "-pie"
5237 Produce a position independent executable on targets which support it.
5238 For predictable results, you must also specify the same set of options
5239 that were used to generate code (\fB\-fpie\fR, \fB\-fPIE\fR,
5240 or model suboptions) when you specify this option.
5241 .Ip "\fB\-s\fR" 4
5242 .IX Item "-s"
5243 Remove all symbol table and relocation information from the executable.
5244 .Ip "\fB\-static\fR" 4
5245 .IX Item "-static"
5246 On systems that support dynamic linking, this prevents linking with the shared
5247 libraries.  On other systems, this option has no effect.
5248 .Ip "\fB\-shared\fR" 4
5249 .IX Item "-shared"
5250 Produce a shared object which can then be linked with other objects to
5251 form an executable.  Not all systems support this option.  For predictable
5252 results, you must also specify the same set of options that were used to
5253 generate code (\fB\-fpic\fR, \fB\-fPIC\fR, or model suboptions)
5254 when you specify this option.[1]
5255 .Ip "\fB\-shared-libgcc\fR" 4
5256 .IX Item "-shared-libgcc"
5257 .PD 0
5258 .Ip "\fB\-static-libgcc\fR" 4
5259 .IX Item "-static-libgcc"
5261 On systems that provide \fIlibgcc\fR as a shared library, these options
5262 force the use of either the shared or static version respectively.
5263 If no shared version of \fIlibgcc\fR was built when the compiler was
5264 configured, these options have no effect.
5266 There are several situations in which an application should use the
5267 shared \fIlibgcc\fR instead of the static version.  The most common
5268 of these is when the application wishes to throw and catch exceptions
5269 across different shared libraries.  In that case, each of the libraries
5270 as well as the application itself should use the shared \fIlibgcc\fR.
5272 Therefore, the G++ and \s-1GCJ\s0 drivers automatically add
5273 \&\fB\-shared-libgcc\fR whenever you build a shared library or a main
5274 executable, because \*(C+ and Java programs typically use exceptions, so
5275 this is the right thing to do.
5277 If, instead, you use the \s-1GCC\s0 driver to create shared libraries, you may
5278 find that they will not always be linked with the shared \fIlibgcc\fR.
5279 If \s-1GCC\s0 finds, at its configuration time, that you have a non-GNU linker
5280 or a \s-1GNU\s0 linker that does not support option \fB\*(--eh-frame-hdr\fR,
5281 it will link the shared version of \fIlibgcc\fR into shared libraries
5282 by default.  Otherwise, it will take advantage of the linker and optimize
5283 away the linking with the shared version of \fIlibgcc\fR, linking with
5284 the static version of libgcc by default.  This allows exceptions to
5285 propagate through such shared libraries, without incurring relocation
5286 costs at library load time.
5288 However, if a library or main executable is supposed to throw or catch
5289 exceptions, you must link it using the G++ or \s-1GCJ\s0 driver, as appropriate
5290 for the languages used in the program, or using the option
5291 \&\fB\-shared-libgcc\fR, such that it is linked with the shared
5292 \&\fIlibgcc\fR.
5293 .Ip "\fB\-symbolic\fR" 4
5294 .IX Item "-symbolic"
5295 Bind references to global symbols when building a shared object.  Warn
5296 about any unresolved references (unless overridden by the link editor
5297 option \fB\-Xlinker \-z \-Xlinker defs\fR).  Only a few systems support
5298 this option.
5299 .Ip "\fB\-Xlinker\fR \fIoption\fR" 4
5300 .IX Item "-Xlinker option"
5301 Pass \fIoption\fR as an option to the linker.  You can use this to
5302 supply system-specific linker options which \s-1GCC\s0 does not know how to
5303 recognize.
5305 If you want to pass an option that takes an argument, you must use
5306 \&\fB\-Xlinker\fR twice, once for the option and once for the argument.
5307 For example, to pass \fB\-assert definitions\fR, you must write
5308 \&\fB\-Xlinker \-assert \-Xlinker definitions\fR.  It does not work to write
5309 \&\fB\-Xlinker \*(L"\-assert definitions\*(R"\fR, because this passes the entire
5310 string as a single argument, which is not what the linker expects.
5311 .Ip "\fB\-Wl,\fR\fIoption\fR" 4
5312 .IX Item "-Wl,option"
5313 Pass \fIoption\fR as an option to the linker.  If \fIoption\fR contains
5314 commas, it is split into multiple options at the commas.
5315 .Ip "\fB\-u\fR \fIsymbol\fR" 4
5316 .IX Item "-u symbol"
5317 Pretend the symbol \fIsymbol\fR is undefined, to force linking of
5318 library modules to define it.  You can use \fB\-u\fR multiple times with
5319 different symbols to force loading of additional library modules.
5320 .Sh "Options for Directory Search"
5321 .IX Subsection "Options for Directory Search"
5322 These options specify directories to search for header files, for
5323 libraries and for parts of the compiler:
5324 .Ip "\fB\-I\fR\fIdir\fR" 4
5325 .IX Item "-Idir"
5326 Add the directory \fIdir\fR to the head of the list of directories to be
5327 searched for header files.  This can be used to override a system header
5328 file, substituting your own version, since these directories are
5329 searched before the system header file directories.  However, you should
5330 not use this option to add directories that contain vendor-supplied
5331 system header files (use \fB\-isystem\fR for that).  If you use more than
5332 one \fB\-I\fR option, the directories are scanned in left-to-right
5333 order; the standard system directories come after.
5335 If a standard system include directory, or a directory specified with
5336 \&\fB\-isystem\fR, is also specified with \fB\-I\fR, the \fB\-I\fR
5337 option will be ignored.  The directory will still be searched but as a
5338 system directory at its normal position in the system include chain.
5339 This is to ensure that \s-1GCC\s0's procedure to fix buggy system headers and
5340 the ordering for the include_next directive are not inadvertently changed.
5341 If you really need to change the search order for system directories,
5342 use the \fB\-nostdinc\fR and/or \fB\-isystem\fR options.
5343 .Ip "\fB\-I-\fR" 4
5344 .IX Item "-I-"
5345 Any directories you specify with \fB\-I\fR options before the \fB\-I-\fR
5346 option are searched only for the case of \fB#include "\fR\fIfile\fR\fB"\fR;
5347 they are not searched for \fB#include <\fR\fIfile\fR\fB>\fR.
5349 If additional directories are specified with \fB\-I\fR options after
5350 the \fB\-I-\fR, these directories are searched for all \fB#include\fR
5351 directives.  (Ordinarily \fIall\fR \fB\-I\fR directories are used
5352 this way.)
5354 In addition, the \fB\-I-\fR option inhibits the use of the current
5355 directory (where the current input file came from) as the first search
5356 directory for \fB#include "\fR\fIfile\fR\fB"\fR.  There is no way to
5357 override this effect of \fB\-I-\fR.  With \fB\-I.\fR you can specify
5358 searching the directory which was current when the compiler was
5359 invoked.  That is not exactly the same as what the preprocessor does
5360 by default, but it is often satisfactory.
5362 \&\fB\-I-\fR does not inhibit the use of the standard system directories
5363 for header files.  Thus, \fB\-I-\fR and \fB\-nostdinc\fR are
5364 independent.
5365 .Ip "\fB\-L\fR\fIdir\fR" 4
5366 .IX Item "-Ldir"
5367 Add directory \fIdir\fR to the list of directories to be searched
5368 for \fB\-l\fR.
5369 .Ip "\fB\-B\fR\fIprefix\fR" 4
5370 .IX Item "-Bprefix"
5371 This option specifies where to find the executables, libraries,
5372 include files, and data files of the compiler itself.
5374 The compiler driver program runs one or more of the subprograms
5375 \&\fIcpp\fR, \fIcc1\fR, \fIas\fR and \fIld\fR.  It tries
5376 \&\fIprefix\fR as a prefix for each program it tries to run, both with and
5377 without \fImachine\fR\fB/\fR\fIversion\fR\fB/\fR.
5379 For each subprogram to be run, the compiler driver first tries the
5380 \&\fB\-B\fR prefix, if any.  If that name is not found, or if \fB\-B\fR
5381 was not specified, the driver tries two standard prefixes, which are
5382 \&\fI/usr/lib/gcc/\fR and \fI/usr/local/lib/gcc/\fR.  If neither of
5383 those results in a file name that is found, the unmodified program
5384 name is searched for using the directories specified in your
5385 \&\fB\s-1PATH\s0\fR environment variable.
5387 The compiler will check to see if the path provided by the \fB\-B\fR
5388 refers to a directory, and if necessary it will add a directory
5389 separator character at the end of the path.
5391 \&\fB\-B\fR prefixes that effectively specify directory names also apply
5392 to libraries in the linker, because the compiler translates these
5393 options into \fB\-L\fR options for the linker.  They also apply to
5394 includes files in the preprocessor, because the compiler translates these
5395 options into \fB\-isystem\fR options for the preprocessor.  In this case,
5396 the compiler appends \fBinclude\fR to the prefix.
5398 The run-time support file \fIlibgcc.a\fR can also be searched for using
5399 the \fB\-B\fR prefix, if needed.  If it is not found there, the two
5400 standard prefixes above are tried, and that is all.  The file is left
5401 out of the link if it is not found by those means.
5403 Another way to specify a prefix much like the \fB\-B\fR prefix is to use
5404 the environment variable \fB\s-1GCC_EXEC_PREFIX\s0\fR.  
5406 As a special kludge, if the path provided by \fB\-B\fR is
5407 \&\fI[dir/]stage\fIN\fI/\fR, where \fIN\fR is a number in the range 0 to
5408 9, then it will be replaced by \fI[dir/]include\fR.  This is to help
5409 with boot-strapping the compiler.
5410 .Ip "\fB\-specs=\fR\fIfile\fR" 4
5411 .IX Item "-specs=file"
5412 Process \fIfile\fR after the compiler reads in the standard \fIspecs\fR
5413 file, in order to override the defaults that the \fIgcc\fR driver
5414 program uses when determining what switches to pass to \fIcc1\fR,
5415 \&\fIcc1plus\fR, \fIas\fR, \fIld\fR, etc.  More than one
5416 \&\fB\-specs=\fR\fIfile\fR can be specified on the command line, and they
5417 are processed in order, from left to right.
5418 .Sh "Specifying Target Machine and Compiler Version"
5419 .IX Subsection "Specifying Target Machine and Compiler Version"
5420 The usual way to run \s-1GCC\s0 is to run the executable called \fIgcc\fR, or
5421 \&\fI<machine>\-gcc\fR when cross-compiling, or
5422 \&\fI<machine>\-gcc-<version>\fR to run a version other than the one that
5423 was installed last.  Sometimes this is inconvenient, so \s-1GCC\s0 provides
5424 options that will switch to another cross-compiler or version.
5425 .Ip "\fB\-b\fR \fImachine\fR" 4
5426 .IX Item "-b machine"
5427 The argument \fImachine\fR specifies the target machine for compilation.
5429 The value to use for \fImachine\fR is the same as was specified as the
5430 machine type when configuring \s-1GCC\s0 as a cross-compiler.  For
5431 example, if a cross-compiler was configured with \fBconfigure
5432 i386v\fR, meaning to compile for an 80386 running System V, then you
5433 would specify \fB\-b i386v\fR to run that cross compiler.
5434 .Ip "\fB\-V\fR \fIversion\fR" 4
5435 .IX Item "-V version"
5436 The argument \fIversion\fR specifies which version of \s-1GCC\s0 to run.
5437 This is useful when multiple versions are installed.  For example,
5438 \&\fIversion\fR might be \fB2.0\fR, meaning to run \s-1GCC\s0 version 2.0.
5440 The \fB\-V\fR and \fB\-b\fR options work by running the
5441 \&\fI<machine>\-gcc-<version>\fR executable, so there's no real reason to
5442 use them if you can just run that directly.
5443 .Sh "Hardware Models and Configurations"
5444 .IX Subsection "Hardware Models and Configurations"
5445 Earlier we discussed the standard option \fB\-b\fR which chooses among
5446 different installed compilers for completely different target
5447 machines, such as \s-1VAX\s0 vs. 68000 vs. 80386.
5449 In addition, each of these target machine types can have its own
5450 special options, starting with \fB\-m\fR, to choose among various
5451 hardware models or configurations\-\-\-for example, 68010 vs 68020,
5452 floating coprocessor or none.  A single installed version of the
5453 compiler can compile for any model or configuration, according to the
5454 options specified.
5456 Some configurations of the compiler also support additional special
5457 options, usually for compatibility with other compilers on the same
5458 platform.
5460 These options are defined by the macro \f(CW\*(C`TARGET_SWITCHES\*(C'\fR in the
5461 machine description.  The default for the options is also defined by
5462 that macro, which enables you to change the defaults.
5464 .I "M680x0 Options"
5465 .IX Subsection "M680x0 Options"
5467 These are the \fB\-m\fR options defined for the 68000 series.  The default
5468 values for these options depends on which style of 68000 was selected when
5469 the compiler was configured; the defaults for the most common choices are
5470 given below.
5471 .Ip "\fB\-m68000\fR" 4
5472 .IX Item "-m68000"
5473 .PD 0
5474 .Ip "\fB\-mc68000\fR" 4
5475 .IX Item "-mc68000"
5477 Generate output for a 68000.  This is the default
5478 when the compiler is configured for 68000\-based systems.
5480 Use this option for microcontrollers with a 68000 or \s-1EC000\s0 core,
5481 including the 68008, 68302, 68306, 68307, 68322, 68328 and 68356.
5482 .Ip "\fB\-m68020\fR" 4
5483 .IX Item "-m68020"
5484 .PD 0
5485 .Ip "\fB\-mc68020\fR" 4
5486 .IX Item "-mc68020"
5488 Generate output for a 68020.  This is the default
5489 when the compiler is configured for 68020\-based systems.
5490 .Ip "\fB\-m68881\fR" 4
5491 .IX Item "-m68881"
5492 Generate output containing 68881 instructions for floating point.
5493 This is the default for most 68020 systems unless \fB\*(--nfp\fR was
5494 specified when the compiler was configured.
5495 .Ip "\fB\-m68030\fR" 4
5496 .IX Item "-m68030"
5497 Generate output for a 68030.  This is the default when the compiler is
5498 configured for 68030\-based systems.
5499 .Ip "\fB\-m68040\fR" 4
5500 .IX Item "-m68040"
5501 Generate output for a 68040.  This is the default when the compiler is
5502 configured for 68040\-based systems.
5504 This option inhibits the use of 68881/68882 instructions that have to be
5505 emulated by software on the 68040.  Use this option if your 68040 does not
5506 have code to emulate those instructions.
5507 .Ip "\fB\-m68060\fR" 4
5508 .IX Item "-m68060"
5509 Generate output for a 68060.  This is the default when the compiler is
5510 configured for 68060\-based systems.
5512 This option inhibits the use of 68020 and 68881/68882 instructions that
5513 have to be emulated by software on the 68060.  Use this option if your 68060
5514 does not have code to emulate those instructions.
5515 .Ip "\fB\-mcpu32\fR" 4
5516 .IX Item "-mcpu32"
5517 Generate output for a \s-1CPU32\s0.  This is the default
5518 when the compiler is configured for CPU32\-based systems.
5520 Use this option for microcontrollers with a
5521 \&\s-1CPU32\s0 or \s-1CPU32+\s0 core, including the 68330, 68331, 68332, 68333, 68334,
5522 68336, 68340, 68341, 68349 and 68360.
5523 .Ip "\fB\-m5200\fR" 4
5524 .IX Item "-m5200"
5525 Generate output for a 520X ``coldfire'' family cpu.  This is the default
5526 when the compiler is configured for 520X-based systems.
5528 Use this option for microcontroller with a 5200 core, including
5529 the \s-1MCF5202\s0, \s-1MCF5203\s0, \s-1MCF5204\s0 and \s-1MCF5202\s0.
5530 .Ip "\fB\-m68020\-40\fR" 4
5531 .IX Item "-m68020-40"
5532 Generate output for a 68040, without using any of the new instructions.
5533 This results in code which can run relatively efficiently on either a
5534 68020/68881 or a 68030 or a 68040.  The generated code does use the
5535 68881 instructions that are emulated on the 68040.
5536 .Ip "\fB\-m68020\-60\fR" 4
5537 .IX Item "-m68020-60"
5538 Generate output for a 68060, without using any of the new instructions.
5539 This results in code which can run relatively efficiently on either a
5540 68020/68881 or a 68030 or a 68040.  The generated code does use the
5541 68881 instructions that are emulated on the 68060.
5542 .Ip "\fB\-msoft-float\fR" 4
5543 .IX Item "-msoft-float"
5544 Generate output containing library calls for floating point.
5545 \&\fBWarning:\fR the requisite libraries are not available for all m68k
5546 targets.  Normally the facilities of the machine's usual C compiler are
5547 used, but this can't be done directly in cross-compilation.  You must
5548 make your own arrangements to provide suitable library functions for
5549 cross-compilation.  The embedded targets \fBm68k-*\-aout\fR and
5550 \&\fBm68k-*\-coff\fR do provide software floating point support.
5551 .Ip "\fB\-mshort\fR" 4
5552 .IX Item "-mshort"
5553 Consider type \f(CW\*(C`int\*(C'\fR to be 16 bits wide, like \f(CW\*(C`short int\*(C'\fR.
5554 .Ip "\fB\-mnobitfield\fR" 4
5555 .IX Item "-mnobitfield"
5556 Do not use the bit-field instructions.  The \fB\-m68000\fR, \fB\-mcpu32\fR
5557 and \fB\-m5200\fR options imply \fB\-mnobitfield\fR.
5558 .Ip "\fB\-mbitfield\fR" 4
5559 .IX Item "-mbitfield"
5560 Do use the bit-field instructions.  The \fB\-m68020\fR option implies
5561 \&\fB\-mbitfield\fR.  This is the default if you use a configuration
5562 designed for a 68020.
5563 .Ip "\fB\-mrtd\fR" 4
5564 .IX Item "-mrtd"
5565 Use a different function-calling convention, in which functions
5566 that take a fixed number of arguments return with the \f(CW\*(C`rtd\*(C'\fR
5567 instruction, which pops their arguments while returning.  This
5568 saves one instruction in the caller since there is no need to pop
5569 the arguments there.
5571 \&\fBWarning:\fR this calling convention is incompatible with the
5572 one normally used on Unix or with \s-1GCC\s0, so you cannot use it if you
5573 need to call libraries compiled with the Unix compiler or with \s-1GCC\s0
5574 without the switch.
5576 Also, you must provide function prototypes for all functions that
5577 take variable numbers of arguments (including \f(CW\*(C`printf\*(C'\fR);
5578 otherwise incorrect code will be generated for calls to those
5579 functions.
5581 In addition, seriously incorrect code will result if you call a
5582 function with too many arguments.  (Normally, extra arguments are
5583 harmlessly ignored.)
5585 The \f(CW\*(C`rtd\*(C'\fR instruction is supported by the 68010, 68020, 68030,
5586 68040, 68060 and \s-1CPU32\s0 processors, but not by the 68000 or 5200.
5587 .Ip "\fB\-malign-int\fR" 4
5588 .IX Item "-malign-int"
5589 .PD 0
5590 .Ip "\fB\-mno-align-int\fR" 4
5591 .IX Item "-mno-align-int"
5593 Control whether \s-1GCC\s0 aligns \f(CW\*(C`int\*(C'\fR, \f(CW\*(C`long\*(C'\fR, \f(CW\*(C`long long\*(C'\fR,
5594 \&\f(CW\*(C`float\*(C'\fR, \f(CW\*(C`double\*(C'\fR, and \f(CW\*(C`long double\*(C'\fR variables on a 32\-bit
5595 boundary (\fB\-malign-int\fR) or a 16\-bit boundary (\fB\-mno-align-int\fR).
5596 Aligning variables on 32\-bit boundaries produces code that runs somewhat
5597 faster on processors with 32\-bit busses at the expense of more memory.
5599 \&\fBWarning:\fR if you use the \fB\-malign-int\fR switch, \s-1GCC\s0 will
5600 align structures containing the above types  differently than
5601 most published application binary interface specifications for the m68k.
5602 .Ip "\fB\-mpcrel\fR" 4
5603 .IX Item "-mpcrel"
5604 Use the pc-relative addressing mode of the 68000 directly, instead of
5605 using a global offset table.  At present, this option implies \fB\-fpic\fR,
5606 allowing at most a 16\-bit offset for pc-relative addressing.  \fB\-fPIC\fR is
5607 not presently supported with \fB\-mpcrel\fR, though this could be supported for
5608 68020 and higher processors.
5609 .Ip "\fB\-mno-strict-align\fR" 4
5610 .IX Item "-mno-strict-align"
5611 .PD 0
5612 .Ip "\fB\-mstrict-align\fR" 4
5613 .IX Item "-mstrict-align"
5615 Do not (do) assume that unaligned memory references will be handled by
5616 the system.
5617 .Ip "\fB\-msep-data\fR" 4
5618 .IX Item "-msep-data"
5619 Generate code that allows the data segment to be located in a different
5620 area of memory from the text segment.  This allows for execute in place in
5621 an environment without virtual memory management.  This option implies \-fPIC.
5622 .Ip "\fB\-mno-sep-data\fR" 4
5623 .IX Item "-mno-sep-data"
5624 Generate code that assumes that the data segment follows the text segment.
5625 This is the default.
5626 .Ip "\fB\-mid-shared-library\fR" 4
5627 .IX Item "-mid-shared-library"
5628 Generate code that supports shared libraries via the library \s-1ID\s0 method.
5629 This allows for execute in place and shared libraries in an environment
5630 without virtual memory management.  This option implies \-fPIC.
5631 .Ip "\fB\-mno-id-shared-library\fR" 4
5632 .IX Item "-mno-id-shared-library"
5633 Generate code that doesn't assume \s-1ID\s0 based shared libraries are being used.
5634 This is the default.
5635 .Ip "\fB\-mshared-library-id=n\fR" 4
5636 .IX Item "-mshared-library-id=n"
5637 Specified the identification number of the \s-1ID\s0 based shared library being
5638 compiled.  Specifying a value of 0 will generate more compact code, specifying
5639 other values will force the allocation of that number to the current
5640 library but is no more space or time efficient than omitting this option.
5642 .I "M68hc1x Options"
5643 .IX Subsection "M68hc1x Options"
5645 These are the \fB\-m\fR options defined for the 68hc11 and 68hc12
5646 microcontrollers.  The default values for these options depends on
5647 which style of microcontroller was selected when the compiler was configured;
5648 the defaults for the most common choices are given below.
5649 .Ip "\fB\-m6811\fR" 4
5650 .IX Item "-m6811"
5651 .PD 0
5652 .Ip "\fB\-m68hc11\fR" 4
5653 .IX Item "-m68hc11"
5655 Generate output for a 68HC11.  This is the default
5656 when the compiler is configured for 68HC11\-based systems.
5657 .Ip "\fB\-m6812\fR" 4
5658 .IX Item "-m6812"
5659 .PD 0
5660 .Ip "\fB\-m68hc12\fR" 4
5661 .IX Item "-m68hc12"
5663 Generate output for a 68HC12.  This is the default
5664 when the compiler is configured for 68HC12\-based systems.
5665 .Ip "\fB\-m68S12\fR" 4
5666 .IX Item "-m68S12"
5667 .PD 0
5668 .Ip "\fB\-m68hcs12\fR" 4
5669 .IX Item "-m68hcs12"
5671 Generate output for a 68HCS12.
5672 .Ip "\fB\-mauto-incdec\fR" 4
5673 .IX Item "-mauto-incdec"
5674 Enable the use of 68HC12 pre and post auto-increment and auto-decrement
5675 addressing modes.
5676 .Ip "\fB\-minmax\fR" 4
5677 .IX Item "-minmax"
5678 .PD 0
5679 .Ip "\fB\-nominmax\fR" 4
5680 .IX Item "-nominmax"
5682 Enable the use of 68HC12 min and max instructions.
5683 .Ip "\fB\-mlong-calls\fR" 4
5684 .IX Item "-mlong-calls"
5685 .PD 0
5686 .Ip "\fB\-mno-long-calls\fR" 4
5687 .IX Item "-mno-long-calls"
5689 Treat all calls as being far away (near).  If calls are assumed to be
5690 far away, the compiler will use the \f(CW\*(C`call\*(C'\fR instruction to
5691 call a function and the \f(CW\*(C`rtc\*(C'\fR instruction for returning.
5692 .Ip "\fB\-mshort\fR" 4
5693 .IX Item "-mshort"
5694 Consider type \f(CW\*(C`int\*(C'\fR to be 16 bits wide, like \f(CW\*(C`short int\*(C'\fR.
5695 .Ip "\fB\-msoft-reg-count=\fR\fIcount\fR" 4
5696 .IX Item "-msoft-reg-count=count"
5697 Specify the number of pseudo-soft registers which are used for the
5698 code generation.  The maximum number is 32.  Using more pseudo-soft
5699 register may or may not result in better code depending on the program.
5700 The default is 4 for 68HC11 and 2 for 68HC12.
5702 .I "\s-1VAX\s0 Options"
5703 .IX Subsection "VAX Options"
5705 These \fB\-m\fR options are defined for the \s-1VAX:\s0
5706 .Ip "\fB\-munix\fR" 4
5707 .IX Item "-munix"
5708 Do not output certain jump instructions (\f(CW\*(C`aobleq\*(C'\fR and so on)
5709 that the Unix assembler for the \s-1VAX\s0 cannot handle across long
5710 ranges.
5711 .Ip "\fB\-mgnu\fR" 4
5712 .IX Item "-mgnu"
5713 Do output those jump instructions, on the assumption that you
5714 will assemble with the \s-1GNU\s0 assembler.
5715 .Ip "\fB\-mg\fR" 4
5716 .IX Item "-mg"
5717 Output code for g-format floating point numbers instead of d-format.
5719 .I "\s-1SPARC\s0 Options"
5720 .IX Subsection "SPARC Options"
5722 These \fB\-m\fR options are supported on the \s-1SPARC:\s0
5723 .Ip "\fB\-mno-app-regs\fR" 4
5724 .IX Item "-mno-app-regs"
5725 .PD 0
5726 .Ip "\fB\-mapp-regs\fR" 4
5727 .IX Item "-mapp-regs"
5729 Specify \fB\-mapp-regs\fR to generate output using the global registers
5730 2 through 4, which the \s-1SPARC\s0 \s-1SVR4\s0 \s-1ABI\s0 reserves for applications.  This
5731 is the default.
5733 To be fully \s-1SVR4\s0 \s-1ABI\s0 compliant at the cost of some performance loss,
5734 specify \fB\-mno-app-regs\fR.  You should compile libraries and system
5735 software with this option.
5736 .Ip "\fB\-mfpu\fR" 4
5737 .IX Item "-mfpu"
5738 .PD 0
5739 .Ip "\fB\-mhard-float\fR" 4
5740 .IX Item "-mhard-float"
5742 Generate output containing floating point instructions.  This is the
5743 default.
5744 .Ip "\fB\-mno-fpu\fR" 4
5745 .IX Item "-mno-fpu"
5746 .PD 0
5747 .Ip "\fB\-msoft-float\fR" 4
5748 .IX Item "-msoft-float"
5750 Generate output containing library calls for floating point.
5751 \&\fBWarning:\fR the requisite libraries are not available for all \s-1SPARC\s0
5752 targets.  Normally the facilities of the machine's usual C compiler are
5753 used, but this cannot be done directly in cross-compilation.  You must make
5754 your own arrangements to provide suitable library functions for
5755 cross-compilation.  The embedded targets \fBsparc-*\-aout\fR and
5756 \&\fBsparclite-*\-*\fR do provide software floating point support.
5758 \&\fB\-msoft-float\fR changes the calling convention in the output file;
5759 therefore, it is only useful if you compile \fIall\fR of a program with
5760 this option.  In particular, you need to compile \fIlibgcc.a\fR, the
5761 library that comes with \s-1GCC\s0, with \fB\-msoft-float\fR in order for
5762 this to work.
5763 .Ip "\fB\-mhard-quad-float\fR" 4
5764 .IX Item "-mhard-quad-float"
5765 Generate output containing quad-word (long double) floating point
5766 instructions.
5767 .Ip "\fB\-msoft-quad-float\fR" 4
5768 .IX Item "-msoft-quad-float"
5769 Generate output containing library calls for quad-word (long double)
5770 floating point instructions.  The functions called are those specified
5771 in the \s-1SPARC\s0 \s-1ABI\s0.  This is the default.
5773 As of this writing, there are no \s-1SPARC\s0 implementations that have hardware
5774 support for the quad-word floating point instructions.  They all invoke
5775 a trap handler for one of these instructions, and then the trap handler
5776 emulates the effect of the instruction.  Because of the trap handler overhead,
5777 this is much slower than calling the \s-1ABI\s0 library routines.  Thus the
5778 \&\fB\-msoft-quad-float\fR option is the default.
5779 .Ip "\fB\-mno-flat\fR" 4
5780 .IX Item "-mno-flat"
5781 .PD 0
5782 .Ip "\fB\-mflat\fR" 4
5783 .IX Item "-mflat"
5785 With \fB\-mflat\fR, the compiler does not generate save/restore instructions
5786 and will use a ``flat'' or single register window calling convention.
5787 This model uses \f(CW%i7\fR as the frame pointer and is compatible with the normal
5788 register window model.  Code from either may be intermixed.
5789 The local registers and the input registers (0\*(--5) are still treated as
5790 ``call saved'' registers and will be saved on the stack as necessary.
5792 With \fB\-mno-flat\fR (the default), the compiler emits save/restore
5793 instructions (except for leaf functions) and is the normal mode of operation.
5795 These options are deprecated and will be deleted in a future \s-1GCC\s0 release.
5796 .Ip "\fB\-mno-unaligned-doubles\fR" 4
5797 .IX Item "-mno-unaligned-doubles"
5798 .PD 0
5799 .Ip "\fB\-munaligned-doubles\fR" 4
5800 .IX Item "-munaligned-doubles"
5802 Assume that doubles have 8 byte alignment.  This is the default.
5804 With \fB\-munaligned-doubles\fR, \s-1GCC\s0 assumes that doubles have 8 byte
5805 alignment only if they are contained in another type, or if they have an
5806 absolute address.  Otherwise, it assumes they have 4 byte alignment.
5807 Specifying this option avoids some rare compatibility problems with code
5808 generated by other compilers.  It is not the default because it results
5809 in a performance loss, especially for floating point code.
5810 .Ip "\fB\-mno-faster-structs\fR" 4
5811 .IX Item "-mno-faster-structs"
5812 .PD 0
5813 .Ip "\fB\-mfaster-structs\fR" 4
5814 .IX Item "-mfaster-structs"
5816 With \fB\-mfaster-structs\fR, the compiler assumes that structures
5817 should have 8 byte alignment.  This enables the use of pairs of
5818 \&\f(CW\*(C`ldd\*(C'\fR and \f(CW\*(C`std\*(C'\fR instructions for copies in structure
5819 assignment, in place of twice as many \f(CW\*(C`ld\*(C'\fR and \f(CW\*(C`st\*(C'\fR pairs.
5820 However, the use of this changed alignment directly violates the \s-1SPARC\s0
5821 \&\s-1ABI\s0.  Thus, it's intended only for use on targets where the developer
5822 acknowledges that their resulting code will not be directly in line with
5823 the rules of the \s-1ABI\s0.
5824 .Ip "\fB\-mimpure-text\fR" 4
5825 .IX Item "-mimpure-text"
5826 \&\fB\-mimpure-text\fR, used in addition to \fB\-shared\fR, tells
5827 the compiler to not pass \fB\-z text\fR to the linker when linking a
5828 shared object.  Using this option, you can link position-dependent
5829 code into a shared object.
5831 \&\fB\-mimpure-text\fR suppresses the ``relocations remain against
5832 allocatable but non-writable sections'' linker error message.
5833 However, the necessary relocations will trigger copy-on-write, and the
5834 shared object is not actually shared across processes.  Instead of
5835 using \fB\-mimpure-text\fR, you should compile all source code with
5836 \&\fB\-fpic\fR or \fB\-fPIC\fR.
5838 This option is only available on SunOS and Solaris.
5839 .Ip "\fB\-mv8\fR" 4
5840 .IX Item "-mv8"
5841 .PD 0
5842 .Ip "\fB\-msparclite\fR" 4
5843 .IX Item "-msparclite"
5845 These two options select variations on the \s-1SPARC\s0 architecture.
5846 These options are deprecated and will be deleted in a future \s-1GCC\s0 release.
5847 They have been replaced with \fB\-mcpu=xxx\fR.
5848 .Ip "\fB\-mcypress\fR" 4
5849 .IX Item "-mcypress"
5850 .PD 0
5851 .Ip "\fB\-msupersparc\fR" 4
5852 .IX Item "-msupersparc"
5853 .Ip "\fB\-mf930\fR" 4
5854 .IX Item "-mf930"
5855 .Ip "\fB\-mf934\fR" 4
5856 .IX Item "-mf934"
5858 These four options select the processor for which the code is optimized.
5859 These options are deprecated and will be deleted in a future \s-1GCC\s0 release.
5860 They have been replaced with \fB\-mcpu=xxx\fR.
5861 .Ip "\fB\-mcpu=\fR\fIcpu_type\fR" 4
5862 .IX Item "-mcpu=cpu_type"
5863 Set the instruction set, register set, and instruction scheduling parameters
5864 for machine type \fIcpu_type\fR.  Supported values for \fIcpu_type\fR are
5865 \&\fBv7\fR, \fBcypress\fR, \fBv8\fR, \fBsupersparc\fR, \fBsparclite\fR,
5866 \&\fBf930\fR, \fBf934\fR, \fBhypersparc\fR, \fBsparclite86x\fR,
5867 \&\fBsparclet\fR, \fBtsc701\fR, \fBv9\fR, \fBultrasparc\fR, and
5868 \&\fBultrasparc3\fR.
5870 Default instruction scheduling parameters are used for values that select
5871 an architecture and not an implementation.  These are \fBv7\fR, \fBv8\fR,
5872 \&\fBsparclite\fR, \fBsparclet\fR, \fBv9\fR.
5874 Here is a list of each supported architecture and their supported
5875 implementations.
5877 .Vb 5
5878 \&            v7:             cypress
5879 \&            v8:             supersparc, hypersparc
5880 \&            sparclite:      f930, f934, sparclite86x
5881 \&            sparclet:       tsc701
5882 \&            v9:             ultrasparc, ultrasparc3
5884 By default (unless configured otherwise), \s-1GCC\s0 generates code for the V7
5885 variant of the \s-1SPARC\s0 architecture.  With \fB\-mcpu=cypress\fR, the compiler
5886 additionally optimizes it for the Cypress \s-1CY7C602\s0 chip, as used in the
5887 SPARCStation/SPARCServer 3xx series.  This is also appropriate for the older
5888 SPARCStation 1, 2, \s-1IPX\s0 etc.
5890 With \fB\-mcpu=v8\fR, \s-1GCC\s0 generates code for the V8 variant of the \s-1SPARC\s0
5891 architecture.  The only difference from V7 code is that the compiler emits
5892 the integer multiply and integer divide instructions which exist in \s-1SPARC-V8\s0
5893 but not in \s-1SPARC-V7\s0.  With \fB\-mcpu=supersparc\fR, the compiler additionally
5894 optimizes it for the SuperSPARC chip, as used in the SPARCStation 10, 1000 and
5895 2000 series.
5897 With \fB\-mcpu=sparclite\fR, \s-1GCC\s0 generates code for the SPARClite variant of
5898 the \s-1SPARC\s0 architecture.  This adds the integer multiply, integer divide step
5899 and scan (\f(CW\*(C`ffs\*(C'\fR) instructions which exist in SPARClite but not in \s-1SPARC-V7\s0.
5900 With \fB\-mcpu=f930\fR, the compiler additionally optimizes it for the
5901 Fujitsu \s-1MB86930\s0 chip, which is the original SPARClite, with no \s-1FPU\s0.  With
5902 \&\fB\-mcpu=f934\fR, the compiler additionally optimizes it for the Fujitsu
5903 \&\s-1MB86934\s0 chip, which is the more recent SPARClite with \s-1FPU\s0.
5905 With \fB\-mcpu=sparclet\fR, \s-1GCC\s0 generates code for the SPARClet variant of
5906 the \s-1SPARC\s0 architecture.  This adds the integer multiply, multiply/accumulate,
5907 integer divide step and scan (\f(CW\*(C`ffs\*(C'\fR) instructions which exist in SPARClet
5908 but not in \s-1SPARC-V7\s0.  With \fB\-mcpu=tsc701\fR, the compiler additionally
5909 optimizes it for the \s-1TEMIC\s0 SPARClet chip.
5911 With \fB\-mcpu=v9\fR, \s-1GCC\s0 generates code for the V9 variant of the \s-1SPARC\s0
5912 architecture.  This adds 64\-bit integer and floating-point move instructions,
5913 3 additional floating-point condition code registers and conditional move
5914 instructions.  With \fB\-mcpu=ultrasparc\fR, the compiler additionally
5915 optimizes it for the Sun UltraSPARC I/II chips.  With
5916 \&\fB\-mcpu=ultrasparc3\fR, the compiler additionally optimizes it for the
5917 Sun UltraSPARC \s-1III\s0 chip.
5918 .Ip "\fB\-mtune=\fR\fIcpu_type\fR" 4
5919 .IX Item "-mtune=cpu_type"
5920 Set the instruction scheduling parameters for machine type
5921 \&\fIcpu_type\fR, but do not set the instruction set or register set that the
5922 option \fB\-mcpu=\fR\fIcpu_type\fR would.
5924 The same values for \fB\-mcpu=\fR\fIcpu_type\fR can be used for
5925 \&\fB\-mtune=\fR\fIcpu_type\fR, but the only useful values are those
5926 that select a particular cpu implementation.  Those are \fBcypress\fR,
5927 \&\fBsupersparc\fR, \fBhypersparc\fR, \fBf930\fR, \fBf934\fR,
5928 \&\fBsparclite86x\fR, \fBtsc701\fR, \fBultrasparc\fR, and
5929 \&\fBultrasparc3\fR.
5930 .Ip "\fB\-mv8plus\fR" 4
5931 .IX Item "-mv8plus"
5932 .PD 0
5933 .Ip "\fB\-mno-v8plus\fR" 4
5934 .IX Item "-mno-v8plus"
5936 With \fB\-mv8plus\fR, \s-1GCC\s0 generates code for the \s-1SPARC-V8+\s0 \s-1ABI\s0.  The
5937 difference from the V8 \s-1ABI\s0 is that the global and out registers are
5938 considered 64\-bit wide.  This is enabled by default on Solaris in 32\-bit
5939 mode for all \s-1SPARC-V9\s0 processors.
5940 .Ip "\fB\-mvis\fR" 4
5941 .IX Item "-mvis"
5942 .PD 0
5943 .Ip "\fB\-mno-vis\fR" 4
5944 .IX Item "-mno-vis"
5946 With \fB\-mvis\fR, \s-1GCC\s0 generates code that takes advantage of the UltraSPARC
5947 Visual Instruction Set extensions.  The default is \fB\-mno-vis\fR.
5949 These \fB\-m\fR options are supported in addition to the above
5950 on \s-1SPARC-V9\s0 processors in 64\-bit environments:
5951 .Ip "\fB\-mlittle-endian\fR" 4
5952 .IX Item "-mlittle-endian"
5953 Generate code for a processor running in little-endian mode. It is only
5954 available for a few configurations and most notably not on Solaris.
5955 .Ip "\fB\-m32\fR" 4
5956 .IX Item "-m32"
5957 .PD 0
5958 .Ip "\fB\-m64\fR" 4
5959 .IX Item "-m64"
5961 Generate code for a 32\-bit or 64\-bit environment.
5962 The 32\-bit environment sets int, long and pointer to 32 bits.
5963 The 64\-bit environment sets int to 32 bits and long and pointer
5964 to 64 bits.
5965 .Ip "\fB\-mcmodel=medlow\fR" 4
5966 .IX Item "-mcmodel=medlow"
5967 Generate code for the Medium/Low code model: 64\-bit addresses, programs
5968 must be linked in the low 32 bits of memory.  Programs can be statically
5969 or dynamically linked.
5970 .Ip "\fB\-mcmodel=medmid\fR" 4
5971 .IX Item "-mcmodel=medmid"
5972 Generate code for the Medium/Middle code model: 64\-bit addresses, programs
5973 must be linked in the low 44 bits of memory, the text and data segments must
5974 be less than 2GB in size and the data segment must be located within 2GB of
5975 the text segment.
5976 .Ip "\fB\-mcmodel=medany\fR" 4
5977 .IX Item "-mcmodel=medany"
5978 Generate code for the Medium/Anywhere code model: 64\-bit addresses, programs
5979 may be linked anywhere in memory, the text and data segments must be less
5980 than 2GB in size and the data segment must be located within 2GB of the
5981 text segment.
5982 .Ip "\fB\-mcmodel=embmedany\fR" 4
5983 .IX Item "-mcmodel=embmedany"
5984 Generate code for the Medium/Anywhere code model for embedded systems:
5985 64\-bit addresses, the text and data segments must be less than 2GB in
5986 size, both starting anywhere in memory (determined at link time).  The
5987 global register \f(CW%g4\fR points to the base of the data segment.  Programs
5988 are statically linked and \s-1PIC\s0 is not supported.
5989 .Ip "\fB\-mstack-bias\fR" 4
5990 .IX Item "-mstack-bias"
5991 .PD 0
5992 .Ip "\fB\-mno-stack-bias\fR" 4
5993 .IX Item "-mno-stack-bias"
5995 With \fB\-mstack-bias\fR, \s-1GCC\s0 assumes that the stack pointer, and
5996 frame pointer if present, are offset by \-2047 which must be added back
5997 when making stack frame references.  This is the default in 64\-bit mode.
5998 Otherwise, assume no such offset is present.
6000 These switches are supported in addition to the above on Solaris:
6001 .Ip "\fB\-threads\fR" 4
6002 .IX Item "-threads"
6003 Add support for multithreading using the Solaris threads library.  This
6004 option sets flags for both the preprocessor and linker.  This option does
6005 not affect the thread safety of object code produced by the compiler or
6006 that of libraries supplied with it.
6007 .Ip "\fB\-pthreads\fR" 4
6008 .IX Item "-pthreads"
6009 Add support for multithreading using the \s-1POSIX\s0 threads library.  This
6010 option sets flags for both the preprocessor and linker.  This option does
6011 not affect the thread safety of object code produced  by the compiler or
6012 that of libraries supplied with it.
6014 .I "\s-1ARM\s0 Options"
6015 .IX Subsection "ARM Options"
6017 These \fB\-m\fR options are defined for Advanced \s-1RISC\s0 Machines (\s-1ARM\s0)
6018 architectures:
6019 .Ip "\fB\-mapcs-frame\fR" 4
6020 .IX Item "-mapcs-frame"
6021 Generate a stack frame that is compliant with the \s-1ARM\s0 Procedure Call
6022 Standard for all functions, even if this is not strictly necessary for
6023 correct execution of the code.  Specifying \fB\-fomit-frame-pointer\fR
6024 with this option will cause the stack frames not to be generated for
6025 leaf functions.  The default is \fB\-mno-apcs-frame\fR.
6026 .Ip "\fB\-mapcs\fR" 4
6027 .IX Item "-mapcs"
6028 This is a synonym for \fB\-mapcs-frame\fR.
6029 .Ip "\fB\-mapcs-26\fR" 4
6030 .IX Item "-mapcs-26"
6031 Generate code for a processor running with a 26\-bit program counter,
6032 and conforming to the function calling standards for the \s-1APCS\s0 26\-bit
6033 option.
6035 This option is deprecated.  Future releases of the \s-1GCC\s0 will only support
6036 generating code that runs in apcs-32 mode.
6037 .Ip "\fB\-mapcs-32\fR" 4
6038 .IX Item "-mapcs-32"
6039 Generate code for a processor running with a 32\-bit program counter,
6040 and conforming to the function calling standards for the \s-1APCS\s0 32\-bit
6041 option.
6043 This flag is deprecated.  Future releases of \s-1GCC\s0 will make this flag
6044 unconditional.
6045 .Ip "\fB\-mthumb-interwork\fR" 4
6046 .IX Item "-mthumb-interwork"
6047 Generate code which supports calling between the \s-1ARM\s0 and Thumb
6048 instruction sets.  Without this option the two instruction sets cannot
6049 be reliably used inside one program.  The default is
6050 \&\fB\-mno-thumb-interwork\fR, since slightly larger code is generated
6051 when \fB\-mthumb-interwork\fR is specified.
6052 .Ip "\fB\-mno-sched-prolog\fR" 4
6053 .IX Item "-mno-sched-prolog"
6054 Prevent the reordering of instructions in the function prolog, or the
6055 merging of those instruction with the instructions in the function's
6056 body.  This means that all functions will start with a recognizable set
6057 of instructions (or in fact one of a choice from a small set of
6058 different function prologues), and this information can be used to
6059 locate the start if functions inside an executable piece of code.  The
6060 default is \fB\-msched-prolog\fR.
6061 .Ip "\fB\-mhard-float\fR" 4
6062 .IX Item "-mhard-float"
6063 Generate output containing floating point instructions.  This is the
6064 default.
6065 .Ip "\fB\-msoft-float\fR" 4
6066 .IX Item "-msoft-float"
6067 Generate output containing library calls for floating point.
6068 \&\fBWarning:\fR the requisite libraries are not available for all \s-1ARM\s0
6069 targets.  Normally the facilities of the machine's usual C compiler are
6070 used, but this cannot be done directly in cross-compilation.  You must make
6071 your own arrangements to provide suitable library functions for
6072 cross-compilation.
6074 \&\fB\-msoft-float\fR changes the calling convention in the output file;
6075 therefore, it is only useful if you compile \fIall\fR of a program with
6076 this option.  In particular, you need to compile \fIlibgcc.a\fR, the
6077 library that comes with \s-1GCC\s0, with \fB\-msoft-float\fR in order for
6078 this to work.
6079 .Ip "\fB\-mlittle-endian\fR" 4
6080 .IX Item "-mlittle-endian"
6081 Generate code for a processor running in little-endian mode.  This is
6082 the default for all standard configurations.
6083 .Ip "\fB\-mbig-endian\fR" 4
6084 .IX Item "-mbig-endian"
6085 Generate code for a processor running in big-endian mode; the default is
6086 to compile code for a little-endian processor.
6087 .Ip "\fB\-mwords-little-endian\fR" 4
6088 .IX Item "-mwords-little-endian"
6089 This option only applies when generating code for big-endian processors.
6090 Generate code for a little-endian word order but a big-endian byte
6091 order.  That is, a byte order of the form \fB32107654\fR.  Note: this
6092 option should only be used if you require compatibility with code for
6093 big-endian \s-1ARM\s0 processors generated by versions of the compiler prior to
6094 2.8.
6095 .Ip "\fB\-malignment-traps\fR" 4
6096 .IX Item "-malignment-traps"
6097 Generate code that will not trap if the \s-1MMU\s0 has alignment traps enabled.
6098 On \s-1ARM\s0 architectures prior to ARMv4, there were no instructions to
6099 access half-word objects stored in memory.  However, when reading from
6100 memory a feature of the \s-1ARM\s0 architecture allows a word load to be used,
6101 even if the address is unaligned, and the processor core will rotate the
6102 data as it is being loaded.  This option tells the compiler that such
6103 misaligned accesses will cause a \s-1MMU\s0 trap and that it should instead
6104 synthesize the access as a series of byte accesses.  The compiler can
6105 still use word accesses to load half-word data if it knows that the
6106 address is aligned to a word boundary.
6108 This option has no effect when compiling for \s-1ARM\s0 architecture 4 or later,
6109 since these processors have instructions to directly access half-word
6110 objects in memory.
6111 .Ip "\fB\-mno-alignment-traps\fR" 4
6112 .IX Item "-mno-alignment-traps"
6113 Generate code that assumes that the \s-1MMU\s0 will not trap unaligned
6114 accesses.  This produces better code when the target instruction set
6115 does not have half-word memory operations (i.e. implementations prior to
6116 ARMv4).
6118 Note that you cannot use this option to access unaligned word objects,
6119 since the processor will only fetch one 32\-bit aligned object from
6120 memory.
6122 The default setting is \fB\-malignment-traps\fR, since this produces
6123 code that will also run on processors implementing \s-1ARM\s0 architecture
6124 version 6 or later.
6126 This option is deprecated and will be removed in the next release of \s-1GCC\s0.
6127 .Ip "\fB\-mcpu=\fR\fIname\fR" 4
6128 .IX Item "-mcpu=name"
6129 This specifies the name of the target \s-1ARM\s0 processor.  \s-1GCC\s0 uses this name
6130 to determine what kind of instructions it can emit when generating
6131 assembly code.  Permissible names are: \fBarm2\fR, \fBarm250\fR,
6132 \&\fBarm3\fR, \fBarm6\fR, \fBarm60\fR, \fBarm600\fR, \fBarm610\fR,
6133 \&\fBarm620\fR, \fBarm7\fR, \fBarm7m\fR, \fBarm7d\fR, \fBarm7dm\fR,
6134 \&\fBarm7di\fR, \fBarm7dmi\fR, \fBarm70\fR, \fBarm700\fR,
6135 \&\fBarm700i\fR, \fBarm710\fR, \fBarm710c\fR, \fBarm7100\fR,
6136 \&\fBarm7500\fR, \fBarm7500fe\fR, \fBarm7tdmi\fR, \fBarm8\fR,
6137 \&\fBstrongarm\fR, \fBstrongarm110\fR, \fBstrongarm1100\fR,
6138 \&\fBarm8\fR, \fBarm810\fR, \fBarm9\fR, \fBarm9e\fR, \fBarm920\fR,
6139 \&\fBarm920t\fR, \fBarm926ejs\fR, \fBarm940t\fR, \fBarm9tdmi\fR,
6140 \&\fBarm10tdmi\fR, \fBarm1020t\fR, \fBarm1026ejs\fR,
6141 \&\fBarm1136js\fR, \fBarm1136jfs\fR ,\fBxscale\fR, \fBiwmmxt\fR,
6142 \&\fBep9312\fR.
6143 .Ip "\fB\-mtune=\fR\fIname\fR" 4
6144 .IX Item "-mtune=name"
6145 This option is very similar to the \fB\-mcpu=\fR option, except that
6146 instead of specifying the actual target processor type, and hence
6147 restricting which instructions can be used, it specifies that \s-1GCC\s0 should
6148 tune the performance of the code as if the target were of the type
6149 specified in this option, but still choosing the instructions that it
6150 will generate based on the cpu specified by a \fB\-mcpu=\fR option.
6151 For some \s-1ARM\s0 implementations better performance can be obtained by using
6152 this option.
6153 .Ip "\fB\-march=\fR\fIname\fR" 4
6154 .IX Item "-march=name"
6155 This specifies the name of the target \s-1ARM\s0 architecture.  \s-1GCC\s0 uses this
6156 name to determine what kind of instructions it can emit when generating
6157 assembly code.  This option can be used in conjunction with or instead
6158 of the \fB\-mcpu=\fR option.  Permissible names are: \fBarmv2\fR,
6159 \&\fBarmv2a\fR, \fBarmv3\fR, \fBarmv3m\fR, \fBarmv4\fR, \fBarmv4t\fR,
6160 \&\fBarmv5\fR, \fBarmv5t\fR, \fBarmv5te\fR, \fBarmv6j\fR,
6161 \&\fBiwmmxt\fR, \fBep9312\fR.
6162 .Ip "\fB\-mfpe=\fR\fInumber\fR" 4
6163 .IX Item "-mfpe=number"
6164 .PD 0
6165 .Ip "\fB\-mfp=\fR\fInumber\fR" 4
6166 .IX Item "-mfp=number"
6168 This specifies the version of the floating point emulation available on
6169 the target.  Permissible values are 2 and 3.  \fB\-mfp=\fR is a synonym
6170 for \fB\-mfpe=\fR, for compatibility with older versions of \s-1GCC\s0.
6171 .Ip "\fB\-mstructure-size-boundary=\fR\fIn\fR" 4
6172 .IX Item "-mstructure-size-boundary=n"
6173 The size of all structures and unions will be rounded up to a multiple
6174 of the number of bits set by this option.  Permissible values are 8 and
6175 32.  The default value varies for different toolchains.  For the \s-1COFF\s0
6176 targeted toolchain the default value is 8.  Specifying the larger number
6177 can produce faster, more efficient code, but can also increase the size
6178 of the program.  The two values are potentially incompatible.  Code
6179 compiled with one value cannot necessarily expect to work with code or
6180 libraries compiled with the other value, if they exchange information
6181 using structures or unions.
6182 .Ip "\fB\-mabort-on-noreturn\fR" 4
6183 .IX Item "-mabort-on-noreturn"
6184 Generate a call to the function \f(CW\*(C`abort\*(C'\fR at the end of a
6185 \&\f(CW\*(C`noreturn\*(C'\fR function.  It will be executed if the function tries to
6186 return.
6187 .Ip "\fB\-mlong-calls\fR" 4
6188 .IX Item "-mlong-calls"
6189 .PD 0
6190 .Ip "\fB\-mno-long-calls\fR" 4
6191 .IX Item "-mno-long-calls"
6193 Tells the compiler to perform function calls by first loading the
6194 address of the function into a register and then performing a subroutine
6195 call on this register.  This switch is needed if the target function
6196 will lie outside of the 64 megabyte addressing range of the offset based
6197 version of subroutine call instruction.
6199 Even if this switch is enabled, not all function calls will be turned
6200 into long calls.  The heuristic is that static functions, functions
6201 which have the \fBshort-call\fR attribute, functions that are inside
6202 the scope of a \fB#pragma no_long_calls\fR directive and functions whose
6203 definitions have already been compiled within the current compilation
6204 unit, will not be turned into long calls.  The exception to this rule is
6205 that weak function definitions, functions with the \fBlong-call\fR
6206 attribute or the \fBsection\fR attribute, and functions that are within
6207 the scope of a \fB#pragma long_calls\fR directive, will always be
6208 turned into long calls.
6210 This feature is not enabled by default.  Specifying
6211 \&\fB\-mno-long-calls\fR will restore the default behavior, as will
6212 placing the function calls within the scope of a \fB#pragma
6213 long_calls_off\fR directive.  Note these switches have no effect on how
6214 the compiler generates code to handle function calls via function
6215 pointers.
6216 .Ip "\fB\-mnop-fun-dllimport\fR" 4
6217 .IX Item "-mnop-fun-dllimport"
6218 Disable support for the \f(CW\*(C`dllimport\*(C'\fR attribute.
6219 .Ip "\fB\-msingle-pic-base\fR" 4
6220 .IX Item "-msingle-pic-base"
6221 Treat the register used for \s-1PIC\s0 addressing as read-only, rather than
6222 loading it in the prologue for each function.  The run-time system is
6223 responsible for initializing this register with an appropriate value
6224 before execution begins.
6225 .Ip "\fB\-mpic-register=\fR\fIreg\fR" 4
6226 .IX Item "-mpic-register=reg"
6227 Specify the register to be used for \s-1PIC\s0 addressing.  The default is R10
6228 unless stack-checking is enabled, when R9 is used.
6229 .Ip "\fB\-mcirrus-fix-invalid-insns\fR" 4
6230 .IX Item "-mcirrus-fix-invalid-insns"
6231 Insert NOPs into the instruction stream to in order to work around
6232 problems with invalid Maverick instruction combinations.  This option
6233 is only valid if the \fB\-mcpu=ep9312\fR option has been used to
6234 enable generation of instructions for the Cirrus Maverick floating
6235 point co-processor.  This option is not enabled by default, since the
6236 problem is only present in older Maverick implementations.  The default
6237 can be re-enabled by use of the \fB\-mno-cirrus-fix-invalid-insns\fR
6238 switch.
6239 .Ip "\fB\-mpoke-function-name\fR" 4
6240 .IX Item "-mpoke-function-name"
6241 Write the name of each function into the text section, directly
6242 preceding the function prologue.  The generated code is similar to this:
6244 .Vb 9
6245 \&             t0
6246 \&                 .ascii "arm_poke_function_name", 0
6247 \&                 .align
6248 \&             t1
6249 \&                 .word 0xff000000 + (t1 - t0)
6250 \&             arm_poke_function_name
6251 \&                 mov     ip, sp
6252 \&                 stmfd   sp!, {fp, ip, lr, pc}
6253 \&                 sub     fp, ip, #4
6255 When performing a stack backtrace, code can inspect the value of
6256 \&\f(CW\*(C`pc\*(C'\fR stored at \f(CW\*(C`fp + 0\*(C'\fR.  If the trace function then looks at
6257 location \f(CW\*(C`pc \- 12\*(C'\fR and the top 8 bits are set, then we know that
6258 there is a function name embedded immediately preceding this location
6259 and has length \f(CW\*(C`((pc[\-3]) & 0xff000000)\*(C'\fR.
6260 .Ip "\fB\-mthumb\fR" 4
6261 .IX Item "-mthumb"
6262 Generate code for the 16\-bit Thumb instruction set.  The default is to
6263 use the 32\-bit \s-1ARM\s0 instruction set.
6264 .Ip "\fB\-mtpcs-frame\fR" 4
6265 .IX Item "-mtpcs-frame"
6266 Generate a stack frame that is compliant with the Thumb Procedure Call
6267 Standard for all non-leaf functions.  (A leaf function is one that does
6268 not call any other functions.)  The default is \fB\-mno-tpcs-frame\fR.
6269 .Ip "\fB\-mtpcs-leaf-frame\fR" 4
6270 .IX Item "-mtpcs-leaf-frame"
6271 Generate a stack frame that is compliant with the Thumb Procedure Call
6272 Standard for all leaf functions.  (A leaf function is one that does
6273 not call any other functions.)  The default is \fB\-mno-apcs-leaf-frame\fR.
6274 .Ip "\fB\-mcallee-super-interworking\fR" 4
6275 .IX Item "-mcallee-super-interworking"
6276 Gives all externally visible functions in the file being compiled an \s-1ARM\s0
6277 instruction set header which switches to Thumb mode before executing the
6278 rest of the function.  This allows these functions to be called from
6279 non-interworking code.
6280 .Ip "\fB\-mcaller-super-interworking\fR" 4
6281 .IX Item "-mcaller-super-interworking"
6282 Allows calls via function pointers (including virtual functions) to
6283 execute correctly regardless of whether the target code has been
6284 compiled for interworking or not.  There is a small overhead in the cost
6285 of executing a function pointer if this option is enabled.
6287 .I "\s-1MN10300\s0 Options"
6288 .IX Subsection "MN10300 Options"
6290 These \fB\-m\fR options are defined for Matsushita \s-1MN10300\s0 architectures:
6291 .Ip "\fB\-mmult-bug\fR" 4
6292 .IX Item "-mmult-bug"
6293 Generate code to avoid bugs in the multiply instructions for the \s-1MN10300\s0
6294 processors.  This is the default.
6295 .Ip "\fB\-mno-mult-bug\fR" 4
6296 .IX Item "-mno-mult-bug"
6297 Do not generate code to avoid bugs in the multiply instructions for the
6298 \&\s-1MN10300\s0 processors.
6299 .Ip "\fB\-mam33\fR" 4
6300 .IX Item "-mam33"
6301 Generate code which uses features specific to the \s-1AM33\s0 processor.
6302 .Ip "\fB\-mno-am33\fR" 4
6303 .IX Item "-mno-am33"
6304 Do not generate code which uses features specific to the \s-1AM33\s0 processor.  This
6305 is the default.
6306 .Ip "\fB\-mno-crt0\fR" 4
6307 .IX Item "-mno-crt0"
6308 Do not link in the C run-time initialization object file.
6309 .Ip "\fB\-mrelax\fR" 4
6310 .IX Item "-mrelax"
6311 Indicate to the linker that it should perform a relaxation optimization pass
6312 to shorten branches, calls and absolute memory addresses.  This option only
6313 has an effect when used on the command line for the final link step.
6315 This option makes symbolic debugging impossible.
6317 .I "M32R/D Options"
6318 .IX Subsection "M32R/D Options"
6320 These \fB\-m\fR options are defined for Renesas M32R/D architectures:
6321 .Ip "\fB\-m32r2\fR" 4
6322 .IX Item "-m32r2"
6323 Generate code for the M32R/2.
6324 .Ip "\fB\-m32rx\fR" 4
6325 .IX Item "-m32rx"
6326 Generate code for the M32R/X.
6327 .Ip "\fB\-m32r\fR" 4
6328 .IX Item "-m32r"
6329 Generate code for the M32R.  This is the default.
6330 .Ip "\fB\-mmodel=small\fR" 4
6331 .IX Item "-mmodel=small"
6332 Assume all objects live in the lower 16MB of memory (so that their addresses
6333 can be loaded with the \f(CW\*(C`ld24\*(C'\fR instruction), and assume all subroutines
6334 are reachable with the \f(CW\*(C`bl\*(C'\fR instruction.
6335 This is the default.
6337 The addressability of a particular object can be set with the
6338 \&\f(CW\*(C`model\*(C'\fR attribute.
6339 .Ip "\fB\-mmodel=medium\fR" 4
6340 .IX Item "-mmodel=medium"
6341 Assume objects may be anywhere in the 32\-bit address space (the compiler
6342 will generate \f(CW\*(C`seth/add3\*(C'\fR instructions to load their addresses), and
6343 assume all subroutines are reachable with the \f(CW\*(C`bl\*(C'\fR instruction.
6344 .Ip "\fB\-mmodel=large\fR" 4
6345 .IX Item "-mmodel=large"
6346 Assume objects may be anywhere in the 32\-bit address space (the compiler
6347 will generate \f(CW\*(C`seth/add3\*(C'\fR instructions to load their addresses), and
6348 assume subroutines may not be reachable with the \f(CW\*(C`bl\*(C'\fR instruction
6349 (the compiler will generate the much slower \f(CW\*(C`seth/add3/jl\*(C'\fR
6350 instruction sequence).
6351 .Ip "\fB\-msdata=none\fR" 4
6352 .IX Item "-msdata=none"
6353 Disable use of the small data area.  Variables will be put into
6354 one of \fB.data\fR, \fBbss\fR, or \fB.rodata\fR (unless the
6355 \&\f(CW\*(C`section\*(C'\fR attribute has been specified).
6356 This is the default.
6358 The small data area consists of sections \fB.sdata\fR and \fB.sbss\fR.
6359 Objects may be explicitly put in the small data area with the
6360 \&\f(CW\*(C`section\*(C'\fR attribute using one of these sections.
6361 .Ip "\fB\-msdata=sdata\fR" 4
6362 .IX Item "-msdata=sdata"
6363 Put small global and static data in the small data area, but do not
6364 generate special code to reference them.
6365 .Ip "\fB\-msdata=use\fR" 4
6366 .IX Item "-msdata=use"
6367 Put small global and static data in the small data area, and generate
6368 special instructions to reference them.
6369 .Ip "\fB\-G\fR \fInum\fR" 4
6370 .IX Item "-G num"
6371 Put global and static objects less than or equal to \fInum\fR bytes
6372 into the small data or bss sections instead of the normal data or bss
6373 sections.  The default value of \fInum\fR is 8.
6374 The \fB\-msdata\fR option must be set to one of \fBsdata\fR or \fBuse\fR
6375 for this option to have any effect.
6377 All modules should be compiled with the same \fB\-G\fR \fInum\fR value.
6378 Compiling with different values of \fInum\fR may or may not work; if it
6379 doesn't the linker will give an error message\-\-\-incorrect code will not be
6380 generated.
6381 .Ip "\fB\-mdebug\fR" 4
6382 .IX Item "-mdebug"
6383 Makes the M32R specific code in the compiler display some statistics
6384 that might help in debugging programs.
6385 .Ip "\fB\-malign-loops\fR" 4
6386 .IX Item "-malign-loops"
6387 Align all loops to a 32\-byte boundary.
6388 .Ip "\fB\-mno-align-loops\fR" 4
6389 .IX Item "-mno-align-loops"
6390 Do not enforce a 32\-byte alignment for loops.  This is the default.
6391 .Ip "\fB\-missue-rate=\fR\fInumber\fR" 4
6392 .IX Item "-missue-rate=number"
6393 Issue \fInumber\fR instructions per cycle.  \fInumber\fR can only be 1
6394 or 2.
6395 .Ip "\fB\-mbranch-cost=\fR\fInumber\fR" 4
6396 .IX Item "-mbranch-cost=number"
6397 \&\fInumber\fR can only be 1 or 2.  If it is 1 then branches will be
6398 preferred over conditional code, if it is 2, then the opposite will
6399 apply.
6400 .Ip "\fB\-mflush-trap=\fR\fInumber\fR" 4
6401 .IX Item "-mflush-trap=number"
6402 Specifies the trap number to use to flush the cache.  The default is
6403 12.  Valid numbers are between 0 and 15 inclusive.
6404 .Ip "\fB\-mno-flush-trap\fR" 4
6405 .IX Item "-mno-flush-trap"
6406 Specifies that the cache cannot be flushed by using a trap.
6407 .Ip "\fB\-mflush-func=\fR\fIname\fR" 4
6408 .IX Item "-mflush-func=name"
6409 Specifies the name of the operating system function to call to flush
6410 the cache.  The default is \fI_flush_cache\fR, but a function call
6411 will only be used if a trap is not available.
6412 .Ip "\fB\-mno-flush-func\fR" 4
6413 .IX Item "-mno-flush-func"
6414 Indicates that there is no \s-1OS\s0 function for flushing the cache.
6416 .I "\s-1IBM\s0 \s-1RS/6000\s0 and PowerPC Options"
6417 .IX Subsection "IBM RS/6000 and PowerPC Options"
6419 These \fB\-m\fR options are defined for the \s-1IBM\s0 \s-1RS/6000\s0 and PowerPC:
6420 .Ip "\fB\-mpower\fR" 4
6421 .IX Item "-mpower"
6422 .PD 0
6423 .Ip "\fB\-mno-power\fR" 4
6424 .IX Item "-mno-power"
6425 .Ip "\fB\-mpower2\fR" 4
6426 .IX Item "-mpower2"
6427 .Ip "\fB\-mno-power2\fR" 4
6428 .IX Item "-mno-power2"
6429 .Ip "\fB\-mpowerpc\fR" 4
6430 .IX Item "-mpowerpc"
6431 .Ip "\fB\-mno-powerpc\fR" 4
6432 .IX Item "-mno-powerpc"
6433 .Ip "\fB\-mpowerpc-gpopt\fR" 4
6434 .IX Item "-mpowerpc-gpopt"
6435 .Ip "\fB\-mno-powerpc-gpopt\fR" 4
6436 .IX Item "-mno-powerpc-gpopt"
6437 .Ip "\fB\-mpowerpc-gfxopt\fR" 4
6438 .IX Item "-mpowerpc-gfxopt"
6439 .Ip "\fB\-mno-powerpc-gfxopt\fR" 4
6440 .IX Item "-mno-powerpc-gfxopt"
6441 .Ip "\fB\-mpowerpc64\fR" 4
6442 .IX Item "-mpowerpc64"
6443 .Ip "\fB\-mno-powerpc64\fR" 4
6444 .IX Item "-mno-powerpc64"
6446 \&\s-1GCC\s0 supports two related instruction set architectures for the
6447 \&\s-1RS/6000\s0 and PowerPC.  The \fI\s-1POWER\s0\fR instruction set are those
6448 instructions supported by the \fBrios\fR chip set used in the original
6449 \&\s-1RS/6000\s0 systems and the \fIPowerPC\fR instruction set is the
6450 architecture of the Motorola MPC5xx, MPC6xx, MPC8xx microprocessors, and
6451 the \s-1IBM\s0 4xx microprocessors.
6453 Neither architecture is a subset of the other.  However there is a
6454 large common subset of instructions supported by both.  An \s-1MQ\s0
6455 register is included in processors supporting the \s-1POWER\s0 architecture.
6457 You use these options to specify which instructions are available on the
6458 processor you are using.  The default value of these options is
6459 determined when configuring \s-1GCC\s0.  Specifying the
6460 \&\fB\-mcpu=\fR\fIcpu_type\fR overrides the specification of these
6461 options.  We recommend you use the \fB\-mcpu=\fR\fIcpu_type\fR option
6462 rather than the options listed above.
6464 The \fB\-mpower\fR option allows \s-1GCC\s0 to generate instructions that
6465 are found only in the \s-1POWER\s0 architecture and to use the \s-1MQ\s0 register.
6466 Specifying \fB\-mpower2\fR implies \fB\-power\fR and also allows \s-1GCC\s0
6467 to generate instructions that are present in the \s-1POWER2\s0 architecture but
6468 not the original \s-1POWER\s0 architecture.
6470 The \fB\-mpowerpc\fR option allows \s-1GCC\s0 to generate instructions that
6471 are found only in the 32\-bit subset of the PowerPC architecture.
6472 Specifying \fB\-mpowerpc-gpopt\fR implies \fB\-mpowerpc\fR and also allows
6473 \&\s-1GCC\s0 to use the optional PowerPC architecture instructions in the
6474 General Purpose group, including floating-point square root.  Specifying
6475 \&\fB\-mpowerpc-gfxopt\fR implies \fB\-mpowerpc\fR and also allows \s-1GCC\s0 to
6476 use the optional PowerPC architecture instructions in the Graphics
6477 group, including floating-point select.
6479 The \fB\-mpowerpc64\fR option allows \s-1GCC\s0 to generate the additional
6480 64\-bit instructions that are found in the full PowerPC64 architecture
6481 and to treat GPRs as 64\-bit, doubleword quantities.  \s-1GCC\s0 defaults to
6482 \&\fB\-mno-powerpc64\fR.
6484 If you specify both \fB\-mno-power\fR and \fB\-mno-powerpc\fR, \s-1GCC\s0
6485 will use only the instructions in the common subset of both
6486 architectures plus some special \s-1AIX\s0 common-mode calls, and will not use
6487 the \s-1MQ\s0 register.  Specifying both \fB\-mpower\fR and \fB\-mpowerpc\fR
6488 permits \s-1GCC\s0 to use any instruction from either architecture and to
6489 allow use of the \s-1MQ\s0 register; specify this for the Motorola \s-1MPC601\s0.
6490 .Ip "\fB\-mnew-mnemonics\fR" 4
6491 .IX Item "-mnew-mnemonics"
6492 .PD 0
6493 .Ip "\fB\-mold-mnemonics\fR" 4
6494 .IX Item "-mold-mnemonics"
6496 Select which mnemonics to use in the generated assembler code.  With
6497 \&\fB\-mnew-mnemonics\fR, \s-1GCC\s0 uses the assembler mnemonics defined for
6498 the PowerPC architecture.  With \fB\-mold-mnemonics\fR it uses the
6499 assembler mnemonics defined for the \s-1POWER\s0 architecture.  Instructions
6500 defined in only one architecture have only one mnemonic; \s-1GCC\s0 uses that
6501 mnemonic irrespective of which of these options is specified.
6503 \&\s-1GCC\s0 defaults to the mnemonics appropriate for the architecture in
6504 use.  Specifying \fB\-mcpu=\fR\fIcpu_type\fR sometimes overrides the
6505 value of these option.  Unless you are building a cross-compiler, you
6506 should normally not specify either \fB\-mnew-mnemonics\fR or
6507 \&\fB\-mold-mnemonics\fR, but should instead accept the default.
6508 .Ip "\fB\-mcpu=\fR\fIcpu_type\fR" 4
6509 .IX Item "-mcpu=cpu_type"
6510 Set architecture type, register usage, choice of mnemonics, and
6511 instruction scheduling parameters for machine type \fIcpu_type\fR.
6512 Supported values for \fIcpu_type\fR are \fB401\fR, \fB403\fR,
6513 \&\fB405\fR, \fB405fp\fR, \fB440\fR, \fB440fp\fR, \fB505\fR,
6514 \&\fB601\fR, \fB602\fR, \fB603\fR, \fB603e\fR, \fB604\fR,
6515 \&\fB604e\fR, \fB620\fR, \fB630\fR, \fB740\fR, \fB7400\fR,
6516 \&\fB7450\fR, \fB750\fR, \fB801\fR, \fB821\fR, \fB823\fR,
6517 \&\fB860\fR, \fB970\fR, \fBcommon\fR, \fBec603e\fR, \fBG3\fR,
6518 \&\fBG4\fR, \fBG5\fR, \fBpower\fR, \fBpower2\fR, \fBpower3\fR,
6519 \&\fBpower4\fR, \fBpower5\fR, \fBpowerpc\fR, \fBpowerpc64\fR,
6520 \&\fBrios\fR, \fBrios1\fR, \fBrios2\fR, \fBrsc\fR, and \fBrs64a\fR.
6522 \&\fB\-mcpu=common\fR selects a completely generic processor.  Code
6523 generated under this option will run on any \s-1POWER\s0 or PowerPC processor.
6524 \&\s-1GCC\s0 will use only the instructions in the common subset of both
6525 architectures, and will not use the \s-1MQ\s0 register.  \s-1GCC\s0 assumes a generic
6526 processor model for scheduling purposes.
6528 \&\fB\-mcpu=power\fR, \fB\-mcpu=power2\fR, \fB\-mcpu=powerpc\fR, and
6529 \&\fB\-mcpu=powerpc64\fR specify generic \s-1POWER\s0, \s-1POWER2\s0, pure 32\-bit
6530 PowerPC (i.e., not \s-1MPC601\s0), and 64\-bit PowerPC architecture machine
6531 types, with an appropriate, generic processor model assumed for
6532 scheduling purposes.
6534 The other options specify a specific processor.  Code generated under
6535 those options will run best on that processor, and may not run at all on
6536 others.
6538 The \fB\-mcpu\fR options automatically enable or disable the
6539 following options: \fB\-maltivec\fR, \fB\-mhard-float\fR,
6540 \&\fB\-mmfcrf\fR, \fB\-mmultiple\fR, \fB\-mnew-mnemonics\fR,
6541 \&\fB\-mpower\fR, \fB\-mpower2\fR, \fB\-mpowerpc64\fR,
6542 \&\fB\-mpowerpc-gpopt\fR, \fB\-mpowerpc-gfxopt\fR,
6543 \&\fB\-mstring\fR.  The particular options set for any particular \s-1CPU\s0
6544 will vary between compiler versions, depending on what setting seems
6545 to produce optimal code for that \s-1CPU\s0; it doesn't necessarily reflect
6546 the actual hardware's capabilities.  If you wish to set an individual
6547 option to a particular value, you may specify it after the
6548 \&\fB\-mcpu\fR option, like \fB\-mcpu=970 \-mno-altivec\fR.
6550 On \s-1AIX\s0, the \fB\-maltivec\fR and \fB\-mpowerpc64\fR options are
6551 not enabled or disabled by the \fB\-mcpu\fR option at present, since
6552 \&\s-1AIX\s0 does not have full support for these options.  You may still
6553 enable or disable them individually if you're sure it'll work in your
6554 environment.
6555 .Ip "\fB\-mtune=\fR\fIcpu_type\fR" 4
6556 .IX Item "-mtune=cpu_type"
6557 Set the instruction scheduling parameters for machine type
6558 \&\fIcpu_type\fR, but do not set the architecture type, register usage, or
6559 choice of mnemonics, as \fB\-mcpu=\fR\fIcpu_type\fR would.  The same
6560 values for \fIcpu_type\fR are used for \fB\-mtune\fR as for
6561 \&\fB\-mcpu\fR.  If both are specified, the code generated will use the
6562 architecture, registers, and mnemonics set by \fB\-mcpu\fR, but the
6563 scheduling parameters set by \fB\-mtune\fR.
6564 .Ip "\fB\-maltivec\fR" 4
6565 .IX Item "-maltivec"
6566 .PD 0
6567 .Ip "\fB\-mno-altivec\fR" 4
6568 .IX Item "-mno-altivec"
6570 These switches enable or disable the use of built-in functions that
6571 allow access to the AltiVec instruction set.  You may also need to set
6572 \&\fB\-mabi=altivec\fR to adjust the current \s-1ABI\s0 with AltiVec \s-1ABI\s0
6573 enhancements.
6574 .Ip "\fB\-mabi=spe\fR" 4
6575 .IX Item "-mabi=spe"
6576 Extend the current \s-1ABI\s0 with \s-1SPE\s0 \s-1ABI\s0 extensions.  This does not change
6577 the default \s-1ABI\s0, instead it adds the \s-1SPE\s0 \s-1ABI\s0 extensions to the current
6578 \&\s-1ABI\s0.
6579 .Ip "\fB\-mabi=no-spe\fR" 4
6580 .IX Item "-mabi=no-spe"
6581 Disable Booke \s-1SPE\s0 \s-1ABI\s0 extensions for the current \s-1ABI\s0.
6582 .Ip "\fB\-misel=\fR\fIyes/no\fR" 4
6583 .IX Item "-misel=yes/no"
6584 .PD 0
6585 .Ip "\fB\-misel\fR" 4
6586 .IX Item "-misel"
6588 This switch enables or disables the generation of \s-1ISEL\s0 instructions.
6589 .Ip "\fB\-mspe=\fR\fIyes/no\fR" 4
6590 .IX Item "-mspe=yes/no"
6591 .PD 0
6592 .Ip "\fB\-mspe\fR" 4
6593 .IX Item "-mspe"
6595 This switch enables or disables the generation of \s-1SPE\s0 simd
6596 instructions.
6597 .Ip "\fB\-mfloat-gprs=\fR\fIyes/no\fR" 4
6598 .IX Item "-mfloat-gprs=yes/no"
6599 .PD 0
6600 .Ip "\fB\-mfloat-gprs\fR" 4
6601 .IX Item "-mfloat-gprs"
6603 This switch enables or disables the generation of floating point
6604 operations on the general purpose registers for architectures that
6605 support it.  This option is currently only available on the \s-1MPC8540\s0.
6606 .Ip "\fB\-mfull-toc\fR" 4
6607 .IX Item "-mfull-toc"
6608 .PD 0
6609 .Ip "\fB\-mno-fp-in-toc\fR" 4
6610 .IX Item "-mno-fp-in-toc"
6611 .Ip "\fB\-mno-sum-in-toc\fR" 4
6612 .IX Item "-mno-sum-in-toc"
6613 .Ip "\fB\-mminimal-toc\fR" 4
6614 .IX Item "-mminimal-toc"
6616 Modify generation of the \s-1TOC\s0 (Table Of Contents), which is created for
6617 every executable file.  The \fB\-mfull-toc\fR option is selected by
6618 default.  In that case, \s-1GCC\s0 will allocate at least one \s-1TOC\s0 entry for
6619 each unique non-automatic variable reference in your program.  \s-1GCC\s0
6620 will also place floating-point constants in the \s-1TOC\s0.  However, only
6621 16,384 entries are available in the \s-1TOC\s0.
6623 If you receive a linker error message that saying you have overflowed
6624 the available \s-1TOC\s0 space, you can reduce the amount of \s-1TOC\s0 space used
6625 with the \fB\-mno-fp-in-toc\fR and \fB\-mno-sum-in-toc\fR options.
6626 \&\fB\-mno-fp-in-toc\fR prevents \s-1GCC\s0 from putting floating-point
6627 constants in the \s-1TOC\s0 and \fB\-mno-sum-in-toc\fR forces \s-1GCC\s0 to
6628 generate code to calculate the sum of an address and a constant at
6629 run-time instead of putting that sum into the \s-1TOC\s0.  You may specify one
6630 or both of these options.  Each causes \s-1GCC\s0 to produce very slightly
6631 slower and larger code at the expense of conserving \s-1TOC\s0 space.
6633 If you still run out of space in the \s-1TOC\s0 even when you specify both of
6634 these options, specify \fB\-mminimal-toc\fR instead.  This option causes
6635 \&\s-1GCC\s0 to make only one \s-1TOC\s0 entry for every file.  When you specify this
6636 option, \s-1GCC\s0 will produce code that is slower and larger but which
6637 uses extremely little \s-1TOC\s0 space.  You may wish to use this option
6638 only on files that contain less frequently executed code.
6639 .Ip "\fB\-maix64\fR" 4
6640 .IX Item "-maix64"
6641 .PD 0
6642 .Ip "\fB\-maix32\fR" 4
6643 .IX Item "-maix32"
6645 Enable 64\-bit \s-1AIX\s0 \s-1ABI\s0 and calling convention: 64\-bit pointers, 64\-bit
6646 \&\f(CW\*(C`long\*(C'\fR type, and the infrastructure needed to support them.
6647 Specifying \fB\-maix64\fR implies \fB\-mpowerpc64\fR and
6648 \&\fB\-mpowerpc\fR, while \fB\-maix32\fR disables the 64\-bit \s-1ABI\s0 and
6649 implies \fB\-mno-powerpc64\fR.  \s-1GCC\s0 defaults to \fB\-maix32\fR.
6650 .Ip "\fB\-mxl-call\fR" 4
6651 .IX Item "-mxl-call"
6652 .PD 0
6653 .Ip "\fB\-mno-xl-call\fR" 4
6654 .IX Item "-mno-xl-call"
6656 On \s-1AIX\s0, pass floating-point arguments to prototyped functions beyond the
6657 register save area (\s-1RSA\s0) on the stack in addition to argument FPRs.  The
6658 \&\s-1AIX\s0 calling convention was extended but not initially documented to
6659 handle an obscure K&R C case of calling a function that takes the
6660 address of its arguments with fewer arguments than declared.  \s-1AIX\s0 \s-1XL\s0
6661 compilers access floating point arguments which do not fit in the
6662 \&\s-1RSA\s0 from the stack when a subroutine is compiled without
6663 optimization.  Because always storing floating-point arguments on the
6664 stack is inefficient and rarely needed, this option is not enabled by
6665 default and only is necessary when calling subroutines compiled by \s-1AIX\s0
6666 \&\s-1XL\s0 compilers without optimization.
6667 .Ip "\fB\-mpe\fR" 4
6668 .IX Item "-mpe"
6669 Support \fI\s-1IBM\s0 \s-1RS/6000\s0 \s-1SP\s0\fR \fIParallel Environment\fR (\s-1PE\s0).  Link an
6670 application written to use message passing with special startup code to
6671 enable the application to run.  The system must have \s-1PE\s0 installed in the
6672 standard location (\fI/usr/lpp/ppe.poe/\fR), or the \fIspecs\fR file
6673 must be overridden with the \fB\-specs=\fR option to specify the
6674 appropriate directory location.  The Parallel Environment does not
6675 support threads, so the \fB\-mpe\fR option and the \fB\-pthread\fR
6676 option are incompatible.
6677 .Ip "\fB\-malign-natural\fR" 4
6678 .IX Item "-malign-natural"
6679 .PD 0
6680 .Ip "\fB\-malign-power\fR" 4
6681 .IX Item "-malign-power"
6683 On \s-1AIX\s0, Darwin, and 64\-bit PowerPC GNU/Linux, the option
6684 \&\fB\-malign-natural\fR overrides the ABI-defined alignment of larger
6685 types, such as floating-point doubles, on their natural size-based boundary.
6686 The option \fB\-malign-power\fR instructs \s-1GCC\s0 to follow the ABI-specified
6687 alignment rules.  \s-1GCC\s0 defaults to the standard alignment defined in the \s-1ABI\s0.
6688 .Ip "\fB\-msoft-float\fR" 4
6689 .IX Item "-msoft-float"
6690 .PD 0
6691 .Ip "\fB\-mhard-float\fR" 4
6692 .IX Item "-mhard-float"
6694 Generate code that does not use (uses) the floating-point register set.
6695 Software floating point emulation is provided if you use the
6696 \&\fB\-msoft-float\fR option, and pass the option to \s-1GCC\s0 when linking.
6697 .Ip "\fB\-mmultiple\fR" 4
6698 .IX Item "-mmultiple"
6699 .PD 0
6700 .Ip "\fB\-mno-multiple\fR" 4
6701 .IX Item "-mno-multiple"
6703 Generate code that uses (does not use) the load multiple word
6704 instructions and the store multiple word instructions.  These
6705 instructions are generated by default on \s-1POWER\s0 systems, and not
6706 generated on PowerPC systems.  Do not use \fB\-mmultiple\fR on little
6707 endian PowerPC systems, since those instructions do not work when the
6708 processor is in little endian mode.  The exceptions are \s-1PPC740\s0 and
6709 \&\s-1PPC750\s0 which permit the instructions usage in little endian mode.
6710 .Ip "\fB\-mstring\fR" 4
6711 .IX Item "-mstring"
6712 .PD 0
6713 .Ip "\fB\-mno-string\fR" 4
6714 .IX Item "-mno-string"
6716 Generate code that uses (does not use) the load string instructions
6717 and the store string word instructions to save multiple registers and
6718 do small block moves.  These instructions are generated by default on
6719 \&\s-1POWER\s0 systems, and not generated on PowerPC systems.  Do not use
6720 \&\fB\-mstring\fR on little endian PowerPC systems, since those
6721 instructions do not work when the processor is in little endian mode.
6722 The exceptions are \s-1PPC740\s0 and \s-1PPC750\s0 which permit the instructions
6723 usage in little endian mode.
6724 .Ip "\fB\-mupdate\fR" 4
6725 .IX Item "-mupdate"
6726 .PD 0
6727 .Ip "\fB\-mno-update\fR" 4
6728 .IX Item "-mno-update"
6730 Generate code that uses (does not use) the load or store instructions
6731 that update the base register to the address of the calculated memory
6732 location.  These instructions are generated by default.  If you use
6733 \&\fB\-mno-update\fR, there is a small window between the time that the
6734 stack pointer is updated and the address of the previous frame is
6735 stored, which means code that walks the stack frame across interrupts or
6736 signals may get corrupted data.
6737 .Ip "\fB\-mfused-madd\fR" 4
6738 .IX Item "-mfused-madd"
6739 .PD 0
6740 .Ip "\fB\-mno-fused-madd\fR" 4
6741 .IX Item "-mno-fused-madd"
6743 Generate code that uses (does not use) the floating point multiply and
6744 accumulate instructions.  These instructions are generated by default if
6745 hardware floating is used.
6746 .Ip "\fB\-mno-bit-align\fR" 4
6747 .IX Item "-mno-bit-align"
6748 .PD 0
6749 .Ip "\fB\-mbit-align\fR" 4
6750 .IX Item "-mbit-align"
6752 On System V.4 and embedded PowerPC systems do not (do) force structures
6753 and unions that contain bit-fields to be aligned to the base type of the
6754 bit-field.
6756 For example, by default a structure containing nothing but 8
6757 \&\f(CW\*(C`unsigned\*(C'\fR bit-fields of length 1 would be aligned to a 4 byte
6758 boundary and have a size of 4 bytes.  By using \fB\-mno-bit-align\fR,
6759 the structure would be aligned to a 1 byte boundary and be one byte in
6760 size.
6761 .Ip "\fB\-mno-strict-align\fR" 4
6762 .IX Item "-mno-strict-align"
6763 .PD 0
6764 .Ip "\fB\-mstrict-align\fR" 4
6765 .IX Item "-mstrict-align"
6767 On System V.4 and embedded PowerPC systems do not (do) assume that
6768 unaligned memory references will be handled by the system.
6769 .Ip "\fB\-mrelocatable\fR" 4
6770 .IX Item "-mrelocatable"
6771 .PD 0
6772 .Ip "\fB\-mno-relocatable\fR" 4
6773 .IX Item "-mno-relocatable"
6775 On embedded PowerPC systems generate code that allows (does not allow)
6776 the program to be relocated to a different address at runtime.  If you
6777 use \fB\-mrelocatable\fR on any module, all objects linked together must
6778 be compiled with \fB\-mrelocatable\fR or \fB\-mrelocatable-lib\fR.
6779 .Ip "\fB\-mrelocatable-lib\fR" 4
6780 .IX Item "-mrelocatable-lib"
6781 .PD 0
6782 .Ip "\fB\-mno-relocatable-lib\fR" 4
6783 .IX Item "-mno-relocatable-lib"
6785 On embedded PowerPC systems generate code that allows (does not allow)
6786 the program to be relocated to a different address at runtime.  Modules
6787 compiled with \fB\-mrelocatable-lib\fR can be linked with either modules
6788 compiled without \fB\-mrelocatable\fR and \fB\-mrelocatable-lib\fR or
6789 with modules compiled with the \fB\-mrelocatable\fR options.
6790 .Ip "\fB\-mno-toc\fR" 4
6791 .IX Item "-mno-toc"
6792 .PD 0
6793 .Ip "\fB\-mtoc\fR" 4
6794 .IX Item "-mtoc"
6796 On System V.4 and embedded PowerPC systems do not (do) assume that
6797 register 2 contains a pointer to a global area pointing to the addresses
6798 used in the program.
6799 .Ip "\fB\-mlittle\fR" 4
6800 .IX Item "-mlittle"
6801 .PD 0
6802 .Ip "\fB\-mlittle-endian\fR" 4
6803 .IX Item "-mlittle-endian"
6805 On System V.4 and embedded PowerPC systems compile code for the
6806 processor in little endian mode.  The \fB\-mlittle-endian\fR option is
6807 the same as \fB\-mlittle\fR.
6808 .Ip "\fB\-mbig\fR" 4
6809 .IX Item "-mbig"
6810 .PD 0
6811 .Ip "\fB\-mbig-endian\fR" 4
6812 .IX Item "-mbig-endian"
6814 On System V.4 and embedded PowerPC systems compile code for the
6815 processor in big endian mode.  The \fB\-mbig-endian\fR option is
6816 the same as \fB\-mbig\fR.
6817 .Ip "\fB\-mdynamic-no-pic\fR" 4
6818 .IX Item "-mdynamic-no-pic"
6819 On Darwin and Mac \s-1OS\s0 X systems, compile code so that it is not
6820 relocatable, but that its external references are relocatable.  The
6821 resulting code is suitable for applications, but not shared
6822 libraries.
6823 .Ip "\fB\-mprioritize-restricted-insns=\fR\fIpriority\fR" 4
6824 .IX Item "-mprioritize-restricted-insns=priority"
6825 This option controls the priority that is assigned to
6826 dispatch-slot restricted instructions during the second scheduling
6827 pass.  The argument \fIpriority\fR takes the value \fI0/1/2\fR to assign
6828 \&\fIno/highest/second-highest\fR priority to dispatch slot restricted
6829 instructions.
6830 .Ip "\fB\-msched-costly-dep=\fR\fIdependence_type\fR" 4
6831 .IX Item "-msched-costly-dep=dependence_type"
6832 This option controls which dependences are considered costly
6833 by the target during instruction scheduling.  The argument
6834 \&\fIdependence_type\fR takes one of the following values:
6835 \&\fIno\fR: no dependence is costly,
6836 \&\fIall\fR: all dependences are costly,
6837 \&\fItrue_store_to_load\fR: a true dependence from store to load is costly,
6838 \&\fIstore_to_load\fR: any dependence from store to load is costly,
6839 \&\fInumber\fR: any dependence which latency >= \fInumber\fR is costly.
6840 .Ip "\fB\-minsert-sched-nops=\fR\fIscheme\fR" 4
6841 .IX Item "-minsert-sched-nops=scheme"
6842 This option controls which nop insertion scheme will be used during
6843 the second scheduling pass. The argument \fIscheme\fR takes one of the
6844 following values:
6845 \&\fIno\fR: Don't insert nops.
6846 \&\fIpad\fR: Pad with nops any dispatch group which has vacant issue slots,
6847 according to the scheduler's grouping.
6848 \&\fIregroup_exact\fR: Insert nops to force costly dependent insns into
6849 separate groups.  Insert exactly as many nops as needed to force an insn
6850 to a new group, according to the estimated processor grouping.
6851 \&\fInumber\fR: Insert nops to force costly dependent insns into
6852 separate groups.  Insert \fInumber\fR nops to force an insn to a new group.
6853 .Ip "\fB\-mcall-sysv\fR" 4
6854 .IX Item "-mcall-sysv"
6855 On System V.4 and embedded PowerPC systems compile code using calling
6856 conventions that adheres to the March 1995 draft of the System V
6857 Application Binary Interface, PowerPC processor supplement.  This is the
6858 default unless you configured \s-1GCC\s0 using \fBpowerpc-*\-eabiaix\fR.
6859 .Ip "\fB\-mcall-sysv-eabi\fR" 4
6860 .IX Item "-mcall-sysv-eabi"
6861 Specify both \fB\-mcall-sysv\fR and \fB\-meabi\fR options.
6862 .Ip "\fB\-mcall-sysv-noeabi\fR" 4
6863 .IX Item "-mcall-sysv-noeabi"
6864 Specify both \fB\-mcall-sysv\fR and \fB\-mno-eabi\fR options.
6865 .Ip "\fB\-mcall-solaris\fR" 4
6866 .IX Item "-mcall-solaris"
6867 On System V.4 and embedded PowerPC systems compile code for the Solaris
6868 operating system.
6869 .Ip "\fB\-mcall-linux\fR" 4
6870 .IX Item "-mcall-linux"
6871 On System V.4 and embedded PowerPC systems compile code for the
6872 Linux-based \s-1GNU\s0 system.
6873 .Ip "\fB\-mcall-gnu\fR" 4
6874 .IX Item "-mcall-gnu"
6875 On System V.4 and embedded PowerPC systems compile code for the
6876 Hurd-based \s-1GNU\s0 system.
6877 .Ip "\fB\-mcall-netbsd\fR" 4
6878 .IX Item "-mcall-netbsd"
6879 On System V.4 and embedded PowerPC systems compile code for the
6880 NetBSD operating system.
6881 .Ip "\fB\-maix-struct-return\fR" 4
6882 .IX Item "-maix-struct-return"
6883 Return all structures in memory (as specified by the \s-1AIX\s0 \s-1ABI\s0).
6884 .Ip "\fB\-msvr4\-struct-return\fR" 4
6885 .IX Item "-msvr4-struct-return"
6886 Return structures smaller than 8 bytes in registers (as specified by the
6887 \&\s-1SVR4\s0 \s-1ABI\s0).
6888 .Ip "\fB\-mabi=altivec\fR" 4
6889 .IX Item "-mabi=altivec"
6890 Extend the current \s-1ABI\s0 with AltiVec \s-1ABI\s0 extensions.  This does not
6891 change the default \s-1ABI\s0, instead it adds the AltiVec \s-1ABI\s0 extensions to
6892 the current \s-1ABI\s0.
6893 .Ip "\fB\-mabi=no-altivec\fR" 4
6894 .IX Item "-mabi=no-altivec"
6895 Disable AltiVec \s-1ABI\s0 extensions for the current \s-1ABI\s0.
6896 .Ip "\fB\-mprototype\fR" 4
6897 .IX Item "-mprototype"
6898 .PD 0
6899 .Ip "\fB\-mno-prototype\fR" 4
6900 .IX Item "-mno-prototype"
6902 On System V.4 and embedded PowerPC systems assume that all calls to
6903 variable argument functions are properly prototyped.  Otherwise, the
6904 compiler must insert an instruction before every non prototyped call to
6905 set or clear bit 6 of the condition code register (\fI\s-1CR\s0\fR) to
6906 indicate whether floating point values were passed in the floating point
6907 registers in case the function takes a variable arguments.  With
6908 \&\fB\-mprototype\fR, only calls to prototyped variable argument functions
6909 will set or clear the bit.
6910 .Ip "\fB\-msim\fR" 4
6911 .IX Item "-msim"
6912 On embedded PowerPC systems, assume that the startup module is called
6913 \&\fIsim-crt0.o\fR and that the standard C libraries are \fIlibsim.a\fR and
6914 \&\fIlibc.a\fR.  This is the default for \fBpowerpc-*\-eabisim\fR.
6915 configurations.
6916 .Ip "\fB\-mmvme\fR" 4
6917 .IX Item "-mmvme"
6918 On embedded PowerPC systems, assume that the startup module is called
6919 \&\fIcrt0.o\fR and the standard C libraries are \fIlibmvme.a\fR and
6920 \&\fIlibc.a\fR.
6921 .Ip "\fB\-mads\fR" 4
6922 .IX Item "-mads"
6923 On embedded PowerPC systems, assume that the startup module is called
6924 \&\fIcrt0.o\fR and the standard C libraries are \fIlibads.a\fR and
6925 \&\fIlibc.a\fR.
6926 .Ip "\fB\-myellowknife\fR" 4
6927 .IX Item "-myellowknife"
6928 On embedded PowerPC systems, assume that the startup module is called
6929 \&\fIcrt0.o\fR and the standard C libraries are \fIlibyk.a\fR and
6930 \&\fIlibc.a\fR.
6931 .Ip "\fB\-mvxworks\fR" 4
6932 .IX Item "-mvxworks"
6933 On System V.4 and embedded PowerPC systems, specify that you are
6934 compiling for a VxWorks system.
6935 .Ip "\fB\-mwindiss\fR" 4
6936 .IX Item "-mwindiss"
6937 Specify that you are compiling for the WindISS simulation environment.
6938 .Ip "\fB\-memb\fR" 4
6939 .IX Item "-memb"
6940 On embedded PowerPC systems, set the \fI\s-1PPC_EMB\s0\fR bit in the \s-1ELF\s0 flags
6941 header to indicate that \fBeabi\fR extended relocations are used.
6942 .Ip "\fB\-meabi\fR" 4
6943 .IX Item "-meabi"
6944 .PD 0
6945 .Ip "\fB\-mno-eabi\fR" 4
6946 .IX Item "-mno-eabi"
6948 On System V.4 and embedded PowerPC systems do (do not) adhere to the
6949 Embedded Applications Binary Interface (eabi) which is a set of
6950 modifications to the System V.4 specifications.  Selecting \fB\-meabi\fR
6951 means that the stack is aligned to an 8 byte boundary, a function
6952 \&\f(CW\*(C`_\|_eabi\*(C'\fR is called to from \f(CW\*(C`main\*(C'\fR to set up the eabi
6953 environment, and the \fB\-msdata\fR option can use both \f(CW\*(C`r2\*(C'\fR and
6954 \&\f(CW\*(C`r13\*(C'\fR to point to two separate small data areas.  Selecting
6955 \&\fB\-mno-eabi\fR means that the stack is aligned to a 16 byte boundary,
6956 do not call an initialization function from \f(CW\*(C`main\*(C'\fR, and the
6957 \&\fB\-msdata\fR option will only use \f(CW\*(C`r13\*(C'\fR to point to a single
6958 small data area.  The \fB\-meabi\fR option is on by default if you
6959 configured \s-1GCC\s0 using one of the \fBpowerpc*\-*\-eabi*\fR options.
6960 .Ip "\fB\-msdata=eabi\fR" 4
6961 .IX Item "-msdata=eabi"
6962 On System V.4 and embedded PowerPC systems, put small initialized
6963 \&\f(CW\*(C`const\*(C'\fR global and static data in the \fB.sdata2\fR section, which
6964 is pointed to by register \f(CW\*(C`r2\*(C'\fR.  Put small initialized
6965 non-\f(CW\*(C`const\*(C'\fR global and static data in the \fB.sdata\fR section,
6966 which is pointed to by register \f(CW\*(C`r13\*(C'\fR.  Put small uninitialized
6967 global and static data in the \fB.sbss\fR section, which is adjacent to
6968 the \fB.sdata\fR section.  The \fB\-msdata=eabi\fR option is
6969 incompatible with the \fB\-mrelocatable\fR option.  The
6970 \&\fB\-msdata=eabi\fR option also sets the \fB\-memb\fR option.
6971 .Ip "\fB\-msdata=sysv\fR" 4
6972 .IX Item "-msdata=sysv"
6973 On System V.4 and embedded PowerPC systems, put small global and static
6974 data in the \fB.sdata\fR section, which is pointed to by register
6975 \&\f(CW\*(C`r13\*(C'\fR.  Put small uninitialized global and static data in the
6976 \&\fB.sbss\fR section, which is adjacent to the \fB.sdata\fR section.
6977 The \fB\-msdata=sysv\fR option is incompatible with the
6978 \&\fB\-mrelocatable\fR option.
6979 .Ip "\fB\-msdata=default\fR" 4
6980 .IX Item "-msdata=default"
6981 .PD 0
6982 .Ip "\fB\-msdata\fR" 4
6983 .IX Item "-msdata"
6985 On System V.4 and embedded PowerPC systems, if \fB\-meabi\fR is used,
6986 compile code the same as \fB\-msdata=eabi\fR, otherwise compile code the
6987 same as \fB\-msdata=sysv\fR.
6988 .Ip "\fB\-msdata-data\fR" 4
6989 .IX Item "-msdata-data"
6990 On System V.4 and embedded PowerPC systems, put small global and static
6991 data in the \fB.sdata\fR section.  Put small uninitialized global and
6992 static data in the \fB.sbss\fR section.  Do not use register \f(CW\*(C`r13\*(C'\fR
6993 to address small data however.  This is the default behavior unless
6994 other \fB\-msdata\fR options are used.
6995 .Ip "\fB\-msdata=none\fR" 4
6996 .IX Item "-msdata=none"
6997 .PD 0
6998 .Ip "\fB\-mno-sdata\fR" 4
6999 .IX Item "-mno-sdata"
7001 On embedded PowerPC systems, put all initialized global and static data
7002 in the \fB.data\fR section, and all uninitialized data in the
7003 \&\fB.bss\fR section.
7004 .Ip "\fB\-G\fR \fInum\fR" 4
7005 .IX Item "-G num"
7006 On embedded PowerPC systems, put global and static items less than or
7007 equal to \fInum\fR bytes into the small data or bss sections instead of
7008 the normal data or bss section.  By default, \fInum\fR is 8.  The
7009 \&\fB\-G\fR \fInum\fR switch is also passed to the linker.
7010 All modules should be compiled with the same \fB\-G\fR \fInum\fR value.
7011 .Ip "\fB\-mregnames\fR" 4
7012 .IX Item "-mregnames"
7013 .PD 0
7014 .Ip "\fB\-mno-regnames\fR" 4
7015 .IX Item "-mno-regnames"
7017 On System V.4 and embedded PowerPC systems do (do not) emit register
7018 names in the assembly language output using symbolic forms.
7019 .Ip "\fB\-mlongcall\fR" 4
7020 .IX Item "-mlongcall"
7021 .PD 0
7022 .Ip "\fB\-mno-longcall\fR" 4
7023 .IX Item "-mno-longcall"
7025 Default to making all function calls via pointers, so that functions
7026 which reside further than 64 megabytes (67,108,864 bytes) from the
7027 current location can be called.  This setting can be overridden by the
7028 \&\f(CW\*(C`shortcall\*(C'\fR function attribute, or by \f(CW\*(C`#pragma longcall(0)\*(C'\fR.
7030 Some linkers are capable of detecting out-of-range calls and generating
7031 glue code on the fly.  On these systems, long calls are unnecessary and
7032 generate slower code.  As of this writing, the \s-1AIX\s0 linker can do this,
7033 as can the \s-1GNU\s0 linker for PowerPC/64.  It is planned to add this feature
7034 to the \s-1GNU\s0 linker for 32\-bit PowerPC systems as well.
7036 On Mach-O (Darwin) systems, this option directs the compiler emit to
7037 the glue for every direct call, and the Darwin linker decides whether
7038 to use or discard it.
7040 In the future, we may cause \s-1GCC\s0 to ignore all longcall specifications
7041 when the linker is known to generate glue.
7042 .Ip "\fB\-pthread\fR" 4
7043 .IX Item "-pthread"
7044 Adds support for multithreading with the \fIpthreads\fR library.
7045 This option sets flags for both the preprocessor and linker.
7047 .I "Darwin Options"
7048 .IX Subsection "Darwin Options"
7050 These options are defined for all architectures running the Darwin operating
7051 system.  They are useful for compatibility with other Mac \s-1OS\s0 compilers.
7052 .Ip "\fB\-all_load\fR" 4
7053 .IX Item "-all_load"
7054 Loads all members of static archive libraries.
7055 See man \fIld\fR\|(1) for more information.
7056 .Ip "\fB\-arch_errors_fatal\fR" 4
7057 .IX Item "-arch_errors_fatal"
7058 Cause the errors having to do with files that have the wrong architecture
7059 to be fatal.
7060 .Ip "\fB\-bind_at_load\fR" 4
7061 .IX Item "-bind_at_load"
7062 Causes the output file to be marked such that the dynamic linker will
7063 bind all undefined references when the file is loaded or launched.
7064 .Ip "\fB\-bundle\fR" 4
7065 .IX Item "-bundle"
7066 Produce a Mach-o bundle format file.
7067 See man \fIld\fR\|(1) for more information.
7068 .Ip "\fB\-bundle_loader\fR \fIexecutable\fR" 4
7069 .IX Item "-bundle_loader executable"
7070 This specifies the \fIexecutable\fR that will be loading the build
7071 output file being linked. See man \fIld\fR\|(1) for more information.
7072 .Ip "\fB\-allowable_client\fR  \fIclient_name\fR" 4
7073 .IX Item "-allowable_client  client_name"
7074 .PD 0
7075 .Ip "\fB\-arch_only\fR" 4
7076 .IX Item "-arch_only"
7077 .Ip "\fB\-client_name\fR" 4
7078 .IX Item "-client_name"
7079 .Ip "\fB\-compatibility_version\fR" 4
7080 .IX Item "-compatibility_version"
7081 .Ip "\fB\-current_version\fR" 4
7082 .IX Item "-current_version"
7083 .Ip "\fB\-dependency-file\fR" 4
7084 .IX Item "-dependency-file"
7085 .Ip "\fB\-dylib_file\fR" 4
7086 .IX Item "-dylib_file"
7087 .Ip "\fB\-dylinker_install_name\fR" 4
7088 .IX Item "-dylinker_install_name"
7089 .Ip "\fB\-dynamic\fR" 4
7090 .IX Item "-dynamic"
7091 .Ip "\fB\-dynamiclib\fR" 4
7092 .IX Item "-dynamiclib"
7093 .Ip "\fB\-exported_symbols_list\fR" 4
7094 .IX Item "-exported_symbols_list"
7095 .Ip "\fB\-filelist\fR" 4
7096 .IX Item "-filelist"
7097 .Ip "\fB\-flat_namespace\fR" 4
7098 .IX Item "-flat_namespace"
7099 .Ip "\fB\-force_cpusubtype_ALL\fR" 4
7100 .IX Item "-force_cpusubtype_ALL"
7101 .Ip "\fB\-force_flat_namespace\fR" 4
7102 .IX Item "-force_flat_namespace"
7103 .Ip "\fB\-headerpad_max_install_names\fR" 4
7104 .IX Item "-headerpad_max_install_names"
7105 .Ip "\fB\-image_base\fR" 4
7106 .IX Item "-image_base"
7107 .Ip "\fB\-init\fR" 4
7108 .IX Item "-init"
7109 .Ip "\fB\-install_name\fR" 4
7110 .IX Item "-install_name"
7111 .Ip "\fB\-keep_private_externs\fR" 4
7112 .IX Item "-keep_private_externs"
7113 .Ip "\fB\-multi_module\fR" 4
7114 .IX Item "-multi_module"
7115 .Ip "\fB\-multiply_defined\fR" 4
7116 .IX Item "-multiply_defined"
7117 .Ip "\fB\-multiply_defined_unused\fR" 4
7118 .IX Item "-multiply_defined_unused"
7119 .Ip "\fB\-noall_load\fR" 4
7120 .IX Item "-noall_load"
7121 .Ip "\fB\-nofixprebinding\fR" 4
7122 .IX Item "-nofixprebinding"
7123 .Ip "\fB\-nomultidefs\fR" 4
7124 .IX Item "-nomultidefs"
7125 .Ip "\fB\-noprebind\fR" 4
7126 .IX Item "-noprebind"
7127 .Ip "\fB\-noseglinkedit\fR" 4
7128 .IX Item "-noseglinkedit"
7129 .Ip "\fB\-pagezero_size\fR" 4
7130 .IX Item "-pagezero_size"
7131 .Ip "\fB\-prebind\fR" 4
7132 .IX Item "-prebind"
7133 .Ip "\fB\-prebind_all_twolevel_modules\fR" 4
7134 .IX Item "-prebind_all_twolevel_modules"
7135 .Ip "\fB\-private_bundle\fR" 4
7136 .IX Item "-private_bundle"
7137 .Ip "\fB\-read_only_relocs\fR" 4
7138 .IX Item "-read_only_relocs"
7139 .Ip "\fB\-sectalign\fR" 4
7140 .IX Item "-sectalign"
7141 .Ip "\fB\-sectobjectsymbols\fR" 4
7142 .IX Item "-sectobjectsymbols"
7143 .Ip "\fB\-whyload\fR" 4
7144 .IX Item "-whyload"
7145 .Ip "\fB\-seg1addr\fR" 4
7146 .IX Item "-seg1addr"
7147 .Ip "\fB\-sectcreate\fR" 4
7148 .IX Item "-sectcreate"
7149 .Ip "\fB\-sectobjectsymbols\fR" 4
7150 .IX Item "-sectobjectsymbols"
7151 .Ip "\fB\-sectorder\fR" 4
7152 .IX Item "-sectorder"
7153 .Ip "\fB\-seg_addr_table\fR" 4
7154 .IX Item "-seg_addr_table"
7155 .Ip "\fB\-seg_addr_table_filename\fR" 4
7156 .IX Item "-seg_addr_table_filename"
7157 .Ip "\fB\-seglinkedit\fR" 4
7158 .IX Item "-seglinkedit"
7159 .Ip "\fB\-segprot\fR" 4
7160 .IX Item "-segprot"
7161 .Ip "\fB\-segs_read_only_addr\fR" 4
7162 .IX Item "-segs_read_only_addr"
7163 .Ip "\fB\-segs_read_write_addr\fR" 4
7164 .IX Item "-segs_read_write_addr"
7165 .Ip "\fB\-single_module\fR" 4
7166 .IX Item "-single_module"
7167 .Ip "\fB\-static\fR" 4
7168 .IX Item "-static"
7169 .Ip "\fB\-sub_library\fR" 4
7170 .IX Item "-sub_library"
7171 .Ip "\fB\-sub_umbrella\fR" 4
7172 .IX Item "-sub_umbrella"
7173 .Ip "\fB\-twolevel_namespace\fR" 4
7174 .IX Item "-twolevel_namespace"
7175 .Ip "\fB\-umbrella\fR" 4
7176 .IX Item "-umbrella"
7177 .Ip "\fB\-undefined\fR" 4
7178 .IX Item "-undefined"
7179 .Ip "\fB\-unexported_symbols_list\fR" 4
7180 .IX Item "-unexported_symbols_list"
7181 .Ip "\fB\-weak_reference_mismatches\fR" 4
7182 .IX Item "-weak_reference_mismatches"
7183 .Ip "\fB\-whatsloaded\fR" 4
7184 .IX Item "-whatsloaded"
7186 These options are available for Darwin linker. Darwin linker man page
7187 describes them in detail.
7189 .I "\s-1MIPS\s0 Options"
7190 .IX Subsection "MIPS Options"
7191 .Ip "\fB\-EB\fR" 4
7192 .IX Item "-EB"
7193 Generate big-endian code.
7194 .Ip "\fB\-EL\fR" 4
7195 .IX Item "-EL"
7196 Generate little-endian code.  This is the default for \fBmips*el-*\-*\fR
7197 configurations.
7198 .Ip "\fB\-march=\fR\fIarch\fR" 4
7199 .IX Item "-march=arch"
7200 Generate code that will run on \fIarch\fR, which can be the name of a
7201 generic \s-1MIPS\s0 \s-1ISA\s0, or the name of a particular processor.
7202 The \s-1ISA\s0 names are:
7203 \&\fBmips1\fR, \fBmips2\fR, \fBmips3\fR, \fBmips4\fR,
7204 \&\fBmips32\fR, \fBmips32r2\fR, and \fBmips64\fR.
7205 The processor names are:
7206 \&\fB4kc\fR, \fB4kp\fR, \fB5kc\fR, \fB20kc\fR,
7207 \&\fBm4k\fR,
7208 \&\fBr2000\fR, \fBr3000\fR, \fBr3900\fR, \fBr4000\fR, \fBr4400\fR,
7209 \&\fBr4600\fR, \fBr4650\fR, \fBr6000\fR, \fBr8000\fR, \fBrm7000\fR,
7210 \&\fBrm9000\fR,
7211 \&\fBorion\fR,
7212 \&\fBsb1\fR,
7213 \&\fBvr4100\fR, \fBvr4111\fR, \fBvr4120\fR, \fBvr4300\fR,
7214 \&\fBvr5000\fR, \fBvr5400\fR and \fBvr5500\fR.
7215 The special value \fBfrom-abi\fR selects the
7216 most compatible architecture for the selected \s-1ABI\s0 (that is,
7217 \&\fBmips1\fR for 32\-bit ABIs and \fBmips3\fR for 64\-bit ABIs).
7219 In processor names, a final \fB000\fR can be abbreviated as \fBk\fR
7220 (for example, \fB\-march=r2k\fR).  Prefixes are optional, and
7221 \&\fBvr\fR may be written \fBr\fR.
7223 \&\s-1GCC\s0 defines two macros based on the value of this option.  The first
7224 is \fB_MIPS_ARCH\fR, which gives the name of target architecture, as
7225 a string.  The second has the form \fB_MIPS_ARCH_\fR\fIfoo\fR,
7226 where \fIfoo\fR is the capitalized value of \fB_MIPS_ARCH\fR.
7227 For example, \fB\-march=r2000\fR will set \fB_MIPS_ARCH\fR
7228 to \fB\*(L"r2000\*(R"\fR and define the macro \fB_MIPS_ARCH_R2000\fR.
7230 Note that the \fB_MIPS_ARCH\fR macro uses the processor names given
7231 above.  In other words, it will have the full prefix and will not
7232 abbreviate \fB000\fR as \fBk\fR.  In the case of \fBfrom-abi\fR,
7233 the macro names the resolved architecture (either \fB\*(L"mips1\*(R"\fR or
7234 \&\fB\*(L"mips3\*(R"\fR).  It names the default architecture when no
7235 \&\fB\-march\fR option is given.
7236 .Ip "\fB\-mtune=\fR\fIarch\fR" 4
7237 .IX Item "-mtune=arch"
7238 Optimize for \fIarch\fR.  Among other things, this option controls
7239 the way instructions are scheduled, and the perceived cost of arithmetic
7240 operations.  The list of \fIarch\fR values is the same as for
7241 \&\fB\-march\fR.
7243 When this option is not used, \s-1GCC\s0 will optimize for the processor
7244 specified by \fB\-march\fR.  By using \fB\-march\fR and
7245 \&\fB\-mtune\fR together, it is possible to generate code that will
7246 run on a family of processors, but optimize the code for one
7247 particular member of that family.
7249 \&\fB\-mtune\fR defines the macros \fB_MIPS_TUNE\fR and
7250 \&\fB_MIPS_TUNE_\fR\fIfoo\fR, which work in the same way as the
7251 \&\fB\-march\fR ones described above.
7252 .Ip "\fB\-mips1\fR" 4
7253 .IX Item "-mips1"
7254 Equivalent to \fB\-march=mips1\fR.
7255 .Ip "\fB\-mips2\fR" 4
7256 .IX Item "-mips2"
7257 Equivalent to \fB\-march=mips2\fR.
7258 .Ip "\fB\-mips3\fR" 4
7259 .IX Item "-mips3"
7260 Equivalent to \fB\-march=mips3\fR.
7261 .Ip "\fB\-mips4\fR" 4
7262 .IX Item "-mips4"
7263 Equivalent to \fB\-march=mips4\fR.
7264 .Ip "\fB\-mips32\fR" 4
7265 .IX Item "-mips32"
7266 Equivalent to \fB\-march=mips32\fR.
7267 .Ip "\fB\-mips32r2\fR" 4
7268 .IX Item "-mips32r2"
7269 Equivalent to \fB\-march=mips32r2\fR.
7270 .Ip "\fB\-mips64\fR" 4
7271 .IX Item "-mips64"
7272 Equivalent to \fB\-march=mips64\fR.
7273 .Ip "\fB\-mips16\fR" 4
7274 .IX Item "-mips16"
7275 .PD 0
7276 .Ip "\fB\-mno-mips16\fR" 4
7277 .IX Item "-mno-mips16"
7279 Use (do not use) the \s-1MIPS16\s0 \s-1ISA\s0.
7280 .Ip "\fB\-mabi=32\fR" 4
7281 .IX Item "-mabi=32"
7282 .PD 0
7283 .Ip "\fB\-mabi=o64\fR" 4
7284 .IX Item "-mabi=o64"
7285 .Ip "\fB\-mabi=n32\fR" 4
7286 .IX Item "-mabi=n32"
7287 .Ip "\fB\-mabi=64\fR" 4
7288 .IX Item "-mabi=64"
7289 .Ip "\fB\-mabi=eabi\fR" 4
7290 .IX Item "-mabi=eabi"
7292 Generate code for the given \s-1ABI\s0.
7294 Note that the \s-1EABI\s0 has a 32\-bit and a 64\-bit variant.  \s-1GCC\s0 normally
7295 generates 64\-bit code when you select a 64\-bit architecture, but you
7296 can use \fB\-mgp32\fR to get 32\-bit code instead.
7297 .Ip "\fB\-mabicalls\fR" 4
7298 .IX Item "-mabicalls"
7299 .PD 0
7300 .Ip "\fB\-mno-abicalls\fR" 4
7301 .IX Item "-mno-abicalls"
7303 Generate (do not generate) SVR4\-style position-independent code.
7304 \&\fB\-mabicalls\fR is the default for SVR4\-based systems.
7305 .Ip "\fB\-mxgot\fR" 4
7306 .IX Item "-mxgot"
7307 .PD 0
7308 .Ip "\fB\-mno-xgot\fR" 4
7309 .IX Item "-mno-xgot"
7311 Lift (do not lift) the usual restrictions on the size of the global
7312 offset table.
7314 \&\s-1GCC\s0 normally uses a single instruction to load values from the \s-1GOT\s0.
7315 While this is relatively efficient, it will only work if the \s-1GOT\s0
7316 is smaller than about 64k.  Anything larger will cause the linker
7317 to report an error such as:
7319 .Vb 1
7320 \&        relocation truncated to fit: R_MIPS_GOT16 foobar
7322 If this happens, you should recompile your code with \fB\-mxgot\fR.
7323 It should then work with very large GOTs, although it will also be
7324 less efficient, since it will take three instructions to fetch the
7325 value of a global symbol.
7327 Note that some linkers can create multiple GOTs.  If you have such a
7328 linker, you should only need to use \fB\-mxgot\fR when a single object
7329 file accesses more than 64k's worth of \s-1GOT\s0 entries.  Very few do.
7331 These options have no effect unless \s-1GCC\s0 is generating position
7332 independent code.
7333 .Ip "\fB\-membedded-pic\fR" 4
7334 .IX Item "-membedded-pic"
7335 .PD 0
7336 .Ip "\fB\-mno-embedded-pic\fR" 4
7337 .IX Item "-mno-embedded-pic"
7339 Generate (do not generate) position-independent code suitable for some
7340 embedded systems.  All calls are made using \s-1PC\s0 relative addresses, and
7341 all data is addressed using the \f(CW$gp\fR register.  No more than 65536
7342 bytes of global data may be used.  This requires \s-1GNU\s0 as and \s-1GNU\s0 ld,
7343 which do most of the work.
7344 .Ip "\fB\-mgp32\fR" 4
7345 .IX Item "-mgp32"
7346 Assume that general-purpose registers are 32 bits wide.
7347 .Ip "\fB\-mgp64\fR" 4
7348 .IX Item "-mgp64"
7349 Assume that general-purpose registers are 64 bits wide.
7350 .Ip "\fB\-mfp32\fR" 4
7351 .IX Item "-mfp32"
7352 Assume that floating-point registers are 32 bits wide.
7353 .Ip "\fB\-mfp64\fR" 4
7354 .IX Item "-mfp64"
7355 Assume that floating-point registers are 64 bits wide.
7356 .Ip "\fB\-mhard-float\fR" 4
7357 .IX Item "-mhard-float"
7358 Use floating-point coprocessor instructions.
7359 .Ip "\fB\-msoft-float\fR" 4
7360 .IX Item "-msoft-float"
7361 Do not use floating-point coprocessor instructions.  Implement
7362 floating-point calculations using library calls instead.
7363 .Ip "\fB\-msingle-float\fR" 4
7364 .IX Item "-msingle-float"
7365 Assume that the floating-point coprocessor only supports single-precision
7366 operations.
7367 .Ip "\fB\-mdouble-float\fR" 4
7368 .IX Item "-mdouble-float"
7369 Assume that the floating-point coprocessor supports double-precision
7370 operations.  This is the default.
7371 .Ip "\fB\-mint64\fR" 4
7372 .IX Item "-mint64"
7373 Force \f(CW\*(C`int\*(C'\fR and \f(CW\*(C`long\*(C'\fR types to be 64 bits wide.  See
7374 \&\fB\-mlong32\fR for an explanation of the default and the way
7375 that the pointer size is determined.
7376 .Ip "\fB\-mlong64\fR" 4
7377 .IX Item "-mlong64"
7378 Force \f(CW\*(C`long\*(C'\fR types to be 64 bits wide.  See \fB\-mlong32\fR for
7379 an explanation of the default and the way that the pointer size is
7380 determined.
7381 .Ip "\fB\-mlong32\fR" 4
7382 .IX Item "-mlong32"
7383 Force \f(CW\*(C`long\*(C'\fR, \f(CW\*(C`int\*(C'\fR, and pointer types to be 32 bits wide.
7385 The default size of \f(CW\*(C`int\*(C'\fRs, \f(CW\*(C`long\*(C'\fRs and pointers depends on
7386 the \s-1ABI\s0.  All the supported ABIs use 32\-bit \f(CW\*(C`int\*(C'\fRs.  The n64 \s-1ABI\s0
7387 uses 64\-bit \f(CW\*(C`long\*(C'\fRs, as does the 64\-bit \s-1EABI\s0; the others use
7388 32\-bit \f(CW\*(C`long\*(C'\fRs.  Pointers are the same size as \f(CW\*(C`long\*(C'\fRs,
7389 or the same size as integer registers, whichever is smaller.
7390 .Ip "\fB\-G\fR \fInum\fR" 4
7391 .IX Item "-G num"
7392 Put global and static items less than or equal to \fInum\fR bytes into
7393 the small data or bss section instead of the normal data or bss section.
7394 This allows the data to be accessed using a single instruction.
7396 All modules should be compiled with the same \fB\-G\fR \fInum\fR
7397 value.
7398 .Ip "\fB\-membedded-data\fR" 4
7399 .IX Item "-membedded-data"
7400 .PD 0
7401 .Ip "\fB\-mno-embedded-data\fR" 4
7402 .IX Item "-mno-embedded-data"
7404 Allocate variables to the read-only data section first if possible, then
7405 next in the small data section if possible, otherwise in data.  This gives
7406 slightly slower code than the default, but reduces the amount of \s-1RAM\s0 required
7407 when executing, and thus may be preferred for some embedded systems.
7408 .Ip "\fB\-muninit-const-in-rodata\fR" 4
7409 .IX Item "-muninit-const-in-rodata"
7410 .PD 0
7411 .Ip "\fB\-mno-uninit-const-in-rodata\fR" 4
7412 .IX Item "-mno-uninit-const-in-rodata"
7414 Put uninitialized \f(CW\*(C`const\*(C'\fR variables in the read-only data section.
7415 This option is only meaningful in conjunction with \fB\-membedded-data\fR.
7416 .Ip "\fB\-msplit-addresses\fR" 4
7417 .IX Item "-msplit-addresses"
7418 .PD 0
7419 .Ip "\fB\-mno-split-addresses\fR" 4
7420 .IX Item "-mno-split-addresses"
7422 Enable (disable) use of the \f(CW\*(C`%hi()\*(C'\fR and \f(CW\*(C`%lo()\*(C'\fR assembler
7423 relocation operators.  This option has been superceded by
7424 \&\fB\-mexplicit-relocs\fR but is retained for backwards compatibility.
7425 .Ip "\fB\-mexplicit-relocs\fR" 4
7426 .IX Item "-mexplicit-relocs"
7427 .PD 0
7428 .Ip "\fB\-mno-explicit-relocs\fR" 4
7429 .IX Item "-mno-explicit-relocs"
7431 Use (do not use) assembler relocation operators when dealing with symbolic
7432 addresses.  The alternative, selected by \fB\-mno-explicit-relocs\fR,
7433 is to use assembler macros instead.
7435 \&\fB\-mexplicit-relocs\fR is usually the default if \s-1GCC\s0 was
7436 configured to use an assembler that supports relocation operators.
7437 However, there are two exceptions:
7438 .RS 4
7439 .Ip "\(bu" 4
7440 \&\s-1GCC\s0 is not yet able to generate explicit relocations for the combination
7441 of \fB\-mabi=64\fR and \fB\-mno-abicalls\fR.  This will be addressed
7442 in a future release.
7443 .Ip "\(bu" 4
7444 The combination of \fB\-mabicalls\fR and \fB\-fno-unit-at-a-time\fR
7445 implies \fB\-mno-explicit-relocs\fR unless explicitly overridden.
7446 This is because, when generating abicalls, the choice of relocation
7447 depends on whether a symbol is local or global.  In some rare cases,
7448 \&\s-1GCC\s0 will not be able to decide this until the whole compilation unit
7449 has been read.
7451 .RS 4
7453 .Ip "\fB\-mrnames\fR" 4
7454 .IX Item "-mrnames"
7455 .PD 0
7456 .Ip "\fB\-mno-rnames\fR" 4
7457 .IX Item "-mno-rnames"
7459 Generate (do not generate) code that refers to registers using their
7460 software names.  The default is \fB\-mno-rnames\fR, which tells \s-1GCC\s0
7461 to use hardware names like \fB$4\fR instead of software names like
7462 \&\fBa0\fR.  The only assembler known to support \fB\-rnames\fR is
7463 the Algorithmics assembler.
7464 .Ip "\fB\-mcheck-zero-division\fR" 4
7465 .IX Item "-mcheck-zero-division"
7466 .PD 0
7467 .Ip "\fB\-mno-check-zero-division\fR" 4
7468 .IX Item "-mno-check-zero-division"
7470 Trap (do not trap) on integer division by zero.  The default is
7471 \&\fB\-mcheck-zero-division\fR.
7472 .Ip "\fB\-mmemcpy\fR" 4
7473 .IX Item "-mmemcpy"
7474 .PD 0
7475 .Ip "\fB\-mno-memcpy\fR" 4
7476 .IX Item "-mno-memcpy"
7478 Force (do not force) the use of \f(CW\*(C`memcpy()\*(C'\fR for non-trivial block
7479 moves.  The default is \fB\-mno-memcpy\fR, which allows \s-1GCC\s0 to inline
7480 most constant-sized copies.
7481 .Ip "\fB\-mlong-calls\fR" 4
7482 .IX Item "-mlong-calls"
7483 .PD 0
7484 .Ip "\fB\-mno-long-calls\fR" 4
7485 .IX Item "-mno-long-calls"
7487 Disable (do not disable) use of the \f(CW\*(C`jal\*(C'\fR instruction.  Calling
7488 functions using \f(CW\*(C`jal\*(C'\fR is more efficient but requires the caller
7489 and callee to be in the same 256 megabyte segment.
7491 This option has no effect on abicalls code.  The default is
7492 \&\fB\-mno-long-calls\fR.
7493 .Ip "\fB\-mmad\fR" 4
7494 .IX Item "-mmad"
7495 .PD 0
7496 .Ip "\fB\-mno-mad\fR" 4
7497 .IX Item "-mno-mad"
7499 Enable (disable) use of the \f(CW\*(C`mad\*(C'\fR, \f(CW\*(C`madu\*(C'\fR and \f(CW\*(C`mul\*(C'\fR
7500 instructions, as provided by the R4650 \s-1ISA\s0.
7501 .Ip "\fB\-mfused-madd\fR" 4
7502 .IX Item "-mfused-madd"
7503 .PD 0
7504 .Ip "\fB\-mno-fused-madd\fR" 4
7505 .IX Item "-mno-fused-madd"
7507 Enable (disable) use of the floating point multiply-accumulate
7508 instructions, when they are available.  The default is
7509 \&\fB\-mfused-madd\fR.
7511 When multiply-accumulate instructions are used, the intermediate
7512 product is calculated to infinite precision and is not subject to
7513 the \s-1FCSR\s0 Flush to Zero bit.  This may be undesirable in some
7514 circumstances.
7515 .Ip "\fB\-nocpp\fR" 4
7516 .IX Item "-nocpp"
7517 Tell the \s-1MIPS\s0 assembler to not run its preprocessor over user
7518 assembler files (with a \fB.s\fR suffix) when assembling them.
7519 .Ip "\fB\-mfix-sb1\fR" 4
7520 .IX Item "-mfix-sb1"
7521 .PD 0
7522 .Ip "\fB\-mno-fix-sb1\fR" 4
7523 .IX Item "-mno-fix-sb1"
7525 Work around certain \s-1SB-1\s0 \s-1CPU\s0 core errata.
7526 (This flag currently works around the \s-1SB-1\s0 revision 2
7527 ``F1'' and ``F2'' floating point errata.)
7528 .Ip "\fB\-mflush-func=\fR\fIfunc\fR" 4
7529 .IX Item "-mflush-func=func"
7530 .PD 0
7531 .Ip "\fB\-mno-flush-func\fR" 4
7532 .IX Item "-mno-flush-func"
7534 Specifies the function to call to flush the I and D caches, or to not
7535 call any such function.  If called, the function must take the same
7536 arguments as the common \f(CW\*(C`_flush_func()\*(C'\fR, that is, the address of the
7537 memory range for which the cache is being flushed, the size of the
7538 memory range, and the number 3 (to flush both caches).  The default
7539 depends on the target \s-1GCC\s0 was configured for, but commonly is either
7540 \&\fB_flush_func\fR or \fB_\|_cpu_flush\fR.
7541 .Ip "\fB\-mbranch-likely\fR" 4
7542 .IX Item "-mbranch-likely"
7543 .PD 0
7544 .Ip "\fB\-mno-branch-likely\fR" 4
7545 .IX Item "-mno-branch-likely"
7547 Enable or disable use of Branch Likely instructions, regardless of the
7548 default for the selected architecture.  By default, Branch Likely
7549 instructions may be generated if they are supported by the selected
7550 architecture.  An exception is for the \s-1MIPS32\s0 and \s-1MIPS64\s0 architectures
7551 and processors which implement those architectures; for those, Branch
7552 Likely instructions will not be generated by default because the \s-1MIPS32\s0
7553 and \s-1MIPS64\s0 architectures specifically deprecate their use.
7555 .I "Intel 386 and \s-1AMD\s0 x86\-64 Options"
7556 .IX Subsection "Intel 386 and AMD x86-64 Options"
7558 These \fB\-m\fR options are defined for the i386 and x86\-64 family of
7559 computers:
7560 .Ip "\fB\-mtune=\fR\fIcpu-type\fR" 4
7561 .IX Item "-mtune=cpu-type"
7562 Tune to \fIcpu-type\fR everything applicable about the generated code, except
7563 for the \s-1ABI\s0 and the set of available instructions.  The choices for
7564 \&\fIcpu-type\fR are:
7565 .RS 4
7566 .Ip "\fIi386\fR" 4
7567 .IX Item "i386"
7568 Original Intel's i386 \s-1CPU\s0.
7569 .Ip "\fIi486\fR" 4
7570 .IX Item "i486"
7571 Intel's i486 \s-1CPU\s0.  (No scheduling is implemented for this chip.)
7572 .Ip "\fIi586, pentium\fR" 4
7573 .IX Item "i586, pentium"
7574 Intel Pentium \s-1CPU\s0 with no \s-1MMX\s0 support.
7575 .Ip "\fIpentium-mmx\fR" 4
7576 .IX Item "pentium-mmx"
7577 Intel PentiumMMX \s-1CPU\s0 based on Pentium core with \s-1MMX\s0 instruction set support.
7578 .Ip "\fIi686, pentiumpro\fR" 4
7579 .IX Item "i686, pentiumpro"
7580 Intel PentiumPro \s-1CPU\s0.
7581 .Ip "\fIpentium2\fR" 4
7582 .IX Item "pentium2"
7583 Intel Pentium2 \s-1CPU\s0 based on PentiumPro core with \s-1MMX\s0 instruction set support.
7584 .Ip "\fIpentium3, pentium3m\fR" 4
7585 .IX Item "pentium3, pentium3m"
7586 Intel Pentium3 \s-1CPU\s0 based on PentiumPro core with \s-1MMX\s0 and \s-1SSE\s0 instruction set
7587 support.
7588 .Ip "\fIpentium-m\fR" 4
7589 .IX Item "pentium-m"
7590 Low power version of Intel Pentium3 \s-1CPU\s0 with \s-1MMX\s0, \s-1SSE\s0 and \s-1SSE2\s0 instruction set
7591 support.  Used by Centrino notebooks.
7592 .Ip "\fIpentium4, pentium4m\fR" 4
7593 .IX Item "pentium4, pentium4m"
7594 Intel Pentium4 \s-1CPU\s0 with \s-1MMX\s0, \s-1SSE\s0 and \s-1SSE2\s0 instruction set support.
7595 .Ip "\fIprescott\fR" 4
7596 .IX Item "prescott"
7597 Improved version of Intel Pentium4 \s-1CPU\s0 with \s-1MMX\s0, \s-1SSE\s0, \s-1SSE2\s0 and \s-1SSE3\s0 instruction
7598 set support.
7599 .Ip "\fInocona\fR" 4
7600 .IX Item "nocona"
7601 Improved version of Intel Pentium4 \s-1CPU\s0 with 64\-bit extensions, \s-1MMX\s0, \s-1SSE\s0,
7602 \&\s-1SSE2\s0 and \s-1SSE3\s0 instruction set support.
7603 .Ip "\fIk6\fR" 4
7604 .IX Item "k6"
7605 \&\s-1AMD\s0 K6 \s-1CPU\s0 with \s-1MMX\s0 instruction set support.
7606 .Ip "\fIk6\-2, k6\-3\fR" 4
7607 .IX Item "k6-2, k6-3"
7608 Improved versions of \s-1AMD\s0 K6 \s-1CPU\s0 with \s-1MMX\s0 and 3dNOW! instruction set support.
7609 .Ip "\fIathlon, athlon-tbird\fR" 4
7610 .IX Item "athlon, athlon-tbird"
7611 \&\s-1AMD\s0 Athlon \s-1CPU\s0 with \s-1MMX\s0, 3dNOW!, enhanced 3dNOW! and \s-1SSE\s0 prefetch instructions
7612 support.
7613 .Ip "\fIathlon-4, athlon-xp, athlon-mp\fR" 4
7614 .IX Item "athlon-4, athlon-xp, athlon-mp"
7615 Improved \s-1AMD\s0 Athlon \s-1CPU\s0 with \s-1MMX\s0, 3dNOW!, enhanced 3dNOW! and full \s-1SSE\s0
7616 instruction set support.
7617 .Ip "\fIk8, opteron, athlon64, athlon-fx\fR" 4
7618 .IX Item "k8, opteron, athlon64, athlon-fx"
7619 \&\s-1AMD\s0 K8 core based CPUs with x86\-64 instruction set support.  (This supersets
7620 \&\s-1MMX\s0, \s-1SSE\s0, \s-1SSE2\s0, 3dNOW!, enhanced 3dNOW! and 64\-bit instruction set extensions.)
7621 .Ip "\fIwinchip-c6\fR" 4
7622 .IX Item "winchip-c6"
7623 \&\s-1IDT\s0 Winchip C6 \s-1CPU\s0, dealt in same way as i486 with additional \s-1MMX\s0 instruction
7624 set support.
7625 .Ip "\fIwinchip2\fR" 4
7626 .IX Item "winchip2"
7627 \&\s-1IDT\s0 Winchip2 \s-1CPU\s0, dealt in same way as i486 with additional \s-1MMX\s0 and 3dNOW!
7628 instruction set support.
7629 .Ip "\fIc3\fR" 4
7630 .IX Item "c3"
7631 Via C3 \s-1CPU\s0 with \s-1MMX\s0 and 3dNOW!  instruction set support.  (No scheduling is
7632 implemented for this chip.)
7633 .Ip "\fIc3\-2\fR" 4
7634 .IX Item "c3-2"
7635 Via C3\-2 \s-1CPU\s0 with \s-1MMX\s0 and \s-1SSE\s0 instruction set support.  (No scheduling is
7636 implemented for this chip.)
7638 .RS 4
7640 While picking a specific \fIcpu-type\fR will schedule things appropriately
7641 for that particular chip, the compiler will not generate any code that
7642 does not run on the i386 without the \fB\-march=\fR\fIcpu-type\fR option
7643 being used.
7645 .Ip "\fB\-march=\fR\fIcpu-type\fR" 4
7646 .IX Item "-march=cpu-type"
7647 Generate instructions for the machine type \fIcpu-type\fR.  The choices
7648 for \fIcpu-type\fR are the same as for \fB\-mtune\fR.  Moreover,
7649 specifying \fB\-march=\fR\fIcpu-type\fR implies \fB\-mtune=\fR\fIcpu-type\fR.
7650 .Ip "\fB\-mcpu=\fR\fIcpu-type\fR" 4
7651 .IX Item "-mcpu=cpu-type"
7652 A deprecated synonym for \fB\-mtune\fR.
7653 .Ip "\fB\-m386\fR" 4
7654 .IX Item "-m386"
7655 .PD 0
7656 .Ip "\fB\-m486\fR" 4
7657 .IX Item "-m486"
7658 .Ip "\fB\-mpentium\fR" 4
7659 .IX Item "-mpentium"
7660 .Ip "\fB\-mpentiumpro\fR" 4
7661 .IX Item "-mpentiumpro"
7663 These options are synonyms for \fB\-mtune=i386\fR, \fB\-mtune=i486\fR,
7664 \&\fB\-mtune=pentium\fR, and \fB\-mtune=pentiumpro\fR respectively.
7665 These synonyms are deprecated.
7666 .Ip "\fB\-mfpmath=\fR\fIunit\fR" 4
7667 .IX Item "-mfpmath=unit"
7668 Generate floating point arithmetics for selected unit \fIunit\fR.  The choices
7669 for \fIunit\fR are:
7670 .RS 4
7671 .Ip "\fB387\fR" 4
7672 .IX Item "387"
7673 Use the standard 387 floating point coprocessor present majority of chips and
7674 emulated otherwise.  Code compiled with this option will run almost everywhere.
7675 The temporary results are computed in 80bit precision instead of precision
7676 specified by the type resulting in slightly different results compared to most
7677 of other chips. See \fB\-ffloat-store\fR for more detailed description.
7679 This is the default choice for i386 compiler.
7680 .Ip "\fBsse\fR" 4
7681 .IX Item "sse"
7682 Use scalar floating point instructions present in the \s-1SSE\s0 instruction set.
7683 This instruction set is supported by Pentium3 and newer chips, in the \s-1AMD\s0 line
7684 by Athlon-4, Athlon-xp and Athlon-mp chips.  The earlier version of \s-1SSE\s0
7685 instruction set supports only single precision arithmetics, thus the double and
7686 extended precision arithmetics is still done using 387.  Later version, present
7687 only in Pentium4 and the future \s-1AMD\s0 x86\-64 chips supports double precision
7688 arithmetics too.
7690 For i387 you need to use \fB\-march=\fR\fIcpu-type\fR, \fB\-msse\fR or
7691 \&\fB\-msse2\fR switches to enable \s-1SSE\s0 extensions and make this option
7692 effective.  For x86\-64 compiler, these extensions are enabled by default.
7694 The resulting code should be considerably faster in the majority of cases and avoid
7695 the numerical instability problems of 387 code, but may break some existing
7696 code that expects temporaries to be 80bit.
7698 This is the default choice for the x86\-64 compiler.
7699 .Ip "\fBsse,387\fR" 4
7700 .IX Item "sse,387"
7701 Attempt to utilize both instruction sets at once.  This effectively double the
7702 amount of available registers and on chips with separate execution units for
7703 387 and \s-1SSE\s0 the execution resources too.  Use this option with care, as it is
7704 still experimental, because the \s-1GCC\s0 register allocator does not model separate
7705 functional units well resulting in instable performance.
7707 .RS 4
7709 .Ip "\fB\-masm=\fR\fIdialect\fR" 4
7710 .IX Item "-masm=dialect"
7711 Output asm instructions using selected \fIdialect\fR. Supported choices are
7712 \&\fBintel\fR or \fBatt\fR (the default one).
7713 .Ip "\fB\-mieee-fp\fR" 4
7714 .IX Item "-mieee-fp"
7715 .PD 0
7716 .Ip "\fB\-mno-ieee-fp\fR" 4
7717 .IX Item "-mno-ieee-fp"
7719 Control whether or not the compiler uses \s-1IEEE\s0 floating point
7720 comparisons.  These handle correctly the case where the result of a
7721 comparison is unordered.
7722 .Ip "\fB\-msoft-float\fR" 4
7723 .IX Item "-msoft-float"
7724 Generate output containing library calls for floating point.
7725 \&\fBWarning:\fR the requisite libraries are not part of \s-1GCC\s0.
7726 Normally the facilities of the machine's usual C compiler are used, but
7727 this can't be done directly in cross-compilation.  You must make your
7728 own arrangements to provide suitable library functions for
7729 cross-compilation.
7731 On machines where a function returns floating point results in the 80387
7732 register stack, some floating point opcodes may be emitted even if
7733 \&\fB\-msoft-float\fR is used.
7734 .Ip "\fB\-mno-fp-ret-in-387\fR" 4
7735 .IX Item "-mno-fp-ret-in-387"
7736 Do not use the \s-1FPU\s0 registers for return values of functions.
7738 The usual calling convention has functions return values of types
7739 \&\f(CW\*(C`float\*(C'\fR and \f(CW\*(C`double\*(C'\fR in an \s-1FPU\s0 register, even if there
7740 is no \s-1FPU\s0.  The idea is that the operating system should emulate
7741 an \s-1FPU\s0.
7743 The option \fB\-mno-fp-ret-in-387\fR causes such values to be returned
7744 in ordinary \s-1CPU\s0 registers instead.
7745 .Ip "\fB\-mno-fancy-math-387\fR" 4
7746 .IX Item "-mno-fancy-math-387"
7747 Some 387 emulators do not support the \f(CW\*(C`sin\*(C'\fR, \f(CW\*(C`cos\*(C'\fR and
7748 \&\f(CW\*(C`sqrt\*(C'\fR instructions for the 387.  Specify this option to avoid
7749 generating those instructions.  This option is the default on FreeBSD,
7750 OpenBSD and NetBSD.  This option is overridden when \fB\-march\fR
7751 indicates that the target cpu will always have an \s-1FPU\s0 and so the
7752 instruction will not need emulation.  As of revision 2.6.1, these
7753 instructions are not generated unless you also use the
7754 \&\fB\-funsafe-math-optimizations\fR switch.
7755 .Ip "\fB\-malign-double\fR" 4
7756 .IX Item "-malign-double"
7757 .PD 0
7758 .Ip "\fB\-mno-align-double\fR" 4
7759 .IX Item "-mno-align-double"
7761 Control whether \s-1GCC\s0 aligns \f(CW\*(C`double\*(C'\fR, \f(CW\*(C`long double\*(C'\fR, and
7762 \&\f(CW\*(C`long long\*(C'\fR variables on a two word boundary or a one word
7763 boundary.  Aligning \f(CW\*(C`double\*(C'\fR variables on a two word boundary will
7764 produce code that runs somewhat faster on a \fBPentium\fR at the
7765 expense of more memory.
7767 \&\fBWarning:\fR if you use the \fB\-malign-double\fR switch,
7768 structures containing the above types will be aligned differently than
7769 the published application binary interface specifications for the 386
7770 and will not be binary compatible with structures in code compiled
7771 without that switch.
7772 .Ip "\fB\-m96bit-long-double\fR" 4
7773 .IX Item "-m96bit-long-double"
7774 .PD 0
7775 .Ip "\fB\-m128bit-long-double\fR" 4
7776 .IX Item "-m128bit-long-double"
7778 These switches control the size of \f(CW\*(C`long double\*(C'\fR type. The i386
7779 application binary interface specifies the size to be 96 bits,
7780 so \fB\-m96bit-long-double\fR is the default in 32 bit mode.
7782 Modern architectures (Pentium and newer) would prefer \f(CW\*(C`long double\*(C'\fR
7783 to be aligned to an 8 or 16 byte boundary.  In arrays or structures
7784 conforming to the \s-1ABI\s0, this would not be possible.  So specifying a
7785 \&\fB\-m128bit-long-double\fR will align \f(CW\*(C`long double\*(C'\fR
7786 to a 16 byte boundary by padding the \f(CW\*(C`long double\*(C'\fR with an additional
7787 32 bit zero.
7789 In the x86\-64 compiler, \fB\-m128bit-long-double\fR is the default choice as
7790 its \s-1ABI\s0 specifies that \f(CW\*(C`long double\*(C'\fR is to be aligned on 16 byte boundary.
7792 Notice that neither of these options enable any extra precision over the x87
7793 standard of 80 bits for a \f(CW\*(C`long double\*(C'\fR.
7795 \&\fBWarning:\fR if you override the default value for your target \s-1ABI\s0, the
7796 structures and arrays containing \f(CW\*(C`long double\*(C'\fR variables will change
7797 their size as well as function calling convention for function taking
7798 \&\f(CW\*(C`long double\*(C'\fR will be modified.  Hence they will not be binary
7799 compatible with arrays or structures in code compiled without that switch.
7800 .Ip "\fB\-msvr3\-shlib\fR" 4
7801 .IX Item "-msvr3-shlib"
7802 .PD 0
7803 .Ip "\fB\-mno-svr3\-shlib\fR" 4
7804 .IX Item "-mno-svr3-shlib"
7806 Control whether \s-1GCC\s0 places uninitialized local variables into the
7807 \&\f(CW\*(C`bss\*(C'\fR or \f(CW\*(C`data\*(C'\fR segments.  \fB\-msvr3\-shlib\fR places them
7808 into \f(CW\*(C`bss\*(C'\fR.  These options are meaningful only on System V Release 3.
7809 .Ip "\fB\-mrtd\fR" 4
7810 .IX Item "-mrtd"
7811 Use a different function-calling convention, in which functions that
7812 take a fixed number of arguments return with the \f(CW\*(C`ret\*(C'\fR \fInum\fR
7813 instruction, which pops their arguments while returning.  This saves one
7814 instruction in the caller since there is no need to pop the arguments
7815 there.
7817 You can specify that an individual function is called with this calling
7818 sequence with the function attribute \fBstdcall\fR.  You can also
7819 override the \fB\-mrtd\fR option by using the function attribute
7820 \&\fBcdecl\fR.  
7822 \&\fBWarning:\fR this calling convention is incompatible with the one
7823 normally used on Unix, so you cannot use it if you need to call
7824 libraries compiled with the Unix compiler.
7826 Also, you must provide function prototypes for all functions that
7827 take variable numbers of arguments (including \f(CW\*(C`printf\*(C'\fR);
7828 otherwise incorrect code will be generated for calls to those
7829 functions.
7831 In addition, seriously incorrect code will result if you call a
7832 function with too many arguments.  (Normally, extra arguments are
7833 harmlessly ignored.)
7834 .Ip "\fB\-mregparm=\fR\fInum\fR" 4
7835 .IX Item "-mregparm=num"
7836 Control how many registers are used to pass integer arguments.  By
7837 default, no registers are used to pass arguments, and at most 3
7838 registers can be used.  You can control this behavior for a specific
7839 function by using the function attribute \fBregparm\fR.
7841 \&\fBWarning:\fR if you use this switch, and
7842 \&\fInum\fR is nonzero, then you must build all modules with the same
7843 value, including any libraries.  This includes the system libraries and
7844 startup modules.
7845 .Ip "\fB\-mpreferred-stack-boundary=\fR\fInum\fR" 4
7846 .IX Item "-mpreferred-stack-boundary=num"
7847 Attempt to keep the stack boundary aligned to a 2 raised to \fInum\fR
7848 byte boundary.  If \fB\-mpreferred-stack-boundary\fR is not specified,
7849 the default is 4 (16 bytes or 128 bits), except when optimizing for code
7850 size (\fB\-Os\fR), in which case the default is the minimum correct
7851 alignment (4 bytes for x86, and 8 bytes for x86\-64).
7853 On Pentium and PentiumPro, \f(CW\*(C`double\*(C'\fR and \f(CW\*(C`long double\*(C'\fR values
7854 should be aligned to an 8 byte boundary (see \fB\-malign-double\fR) or
7855 suffer significant run time performance penalties.  On Pentium \s-1III\s0, the
7856 Streaming \s-1SIMD\s0 Extension (\s-1SSE\s0) data type \f(CW\*(C`_\|_m128\*(C'\fR suffers similar
7857 penalties if it is not 16 byte aligned.
7859 To ensure proper alignment of this values on the stack, the stack boundary
7860 must be as aligned as that required by any value stored on the stack.
7861 Further, every function must be generated such that it keeps the stack
7862 aligned.  Thus calling a function compiled with a higher preferred
7863 stack boundary from a function compiled with a lower preferred stack
7864 boundary will most likely misalign the stack.  It is recommended that
7865 libraries that use callbacks always use the default setting.
7867 This extra alignment does consume extra stack space, and generally
7868 increases code size.  Code that is sensitive to stack space usage, such
7869 as embedded systems and operating system kernels, may want to reduce the
7870 preferred alignment to \fB\-mpreferred-stack-boundary=2\fR.
7871 .Ip "\fB\-mmmx\fR" 4
7872 .IX Item "-mmmx"
7873 .PD 0
7874 .Ip "\fB\-mno-mmx\fR" 4
7875 .IX Item "-mno-mmx"
7876 .Ip "\fB\-msse\fR" 4
7877 .IX Item "-msse"
7878 .Ip "\fB\-mno-sse\fR" 4
7879 .IX Item "-mno-sse"
7880 .Ip "\fB\-msse2\fR" 4
7881 .IX Item "-msse2"
7882 .Ip "\fB\-mno-sse2\fR" 4
7883 .IX Item "-mno-sse2"
7884 .Ip "\fB\-msse3\fR" 4
7885 .IX Item "-msse3"
7886 .Ip "\fB\-mno-sse3\fR" 4
7887 .IX Item "-mno-sse3"
7888 .Ip "\fB\-m3dnow\fR" 4
7889 .IX Item "-m3dnow"
7890 .Ip "\fB\-mno-3dnow\fR" 4
7891 .IX Item "-mno-3dnow"
7893 These switches enable or disable the use of built-in functions that allow
7894 direct access to the \s-1MMX\s0, \s-1SSE\s0, \s-1SSE2\s0, \s-1SSE3\s0 and 3Dnow extensions of the
7895 instruction set.
7897 To have \s-1SSE/SSE2\s0 instructions generated automatically from floating-point
7898 code, see \fB\-mfpmath=sse\fR.
7899 .Ip "\fB\-mpush-args\fR" 4
7900 .IX Item "-mpush-args"
7901 .PD 0
7902 .Ip "\fB\-mno-push-args\fR" 4
7903 .IX Item "-mno-push-args"
7905 Use \s-1PUSH\s0 operations to store outgoing parameters.  This method is shorter
7906 and usually equally fast as method using \s-1SUB/MOV\s0 operations and is enabled
7907 by default.  In some cases disabling it may improve performance because of
7908 improved scheduling and reduced dependencies.
7909 .Ip "\fB\-maccumulate-outgoing-args\fR" 4
7910 .IX Item "-maccumulate-outgoing-args"
7911 If enabled, the maximum amount of space required for outgoing arguments will be
7912 computed in the function prologue.  This is faster on most modern CPUs
7913 because of reduced dependencies, improved scheduling and reduced stack usage
7914 when preferred stack boundary is not equal to 2.  The drawback is a notable
7915 increase in code size.  This switch implies \fB\-mno-push-args\fR.
7916 .Ip "\fB\-mthreads\fR" 4
7917 .IX Item "-mthreads"
7918 Support thread-safe exception handling on \fBMingw32\fR.  Code that relies
7919 on thread-safe exception handling must compile and link all code with the
7920 \&\fB\-mthreads\fR option.  When compiling, \fB\-mthreads\fR defines
7921 \&\fB\-D_MT\fR; when linking, it links in a special thread helper library
7922 \&\fB\-lmingwthrd\fR which cleans up per thread exception handling data.
7923 .Ip "\fB\-mno-align-stringops\fR" 4
7924 .IX Item "-mno-align-stringops"
7925 Do not align destination of inlined string operations.  This switch reduces
7926 code size and improves performance in case the destination is already aligned,
7927 but \s-1GCC\s0 doesn't know about it.
7928 .Ip "\fB\-minline-all-stringops\fR" 4
7929 .IX Item "-minline-all-stringops"
7930 By default \s-1GCC\s0 inlines string operations only when destination is known to be
7931 aligned at least to 4 byte boundary.  This enables more inlining, increase code
7932 size, but may improve performance of code that depends on fast memcpy, strlen
7933 and memset for short lengths.
7934 .Ip "\fB\-momit-leaf-frame-pointer\fR" 4
7935 .IX Item "-momit-leaf-frame-pointer"
7936 Don't keep the frame pointer in a register for leaf functions.  This
7937 avoids the instructions to save, set up and restore frame pointers and
7938 makes an extra register available in leaf functions.  The option
7939 \&\fB\-fomit-frame-pointer\fR removes the frame pointer for all functions
7940 which might make debugging harder.
7941 .Ip "\fB\-mtls-direct-seg-refs\fR" 4
7942 .IX Item "-mtls-direct-seg-refs"
7943 .PD 0
7944 .Ip "\fB\-mno-tls-direct-seg-refs\fR" 4
7945 .IX Item "-mno-tls-direct-seg-refs"
7947 Controls whether \s-1TLS\s0 variables may be accessed with offsets from the
7948 \&\s-1TLS\s0 segment register (\f(CW\*(C`%gs\*(C'\fR for 32\-bit, \f(CW\*(C`%fs\*(C'\fR for 64\-bit),
7949 or whether the thread base pointer must be added.  Whether or not this
7950 is legal depends on the operating system, and whether it maps the
7951 segment to cover the entire \s-1TLS\s0 area.
7953 For systems that use \s-1GNU\s0 libc, the default is on.
7955 These \fB\-m\fR switches are supported in addition to the above
7956 on \s-1AMD\s0 x86\-64 processors in 64\-bit environments.
7957 .Ip "\fB\-m32\fR" 4
7958 .IX Item "-m32"
7959 .PD 0
7960 .Ip "\fB\-m64\fR" 4
7961 .IX Item "-m64"
7963 Generate code for a 32\-bit or 64\-bit environment.
7964 The 32\-bit environment sets int, long and pointer to 32 bits and
7965 generates code that runs on any i386 system.
7966 The 64\-bit environment sets int to 32 bits and long and pointer
7967 to 64 bits and generates code for \s-1AMD\s0's x86\-64 architecture.
7968 .Ip "\fB\-mno-red-zone\fR" 4
7969 .IX Item "-mno-red-zone"
7970 Do not use a so called red zone for x86\-64 code.  The red zone is mandated
7971 by the x86\-64 \s-1ABI\s0, it is a 128\-byte area beyond the location of the
7972 stack pointer that will not be modified by signal or interrupt handlers
7973 and therefore can be used for temporary data without adjusting the stack
7974 pointer.  The flag \fB\-mno-red-zone\fR disables this red zone.
7975 .Ip "\fB\-mcmodel=small\fR" 4
7976 .IX Item "-mcmodel=small"
7977 Generate code for the small code model: the program and its symbols must
7978 be linked in the lower 2 \s-1GB\s0 of the address space.  Pointers are 64 bits.
7979 Programs can be statically or dynamically linked.  This is the default
7980 code model.
7981 .Ip "\fB\-mcmodel=kernel\fR" 4
7982 .IX Item "-mcmodel=kernel"
7983 Generate code for the kernel code model.  The kernel runs in the
7984 negative 2 \s-1GB\s0 of the address space.
7985 This model has to be used for Linux kernel code.
7986 .Ip "\fB\-mcmodel=medium\fR" 4
7987 .IX Item "-mcmodel=medium"
7988 Generate code for the medium model: The program is linked in the lower 2
7989 \&\s-1GB\s0 of the address space but symbols can be located anywhere in the
7990 address space.  Programs can be statically or dynamically linked, but
7991 building of shared libraries are not supported with the medium model.
7992 .Ip "\fB\-mcmodel=large\fR" 4
7993 .IX Item "-mcmodel=large"
7994 Generate code for the large model: This model makes no assumptions
7995 about addresses and sizes of sections.  Currently \s-1GCC\s0 does not implement
7996 this model.
7997 .Ip "\fB\-mstack-arg-probe\fR" 4
7998 .IX Item "-mstack-arg-probe"
7999 Emit code in function prologue to probe the stack when allocating more
8000 than \s-1CHECK_STACK_LIMIT\s0 bytes in one go. 
8002 Currently, this is the default on windows systems (cygwin and mingw32),
8003 which define \s-1CHECK_STACK_LIMIT\s0 as 4000. On these systems, touching the
8004 stack at 4K increments is necessary to ensure that the guard pages used
8005 by the \s-1OS\s0 virtual memory manger are allocated in correct sequence.
8007 .I "\s-1HPPA\s0 Options"
8008 .IX Subsection "HPPA Options"
8010 These \fB\-m\fR options are defined for the \s-1HPPA\s0 family of computers:
8011 .Ip "\fB\-march=\fR\fIarchitecture-type\fR" 4
8012 .IX Item "-march=architecture-type"
8013 Generate code for the specified architecture.  The choices for
8014 \&\fIarchitecture-type\fR are \fB1.0\fR for \s-1PA\s0 1.0, \fB1.1\fR for \s-1PA\s0
8015 1.1, and \fB2.0\fR for \s-1PA\s0 2.0 processors.  Refer to
8016 \&\fI/usr/lib/sched.models\fR on an \s-1HP-UX\s0 system to determine the proper
8017 architecture option for your machine.  Code compiled for lower numbered
8018 architectures will run on higher numbered architectures, but not the
8019 other way around.
8021 \&\s-1PA\s0 2.0 support currently requires gas snapshot 19990413 or later.  The
8022 next release of binutils (current is 2.9.1) will probably contain \s-1PA\s0 2.0
8023 support.
8024 .Ip "\fB\-mpa-risc-1\-0\fR" 4
8025 .IX Item "-mpa-risc-1-0"
8026 .PD 0
8027 .Ip "\fB\-mpa-risc-1\-1\fR" 4
8028 .IX Item "-mpa-risc-1-1"
8029 .Ip "\fB\-mpa-risc-2\-0\fR" 4
8030 .IX Item "-mpa-risc-2-0"
8032 Synonyms for \fB\-march=1.0\fR, \fB\-march=1.1\fR, and \fB\-march=2.0\fR respectively.
8033 .Ip "\fB\-mbig-switch\fR" 4
8034 .IX Item "-mbig-switch"
8035 Generate code suitable for big switch tables.  Use this option only if
8036 the assembler/linker complain about out of range branches within a switch
8037 table.
8038 .Ip "\fB\-mjump-in-delay\fR" 4
8039 .IX Item "-mjump-in-delay"
8040 Fill delay slots of function calls with unconditional jump instructions
8041 by modifying the return pointer for the function call to be the target
8042 of the conditional jump.
8043 .Ip "\fB\-mdisable-fpregs\fR" 4
8044 .IX Item "-mdisable-fpregs"
8045 Prevent floating point registers from being used in any manner.  This is
8046 necessary for compiling kernels which perform lazy context switching of
8047 floating point registers.  If you use this option and attempt to perform
8048 floating point operations, the compiler will abort.
8049 .Ip "\fB\-mdisable-indexing\fR" 4
8050 .IX Item "-mdisable-indexing"
8051 Prevent the compiler from using indexing address modes.  This avoids some
8052 rather obscure problems when compiling \s-1MIG\s0 generated code under \s-1MACH\s0.
8053 .Ip "\fB\-mno-space-regs\fR" 4
8054 .IX Item "-mno-space-regs"
8055 Generate code that assumes the target has no space registers.  This allows
8056 \&\s-1GCC\s0 to generate faster indirect calls and use unscaled index address modes.
8058 Such code is suitable for level 0 \s-1PA\s0 systems and kernels.
8059 .Ip "\fB\-mfast-indirect-calls\fR" 4
8060 .IX Item "-mfast-indirect-calls"
8061 Generate code that assumes calls never cross space boundaries.  This
8062 allows \s-1GCC\s0 to emit code which performs faster indirect calls.
8064 This option will not work in the presence of shared libraries or nested
8065 functions.
8066 .Ip "\fB\-mlong-load-store\fR" 4
8067 .IX Item "-mlong-load-store"
8068 Generate 3\-instruction load and store sequences as sometimes required by
8069 the \s-1HP-UX\s0 10 linker.  This is equivalent to the \fB+k\fR option to
8070 the \s-1HP\s0 compilers.
8071 .Ip "\fB\-mportable-runtime\fR" 4
8072 .IX Item "-mportable-runtime"
8073 Use the portable calling conventions proposed by \s-1HP\s0 for \s-1ELF\s0 systems.
8074 .Ip "\fB\-mgas\fR" 4
8075 .IX Item "-mgas"
8076 Enable the use of assembler directives only \s-1GAS\s0 understands.
8077 .Ip "\fB\-mschedule=\fR\fIcpu-type\fR" 4
8078 .IX Item "-mschedule=cpu-type"
8079 Schedule code according to the constraints for the machine type
8080 \&\fIcpu-type\fR.  The choices for \fIcpu-type\fR are \fB700\fR
8081 \&\fB7100\fR, \fB7100LC\fR, \fB7200\fR, \fB7300\fR and \fB8000\fR.  Refer
8082 to \fI/usr/lib/sched.models\fR on an \s-1HP-UX\s0 system to determine the
8083 proper scheduling option for your machine.  The default scheduling is
8084 \&\fB8000\fR.
8085 .Ip "\fB\-mlinker-opt\fR" 4
8086 .IX Item "-mlinker-opt"
8087 Enable the optimization pass in the \s-1HP-UX\s0 linker.  Note this makes symbolic
8088 debugging impossible.  It also triggers a bug in the \s-1HP-UX\s0 8 and \s-1HP-UX\s0 9
8089 linkers in which they give bogus error messages when linking some programs.
8090 .Ip "\fB\-msoft-float\fR" 4
8091 .IX Item "-msoft-float"
8092 Generate output containing library calls for floating point.
8093 \&\fBWarning:\fR the requisite libraries are not available for all \s-1HPPA\s0
8094 targets.  Normally the facilities of the machine's usual C compiler are
8095 used, but this cannot be done directly in cross-compilation.  You must make
8096 your own arrangements to provide suitable library functions for
8097 cross-compilation.  The embedded target \fBhppa1.1\-*\-pro\fR
8098 does provide software floating point support.
8100 \&\fB\-msoft-float\fR changes the calling convention in the output file;
8101 therefore, it is only useful if you compile \fIall\fR of a program with
8102 this option.  In particular, you need to compile \fIlibgcc.a\fR, the
8103 library that comes with \s-1GCC\s0, with \fB\-msoft-float\fR in order for
8104 this to work.
8105 .Ip "\fB\-msio\fR" 4
8106 .IX Item "-msio"
8107 Generate the predefine, \f(CW\*(C`_SIO\*(C'\fR, for server \s-1IO\s0.  The default is
8108 \&\fB\-mwsio\fR.  This generates the predefines, \f(CW\*(C`_\|_hp9000s700\*(C'\fR,
8109 \&\f(CW\*(C`_\|_hp9000s700_\|_\*(C'\fR and \f(CW\*(C`_WSIO\*(C'\fR, for workstation \s-1IO\s0.  These
8110 options are available under \s-1HP-UX\s0 and \s-1HI-UX\s0.
8111 .Ip "\fB\-mgnu-ld\fR" 4
8112 .IX Item "-mgnu-ld"
8113 Use \s-1GNU\s0 ld specific options.  This passes \fB\-shared\fR to ld when
8114 building a shared library.  It is the default when \s-1GCC\s0 is configured,
8115 explicitly or implicitly, with the \s-1GNU\s0 linker.  This option does not
8116 have any affect on which ld is called, it only changes what parameters
8117 are passed to that ld.  The ld that is called is determined by the
8118 \&\fB\*(--with-ld\fR configure option, \s-1GCC\s0's program search path, and
8119 finally by the user's \fB\s-1PATH\s0\fR.  The linker used by \s-1GCC\s0 can be printed
8120 using \fBwhich `gcc \-print-prog-name=ld`\fR.
8121 .Ip "\fB\-mhp-ld\fR" 4
8122 .IX Item "-mhp-ld"
8123 Use \s-1HP\s0 ld specific options.  This passes \fB\-b\fR to ld when building
8124 a shared library and passes \fB+Accept TypeMismatch\fR to ld on all
8125 links.  It is the default when \s-1GCC\s0 is configured, explicitly or
8126 implicitly, with the \s-1HP\s0 linker.  This option does not have any affect on
8127 which ld is called, it only changes what parameters are passed to that
8128 ld.  The ld that is called is determined by the \fB\*(--with-ld\fR
8129 configure option, \s-1GCC\s0's program search path, and finally by the user's
8130 \&\fB\s-1PATH\s0\fR.  The linker used by \s-1GCC\s0 can be printed using \fBwhich
8131 `gcc \-print-prog-name=ld`\fR.
8132 .Ip "\fB\-mlong-calls\fR" 4
8133 .IX Item "-mlong-calls"
8134 Generate code that uses long call sequences.  This ensures that a call
8135 is always able to reach linker generated stubs.  The default is to generate
8136 long calls only when the distance from the call site to the beginning
8137 of the function or translation unit, as the case may be, exceeds a
8138 predefined limit set by the branch type being used.  The limits for
8139 normal calls are 7,600,000 and 240,000 bytes, respectively for the
8140 \&\s-1PA\s0 2.0 and \s-1PA\s0 1.X architectures.  Sibcalls are always limited at
8141 240,000 bytes.
8143 Distances are measured from the beginning of functions when using the
8144 \&\fB\-ffunction-sections\fR option, or when using the \fB\-mgas\fR
8145 and \fB\-mno-portable-runtime\fR options together under \s-1HP-UX\s0 with
8146 the \s-1SOM\s0 linker.
8148 It is normally not desirable to use this option as it will degrade
8149 performance.  However, it may be useful in large applications,
8150 particularly when partial linking is used to build the application.
8152 The types of long calls used depends on the capabilities of the
8153 assembler and linker, and the type of code being generated.  The
8154 impact on systems that support long absolute calls, and long pic
8155 symbol-difference or pc-relative calls should be relatively small.
8156 However, an indirect call is used on 32\-bit \s-1ELF\s0 systems in pic code
8157 and it is quite long.
8158 .Ip "\fB\-nolibdld\fR" 4
8159 .IX Item "-nolibdld"
8160 Suppress the generation of link options to search libdld.sl when the
8161 \&\fB\-static\fR option is specified on \s-1HP-UX\s0 10 and later.
8162 .Ip "\fB\-static\fR" 4
8163 .IX Item "-static"
8164 The \s-1HP-UX\s0 implementation of setlocale in libc has a dependency on
8165 libdld.sl.  There isn't an archive version of libdld.sl.  Thus,
8166 when the \fB\-static\fR option is specified, special link options
8167 are needed to resolve this dependency.
8169 On \s-1HP-UX\s0 10 and later, the \s-1GCC\s0 driver adds the necessary options to
8170 link with libdld.sl when the \fB\-static\fR option is specified.
8171 This causes the resulting binary to be dynamic.  On the 64\-bit port,
8172 the linkers generate dynamic binaries by default in any case.  The
8173 \&\fB\-nolibdld\fR option can be used to prevent the \s-1GCC\s0 driver from
8174 adding these link options.
8175 .Ip "\fB\-threads\fR" 4
8176 .IX Item "-threads"
8177 Add support for multithreading with the \fIdce thread\fR library
8178 under \s-1HP-UX\s0.  This option sets flags for both the preprocessor and
8179 linker.
8181 .I "Intel 960 Options"
8182 .IX Subsection "Intel 960 Options"
8184 These \fB\-m\fR options are defined for the Intel 960 implementations:
8185 .Ip "\fB\-m\fR\fIcpu-type\fR" 4
8186 .IX Item "-mcpu-type"
8187 Assume the defaults for the machine type \fIcpu-type\fR for some of
8188 the other options, including instruction scheduling, floating point
8189 support, and addressing modes.  The choices for \fIcpu-type\fR are
8190 \&\fBka\fR, \fBkb\fR, \fBmc\fR, \fBca\fR, \fBcf\fR,
8191 \&\fBsa\fR, and \fBsb\fR.
8192 The default is
8193 \&\fBkb\fR.
8194 .Ip "\fB\-mnumerics\fR" 4
8195 .IX Item "-mnumerics"
8196 .PD 0
8197 .Ip "\fB\-msoft-float\fR" 4
8198 .IX Item "-msoft-float"
8200 The \fB\-mnumerics\fR option indicates that the processor does support
8201 floating-point instructions.  The \fB\-msoft-float\fR option indicates
8202 that floating-point support should not be assumed.
8203 .Ip "\fB\-mleaf-procedures\fR" 4
8204 .IX Item "-mleaf-procedures"
8205 .PD 0
8206 .Ip "\fB\-mno-leaf-procedures\fR" 4
8207 .IX Item "-mno-leaf-procedures"
8209 Do (or do not) attempt to alter leaf procedures to be callable with the
8210 \&\f(CW\*(C`bal\*(C'\fR instruction as well as \f(CW\*(C`call\*(C'\fR.  This will result in more
8211 efficient code for explicit calls when the \f(CW\*(C`bal\*(C'\fR instruction can be
8212 substituted by the assembler or linker, but less efficient code in other
8213 cases, such as calls via function pointers, or using a linker that doesn't
8214 support this optimization.
8215 .Ip "\fB\-mtail-call\fR" 4
8216 .IX Item "-mtail-call"
8217 .PD 0
8218 .Ip "\fB\-mno-tail-call\fR" 4
8219 .IX Item "-mno-tail-call"
8221 Do (or do not) make additional attempts (beyond those of the
8222 machine-independent portions of the compiler) to optimize tail-recursive
8223 calls into branches.  You may not want to do this because the detection of
8224 cases where this is not valid is not totally complete.  The default is
8225 \&\fB\-mno-tail-call\fR.
8226 .Ip "\fB\-mcomplex-addr\fR" 4
8227 .IX Item "-mcomplex-addr"
8228 .PD 0
8229 .Ip "\fB\-mno-complex-addr\fR" 4
8230 .IX Item "-mno-complex-addr"
8232 Assume (or do not assume) that the use of a complex addressing mode is a
8233 win on this implementation of the i960.  Complex addressing modes may not
8234 be worthwhile on the K-series, but they definitely are on the C-series.
8235 The default is currently \fB\-mcomplex-addr\fR for all processors except
8236 the \s-1CB\s0 and \s-1CC\s0.
8237 .Ip "\fB\-mcode-align\fR" 4
8238 .IX Item "-mcode-align"
8239 .PD 0
8240 .Ip "\fB\-mno-code-align\fR" 4
8241 .IX Item "-mno-code-align"
8243 Align code to 8\-byte boundaries for faster fetching (or don't bother).
8244 Currently turned on by default for C-series implementations only.
8245 .Ip "\fB\-mic-compat\fR" 4
8246 .IX Item "-mic-compat"
8247 .PD 0
8248 .Ip "\fB\-mic2.0\-compat\fR" 4
8249 .IX Item "-mic2.0-compat"
8250 .Ip "\fB\-mic3.0\-compat\fR" 4
8251 .IX Item "-mic3.0-compat"
8253 Enable compatibility with iC960 v2.0 or v3.0.
8254 .Ip "\fB\-masm-compat\fR" 4
8255 .IX Item "-masm-compat"
8256 .PD 0
8257 .Ip "\fB\-mintel-asm\fR" 4
8258 .IX Item "-mintel-asm"
8260 Enable compatibility with the iC960 assembler.
8261 .Ip "\fB\-mstrict-align\fR" 4
8262 .IX Item "-mstrict-align"
8263 .PD 0
8264 .Ip "\fB\-mno-strict-align\fR" 4
8265 .IX Item "-mno-strict-align"
8267 Do not permit (do permit) unaligned accesses.
8268 .Ip "\fB\-mold-align\fR" 4
8269 .IX Item "-mold-align"
8270 Enable structure-alignment compatibility with Intel's gcc release version
8271 1.3 (based on gcc 1.37).  This option implies \fB\-mstrict-align\fR.
8272 .Ip "\fB\-mlong-double-64\fR" 4
8273 .IX Item "-mlong-double-64"
8274 Implement type \fBlong double\fR as 64\-bit floating point numbers.
8275 Without the option \fBlong double\fR is implemented by 80\-bit
8276 floating point numbers.  The only reason we have it because there is
8277 no 128\-bit \fBlong double\fR support in \fBfp-bit.c\fR yet.  So it
8278 is only useful for people using soft-float targets.  Otherwise, we
8279 should recommend against use of it.
8281 .I "\s-1DEC\s0 Alpha Options"
8282 .IX Subsection "DEC Alpha Options"
8284 These \fB\-m\fR options are defined for the \s-1DEC\s0 Alpha implementations:
8285 .Ip "\fB\-mno-soft-float\fR" 4
8286 .IX Item "-mno-soft-float"
8287 .PD 0
8288 .Ip "\fB\-msoft-float\fR" 4
8289 .IX Item "-msoft-float"
8291 Use (do not use) the hardware floating-point instructions for
8292 floating-point operations.  When \fB\-msoft-float\fR is specified,
8293 functions in \fIlibgcc.a\fR will be used to perform floating-point
8294 operations.  Unless they are replaced by routines that emulate the
8295 floating-point operations, or compiled in such a way as to call such
8296 emulations routines, these routines will issue floating-point
8297 operations.   If you are compiling for an Alpha without floating-point
8298 operations, you must ensure that the library is built so as not to call
8299 them.
8301 Note that Alpha implementations without floating-point operations are
8302 required to have floating-point registers.
8303 .Ip "\fB\-mfp-reg\fR" 4
8304 .IX Item "-mfp-reg"
8305 .PD 0
8306 .Ip "\fB\-mno-fp-regs\fR" 4
8307 .IX Item "-mno-fp-regs"
8309 Generate code that uses (does not use) the floating-point register set.
8310 \&\fB\-mno-fp-regs\fR implies \fB\-msoft-float\fR.  If the floating-point
8311 register set is not used, floating point operands are passed in integer
8312 registers as if they were integers and floating-point results are passed
8313 in \f(CW\*(C`$0\*(C'\fR instead of \f(CW\*(C`$f0\*(C'\fR.  This is a non-standard calling sequence,
8314 so any function with a floating-point argument or return value called by code
8315 compiled with \fB\-mno-fp-regs\fR must also be compiled with that
8316 option.
8318 A typical use of this option is building a kernel that does not use,
8319 and hence need not save and restore, any floating-point registers.
8320 .Ip "\fB\-mieee\fR" 4
8321 .IX Item "-mieee"
8322 The Alpha architecture implements floating-point hardware optimized for
8323 maximum performance.  It is mostly compliant with the \s-1IEEE\s0 floating
8324 point standard.  However, for full compliance, software assistance is
8325 required.  This option generates code fully \s-1IEEE\s0 compliant code
8326 \&\fIexcept\fR that the \fIinexact-flag\fR is not maintained (see below).
8327 If this option is turned on, the preprocessor macro \f(CW\*(C`_IEEE_FP\*(C'\fR is
8328 defined during compilation.  The resulting code is less efficient but is
8329 able to correctly support denormalized numbers and exceptional \s-1IEEE\s0
8330 values such as not-a-number and plus/minus infinity.  Other Alpha
8331 compilers call this option \fB\-ieee_with_no_inexact\fR.
8332 .Ip "\fB\-mieee-with-inexact\fR" 4
8333 .IX Item "-mieee-with-inexact"
8334 This is like \fB\-mieee\fR except the generated code also maintains
8335 the \s-1IEEE\s0 \fIinexact-flag\fR.  Turning on this option causes the
8336 generated code to implement fully-compliant \s-1IEEE\s0 math.  In addition to
8337 \&\f(CW\*(C`_IEEE_FP\*(C'\fR, \f(CW\*(C`_IEEE_FP_EXACT\*(C'\fR is defined as a preprocessor
8338 macro.  On some Alpha implementations the resulting code may execute
8339 significantly slower than the code generated by default.  Since there is
8340 very little code that depends on the \fIinexact-flag\fR, you should
8341 normally not specify this option.  Other Alpha compilers call this
8342 option \fB\-ieee_with_inexact\fR.
8343 .Ip "\fB\-mfp-trap-mode=\fR\fItrap-mode\fR" 4
8344 .IX Item "-mfp-trap-mode=trap-mode"
8345 This option controls what floating-point related traps are enabled.
8346 Other Alpha compilers call this option \fB\-fptm\fR \fItrap-mode\fR.
8347 The trap mode can be set to one of four values:
8348 .RS 4
8349 .Ip "\fBn\fR" 4
8350 .IX Item "n"
8351 This is the default (normal) setting.  The only traps that are enabled
8352 are the ones that cannot be disabled in software (e.g., division by zero
8353 trap).
8354 .Ip "\fBu\fR" 4
8355 .IX Item "u"
8356 In addition to the traps enabled by \fBn\fR, underflow traps are enabled
8357 as well.
8358 .Ip "\fBsu\fR" 4
8359 .IX Item "su"
8360 Like \fBsu\fR, but the instructions are marked to be safe for software
8361 completion (see Alpha architecture manual for details).
8362 .Ip "\fBsui\fR" 4
8363 .IX Item "sui"
8364 Like \fBsu\fR, but inexact traps are enabled as well.
8366 .RS 4
8368 .Ip "\fB\-mfp-rounding-mode=\fR\fIrounding-mode\fR" 4
8369 .IX Item "-mfp-rounding-mode=rounding-mode"
8370 Selects the \s-1IEEE\s0 rounding mode.  Other Alpha compilers call this option
8371 \&\fB\-fprm\fR \fIrounding-mode\fR.  The \fIrounding-mode\fR can be one
8373 .RS 4
8374 .Ip "\fBn\fR" 4
8375 .IX Item "n"
8376 Normal \s-1IEEE\s0 rounding mode.  Floating point numbers are rounded towards
8377 the nearest machine number or towards the even machine number in case
8378 of a tie.
8379 .Ip "\fBm\fR" 4
8380 .IX Item "m"
8381 Round towards minus infinity.
8382 .Ip "\fBc\fR" 4
8383 .IX Item "c"
8384 Chopped rounding mode.  Floating point numbers are rounded towards zero.
8385 .Ip "\fBd\fR" 4
8386 .IX Item "d"
8387 Dynamic rounding mode.  A field in the floating point control register
8388 (\fIfpcr\fR, see Alpha architecture reference manual) controls the
8389 rounding mode in effect.  The C library initializes this register for
8390 rounding towards plus infinity.  Thus, unless your program modifies the
8391 \&\fIfpcr\fR, \fBd\fR corresponds to round towards plus infinity.
8393 .RS 4
8395 .Ip "\fB\-mtrap-precision=\fR\fItrap-precision\fR" 4
8396 .IX Item "-mtrap-precision=trap-precision"
8397 In the Alpha architecture, floating point traps are imprecise.  This
8398 means without software assistance it is impossible to recover from a
8399 floating trap and program execution normally needs to be terminated.
8400 \&\s-1GCC\s0 can generate code that can assist operating system trap handlers
8401 in determining the exact location that caused a floating point trap.
8402 Depending on the requirements of an application, different levels of
8403 precisions can be selected:
8404 .RS 4
8405 .Ip "\fBp\fR" 4
8406 .IX Item "p"
8407 Program precision.  This option is the default and means a trap handler
8408 can only identify which program caused a floating point exception.
8409 .Ip "\fBf\fR" 4
8410 .IX Item "f"
8411 Function precision.  The trap handler can determine the function that
8412 caused a floating point exception.
8413 .Ip "\fBi\fR" 4
8414 .IX Item "i"
8415 Instruction precision.  The trap handler can determine the exact
8416 instruction that caused a floating point exception.
8418 .RS 4
8420 Other Alpha compilers provide the equivalent options called
8421 \&\fB\-scope_safe\fR and \fB\-resumption_safe\fR.
8423 .Ip "\fB\-mieee-conformant\fR" 4
8424 .IX Item "-mieee-conformant"
8425 This option marks the generated code as \s-1IEEE\s0 conformant.  You must not
8426 use this option unless you also specify \fB\-mtrap-precision=i\fR and either
8427 \&\fB\-mfp-trap-mode=su\fR or \fB\-mfp-trap-mode=sui\fR.  Its only effect
8428 is to emit the line \fB.eflag 48\fR in the function prologue of the
8429 generated assembly file.  Under \s-1DEC\s0 Unix, this has the effect that
8430 IEEE-conformant math library routines will be linked in.
8431 .Ip "\fB\-mbuild-constants\fR" 4
8432 .IX Item "-mbuild-constants"
8433 Normally \s-1GCC\s0 examines a 32\- or 64\-bit integer constant to
8434 see if it can construct it from smaller constants in two or three
8435 instructions.  If it cannot, it will output the constant as a literal and
8436 generate code to load it from the data segment at runtime.
8438 Use this option to require \s-1GCC\s0 to construct \fIall\fR integer constants
8439 using code, even if it takes more instructions (the maximum is six).
8441 You would typically use this option to build a shared library dynamic
8442 loader.  Itself a shared library, it must relocate itself in memory
8443 before it can find the variables and constants in its own data segment.
8444 .Ip "\fB\-malpha-as\fR" 4
8445 .IX Item "-malpha-as"
8446 .PD 0
8447 .Ip "\fB\-mgas\fR" 4
8448 .IX Item "-mgas"
8450 Select whether to generate code to be assembled by the vendor-supplied
8451 assembler (\fB\-malpha-as\fR) or by the \s-1GNU\s0 assembler \fB\-mgas\fR.
8452 .Ip "\fB\-mbwx\fR" 4
8453 .IX Item "-mbwx"
8454 .PD 0
8455 .Ip "\fB\-mno-bwx\fR" 4
8456 .IX Item "-mno-bwx"
8457 .Ip "\fB\-mcix\fR" 4
8458 .IX Item "-mcix"
8459 .Ip "\fB\-mno-cix\fR" 4
8460 .IX Item "-mno-cix"
8461 .Ip "\fB\-mfix\fR" 4
8462 .IX Item "-mfix"
8463 .Ip "\fB\-mno-fix\fR" 4
8464 .IX Item "-mno-fix"
8465 .Ip "\fB\-mmax\fR" 4
8466 .IX Item "-mmax"
8467 .Ip "\fB\-mno-max\fR" 4
8468 .IX Item "-mno-max"
8470 Indicate whether \s-1GCC\s0 should generate code to use the optional \s-1BWX\s0,
8471 \&\s-1CIX\s0, \s-1FIX\s0 and \s-1MAX\s0 instruction sets.  The default is to use the instruction
8472 sets supported by the \s-1CPU\s0 type specified via \fB\-mcpu=\fR option or that
8473 of the \s-1CPU\s0 on which \s-1GCC\s0 was built if none was specified.
8474 .Ip "\fB\-mfloat-vax\fR" 4
8475 .IX Item "-mfloat-vax"
8476 .PD 0
8477 .Ip "\fB\-mfloat-ieee\fR" 4
8478 .IX Item "-mfloat-ieee"
8480 Generate code that uses (does not use) \s-1VAX\s0 F and G floating point
8481 arithmetic instead of \s-1IEEE\s0 single and double precision.
8482 .Ip "\fB\-mexplicit-relocs\fR" 4
8483 .IX Item "-mexplicit-relocs"
8484 .PD 0
8485 .Ip "\fB\-mno-explicit-relocs\fR" 4
8486 .IX Item "-mno-explicit-relocs"
8488 Older Alpha assemblers provided no way to generate symbol relocations
8489 except via assembler macros.  Use of these macros does not allow
8490 optimal instruction scheduling.  \s-1GNU\s0 binutils as of version 2.12
8491 supports a new syntax that allows the compiler to explicitly mark
8492 which relocations should apply to which instructions.  This option
8493 is mostly useful for debugging, as \s-1GCC\s0 detects the capabilities of
8494 the assembler when it is built and sets the default accordingly.
8495 .Ip "\fB\-msmall-data\fR" 4
8496 .IX Item "-msmall-data"
8497 .PD 0
8498 .Ip "\fB\-mlarge-data\fR" 4
8499 .IX Item "-mlarge-data"
8501 When \fB\-mexplicit-relocs\fR is in effect, static data is
8502 accessed via \fIgp-relative\fR relocations.  When \fB\-msmall-data\fR
8503 is used, objects 8 bytes long or smaller are placed in a \fIsmall data area\fR
8504 (the \f(CW\*(C`.sdata\*(C'\fR and \f(CW\*(C`.sbss\*(C'\fR sections) and are accessed via
8505 16\-bit relocations off of the \f(CW\*(C`$gp\*(C'\fR register.  This limits the
8506 size of the small data area to 64KB, but allows the variables to be
8507 directly accessed via a single instruction.
8509 The default is \fB\-mlarge-data\fR.  With this option the data area
8510 is limited to just below 2GB.  Programs that require more than 2GB of
8511 data must use \f(CW\*(C`malloc\*(C'\fR or \f(CW\*(C`mmap\*(C'\fR to allocate the data in the
8512 heap instead of in the program's data segment.
8514 When generating code for shared libraries, \fB\-fpic\fR implies
8515 \&\fB\-msmall-data\fR and \fB\-fPIC\fR implies \fB\-mlarge-data\fR.
8516 .Ip "\fB\-msmall-text\fR" 4
8517 .IX Item "-msmall-text"
8518 .PD 0
8519 .Ip "\fB\-mlarge-text\fR" 4
8520 .IX Item "-mlarge-text"
8522 When \fB\-msmall-text\fR is used, the compiler assumes that the
8523 code of the entire program (or shared library) fits in 4MB, and is
8524 thus reachable with a branch instruction.  When \fB\-msmall-data\fR
8525 is used, the compiler can assume that all local symbols share the
8526 same \f(CW\*(C`$gp\*(C'\fR value, and thus reduce the number of instructions
8527 required for a function call from 4 to 1.
8529 The default is \fB\-mlarge-text\fR.
8530 .Ip "\fB\-mcpu=\fR\fIcpu_type\fR" 4
8531 .IX Item "-mcpu=cpu_type"
8532 Set the instruction set and instruction scheduling parameters for
8533 machine type \fIcpu_type\fR.  You can specify either the \fB\s-1EV\s0\fR
8534 style name or the corresponding chip number.  \s-1GCC\s0 supports scheduling
8535 parameters for the \s-1EV4\s0, \s-1EV5\s0 and \s-1EV6\s0 family of processors and will
8536 choose the default values for the instruction set from the processor
8537 you specify.  If you do not specify a processor type, \s-1GCC\s0 will default
8538 to the processor on which the compiler was built.
8540 Supported values for \fIcpu_type\fR are
8541 .RS 4
8542 .Ip "\fBev4\fR" 4
8543 .IX Item "ev4"
8544 .PD 0
8545 .Ip "\fBev45\fR" 4
8546 .IX Item "ev45"
8547 .Ip "\fB21064\fR" 4
8548 .IX Item "21064"
8550 Schedules as an \s-1EV4\s0 and has no instruction set extensions.
8551 .Ip "\fBev5\fR" 4
8552 .IX Item "ev5"
8553 .PD 0
8554 .Ip "\fB21164\fR" 4
8555 .IX Item "21164"
8557 Schedules as an \s-1EV5\s0 and has no instruction set extensions.
8558 .Ip "\fBev56\fR" 4
8559 .IX Item "ev56"
8560 .PD 0
8561 .Ip "\fB21164a\fR" 4
8562 .IX Item "21164a"
8564 Schedules as an \s-1EV5\s0 and supports the \s-1BWX\s0 extension.
8565 .Ip "\fBpca56\fR" 4
8566 .IX Item "pca56"
8567 .PD 0
8568 .Ip "\fB21164pc\fR" 4
8569 .IX Item "21164pc"
8570 .Ip "\fB21164PC\fR" 4
8571 .IX Item "21164PC"
8573 Schedules as an \s-1EV5\s0 and supports the \s-1BWX\s0 and \s-1MAX\s0 extensions.
8574 .Ip "\fBev6\fR" 4
8575 .IX Item "ev6"
8576 .PD 0
8577 .Ip "\fB21264\fR" 4
8578 .IX Item "21264"
8580 Schedules as an \s-1EV6\s0 and supports the \s-1BWX\s0, \s-1FIX\s0, and \s-1MAX\s0 extensions.
8581 .Ip "\fBev67\fR" 4
8582 .IX Item "ev67"
8583 .PD 0
8584 .Ip "\fB21264a\fR" 4
8585 .IX Item "21264a"
8587 Schedules as an \s-1EV6\s0 and supports the \s-1BWX\s0, \s-1CIX\s0, \s-1FIX\s0, and \s-1MAX\s0 extensions.
8589 .RS 4
8591 .Ip "\fB\-mtune=\fR\fIcpu_type\fR" 4
8592 .IX Item "-mtune=cpu_type"
8593 Set only the instruction scheduling parameters for machine type
8594 \&\fIcpu_type\fR.  The instruction set is not changed.
8595 .Ip "\fB\-mmemory-latency=\fR\fItime\fR" 4
8596 .IX Item "-mmemory-latency=time"
8597 Sets the latency the scheduler should assume for typical memory
8598 references as seen by the application.  This number is highly
8599 dependent on the memory access patterns used by the application
8600 and the size of the external cache on the machine.
8602 Valid options for \fItime\fR are
8603 .RS 4
8604 .Ip "\fInumber\fR" 4
8605 .IX Item "number"
8606 A decimal number representing clock cycles.
8607 .Ip "\fBL1\fR" 4
8608 .IX Item "L1"
8609 .PD 0
8610 .Ip "\fBL2\fR" 4
8611 .IX Item "L2"
8612 .Ip "\fBL3\fR" 4
8613 .IX Item "L3"
8614 .Ip "\fBmain\fR" 4
8615 .IX Item "main"
8617 The compiler contains estimates of the number of clock cycles for
8618 ``typical'' \s-1EV4\s0 & \s-1EV5\s0 hardware for the Level 1, 2 & 3 caches
8619 (also called Dcache, Scache, and Bcache), as well as to main memory.
8620 Note that L3 is only valid for \s-1EV5\s0.
8622 .RS 4
8625 .I "\s-1DEC\s0 Alpha/VMS Options"
8626 .IX Subsection "DEC Alpha/VMS Options"
8628 These \fB\-m\fR options are defined for the \s-1DEC\s0 Alpha/VMS implementations:
8629 .Ip "\fB\-mvms-return-codes\fR" 4
8630 .IX Item "-mvms-return-codes"
8631 Return \s-1VMS\s0 condition codes from main.  The default is to return \s-1POSIX\s0
8632 style condition (e.g. error) codes.
8634 .I "H8/300 Options"
8635 .IX Subsection "H8/300 Options"
8637 These \fB\-m\fR options are defined for the H8/300 implementations:
8638 .Ip "\fB\-mrelax\fR" 4
8639 .IX Item "-mrelax"
8640 Shorten some address references at link time, when possible; uses the
8641 linker option \fB\-relax\fR.  
8642 .Ip "\fB\-mh\fR" 4
8643 .IX Item "-mh"
8644 Generate code for the H8/300H.
8645 .Ip "\fB\-ms\fR" 4
8646 .IX Item "-ms"
8647 Generate code for the H8S.
8648 .Ip "\fB\-mn\fR" 4
8649 .IX Item "-mn"
8650 Generate code for the H8S and H8/300H in the normal mode.  This switch
8651 must be used either with \-mh or \-ms.
8652 .Ip "\fB\-ms2600\fR" 4
8653 .IX Item "-ms2600"
8654 Generate code for the H8S/2600.  This switch must be used with \fB\-ms\fR.
8655 .Ip "\fB\-mint32\fR" 4
8656 .IX Item "-mint32"
8657 Make \f(CW\*(C`int\*(C'\fR data 32 bits by default.
8658 .Ip "\fB\-malign-300\fR" 4
8659 .IX Item "-malign-300"
8660 On the H8/300H and H8S, use the same alignment rules as for the H8/300.
8661 The default for the H8/300H and H8S is to align longs and floats on 4
8662 byte boundaries.
8663 \&\fB\-malign-300\fR causes them to be aligned on 2 byte boundaries.
8664 This option has no effect on the H8/300.
8666 .I "\s-1SH\s0 Options"
8667 .IX Subsection "SH Options"
8669 These \fB\-m\fR options are defined for the \s-1SH\s0 implementations:
8670 .Ip "\fB\-m1\fR" 4
8671 .IX Item "-m1"
8672 Generate code for the \s-1SH1\s0.
8673 .Ip "\fB\-m2\fR" 4
8674 .IX Item "-m2"
8675 Generate code for the \s-1SH2\s0.
8676 .Ip "\fB\-m2e\fR" 4
8677 .IX Item "-m2e"
8678 Generate code for the SH2e.
8679 .Ip "\fB\-m3\fR" 4
8680 .IX Item "-m3"
8681 Generate code for the \s-1SH3\s0.
8682 .Ip "\fB\-m3e\fR" 4
8683 .IX Item "-m3e"
8684 Generate code for the SH3e.
8685 .Ip "\fB\-m4\-nofpu\fR" 4
8686 .IX Item "-m4-nofpu"
8687 Generate code for the \s-1SH4\s0 without a floating-point unit.
8688 .Ip "\fB\-m4\-single-only\fR" 4
8689 .IX Item "-m4-single-only"
8690 Generate code for the \s-1SH4\s0 with a floating-point unit that only
8691 supports single-precision arithmetic.
8692 .Ip "\fB\-m4\-single\fR" 4
8693 .IX Item "-m4-single"
8694 Generate code for the \s-1SH4\s0 assuming the floating-point unit is in
8695 single-precision mode by default.
8696 .Ip "\fB\-m4\fR" 4
8697 .IX Item "-m4"
8698 Generate code for the \s-1SH4\s0.
8699 .Ip "\fB\-mb\fR" 4
8700 .IX Item "-mb"
8701 Compile code for the processor in big endian mode.
8702 .Ip "\fB\-ml\fR" 4
8703 .IX Item "-ml"
8704 Compile code for the processor in little endian mode.
8705 .Ip "\fB\-mdalign\fR" 4
8706 .IX Item "-mdalign"
8707 Align doubles at 64\-bit boundaries.  Note that this changes the calling
8708 conventions, and thus some functions from the standard C library will
8709 not work unless you recompile it first with \fB\-mdalign\fR.
8710 .Ip "\fB\-mrelax\fR" 4
8711 .IX Item "-mrelax"
8712 Shorten some address references at link time, when possible; uses the
8713 linker option \fB\-relax\fR.
8714 .Ip "\fB\-mbigtable\fR" 4
8715 .IX Item "-mbigtable"
8716 Use 32\-bit offsets in \f(CW\*(C`switch\*(C'\fR tables.  The default is to use
8717 16\-bit offsets.
8718 .Ip "\fB\-mfmovd\fR" 4
8719 .IX Item "-mfmovd"
8720 Enable the use of the instruction \f(CW\*(C`fmovd\*(C'\fR.
8721 .Ip "\fB\-mhitachi\fR" 4
8722 .IX Item "-mhitachi"
8723 Comply with the calling conventions defined by Renesas.
8724 .Ip "\fB\-mnomacsave\fR" 4
8725 .IX Item "-mnomacsave"
8726 Mark the \f(CW\*(C`MAC\*(C'\fR register as call-clobbered, even if
8727 \&\fB\-mhitachi\fR is given.
8728 .Ip "\fB\-mieee\fR" 4
8729 .IX Item "-mieee"
8730 Increase IEEE-compliance of floating-point code.
8731 .Ip "\fB\-misize\fR" 4
8732 .IX Item "-misize"
8733 Dump instruction size and location in the assembly code.
8734 .Ip "\fB\-mpadstruct\fR" 4
8735 .IX Item "-mpadstruct"
8736 This option is deprecated.  It pads structures to multiple of 4 bytes,
8737 which is incompatible with the \s-1SH\s0 \s-1ABI\s0.
8738 .Ip "\fB\-mspace\fR" 4
8739 .IX Item "-mspace"
8740 Optimize for space instead of speed.  Implied by \fB\-Os\fR.
8741 .Ip "\fB\-mprefergot\fR" 4
8742 .IX Item "-mprefergot"
8743 When generating position-independent code, emit function calls using
8744 the Global Offset Table instead of the Procedure Linkage Table.
8745 .Ip "\fB\-musermode\fR" 4
8746 .IX Item "-musermode"
8747 Generate a library function call to invalidate instruction cache
8748 entries, after fixing up a trampoline.  This library function call
8749 doesn't assume it can write to the whole memory address space.  This
8750 is the default when the target is \f(CW\*(C`sh\-*\-linux*\*(C'\fR.
8752 .I "Options for System V"
8753 .IX Subsection "Options for System V"
8755 These additional options are available on System V Release 4 for
8756 compatibility with other compilers on those systems:
8757 .Ip "\fB\-G\fR" 4
8758 .IX Item "-G"
8759 Create a shared object.
8760 It is recommended that \fB\-symbolic\fR or \fB\-shared\fR be used instead.
8761 .Ip "\fB\-Qy\fR" 4
8762 .IX Item "-Qy"
8763 Identify the versions of each tool used by the compiler, in a
8764 \&\f(CW\*(C`.ident\*(C'\fR assembler directive in the output.
8765 .Ip "\fB\-Qn\fR" 4
8766 .IX Item "-Qn"
8767 Refrain from adding \f(CW\*(C`.ident\*(C'\fR directives to the output file (this is
8768 the default).
8769 .Ip "\fB\-YP,\fR\fIdirs\fR" 4
8770 .IX Item "-YP,dirs"
8771 Search the directories \fIdirs\fR, and no others, for libraries
8772 specified with \fB\-l\fR.
8773 .Ip "\fB\-Ym,\fR\fIdir\fR" 4
8774 .IX Item "-Ym,dir"
8775 Look in the directory \fIdir\fR to find the M4 preprocessor.
8776 The assembler uses this option.
8778 .I "TMS320C3x/C4x Options"
8779 .IX Subsection "TMS320C3x/C4x Options"
8781 These \fB\-m\fR options are defined for TMS320C3x/C4x implementations:
8782 .Ip "\fB\-mcpu=\fR\fIcpu_type\fR" 4
8783 .IX Item "-mcpu=cpu_type"
8784 Set the instruction set, register set, and instruction scheduling
8785 parameters for machine type \fIcpu_type\fR.  Supported values for
8786 \&\fIcpu_type\fR are \fBc30\fR, \fBc31\fR, \fBc32\fR, \fBc40\fR, and
8787 \&\fBc44\fR.  The default is \fBc40\fR to generate code for the
8788 \&\s-1TMS320C40\s0.
8789 .Ip "\fB\-mbig-memory\fR" 4
8790 .IX Item "-mbig-memory"
8791 .PD 0
8792 .Ip "\fB\-mbig\fR" 4
8793 .IX Item "-mbig"
8794 .Ip "\fB\-msmall-memory\fR" 4
8795 .IX Item "-msmall-memory"
8796 .Ip "\fB\-msmall\fR" 4
8797 .IX Item "-msmall"
8799 Generates code for the big or small memory model.  The small memory
8800 model assumed that all data fits into one 64K word page.  At run-time
8801 the data page (\s-1DP\s0) register must be set to point to the 64K page
8802 containing the .bss and .data program sections.  The big memory model is
8803 the default and requires reloading of the \s-1DP\s0 register for every direct
8804 memory access.
8805 .Ip "\fB\-mbk\fR" 4
8806 .IX Item "-mbk"
8807 .PD 0
8808 .Ip "\fB\-mno-bk\fR" 4
8809 .IX Item "-mno-bk"
8811 Allow (disallow) allocation of general integer operands into the block
8812 count register \s-1BK\s0.
8813 .Ip "\fB\-mdb\fR" 4
8814 .IX Item "-mdb"
8815 .PD 0
8816 .Ip "\fB\-mno-db\fR" 4
8817 .IX Item "-mno-db"
8819 Enable (disable) generation of code using decrement and branch,
8820 \&\fIDBcond\fR\|(D), instructions.  This is enabled by default for the C4x.  To be
8821 on the safe side, this is disabled for the C3x, since the maximum
8822 iteration count on the C3x is 2^{23 + 1} (but who iterates loops more than
8823 2^{23} times on the C3x?).  Note that \s-1GCC\s0 will try to reverse a loop so
8824 that it can utilize the decrement and branch instruction, but will give
8825 up if there is more than one memory reference in the loop.  Thus a loop
8826 where the loop counter is decremented can generate slightly more
8827 efficient code, in cases where the \s-1RPTB\s0 instruction cannot be utilized.
8828 .Ip "\fB\-mdp-isr-reload\fR" 4
8829 .IX Item "-mdp-isr-reload"
8830 .PD 0
8831 .Ip "\fB\-mparanoid\fR" 4
8832 .IX Item "-mparanoid"
8834 Force the \s-1DP\s0 register to be saved on entry to an interrupt service
8835 routine (\s-1ISR\s0), reloaded to point to the data section, and restored on
8836 exit from the \s-1ISR\s0.  This should not be required unless someone has
8837 violated the small memory model by modifying the \s-1DP\s0 register, say within
8838 an object library.
8839 .Ip "\fB\-mmpyi\fR" 4
8840 .IX Item "-mmpyi"
8841 .PD 0
8842 .Ip "\fB\-mno-mpyi\fR" 4
8843 .IX Item "-mno-mpyi"
8845 For the C3x use the 24\-bit \s-1MPYI\s0 instruction for integer multiplies
8846 instead of a library call to guarantee 32\-bit results.  Note that if one
8847 of the operands is a constant, then the multiplication will be performed
8848 using shifts and adds.  If the \fB\-mmpyi\fR option is not specified for the C3x,
8849 then squaring operations are performed inline instead of a library call.
8850 .Ip "\fB\-mfast-fix\fR" 4
8851 .IX Item "-mfast-fix"
8852 .PD 0
8853 .Ip "\fB\-mno-fast-fix\fR" 4
8854 .IX Item "-mno-fast-fix"
8856 The C3x/C4x \s-1FIX\s0 instruction to convert a floating point value to an
8857 integer value chooses the nearest integer less than or equal to the
8858 floating point value rather than to the nearest integer.  Thus if the
8859 floating point number is negative, the result will be incorrectly
8860 truncated an additional code is necessary to detect and correct this
8861 case.  This option can be used to disable generation of the additional
8862 code required to correct the result.
8863 .Ip "\fB\-mrptb\fR" 4
8864 .IX Item "-mrptb"
8865 .PD 0
8866 .Ip "\fB\-mno-rptb\fR" 4
8867 .IX Item "-mno-rptb"
8869 Enable (disable) generation of repeat block sequences using the \s-1RPTB\s0
8870 instruction for zero overhead looping.  The \s-1RPTB\s0 construct is only used
8871 for innermost loops that do not call functions or jump across the loop
8872 boundaries.  There is no advantage having nested \s-1RPTB\s0 loops due to the
8873 overhead required to save and restore the \s-1RC\s0, \s-1RS\s0, and \s-1RE\s0 registers.
8874 This is enabled by default with \fB\-O2\fR.
8875 .Ip "\fB\-mrpts=\fR\fIcount\fR" 4
8876 .IX Item "-mrpts=count"
8877 .PD 0
8878 .Ip "\fB\-mno-rpts\fR" 4
8879 .IX Item "-mno-rpts"
8881 Enable (disable) the use of the single instruction repeat instruction
8882 \&\s-1RPTS\s0.  If a repeat block contains a single instruction, and the loop
8883 count can be guaranteed to be less than the value \fIcount\fR, \s-1GCC\s0 will
8884 emit a \s-1RPTS\s0 instruction instead of a \s-1RPTB\s0.  If no value is specified,
8885 then a \s-1RPTS\s0 will be emitted even if the loop count cannot be determined
8886 at compile time.  Note that the repeated instruction following \s-1RPTS\s0 does
8887 not have to be reloaded from memory each iteration, thus freeing up the
8888 \&\s-1CPU\s0 buses for operands.  However, since interrupts are blocked by this
8889 instruction, it is disabled by default.
8890 .Ip "\fB\-mloop-unsigned\fR" 4
8891 .IX Item "-mloop-unsigned"
8892 .PD 0
8893 .Ip "\fB\-mno-loop-unsigned\fR" 4
8894 .IX Item "-mno-loop-unsigned"
8896 The maximum iteration count when using \s-1RPTS\s0 and \s-1RPTB\s0 (and \s-1DB\s0 on the C40)
8897 is 2^{31 + 1} since these instructions test if the iteration count is
8898 negative to terminate the loop.  If the iteration count is unsigned
8899 there is a possibility than the 2^{31 + 1} maximum iteration count may be
8900 exceeded.  This switch allows an unsigned iteration count.
8901 .Ip "\fB\-mti\fR" 4
8902 .IX Item "-mti"
8903 Try to emit an assembler syntax that the \s-1TI\s0 assembler (asm30) is happy
8904 with.  This also enforces compatibility with the \s-1API\s0 employed by the \s-1TI\s0
8905 C3x C compiler.  For example, long doubles are passed as structures
8906 rather than in floating point registers.
8907 .Ip "\fB\-mregparm\fR" 4
8908 .IX Item "-mregparm"
8909 .PD 0
8910 .Ip "\fB\-mmemparm\fR" 4
8911 .IX Item "-mmemparm"
8913 Generate code that uses registers (stack) for passing arguments to functions.
8914 By default, arguments are passed in registers where possible rather
8915 than by pushing arguments on to the stack.
8916 .Ip "\fB\-mparallel-insns\fR" 4
8917 .IX Item "-mparallel-insns"
8918 .PD 0
8919 .Ip "\fB\-mno-parallel-insns\fR" 4
8920 .IX Item "-mno-parallel-insns"
8922 Allow the generation of parallel instructions.  This is enabled by
8923 default with \fB\-O2\fR.
8924 .Ip "\fB\-mparallel-mpy\fR" 4
8925 .IX Item "-mparallel-mpy"
8926 .PD 0
8927 .Ip "\fB\-mno-parallel-mpy\fR" 4
8928 .IX Item "-mno-parallel-mpy"
8930 Allow the generation of MPY||ADD and MPY||SUB parallel instructions,
8931 provided \fB\-mparallel-insns\fR is also specified.  These instructions have
8932 tight register constraints which can pessimize the code generation
8933 of large functions.
8935 .I "V850 Options"
8936 .IX Subsection "V850 Options"
8938 These \fB\-m\fR options are defined for V850 implementations:
8939 .Ip "\fB\-mlong-calls\fR" 4
8940 .IX Item "-mlong-calls"
8941 .PD 0
8942 .Ip "\fB\-mno-long-calls\fR" 4
8943 .IX Item "-mno-long-calls"
8945 Treat all calls as being far away (near).  If calls are assumed to be
8946 far away, the compiler will always load the functions address up into a
8947 register, and call indirect through the pointer.
8948 .Ip "\fB\-mno-ep\fR" 4
8949 .IX Item "-mno-ep"
8950 .PD 0
8951 .Ip "\fB\-mep\fR" 4
8952 .IX Item "-mep"
8954 Do not optimize (do optimize) basic blocks that use the same index
8955 pointer 4 or more times to copy pointer into the \f(CW\*(C`ep\*(C'\fR register, and
8956 use the shorter \f(CW\*(C`sld\*(C'\fR and \f(CW\*(C`sst\*(C'\fR instructions.  The \fB\-mep\fR
8957 option is on by default if you optimize.
8958 .Ip "\fB\-mno-prolog-function\fR" 4
8959 .IX Item "-mno-prolog-function"
8960 .PD 0
8961 .Ip "\fB\-mprolog-function\fR" 4
8962 .IX Item "-mprolog-function"
8964 Do not use (do use) external functions to save and restore registers
8965 at the prologue and epilogue of a function.  The external functions
8966 are slower, but use less code space if more than one function saves
8967 the same number of registers.  The \fB\-mprolog-function\fR option
8968 is on by default if you optimize.
8969 .Ip "\fB\-mspace\fR" 4
8970 .IX Item "-mspace"
8971 Try to make the code as small as possible.  At present, this just turns
8972 on the \fB\-mep\fR and \fB\-mprolog-function\fR options.
8973 .Ip "\fB\-mtda=\fR\fIn\fR" 4
8974 .IX Item "-mtda=n"
8975 Put static or global variables whose size is \fIn\fR bytes or less into
8976 the tiny data area that register \f(CW\*(C`ep\*(C'\fR points to.  The tiny data
8977 area can hold up to 256 bytes in total (128 bytes for byte references).
8978 .Ip "\fB\-msda=\fR\fIn\fR" 4
8979 .IX Item "-msda=n"
8980 Put static or global variables whose size is \fIn\fR bytes or less into
8981 the small data area that register \f(CW\*(C`gp\*(C'\fR points to.  The small data
8982 area can hold up to 64 kilobytes.
8983 .Ip "\fB\-mzda=\fR\fIn\fR" 4
8984 .IX Item "-mzda=n"
8985 Put static or global variables whose size is \fIn\fR bytes or less into
8986 the first 32 kilobytes of memory.
8987 .Ip "\fB\-mv850\fR" 4
8988 .IX Item "-mv850"
8989 Specify that the target processor is the V850.
8990 .Ip "\fB\-mbig-switch\fR" 4
8991 .IX Item "-mbig-switch"
8992 Generate code suitable for big switch tables.  Use this option only if
8993 the assembler/linker complain about out of range branches within a switch
8994 table.
8995 .Ip "\fB\-mapp-regs\fR" 4
8996 .IX Item "-mapp-regs"
8997 This option will cause r2 and r5 to be used in the code generated by
8998 the compiler.  This setting is the default.
8999 .Ip "\fB\-mno-app-regs\fR" 4
9000 .IX Item "-mno-app-regs"
9001 This option will cause r2 and r5 to be treated as fixed registers.
9002 .Ip "\fB\-mv850e1\fR" 4
9003 .IX Item "-mv850e1"
9004 Specify that the target processor is the V850E1.  The preprocessor
9005 constants \fB_\|_v850e1_\|_\fR and \fB_\|_v850e_\|_\fR will be defined if
9006 this option is used.
9007 .Ip "\fB\-mv850e\fR" 4
9008 .IX Item "-mv850e"
9009 Specify that the target processor is the V850E.  The preprocessor
9010 constant \fB_\|_v850e_\|_\fR will be defined if this option is used.
9012 If neither \fB\-mv850\fR nor \fB\-mv850e\fR nor \fB\-mv850e1\fR
9013 are defined then a default target processor will be chosen and the
9014 relevant \fB_\|_v850*_\|_\fR preprocessor constant will be defined.
9016 The preprocessor constants \fB_\|_v850\fR and \fB_\|_v851_\|_\fR are always
9017 defined, regardless of which processor variant is the target.
9018 .Ip "\fB\-mdisable-callt\fR" 4
9019 .IX Item "-mdisable-callt"
9020 This option will suppress generation of the \s-1CALLT\s0 instruction for the
9021 v850e and v850e1 flavors of the v850 architecture.  The default is
9022 \&\fB\-mno-disable-callt\fR which allows the \s-1CALLT\s0 instruction to be used.
9024 .I "\s-1ARC\s0 Options"
9025 .IX Subsection "ARC Options"
9027 These options are defined for \s-1ARC\s0 implementations:
9028 .Ip "\fB\-EL\fR" 4
9029 .IX Item "-EL"
9030 Compile code for little endian mode.  This is the default.
9031 .Ip "\fB\-EB\fR" 4
9032 .IX Item "-EB"
9033 Compile code for big endian mode.
9034 .Ip "\fB\-mmangle-cpu\fR" 4
9035 .IX Item "-mmangle-cpu"
9036 Prepend the name of the cpu to all public symbol names.
9037 In multiple-processor systems, there are many \s-1ARC\s0 variants with different
9038 instruction and register set characteristics.  This flag prevents code
9039 compiled for one cpu to be linked with code compiled for another.
9040 No facility exists for handling variants that are ``almost identical''.
9041 This is an all or nothing option.
9042 .Ip "\fB\-mcpu=\fR\fIcpu\fR" 4
9043 .IX Item "-mcpu=cpu"
9044 Compile code for \s-1ARC\s0 variant \fIcpu\fR.
9045 Which variants are supported depend on the configuration.
9046 All variants support \fB\-mcpu=base\fR, this is the default.
9047 .Ip "\fB\-mtext=\fR\fItext-section\fR" 4
9048 .IX Item "-mtext=text-section"
9049 .PD 0
9050 .Ip "\fB\-mdata=\fR\fIdata-section\fR" 4
9051 .IX Item "-mdata=data-section"
9052 .Ip "\fB\-mrodata=\fR\fIreadonly-data-section\fR" 4
9053 .IX Item "-mrodata=readonly-data-section"
9055 Put functions, data, and readonly data in \fItext-section\fR,
9056 \&\fIdata-section\fR, and \fIreadonly-data-section\fR respectively
9057 by default.  This can be overridden with the \f(CW\*(C`section\*(C'\fR attribute.
9059 .I "\s-1NS32K\s0 Options"
9060 .IX Subsection "NS32K Options"
9062 These are the \fB\-m\fR options defined for the 32000 series.  The default
9063 values for these options depends on which style of 32000 was selected when
9064 the compiler was configured; the defaults for the most common choices are
9065 given below.
9066 .Ip "\fB\-m32032\fR" 4
9067 .IX Item "-m32032"
9068 .PD 0
9069 .Ip "\fB\-m32032\fR" 4
9070 .IX Item "-m32032"
9072 Generate output for a 32032.  This is the default
9073 when the compiler is configured for 32032 and 32016 based systems.
9074 .Ip "\fB\-m32332\fR" 4
9075 .IX Item "-m32332"
9076 .PD 0
9077 .Ip "\fB\-m32332\fR" 4
9078 .IX Item "-m32332"
9080 Generate output for a 32332.  This is the default
9081 when the compiler is configured for 32332\-based systems.
9082 .Ip "\fB\-m32532\fR" 4
9083 .IX Item "-m32532"
9084 .PD 0
9085 .Ip "\fB\-m32532\fR" 4
9086 .IX Item "-m32532"
9088 Generate output for a 32532.  This is the default
9089 when the compiler is configured for 32532\-based systems.
9090 .Ip "\fB\-m32081\fR" 4
9091 .IX Item "-m32081"
9092 Generate output containing 32081 instructions for floating point.
9093 This is the default for all systems.
9094 .Ip "\fB\-m32381\fR" 4
9095 .IX Item "-m32381"
9096 Generate output containing 32381 instructions for floating point.  This
9097 also implies \fB\-m32081\fR.  The 32381 is only compatible with the 32332
9098 and 32532 cpus.  This is the default for the pc532\-netbsd configuration.
9099 .Ip "\fB\-mmulti-add\fR" 4
9100 .IX Item "-mmulti-add"
9101 Try and generate multiply-add floating point instructions \f(CW\*(C`polyF\*(C'\fR
9102 and \f(CW\*(C`dotF\*(C'\fR.  This option is only available if the \fB\-m32381\fR
9103 option is in effect.  Using these instructions requires changes to
9104 register allocation which generally has a negative impact on
9105 performance.  This option should only be enabled when compiling code
9106 particularly likely to make heavy use of multiply-add instructions.
9107 .Ip "\fB\-mnomulti-add\fR" 4
9108 .IX Item "-mnomulti-add"
9109 Do not try and generate multiply-add floating point instructions
9110 \&\f(CW\*(C`polyF\*(C'\fR and \f(CW\*(C`dotF\*(C'\fR.  This is the default on all platforms.
9111 .Ip "\fB\-msoft-float\fR" 4
9112 .IX Item "-msoft-float"
9113 Generate output containing library calls for floating point.
9114 \&\fBWarning:\fR the requisite libraries may not be available.
9115 .Ip "\fB\-mieee-compare\fR" 4
9116 .IX Item "-mieee-compare"
9117 .PD 0
9118 .Ip "\fB\-mno-ieee-compare\fR" 4
9119 .IX Item "-mno-ieee-compare"
9121 Control whether or not the compiler uses \s-1IEEE\s0 floating point
9122 comparisons.  These handle correctly the case where the result of a
9123 comparison is unordered.
9124 \&\fBWarning:\fR the requisite kernel support may not be available.
9125 .Ip "\fB\-mnobitfield\fR" 4
9126 .IX Item "-mnobitfield"
9127 Do not use the bit-field instructions.  On some machines it is faster to
9128 use shifting and masking operations.  This is the default for the pc532.
9129 .Ip "\fB\-mbitfield\fR" 4
9130 .IX Item "-mbitfield"
9131 Do use the bit-field instructions.  This is the default for all platforms
9132 except the pc532.
9133 .Ip "\fB\-mrtd\fR" 4
9134 .IX Item "-mrtd"
9135 Use a different function-calling convention, in which functions
9136 that take a fixed number of arguments return pop their
9137 arguments on return with the \f(CW\*(C`ret\*(C'\fR instruction.
9139 This calling convention is incompatible with the one normally
9140 used on Unix, so you cannot use it if you need to call libraries
9141 compiled with the Unix compiler.
9143 Also, you must provide function prototypes for all functions that
9144 take variable numbers of arguments (including \f(CW\*(C`printf\*(C'\fR);
9145 otherwise incorrect code will be generated for calls to those
9146 functions.
9148 In addition, seriously incorrect code will result if you call a
9149 function with too many arguments.  (Normally, extra arguments are
9150 harmlessly ignored.)
9152 This option takes its name from the 680x0 \f(CW\*(C`rtd\*(C'\fR instruction.
9153 .Ip "\fB\-mregparam\fR" 4
9154 .IX Item "-mregparam"
9155 Use a different function-calling convention where the first two arguments
9156 are passed in registers.
9158 This calling convention is incompatible with the one normally
9159 used on Unix, so you cannot use it if you need to call libraries
9160 compiled with the Unix compiler.
9161 .Ip "\fB\-mnoregparam\fR" 4
9162 .IX Item "-mnoregparam"
9163 Do not pass any arguments in registers.  This is the default for all
9164 targets.
9165 .Ip "\fB\-msb\fR" 4
9166 .IX Item "-msb"
9167 It is \s-1OK\s0 to use the sb as an index register which is always loaded with
9168 zero.  This is the default for the pc532\-netbsd target.
9169 .Ip "\fB\-mnosb\fR" 4
9170 .IX Item "-mnosb"
9171 The sb register is not available for use or has not been initialized to
9172 zero by the run time system.  This is the default for all targets except
9173 the pc532\-netbsd.  It is also implied whenever \fB\-mhimem\fR or
9174 \&\fB\-fpic\fR is set.
9175 .Ip "\fB\-mhimem\fR" 4
9176 .IX Item "-mhimem"
9177 Many ns32000 series addressing modes use displacements of up to 512MB.
9178 If an address is above 512MB then displacements from zero can not be used.
9179 This option causes code to be generated which can be loaded above 512MB.
9180 This may be useful for operating systems or \s-1ROM\s0 code.
9181 .Ip "\fB\-mnohimem\fR" 4
9182 .IX Item "-mnohimem"
9183 Assume code will be loaded in the first 512MB of virtual address space.
9184 This is the default for all platforms.
9186 .I "\s-1AVR\s0 Options"
9187 .IX Subsection "AVR Options"
9189 These options are defined for \s-1AVR\s0 implementations:
9190 .Ip "\fB\-mmcu=\fR\fImcu\fR" 4
9191 .IX Item "-mmcu=mcu"
9192 Specify \s-1ATMEL\s0 \s-1AVR\s0 instruction set or \s-1MCU\s0 type.
9194 Instruction set avr1 is for the minimal \s-1AVR\s0 core, not supported by the C
9195 compiler, only for assembler programs (\s-1MCU\s0 types: at90s1200, attiny10,
9196 attiny11, attiny12, attiny15, attiny28).
9198 Instruction set avr2 (default) is for the classic \s-1AVR\s0 core with up to
9199 8K program memory space (\s-1MCU\s0 types: at90s2313, at90s2323, attiny22,
9200 at90s2333, at90s2343, at90s4414, at90s4433, at90s4434, at90s8515,
9201 at90c8534, at90s8535).
9203 Instruction set avr3 is for the classic \s-1AVR\s0 core with up to 128K program
9204 memory space (\s-1MCU\s0 types: atmega103, atmega603, at43usb320, at76c711).
9206 Instruction set avr4 is for the enhanced \s-1AVR\s0 core with up to 8K program
9207 memory space (\s-1MCU\s0 types: atmega8, atmega83, atmega85).
9209 Instruction set avr5 is for the enhanced \s-1AVR\s0 core with up to 128K program
9210 memory space (\s-1MCU\s0 types: atmega16, atmega161, atmega163, atmega32, atmega323,
9211 atmega64, atmega128, at43usb355, at94k).
9212 .Ip "\fB\-msize\fR" 4
9213 .IX Item "-msize"
9214 Output instruction sizes to the asm file.
9215 .Ip "\fB\-minit-stack=\fR\fIN\fR" 4
9216 .IX Item "-minit-stack=N"
9217 Specify the initial stack address, which may be a symbol or numeric value,
9218 \&\fB_\|_stack\fR is the default.
9219 .Ip "\fB\-mno-interrupts\fR" 4
9220 .IX Item "-mno-interrupts"
9221 Generated code is not compatible with hardware interrupts.
9222 Code size will be smaller.
9223 .Ip "\fB\-mcall-prologues\fR" 4
9224 .IX Item "-mcall-prologues"
9225 Functions prologues/epilogues expanded as call to appropriate
9226 subroutines.  Code size will be smaller.
9227 .Ip "\fB\-mno-tablejump\fR" 4
9228 .IX Item "-mno-tablejump"
9229 Do not generate tablejump insns which sometimes increase code size.
9230 .Ip "\fB\-mtiny-stack\fR" 4
9231 .IX Item "-mtiny-stack"
9232 Change only the low 8 bits of the stack pointer.
9234 .I "MCore Options"
9235 .IX Subsection "MCore Options"
9237 These are the \fB\-m\fR options defined for the Motorola M*Core
9238 processors.
9239 .Ip "\fB\-mhardlit\fR" 4
9240 .IX Item "-mhardlit"
9241 .PD 0
9242 .Ip "\fB\-mno-hardlit\fR" 4
9243 .IX Item "-mno-hardlit"
9245 Inline constants into the code stream if it can be done in two
9246 instructions or less.
9247 .Ip "\fB\-mdiv\fR" 4
9248 .IX Item "-mdiv"
9249 .PD 0
9250 .Ip "\fB\-mno-div\fR" 4
9251 .IX Item "-mno-div"
9253 Use the divide instruction.  (Enabled by default).
9254 .Ip "\fB\-mrelax-immediate\fR" 4
9255 .IX Item "-mrelax-immediate"
9256 .PD 0
9257 .Ip "\fB\-mno-relax-immediate\fR" 4
9258 .IX Item "-mno-relax-immediate"
9260 Allow arbitrary sized immediates in bit operations.
9261 .Ip "\fB\-mwide-bitfields\fR" 4
9262 .IX Item "-mwide-bitfields"
9263 .PD 0
9264 .Ip "\fB\-mno-wide-bitfields\fR" 4
9265 .IX Item "-mno-wide-bitfields"
9267 Always treat bit-fields as int-sized.
9268 .Ip "\fB\-m4byte-functions\fR" 4
9269 .IX Item "-m4byte-functions"
9270 .PD 0
9271 .Ip "\fB\-mno-4byte-functions\fR" 4
9272 .IX Item "-mno-4byte-functions"
9274 Force all functions to be aligned to a four byte boundary.
9275 .Ip "\fB\-mcallgraph-data\fR" 4
9276 .IX Item "-mcallgraph-data"
9277 .PD 0
9278 .Ip "\fB\-mno-callgraph-data\fR" 4
9279 .IX Item "-mno-callgraph-data"
9281 Emit callgraph information.
9282 .Ip "\fB\-mslow-bytes\fR" 4
9283 .IX Item "-mslow-bytes"
9284 .PD 0
9285 .Ip "\fB\-mno-slow-bytes\fR" 4
9286 .IX Item "-mno-slow-bytes"
9288 Prefer word access when reading byte quantities.
9289 .Ip "\fB\-mlittle-endian\fR" 4
9290 .IX Item "-mlittle-endian"
9291 .PD 0
9292 .Ip "\fB\-mbig-endian\fR" 4
9293 .IX Item "-mbig-endian"
9295 Generate code for a little endian target.
9296 .Ip "\fB\-m210\fR" 4
9297 .IX Item "-m210"
9298 .PD 0
9299 .Ip "\fB\-m340\fR" 4
9300 .IX Item "-m340"
9302 Generate code for the 210 processor.
9304 .I "\s-1IA-64\s0 Options"
9305 .IX Subsection "IA-64 Options"
9307 These are the \fB\-m\fR options defined for the Intel \s-1IA-64\s0 architecture.
9308 .Ip "\fB\-mbig-endian\fR" 4
9309 .IX Item "-mbig-endian"
9310 Generate code for a big endian target.  This is the default for \s-1HP-UX\s0.
9311 .Ip "\fB\-mlittle-endian\fR" 4
9312 .IX Item "-mlittle-endian"
9313 Generate code for a little endian target.  This is the default for \s-1AIX5\s0
9314 and GNU/Linux.
9315 .Ip "\fB\-mgnu-as\fR" 4
9316 .IX Item "-mgnu-as"
9317 .PD 0
9318 .Ip "\fB\-mno-gnu-as\fR" 4
9319 .IX Item "-mno-gnu-as"
9321 Generate (or don't) code for the \s-1GNU\s0 assembler.  This is the default.
9322 .Ip "\fB\-mgnu-ld\fR" 4
9323 .IX Item "-mgnu-ld"
9324 .PD 0
9325 .Ip "\fB\-mno-gnu-ld\fR" 4
9326 .IX Item "-mno-gnu-ld"
9328 Generate (or don't) code for the \s-1GNU\s0 linker.  This is the default.
9329 .Ip "\fB\-mno-pic\fR" 4
9330 .IX Item "-mno-pic"
9331 Generate code that does not use a global pointer register.  The result
9332 is not position independent code, and violates the \s-1IA-64\s0 \s-1ABI\s0.
9333 .Ip "\fB\-mvolatile-asm-stop\fR" 4
9334 .IX Item "-mvolatile-asm-stop"
9335 .PD 0
9336 .Ip "\fB\-mno-volatile-asm-stop\fR" 4
9337 .IX Item "-mno-volatile-asm-stop"
9339 Generate (or don't) a stop bit immediately before and after volatile asm
9340 statements.
9341 .Ip "\fB\-mb-step\fR" 4
9342 .IX Item "-mb-step"
9343 Generate code that works around Itanium B step errata.
9344 .Ip "\fB\-mregister-names\fR" 4
9345 .IX Item "-mregister-names"
9346 .PD 0
9347 .Ip "\fB\-mno-register-names\fR" 4
9348 .IX Item "-mno-register-names"
9350 Generate (or don't) \fBin\fR, \fBloc\fR, and \fBout\fR register names for
9351 the stacked registers.  This may make assembler output more readable.
9352 .Ip "\fB\-mno-sdata\fR" 4
9353 .IX Item "-mno-sdata"
9354 .PD 0
9355 .Ip "\fB\-msdata\fR" 4
9356 .IX Item "-msdata"
9358 Disable (or enable) optimizations that use the small data section.  This may
9359 be useful for working around optimizer bugs.
9360 .Ip "\fB\-mconstant-gp\fR" 4
9361 .IX Item "-mconstant-gp"
9362 Generate code that uses a single constant global pointer value.  This is
9363 useful when compiling kernel code.
9364 .Ip "\fB\-mauto-pic\fR" 4
9365 .IX Item "-mauto-pic"
9366 Generate code that is self-relocatable.  This implies \fB\-mconstant-gp\fR.
9367 This is useful when compiling firmware code.
9368 .Ip "\fB\-minline-float-divide-min-latency\fR" 4
9369 .IX Item "-minline-float-divide-min-latency"
9370 Generate code for inline divides of floating point values
9371 using the minimum latency algorithm.
9372 .Ip "\fB\-minline-float-divide-max-throughput\fR" 4
9373 .IX Item "-minline-float-divide-max-throughput"
9374 Generate code for inline divides of floating point values
9375 using the maximum throughput algorithm.
9376 .Ip "\fB\-minline-int-divide-min-latency\fR" 4
9377 .IX Item "-minline-int-divide-min-latency"
9378 Generate code for inline divides of integer values
9379 using the minimum latency algorithm.
9380 .Ip "\fB\-minline-int-divide-max-throughput\fR" 4
9381 .IX Item "-minline-int-divide-max-throughput"
9382 Generate code for inline divides of integer values
9383 using the maximum throughput algorithm.
9384 .Ip "\fB\-mno-dwarf2\-asm\fR" 4
9385 .IX Item "-mno-dwarf2-asm"
9386 .PD 0
9387 .Ip "\fB\-mdwarf2\-asm\fR" 4
9388 .IX Item "-mdwarf2-asm"
9390 Don't (or do) generate assembler code for the \s-1DWARF2\s0 line number debugging
9391 info.  This may be useful when not using the \s-1GNU\s0 assembler.
9392 .Ip "\fB\-mfixed-range=\fR\fIregister-range\fR" 4
9393 .IX Item "-mfixed-range=register-range"
9394 Generate code treating the given register range as fixed registers.
9395 A fixed register is one that the register allocator can not use.  This is
9396 useful when compiling kernel code.  A register range is specified as
9397 two registers separated by a dash.  Multiple register ranges can be
9398 specified separated by a comma.
9399 .Ip "\fB\-mearly-stop-bits\fR" 4
9400 .IX Item "-mearly-stop-bits"
9401 .PD 0
9402 .Ip "\fB\-mno-early-stop-bits\fR" 4
9403 .IX Item "-mno-early-stop-bits"
9405 Allow stop bits to be placed earlier than immediately preceding the
9406 instruction that triggered the stop bit.  This can improve instruction
9407 scheduling, but does not always do so.
9409 .I "D30V Options"
9410 .IX Subsection "D30V Options"
9412 These \fB\-m\fR options are defined for D30V implementations:
9413 .Ip "\fB\-mextmem\fR" 4
9414 .IX Item "-mextmem"
9415 Link the \fB.text\fR, \fB.data\fR, \fB.bss\fR, \fB.strings\fR,
9416 \&\fB.rodata\fR, \fB.rodata1\fR, \fB.data1\fR sections into external
9417 memory, which starts at location \f(CW\*(C`0x80000000\*(C'\fR.
9418 .Ip "\fB\-mextmemory\fR" 4
9419 .IX Item "-mextmemory"
9420 Same as the \fB\-mextmem\fR switch.
9421 .Ip "\fB\-monchip\fR" 4
9422 .IX Item "-monchip"
9423 Link the \fB.text\fR section into onchip text memory, which starts at
9424 location \f(CW\*(C`0x0\*(C'\fR.  Also link \fB.data\fR, \fB.bss\fR,
9425 \&\fB.strings\fR, \fB.rodata\fR, \fB.rodata1\fR, \fB.data1\fR sections
9426 into onchip data memory, which starts at location \f(CW\*(C`0x20000000\*(C'\fR.
9427 .Ip "\fB\-mno-asm-optimize\fR" 4
9428 .IX Item "-mno-asm-optimize"
9429 .PD 0
9430 .Ip "\fB\-masm-optimize\fR" 4
9431 .IX Item "-masm-optimize"
9433 Disable (enable) passing \fB\-O\fR to the assembler when optimizing.
9434 The assembler uses the \fB\-O\fR option to automatically parallelize
9435 adjacent short instructions where possible.
9436 .Ip "\fB\-mbranch-cost=\fR\fIn\fR" 4
9437 .IX Item "-mbranch-cost=n"
9438 Increase the internal costs of branches to \fIn\fR.  Higher costs means
9439 that the compiler will issue more instructions to avoid doing a branch.
9440 The default is 2.
9441 .Ip "\fB\-mcond-exec=\fR\fIn\fR" 4
9442 .IX Item "-mcond-exec=n"
9443 Specify the maximum number of conditionally executed instructions that
9444 replace a branch.  The default is 4.
9446 .I "S/390 and zSeries Options"
9447 .IX Subsection "S/390 and zSeries Options"
9449 These are the \fB\-m\fR options defined for the S/390 and zSeries architecture.
9450 .Ip "\fB\-mhard-float\fR" 4
9451 .IX Item "-mhard-float"
9452 .PD 0
9453 .Ip "\fB\-msoft-float\fR" 4
9454 .IX Item "-msoft-float"
9456 Use (do not use) the hardware floating-point instructions and registers
9457 for floating-point operations.  When \fB\-msoft-float\fR is specified,
9458 functions in \fIlibgcc.a\fR will be used to perform floating-point
9459 operations.  When \fB\-mhard-float\fR is specified, the compiler
9460 generates \s-1IEEE\s0 floating-point instructions.  This is the default.
9461 .Ip "\fB\-mbackchain\fR" 4
9462 .IX Item "-mbackchain"
9463 .PD 0
9464 .Ip "\fB\-mno-backchain\fR" 4
9465 .IX Item "-mno-backchain"
9467 Generate (or do not generate) code which maintains an explicit
9468 backchain within the stack frame that points to the caller's frame.
9469 This may be needed to allow debugging using tools that do not understand
9470 \&\s-1DWARF-2\s0 call frame information.  The default is not to generate the
9471 backchain.
9472 .Ip "\fB\-msmall-exec\fR" 4
9473 .IX Item "-msmall-exec"
9474 .PD 0
9475 .Ip "\fB\-mno-small-exec\fR" 4
9476 .IX Item "-mno-small-exec"
9478 Generate (or do not generate) code using the \f(CW\*(C`bras\*(C'\fR instruction
9479 to do subroutine calls.
9480 This only works reliably if the total executable size does not
9481 exceed 64k.  The default is to use the \f(CW\*(C`basr\*(C'\fR instruction instead,
9482 which does not have this limitation.
9483 .Ip "\fB\-m64\fR" 4
9484 .IX Item "-m64"
9485 .PD 0
9486 .Ip "\fB\-m31\fR" 4
9487 .IX Item "-m31"
9489 When \fB\-m31\fR is specified, generate code compliant to the
9490 GNU/Linux for S/390 \s-1ABI\s0.  When \fB\-m64\fR is specified, generate
9491 code compliant to the GNU/Linux for zSeries \s-1ABI\s0.  This allows \s-1GCC\s0 in
9492 particular to generate 64\-bit instructions.  For the \fBs390\fR
9493 targets, the default is \fB\-m31\fR, while the \fBs390x\fR
9494 targets default to \fB\-m64\fR.
9495 .Ip "\fB\-mzarch\fR" 4
9496 .IX Item "-mzarch"
9497 .PD 0
9498 .Ip "\fB\-mesa\fR" 4
9499 .IX Item "-mesa"
9501 When \fB\-mzarch\fR is specified, generate code using the
9502 instructions available on z/Architecture.
9503 When \fB\-mesa\fR is specified, generate code using the
9504 instructions available on \s-1ESA/390\s0. Note that \fB\-mesa\fR is
9505 not possible with \fB\-m64\fR.
9506 When generating code compliant to the GNU/Linux for S/390 \s-1ABI\s0,
9507 the default is \fB\-mesa\fR.  When generating code compliant
9508 to the GNU/Linux for zSeries \s-1ABI\s0, the default is \fB\-mzarch\fR.
9509 .Ip "\fB\-mmvcle\fR" 4
9510 .IX Item "-mmvcle"
9511 .PD 0
9512 .Ip "\fB\-mno-mvcle\fR" 4
9513 .IX Item "-mno-mvcle"
9515 Generate (or do not generate) code using the \f(CW\*(C`mvcle\*(C'\fR instruction
9516 to perform block moves.  When \fB\-mno-mvcle\fR is specified,
9517 use a \f(CW\*(C`mvc\*(C'\fR loop instead.  This is the default.
9518 .Ip "\fB\-mdebug\fR" 4
9519 .IX Item "-mdebug"
9520 .PD 0
9521 .Ip "\fB\-mno-debug\fR" 4
9522 .IX Item "-mno-debug"
9524 Print (or do not print) additional debug information when compiling.
9525 The default is to not print debug information.
9526 .Ip "\fB\-march=\fR\fIcpu-type\fR" 4
9527 .IX Item "-march=cpu-type"
9528 Generate code that will run on \fIcpu-type\fR, which is the name of a system
9529 representing a certain processor type. Possible values for
9530 \&\fIcpu-type\fR are \fBg5\fR, \fBg6\fR, \fBz900\fR, and \fBz990\fR.
9531 When generating code using the instructions available on z/Architecture,
9532 the default is \fB\-march=z900\fR.  Otherwise, the default is
9533 \&\fB\-march=g5\fR.
9534 .Ip "\fB\-mtune=\fR\fIcpu-type\fR" 4
9535 .IX Item "-mtune=cpu-type"
9536 Tune to \fIcpu-type\fR everything applicable about the generated code,
9537 except for the \s-1ABI\s0 and the set of available instructions.
9538 The list of \fIcpu-type\fR values is the same as for \fB\-march\fR.
9539 The default is the value used for \fB\-march\fR.
9540 .Ip "\fB\-mfused-madd\fR" 4
9541 .IX Item "-mfused-madd"
9542 .PD 0
9543 .Ip "\fB\-mno-fused-madd\fR" 4
9544 .IX Item "-mno-fused-madd"
9546 Generate code that uses (does not use) the floating point multiply and
9547 accumulate instructions.  These instructions are generated by default if
9548 hardware floating point is used.
9550 .I "\s-1CRIS\s0 Options"
9551 .IX Subsection "CRIS Options"
9553 These options are defined specifically for the \s-1CRIS\s0 ports.
9554 .Ip "\fB\-march=\fR\fIarchitecture-type\fR" 4
9555 .IX Item "-march=architecture-type"
9556 .PD 0
9557 .Ip "\fB\-mcpu=\fR\fIarchitecture-type\fR" 4
9558 .IX Item "-mcpu=architecture-type"
9560 Generate code for the specified architecture.  The choices for
9561 \&\fIarchitecture-type\fR are \fBv3\fR, \fBv8\fR and \fBv10\fR for
9562 respectively \s-1ETRAX\s0\ 4, \s-1ETRAX\s0\ 100, and \s-1ETRAX\s0\ 100\ \s-1LX\s0.
9563 Default is \fBv0\fR except for cris-axis-linux-gnu, where the default is
9564 \&\fBv10\fR.
9565 .Ip "\fB\-mtune=\fR\fIarchitecture-type\fR" 4
9566 .IX Item "-mtune=architecture-type"
9567 Tune to \fIarchitecture-type\fR everything applicable about the generated
9568 code, except for the \s-1ABI\s0 and the set of available instructions.  The
9569 choices for \fIarchitecture-type\fR are the same as for
9570 \&\fB\-march=\fR\fIarchitecture-type\fR.
9571 .Ip "\fB\-mmax-stack-frame=\fR\fIn\fR" 4
9572 .IX Item "-mmax-stack-frame=n"
9573 Warn when the stack frame of a function exceeds \fIn\fR bytes.
9574 .Ip "\fB\-melinux-stacksize=\fR\fIn\fR" 4
9575 .IX Item "-melinux-stacksize=n"
9576 Only available with the \fBcris-axis-aout\fR target.  Arranges for
9577 indications in the program to the kernel loader that the stack of the
9578 program should be set to \fIn\fR bytes.
9579 .Ip "\fB\-metrax4\fR" 4
9580 .IX Item "-metrax4"
9581 .PD 0
9582 .Ip "\fB\-metrax100\fR" 4
9583 .IX Item "-metrax100"
9585 The options \fB\-metrax4\fR and \fB\-metrax100\fR are synonyms for
9586 \&\fB\-march=v3\fR and \fB\-march=v8\fR respectively.
9587 .Ip "\fB\-mmul-bug-workaround\fR" 4
9588 .IX Item "-mmul-bug-workaround"
9589 .PD 0
9590 .Ip "\fB\-mno-mul-bug-workaround\fR" 4
9591 .IX Item "-mno-mul-bug-workaround"
9593 Work around a bug in the \f(CW\*(C`muls\*(C'\fR and \f(CW\*(C`mulu\*(C'\fR instructions for \s-1CPU\s0
9594 models where it applies.  This option is active by default.
9595 .Ip "\fB\-mpdebug\fR" 4
9596 .IX Item "-mpdebug"
9597 Enable CRIS-specific verbose debug-related information in the assembly
9598 code.  This option also has the effect to turn off the \fB#NO_APP\fR
9599 formatted-code indicator to the assembler at the beginning of the
9600 assembly file.
9601 .Ip "\fB\-mcc-init\fR" 4
9602 .IX Item "-mcc-init"
9603 Do not use condition-code results from previous instruction; always emit
9604 compare and test instructions before use of condition codes.
9605 .Ip "\fB\-mno-side-effects\fR" 4
9606 .IX Item "-mno-side-effects"
9607 Do not emit instructions with side-effects in addressing modes other than
9608 post-increment.
9609 .Ip "\fB\-mstack-align\fR" 4
9610 .IX Item "-mstack-align"
9611 .PD 0
9612 .Ip "\fB\-mno-stack-align\fR" 4
9613 .IX Item "-mno-stack-align"
9614 .Ip "\fB\-mdata-align\fR" 4
9615 .IX Item "-mdata-align"
9616 .Ip "\fB\-mno-data-align\fR" 4
9617 .IX Item "-mno-data-align"
9618 .Ip "\fB\-mconst-align\fR" 4
9619 .IX Item "-mconst-align"
9620 .Ip "\fB\-mno-const-align\fR" 4
9621 .IX Item "-mno-const-align"
9623 These options (no-options) arranges (eliminate arrangements) for the
9624 stack-frame, individual data and constants to be aligned for the maximum
9625 single data access size for the chosen \s-1CPU\s0 model.  The default is to
9626 arrange for 32\-bit alignment.  \s-1ABI\s0 details such as structure layout are
9627 not affected by these options.
9628 .Ip "\fB\-m32\-bit\fR" 4
9629 .IX Item "-m32-bit"
9630 .PD 0
9631 .Ip "\fB\-m16\-bit\fR" 4
9632 .IX Item "-m16-bit"
9633 .Ip "\fB\-m8\-bit\fR" 4
9634 .IX Item "-m8-bit"
9636 Similar to the stack- data- and const-align options above, these options
9637 arrange for stack-frame, writable data and constants to all be 32\-bit,
9638 16\-bit or 8\-bit aligned.  The default is 32\-bit alignment.
9639 .Ip "\fB\-mno-prologue-epilogue\fR" 4
9640 .IX Item "-mno-prologue-epilogue"
9641 .PD 0
9642 .Ip "\fB\-mprologue-epilogue\fR" 4
9643 .IX Item "-mprologue-epilogue"
9645 With \fB\-mno-prologue-epilogue\fR, the normal function prologue and
9646 epilogue that sets up the stack-frame are omitted and no return
9647 instructions or return sequences are generated in the code.  Use this
9648 option only together with visual inspection of the compiled code: no
9649 warnings or errors are generated when call-saved registers must be saved,
9650 or storage for local variable needs to be allocated.
9651 .Ip "\fB\-mno-gotplt\fR" 4
9652 .IX Item "-mno-gotplt"
9653 .PD 0
9654 .Ip "\fB\-mgotplt\fR" 4
9655 .IX Item "-mgotplt"
9657 With \fB\-fpic\fR and \fB\-fPIC\fR, don't generate (do generate)
9658 instruction sequences that load addresses for functions from the \s-1PLT\s0 part
9659 of the \s-1GOT\s0 rather than (traditional on other architectures) calls to the
9660 \&\s-1PLT\s0.  The default is \fB\-mgotplt\fR.
9661 .Ip "\fB\-maout\fR" 4
9662 .IX Item "-maout"
9663 Legacy no-op option only recognized with the cris-axis-aout target.
9664 .Ip "\fB\-melf\fR" 4
9665 .IX Item "-melf"
9666 Legacy no-op option only recognized with the cris-axis-elf and
9667 cris-axis-linux-gnu targets.
9668 .Ip "\fB\-melinux\fR" 4
9669 .IX Item "-melinux"
9670 Only recognized with the cris-axis-aout target, where it selects a
9671 GNU/linux-like multilib, include files and instruction set for
9672 \&\fB\-march=v8\fR.
9673 .Ip "\fB\-mlinux\fR" 4
9674 .IX Item "-mlinux"
9675 Legacy no-op option only recognized with the cris-axis-linux-gnu target.
9676 .Ip "\fB\-sim\fR" 4
9677 .IX Item "-sim"
9678 This option, recognized for the cris-axis-aout and cris-axis-elf arranges
9679 to link with input-output functions from a simulator library.  Code,
9680 initialized data and zero-initialized data are allocated consecutively.
9681 .Ip "\fB\-sim2\fR" 4
9682 .IX Item "-sim2"
9683 Like \fB\-sim\fR, but pass linker options to locate initialized data at
9684 0x40000000 and zero-initialized data at 0x80000000.
9686 .I "\s-1MMIX\s0 Options"
9687 .IX Subsection "MMIX Options"
9689 These options are defined for the \s-1MMIX:\s0
9690 .Ip "\fB\-mlibfuncs\fR" 4
9691 .IX Item "-mlibfuncs"
9692 .PD 0
9693 .Ip "\fB\-mno-libfuncs\fR" 4
9694 .IX Item "-mno-libfuncs"
9696 Specify that intrinsic library functions are being compiled, passing all
9697 values in registers, no matter the size.
9698 .Ip "\fB\-mepsilon\fR" 4
9699 .IX Item "-mepsilon"
9700 .PD 0
9701 .Ip "\fB\-mno-epsilon\fR" 4
9702 .IX Item "-mno-epsilon"
9704 Generate floating-point comparison instructions that compare with respect
9705 to the \f(CW\*(C`rE\*(C'\fR epsilon register.
9706 .Ip "\fB\-mabi=mmixware\fR" 4
9707 .IX Item "-mabi=mmixware"
9708 .PD 0
9709 .Ip "\fB\-mabi=gnu\fR" 4
9710 .IX Item "-mabi=gnu"
9712 Generate code that passes function parameters and return values that (in
9713 the called function) are seen as registers \f(CW\*(C`$0\*(C'\fR and up, as opposed to
9714 the \s-1GNU\s0 \s-1ABI\s0 which uses global registers \f(CW\*(C`$231\*(C'\fR and up.
9715 .Ip "\fB\-mzero-extend\fR" 4
9716 .IX Item "-mzero-extend"
9717 .PD 0
9718 .Ip "\fB\-mno-zero-extend\fR" 4
9719 .IX Item "-mno-zero-extend"
9721 When reading data from memory in sizes shorter than 64 bits, use (do not
9722 use) zero-extending load instructions by default, rather than
9723 sign-extending ones.
9724 .Ip "\fB\-mknuthdiv\fR" 4
9725 .IX Item "-mknuthdiv"
9726 .PD 0
9727 .Ip "\fB\-mno-knuthdiv\fR" 4
9728 .IX Item "-mno-knuthdiv"
9730 Make the result of a division yielding a remainder have the same sign as
9731 the divisor.  With the default, \fB\-mno-knuthdiv\fR, the sign of the
9732 remainder follows the sign of the dividend.  Both methods are
9733 arithmetically valid, the latter being almost exclusively used.
9734 .Ip "\fB\-mtoplevel-symbols\fR" 4
9735 .IX Item "-mtoplevel-symbols"
9736 .PD 0
9737 .Ip "\fB\-mno-toplevel-symbols\fR" 4
9738 .IX Item "-mno-toplevel-symbols"
9740 Prepend (do not prepend) a \fB:\fR to all global symbols, so the assembly
9741 code can be used with the \f(CW\*(C`PREFIX\*(C'\fR assembly directive.
9742 .Ip "\fB\-melf\fR" 4
9743 .IX Item "-melf"
9744 Generate an executable in the \s-1ELF\s0 format, rather than the default
9745 \&\fBmmo\fR format used by the \fBmmix\fR simulator.
9746 .Ip "\fB\-mbranch-predict\fR" 4
9747 .IX Item "-mbranch-predict"
9748 .PD 0
9749 .Ip "\fB\-mno-branch-predict\fR" 4
9750 .IX Item "-mno-branch-predict"
9752 Use (do not use) the probable-branch instructions, when static branch
9753 prediction indicates a probable branch.
9754 .Ip "\fB\-mbase-addresses\fR" 4
9755 .IX Item "-mbase-addresses"
9756 .PD 0
9757 .Ip "\fB\-mno-base-addresses\fR" 4
9758 .IX Item "-mno-base-addresses"
9760 Generate (do not generate) code that uses \fIbase addresses\fR.  Using a
9761 base address automatically generates a request (handled by the assembler
9762 and the linker) for a constant to be set up in a global register.  The
9763 register is used for one or more base address requests within the range 0
9764 to 255 from the value held in the register.  The generally leads to short
9765 and fast code, but the number of different data items that can be
9766 addressed is limited.  This means that a program that uses lots of static
9767 data may require \fB\-mno-base-addresses\fR.
9768 .Ip "\fB\-msingle-exit\fR" 4
9769 .IX Item "-msingle-exit"
9770 .PD 0
9771 .Ip "\fB\-mno-single-exit\fR" 4
9772 .IX Item "-mno-single-exit"
9774 Force (do not force) generated code to have a single exit point in each
9775 function.
9777 .I "\s-1PDP-11\s0 Options"
9778 .IX Subsection "PDP-11 Options"
9780 These options are defined for the \s-1PDP-11:\s0
9781 .Ip "\fB\-mfpu\fR" 4
9782 .IX Item "-mfpu"
9783 Use hardware \s-1FPP\s0 floating point.  This is the default.  (\s-1FIS\s0 floating
9784 point on the \s-1PDP-11/40\s0 is not supported.)
9785 .Ip "\fB\-msoft-float\fR" 4
9786 .IX Item "-msoft-float"
9787 Do not use hardware floating point.
9788 .Ip "\fB\-mac0\fR" 4
9789 .IX Item "-mac0"
9790 Return floating-point results in ac0 (fr0 in Unix assembler syntax).
9791 .Ip "\fB\-mno-ac0\fR" 4
9792 .IX Item "-mno-ac0"
9793 Return floating-point results in memory.  This is the default.
9794 .Ip "\fB\-m40\fR" 4
9795 .IX Item "-m40"
9796 Generate code for a \s-1PDP-11/40\s0.
9797 .Ip "\fB\-m45\fR" 4
9798 .IX Item "-m45"
9799 Generate code for a \s-1PDP-11/45\s0.  This is the default.
9800 .Ip "\fB\-m10\fR" 4
9801 .IX Item "-m10"
9802 Generate code for a \s-1PDP-11/10\s0.
9803 .Ip "\fB\-mbcopy-builtin\fR" 4
9804 .IX Item "-mbcopy-builtin"
9805 Use inline \f(CW\*(C`movstrhi\*(C'\fR patterns for copying memory.  This is the
9806 default.
9807 .Ip "\fB\-mbcopy\fR" 4
9808 .IX Item "-mbcopy"
9809 Do not use inline \f(CW\*(C`movstrhi\*(C'\fR patterns for copying memory.
9810 .Ip "\fB\-mint16\fR" 4
9811 .IX Item "-mint16"
9812 .PD 0
9813 .Ip "\fB\-mno-int32\fR" 4
9814 .IX Item "-mno-int32"
9816 Use 16\-bit \f(CW\*(C`int\*(C'\fR.  This is the default.
9817 .Ip "\fB\-mint32\fR" 4
9818 .IX Item "-mint32"
9819 .PD 0
9820 .Ip "\fB\-mno-int16\fR" 4
9821 .IX Item "-mno-int16"
9823 Use 32\-bit \f(CW\*(C`int\*(C'\fR.
9824 .Ip "\fB\-mfloat64\fR" 4
9825 .IX Item "-mfloat64"
9826 .PD 0
9827 .Ip "\fB\-mno-float32\fR" 4
9828 .IX Item "-mno-float32"
9830 Use 64\-bit \f(CW\*(C`float\*(C'\fR.  This is the default.
9831 .Ip "\fB\-mfloat32\fR" 4
9832 .IX Item "-mfloat32"
9833 .PD 0
9834 .Ip "\fB\-mno-float64\fR" 4
9835 .IX Item "-mno-float64"
9837 Use 32\-bit \f(CW\*(C`float\*(C'\fR.
9838 .Ip "\fB\-mabshi\fR" 4
9839 .IX Item "-mabshi"
9840 Use \f(CW\*(C`abshi2\*(C'\fR pattern.  This is the default.
9841 .Ip "\fB\-mno-abshi\fR" 4
9842 .IX Item "-mno-abshi"
9843 Do not use \f(CW\*(C`abshi2\*(C'\fR pattern.
9844 .Ip "\fB\-mbranch-expensive\fR" 4
9845 .IX Item "-mbranch-expensive"
9846 Pretend that branches are expensive.  This is for experimenting with
9847 code generation only.
9848 .Ip "\fB\-mbranch-cheap\fR" 4
9849 .IX Item "-mbranch-cheap"
9850 Do not pretend that branches are expensive.  This is the default.
9851 .Ip "\fB\-msplit\fR" 4
9852 .IX Item "-msplit"
9853 Generate code for a system with split I&D.
9854 .Ip "\fB\-mno-split\fR" 4
9855 .IX Item "-mno-split"
9856 Generate code for a system without split I&D.  This is the default.
9857 .Ip "\fB\-munix-asm\fR" 4
9858 .IX Item "-munix-asm"
9859 Use Unix assembler syntax.  This is the default when configured for
9860 \&\fBpdp11\-*\-bsd\fR.
9861 .Ip "\fB\-mdec-asm\fR" 4
9862 .IX Item "-mdec-asm"
9863 Use \s-1DEC\s0 assembler syntax.  This is the default when configured for any
9864 \&\s-1PDP-11\s0 target other than \fBpdp11\-*\-bsd\fR.
9866 .I "Xstormy16 Options"
9867 .IX Subsection "Xstormy16 Options"
9869 These options are defined for Xstormy16:
9870 .Ip "\fB\-msim\fR" 4
9871 .IX Item "-msim"
9872 Choose startup files and linker script suitable for the simulator.
9874 .I "\s-1FRV\s0 Options"
9875 .IX Subsection "FRV Options"
9876 .Ip "\fB\-mgpr-32\fR" 4
9877 .IX Item "-mgpr-32"
9878 Only use the first 32 general purpose registers.
9879 .Ip "\fB\-mgpr-64\fR" 4
9880 .IX Item "-mgpr-64"
9881 Use all 64 general purpose registers.
9882 .Ip "\fB\-mfpr-32\fR" 4
9883 .IX Item "-mfpr-32"
9884 Use only the first 32 floating point registers.
9885 .Ip "\fB\-mfpr-64\fR" 4
9886 .IX Item "-mfpr-64"
9887 Use all 64 floating point registers
9888 .Ip "\fB\-mhard-float\fR" 4
9889 .IX Item "-mhard-float"
9890 Use hardware instructions for floating point operations.
9891 .Ip "\fB\-msoft-float\fR" 4
9892 .IX Item "-msoft-float"
9893 Use library routines for floating point operations.
9894 .Ip "\fB\-malloc-cc\fR" 4
9895 .IX Item "-malloc-cc"
9896 Dynamically allocate condition code registers.
9897 .Ip "\fB\-mfixed-cc\fR" 4
9898 .IX Item "-mfixed-cc"
9899 Do not try to dynamically allocate condition code registers, only
9900 use \f(CW\*(C`icc0\*(C'\fR and \f(CW\*(C`fcc0\*(C'\fR.
9901 .Ip "\fB\-mdword\fR" 4
9902 .IX Item "-mdword"
9903 Change \s-1ABI\s0 to use double word insns.
9904 .Ip "\fB\-mno-dword\fR" 4
9905 .IX Item "-mno-dword"
9906 Do not use double word instructions.
9907 .Ip "\fB\-mdouble\fR" 4
9908 .IX Item "-mdouble"
9909 Use floating point double instructions.
9910 .Ip "\fB\-mno-double\fR" 4
9911 .IX Item "-mno-double"
9912 Do not use floating point double instructions.
9913 .Ip "\fB\-mmedia\fR" 4
9914 .IX Item "-mmedia"
9915 Use media instructions.
9916 .Ip "\fB\-mno-media\fR" 4
9917 .IX Item "-mno-media"
9918 Do not use media instructions.
9919 .Ip "\fB\-mmuladd\fR" 4
9920 .IX Item "-mmuladd"
9921 Use multiply and add/subtract instructions.
9922 .Ip "\fB\-mno-muladd\fR" 4
9923 .IX Item "-mno-muladd"
9924 Do not use multiply and add/subtract instructions.
9925 .Ip "\fB\-mlibrary-pic\fR" 4
9926 .IX Item "-mlibrary-pic"
9927 Enable \s-1PIC\s0 support for building libraries
9928 .Ip "\fB\-macc-4\fR" 4
9929 .IX Item "-macc-4"
9930 Use only the first four media accumulator registers.
9931 .Ip "\fB\-macc-8\fR" 4
9932 .IX Item "-macc-8"
9933 Use all eight media accumulator registers.
9934 .Ip "\fB\-mpack\fR" 4
9935 .IX Item "-mpack"
9936 Pack \s-1VLIW\s0 instructions.
9937 .Ip "\fB\-mno-pack\fR" 4
9938 .IX Item "-mno-pack"
9939 Do not pack \s-1VLIW\s0 instructions.
9940 .Ip "\fB\-mno-eflags\fR" 4
9941 .IX Item "-mno-eflags"
9942 Do not mark \s-1ABI\s0 switches in e_flags.
9943 .Ip "\fB\-mcond-move\fR" 4
9944 .IX Item "-mcond-move"
9945 Enable the use of conditional-move instructions (default).
9947 This switch is mainly for debugging the compiler and will likely be removed
9948 in a future version.
9949 .Ip "\fB\-mno-cond-move\fR" 4
9950 .IX Item "-mno-cond-move"
9951 Disable the use of conditional-move instructions.
9953 This switch is mainly for debugging the compiler and will likely be removed
9954 in a future version.
9955 .Ip "\fB\-mscc\fR" 4
9956 .IX Item "-mscc"
9957 Enable the use of conditional set instructions (default).
9959 This switch is mainly for debugging the compiler and will likely be removed
9960 in a future version.
9961 .Ip "\fB\-mno-scc\fR" 4
9962 .IX Item "-mno-scc"
9963 Disable the use of conditional set instructions.
9965 This switch is mainly for debugging the compiler and will likely be removed
9966 in a future version.
9967 .Ip "\fB\-mcond-exec\fR" 4
9968 .IX Item "-mcond-exec"
9969 Enable the use of conditional execution (default).
9971 This switch is mainly for debugging the compiler and will likely be removed
9972 in a future version.
9973 .Ip "\fB\-mno-cond-exec\fR" 4
9974 .IX Item "-mno-cond-exec"
9975 Disable the use of conditional execution.
9977 This switch is mainly for debugging the compiler and will likely be removed
9978 in a future version.
9979 .Ip "\fB\-mvliw-branch\fR" 4
9980 .IX Item "-mvliw-branch"
9981 Run a pass to pack branches into \s-1VLIW\s0 instructions (default).
9983 This switch is mainly for debugging the compiler and will likely be removed
9984 in a future version.
9985 .Ip "\fB\-mno-vliw-branch\fR" 4
9986 .IX Item "-mno-vliw-branch"
9987 Do not run a pass to pack branches into \s-1VLIW\s0 instructions.
9989 This switch is mainly for debugging the compiler and will likely be removed
9990 in a future version.
9991 .Ip "\fB\-mmulti-cond-exec\fR" 4
9992 .IX Item "-mmulti-cond-exec"
9993 Enable optimization of \f(CW\*(C`&&\*(C'\fR and \f(CW\*(C`||\*(C'\fR in conditional execution
9994 (default).
9996 This switch is mainly for debugging the compiler and will likely be removed
9997 in a future version.
9998 .Ip "\fB\-mno-multi-cond-exec\fR" 4
9999 .IX Item "-mno-multi-cond-exec"
10000 Disable optimization of \f(CW\*(C`&&\*(C'\fR and \f(CW\*(C`||\*(C'\fR in conditional execution.
10002 This switch is mainly for debugging the compiler and will likely be removed
10003 in a future version.
10004 .Ip "\fB\-mnested-cond-exec\fR" 4
10005 .IX Item "-mnested-cond-exec"
10006 Enable nested conditional execution optimizations (default).
10008 This switch is mainly for debugging the compiler and will likely be removed
10009 in a future version.
10010 .Ip "\fB\-mno-nested-cond-exec\fR" 4
10011 .IX Item "-mno-nested-cond-exec"
10012 Disable nested conditional execution optimizations.
10014 This switch is mainly for debugging the compiler and will likely be removed
10015 in a future version.
10016 .Ip "\fB\-mtomcat-stats\fR" 4
10017 .IX Item "-mtomcat-stats"
10018 Cause gas to print out tomcat statistics.
10019 .Ip "\fB\-mcpu=\fR\fIcpu\fR" 4
10020 .IX Item "-mcpu=cpu"
10021 Select the processor type for which to generate code.  Possible values are
10022 \&\fBsimple\fR, \fBtomcat\fR, \fBfr500\fR, \fBfr400\fR, \fBfr300\fR,
10023 \&\fBfrv\fR.
10025 .I "Xtensa Options"
10026 .IX Subsection "Xtensa Options"
10028 These options are supported for Xtensa targets:
10029 .Ip "\fB\-mconst16\fR" 4
10030 .IX Item "-mconst16"
10031 .PD 0
10032 .Ip "\fB\-mno-const16\fR" 4
10033 .IX Item "-mno-const16"
10035 Enable or disable use of \f(CW\*(C`CONST16\*(C'\fR instructions for loading
10036 constant values.  The \f(CW\*(C`CONST16\*(C'\fR instruction is currently not a
10037 standard option from Tensilica.  When enabled, \f(CW\*(C`CONST16\*(C'\fR
10038 instructions are always used in place of the standard \f(CW\*(C`L32R\*(C'\fR
10039 instructions.  The use of \f(CW\*(C`CONST16\*(C'\fR is enabled by default only if
10040 the \f(CW\*(C`L32R\*(C'\fR instruction is not available.
10041 .Ip "\fB\-mfused-madd\fR" 4
10042 .IX Item "-mfused-madd"
10043 .PD 0
10044 .Ip "\fB\-mno-fused-madd\fR" 4
10045 .IX Item "-mno-fused-madd"
10047 Enable or disable use of fused multiply/add and multiply/subtract
10048 instructions in the floating-point option.  This has no effect if the
10049 floating-point option is not also enabled.  Disabling fused multiply/add
10050 and multiply/subtract instructions forces the compiler to use separate
10051 instructions for the multiply and add/subtract operations.  This may be
10052 desirable in some cases where strict \s-1IEEE\s0 754\-compliant results are
10053 required: the fused multiply add/subtract instructions do not round the
10054 intermediate result, thereby producing results with \fImore\fR bits of
10055 precision than specified by the \s-1IEEE\s0 standard.  Disabling fused multiply
10056 add/subtract instructions also ensures that the program output is not
10057 sensitive to the compiler's ability to combine multiply and add/subtract
10058 operations.
10059 .Ip "\fB\-mtext-section-literals\fR" 4
10060 .IX Item "-mtext-section-literals"
10061 .PD 0
10062 .Ip "\fB\-mno-text-section-literals\fR" 4
10063 .IX Item "-mno-text-section-literals"
10065 Control the treatment of literal pools.  The default is
10066 \&\fB\-mno-text-section-literals\fR, which places literals in a separate
10067 section in the output file.  This allows the literal pool to be placed
10068 in a data \s-1RAM/ROM\s0, and it also allows the linker to combine literal
10069 pools from separate object files to remove redundant literals and
10070 improve code size.  With \fB\-mtext-section-literals\fR, the literals
10071 are interspersed in the text section in order to keep them as close as
10072 possible to their references.  This may be necessary for large assembly
10073 files.
10074 .Ip "\fB\-mtarget-align\fR" 4
10075 .IX Item "-mtarget-align"
10076 .PD 0
10077 .Ip "\fB\-mno-target-align\fR" 4
10078 .IX Item "-mno-target-align"
10080 When this option is enabled, \s-1GCC\s0 instructs the assembler to
10081 automatically align instructions to reduce branch penalties at the
10082 expense of some code density.  The assembler attempts to widen density
10083 instructions to align branch targets and the instructions following call
10084 instructions.  If there are not enough preceding safe density
10085 instructions to align a target, no widening will be performed.  The
10086 default is \fB\-mtarget-align\fR.  These options do not affect the
10087 treatment of auto-aligned instructions like \f(CW\*(C`LOOP\*(C'\fR, which the
10088 assembler will always align, either by widening density instructions or
10089 by inserting no-op instructions.
10090 .Ip "\fB\-mlongcalls\fR" 4
10091 .IX Item "-mlongcalls"
10092 .PD 0
10093 .Ip "\fB\-mno-longcalls\fR" 4
10094 .IX Item "-mno-longcalls"
10096 When this option is enabled, \s-1GCC\s0 instructs the assembler to translate
10097 direct calls to indirect calls unless it can determine that the target
10098 of a direct call is in the range allowed by the call instruction.  This
10099 translation typically occurs for calls to functions in other source
10100 files.  Specifically, the assembler translates a direct \f(CW\*(C`CALL\*(C'\fR
10101 instruction into an \f(CW\*(C`L32R\*(C'\fR followed by a \f(CW\*(C`CALLX\*(C'\fR instruction.
10102 The default is \fB\-mno-longcalls\fR.  This option should be used in
10103 programs where the call target can potentially be out of range.  This
10104 option is implemented in the assembler, not the compiler, so the
10105 assembly code generated by \s-1GCC\s0 will still show direct call
10106 instructions\-\-\-look at the disassembled object code to see the actual
10107 instructions.  Note that the assembler will use an indirect call for
10108 every cross-file call, not just those that really will be out of range.
10109 .Sh "Options for Code Generation Conventions"
10110 .IX Subsection "Options for Code Generation Conventions"
10111 These machine-independent options control the interface conventions
10112 used in code generation.
10114 Most of them have both positive and negative forms; the negative form
10115 of \fB\-ffoo\fR would be \fB\-fno-foo\fR.  In the table below, only
10116 one of the forms is listed\-\-\-the one which is not the default.  You
10117 can figure out the other form by either removing \fBno-\fR or adding
10119 .Ip "\fB\-fbounds-check\fR" 4
10120 .IX Item "-fbounds-check"
10121 For front-ends that support it, generate additional code to check that
10122 indices used to access arrays are within the declared range.  This is
10123 currently only supported by the Java and Fortran 77 front-ends, where
10124 this option defaults to true and false respectively.
10125 .Ip "\fB\-ftrapv\fR" 4
10126 .IX Item "-ftrapv"
10127 This option generates traps for signed overflow on addition, subtraction,
10128 multiplication operations.
10129 .Ip "\fB\-fwrapv\fR" 4
10130 .IX Item "-fwrapv"
10131 This option instructs the compiler to assume that signed arithmetic
10132 overflow of addition, subtraction and multiplication wraps around
10133 using twos-complement representation.  This flag enables some optimizations
10134 and disables other.  This option is enabled by default for the Java
10135 front-end, as required by the Java language specification.
10136 .Ip "\fB\-fexceptions\fR" 4
10137 .IX Item "-fexceptions"
10138 Enable exception handling.  Generates extra code needed to propagate
10139 exceptions.  For some targets, this implies \s-1GCC\s0 will generate frame
10140 unwind information for all functions, which can produce significant data
10141 size overhead, although it does not affect execution.  If you do not
10142 specify this option, \s-1GCC\s0 will enable it by default for languages like
10143 \&\*(C+ which normally require exception handling, and disable it for
10144 languages like C that do not normally require it.  However, you may need
10145 to enable this option when compiling C code that needs to interoperate
10146 properly with exception handlers written in \*(C+.  You may also wish to
10147 disable this option if you are compiling older \*(C+ programs that don't
10148 use exception handling.
10149 .Ip "\fB\-fnon-call-exceptions\fR" 4
10150 .IX Item "-fnon-call-exceptions"
10151 Generate code that allows trapping instructions to throw exceptions.
10152 Note that this requires platform-specific runtime support that does
10153 not exist everywhere.  Moreover, it only allows \fItrapping\fR
10154 instructions to throw exceptions, i.e. memory references or floating
10155 point instructions.  It does not allow exceptions to be thrown from
10156 arbitrary signal handlers such as \f(CW\*(C`SIGALRM\*(C'\fR.
10157 .Ip "\fB\-funwind-tables\fR" 4
10158 .IX Item "-funwind-tables"
10159 Similar to \fB\-fexceptions\fR, except that it will just generate any needed
10160 static data, but will not affect the generated code in any other way.
10161 You will normally not enable this option; instead, a language processor
10162 that needs this handling would enable it on your behalf.
10163 .Ip "\fB\-fasynchronous-unwind-tables\fR" 4
10164 .IX Item "-fasynchronous-unwind-tables"
10165 Generate unwind table in dwarf2 format, if supported by target machine.  The
10166 table is exact at each instruction boundary, so it can be used for stack
10167 unwinding from asynchronous events (such as debugger or garbage collector).
10168 .Ip "\fB\-fpcc-struct-return\fR" 4
10169 .IX Item "-fpcc-struct-return"
10170 Return ``short'' \f(CW\*(C`struct\*(C'\fR and \f(CW\*(C`union\*(C'\fR values in memory like
10171 longer ones, rather than in registers.  This convention is less
10172 efficient, but it has the advantage of allowing intercallability between
10173 GCC-compiled files and files compiled with other compilers, particularly
10174 the Portable C Compiler (pcc).
10176 The precise convention for returning structures in memory depends
10177 on the target configuration macros.
10179 Short structures and unions are those whose size and alignment match
10180 that of some integer type.
10182 \&\fBWarning:\fR code compiled with the \fB\-fpcc-struct-return\fR
10183 switch is not binary compatible with code compiled with the
10184 \&\fB\-freg-struct-return\fR switch.
10185 Use it to conform to a non-default application binary interface.
10186 .Ip "\fB\-freg-struct-return\fR" 4
10187 .IX Item "-freg-struct-return"
10188 Return \f(CW\*(C`struct\*(C'\fR and \f(CW\*(C`union\*(C'\fR values in registers when possible.
10189 This is more efficient for small structures than
10190 \&\fB\-fpcc-struct-return\fR.
10192 If you specify neither \fB\-fpcc-struct-return\fR nor
10193 \&\fB\-freg-struct-return\fR, \s-1GCC\s0 defaults to whichever convention is
10194 standard for the target.  If there is no standard convention, \s-1GCC\s0
10195 defaults to \fB\-fpcc-struct-return\fR, except on targets where \s-1GCC\s0 is
10196 the principal compiler.  In those cases, we can choose the standard, and
10197 we chose the more efficient register return alternative.
10199 \&\fBWarning:\fR code compiled with the \fB\-freg-struct-return\fR
10200 switch is not binary compatible with code compiled with the
10201 \&\fB\-fpcc-struct-return\fR switch.
10202 Use it to conform to a non-default application binary interface.
10203 .Ip "\fB\-fshort-enums\fR" 4
10204 .IX Item "-fshort-enums"
10205 Allocate to an \f(CW\*(C`enum\*(C'\fR type only as many bytes as it needs for the
10206 declared range of possible values.  Specifically, the \f(CW\*(C`enum\*(C'\fR type
10207 will be equivalent to the smallest integer type which has enough room.
10209 \&\fBWarning:\fR the \fB\-fshort-enums\fR switch causes \s-1GCC\s0 to generate
10210 code that is not binary compatible with code generated without that switch.
10211 Use it to conform to a non-default application binary interface.
10212 .Ip "\fB\-fshort-double\fR" 4
10213 .IX Item "-fshort-double"
10214 Use the same size for \f(CW\*(C`double\*(C'\fR as for \f(CW\*(C`float\*(C'\fR.
10216 \&\fBWarning:\fR the \fB\-fshort-double\fR switch causes \s-1GCC\s0 to generate
10217 code that is not binary compatible with code generated without that switch.
10218 Use it to conform to a non-default application binary interface.
10219 .Ip "\fB\-fshort-wchar\fR" 4
10220 .IX Item "-fshort-wchar"
10221 Override the underlying type for \fBwchar_t\fR to be \fBshort
10222 unsigned int\fR instead of the default for the target.  This option is
10223 useful for building programs to run under \s-1WINE\s0.
10225 \&\fBWarning:\fR the \fB\-fshort-wchar\fR switch causes \s-1GCC\s0 to generate
10226 code that is not binary compatible with code generated without that switch.
10227 Use it to conform to a non-default application binary interface.
10228 .Ip "\fB\-fshared-data\fR" 4
10229 .IX Item "-fshared-data"
10230 Requests that the data and non-\f(CW\*(C`const\*(C'\fR variables of this
10231 compilation be shared data rather than private data.  The distinction
10232 makes sense only on certain operating systems, where shared data is
10233 shared between processes running the same program, while private data
10234 exists in one copy per process.
10235 .Ip "\fB\-fno-common\fR" 4
10236 .IX Item "-fno-common"
10237 In C, allocate even uninitialized global variables in the data section of the
10238 object file, rather than generating them as common blocks.  This has the
10239 effect that if the same variable is declared (without \f(CW\*(C`extern\*(C'\fR) in
10240 two different compilations, you will get an error when you link them.
10241 The only reason this might be useful is if you wish to verify that the
10242 program will work on other systems which always work this way.
10243 .Ip "\fB\-fno-ident\fR" 4
10244 .IX Item "-fno-ident"
10245 Ignore the \fB#ident\fR directive.
10246 .Ip "\fB\-finhibit-size-directive\fR" 4
10247 .IX Item "-finhibit-size-directive"
10248 Don't output a \f(CW\*(C`.size\*(C'\fR assembler directive, or anything else that
10249 would cause trouble if the function is split in the middle, and the
10250 two halves are placed at locations far apart in memory.  This option is
10251 used when compiling \fIcrtstuff.c\fR; you should not need to use it
10252 for anything else.
10253 .Ip "\fB\-fverbose-asm\fR" 4
10254 .IX Item "-fverbose-asm"
10255 Put extra commentary information in the generated assembly code to
10256 make it more readable.  This option is generally only of use to those
10257 who actually need to read the generated assembly code (perhaps while
10258 debugging the compiler itself).
10260 \&\fB\-fno-verbose-asm\fR, the default, causes the
10261 extra information to be omitted and is useful when comparing two assembler
10262 files.
10263 .Ip "\fB\-fpic\fR" 4
10264 .IX Item "-fpic"
10265 Generate position-independent code (\s-1PIC\s0) suitable for use in a shared
10266 library, if supported for the target machine.  Such code accesses all
10267 constant addresses through a global offset table (\s-1GOT\s0).  The dynamic
10268 loader resolves the \s-1GOT\s0 entries when the program starts (the dynamic
10269 loader is not part of \s-1GCC\s0; it is part of the operating system).  If
10270 the \s-1GOT\s0 size for the linked executable exceeds a machine-specific
10271 maximum size, you get an error message from the linker indicating that
10272 \&\fB\-fpic\fR does not work; in that case, recompile with \fB\-fPIC\fR
10273 instead.  (These maximums are 8k on the \s-1SPARC\s0 and 32k
10274 on the m68k and \s-1RS/6000\s0.  The 386 has no such limit.)
10276 Position-independent code requires special support, and therefore works
10277 only on certain machines.  For the 386, \s-1GCC\s0 supports \s-1PIC\s0 for System V
10278 but not for the Sun 386i.  Code generated for the \s-1IBM\s0 \s-1RS/6000\s0 is always
10279 position-independent.
10280 .Ip "\fB\-fPIC\fR" 4
10281 .IX Item "-fPIC"
10282 If supported for the target machine, emit position-independent code,
10283 suitable for dynamic linking and avoiding any limit on the size of the
10284 global offset table.  This option makes a difference on the m68k
10285 and the \s-1SPARC\s0.
10287 Position-independent code requires special support, and therefore works
10288 only on certain machines.
10289 .Ip "\fB\-fpie\fR" 4
10290 .IX Item "-fpie"
10291 .PD 0
10292 .Ip "\fB\-fPIE\fR" 4
10293 .IX Item "-fPIE"
10295 These options are similar to \fB\-fpic\fR and \fB\-fPIC\fR, but
10296 generated position independent code can be only linked into executables.
10297 Usually these options are used when \fB\-pie\fR \s-1GCC\s0 option will be
10298 used during linking.
10299 .Ip "\fB\-ffixed-\fR\fIreg\fR" 4
10300 .IX Item "-ffixed-reg"
10301 Treat the register named \fIreg\fR as a fixed register; generated code
10302 should never refer to it (except perhaps as a stack pointer, frame
10303 pointer or in some other fixed role).
10305 \&\fIreg\fR must be the name of a register.  The register names accepted
10306 are machine-specific and are defined in the \f(CW\*(C`REGISTER_NAMES\*(C'\fR
10307 macro in the machine description macro file.
10309 This flag does not have a negative form, because it specifies a
10310 three-way choice.
10311 .Ip "\fB\-fcall-used-\fR\fIreg\fR" 4
10312 .IX Item "-fcall-used-reg"
10313 Treat the register named \fIreg\fR as an allocable register that is
10314 clobbered by function calls.  It may be allocated for temporaries or
10315 variables that do not live across a call.  Functions compiled this way
10316 will not save and restore the register \fIreg\fR.
10318 It is an error to used this flag with the frame pointer or stack pointer.
10319 Use of this flag for other registers that have fixed pervasive roles in
10320 the machine's execution model will produce disastrous results.
10322 This flag does not have a negative form, because it specifies a
10323 three-way choice.
10324 .Ip "\fB\-fcall-saved-\fR\fIreg\fR" 4
10325 .IX Item "-fcall-saved-reg"
10326 Treat the register named \fIreg\fR as an allocable register saved by
10327 functions.  It may be allocated even for temporaries or variables that
10328 live across a call.  Functions compiled this way will save and restore
10329 the register \fIreg\fR if they use it.
10331 It is an error to used this flag with the frame pointer or stack pointer.
10332 Use of this flag for other registers that have fixed pervasive roles in
10333 the machine's execution model will produce disastrous results.
10335 A different sort of disaster will result from the use of this flag for
10336 a register in which function values may be returned.
10338 This flag does not have a negative form, because it specifies a
10339 three-way choice.
10340 .Ip "\fB\-fpack-struct\fR" 4
10341 .IX Item "-fpack-struct"
10342 Pack all structure members together without holes.
10344 \&\fBWarning:\fR the \fB\-fpack-struct\fR switch causes \s-1GCC\s0 to generate
10345 code that is not binary compatible with code generated without that switch.
10346 Additionally, it makes the code suboptimal.
10347 Use it to conform to a non-default application binary interface.
10348 .Ip "\fB\-finstrument-functions\fR" 4
10349 .IX Item "-finstrument-functions"
10350 Generate instrumentation calls for entry and exit to functions.  Just
10351 after function entry and just before function exit, the following
10352 profiling functions will be called with the address of the current
10353 function and its call site.  (On some platforms,
10354 \&\f(CW\*(C`_\|_builtin_return_address\*(C'\fR does not work beyond the current
10355 function, so the call site information may not be available to the
10356 profiling functions otherwise.)
10358 .Vb 4
10359 \&        void __cyg_profile_func_enter (void *this_fn,
10360 \&                                       void *call_site);
10361 \&        void __cyg_profile_func_exit  (void *this_fn,
10362 \&                                       void *call_site);
10364 The first argument is the address of the start of the current function,
10365 which may be looked up exactly in the symbol table.
10367 This currently disables function inlining.  This restriction is
10368 expected to be removed in future releases.
10370 A function may be given the attribute \f(CW\*(C`no_instrument_function\*(C'\fR, in
10371 which case this instrumentation will not be done.  This can be used, for
10372 example, for the profiling functions listed above, high-priority
10373 interrupt routines, and any functions from which the profiling functions
10374 cannot safely be called (perhaps signal handlers, if the profiling
10375 routines generate output or allocate memory).
10376 .Ip "\fB\-fstack-check\fR" 4
10377 .IX Item "-fstack-check"
10378 Generate code to verify that you do not go beyond the boundary of the
10379 stack.  You should specify this flag if you are running in an
10380 environment with multiple threads, but only rarely need to specify it in
10381 a single-threaded environment since stack overflow is automatically
10382 detected on nearly all systems if there is only one stack.
10384 Note that this switch does not actually cause checking to be done; the
10385 operating system must do that.  The switch causes generation of code
10386 to ensure that the operating system sees the stack being extended.
10387 .Ip "\fB\-fstack-limit-register=\fR\fIreg\fR" 4
10388 .IX Item "-fstack-limit-register=reg"
10389 .PD 0
10390 .Ip "\fB\-fstack-limit-symbol=\fR\fIsym\fR" 4
10391 .IX Item "-fstack-limit-symbol=sym"
10392 .Ip "\fB\-fno-stack-limit\fR" 4
10393 .IX Item "-fno-stack-limit"
10395 Generate code to ensure that the stack does not grow beyond a certain value,
10396 either the value of a register or the address of a symbol.  If the stack
10397 would grow beyond the value, a signal is raised.  For most targets,
10398 the signal is raised before the stack overruns the boundary, so
10399 it is possible to catch the signal without taking special precautions.
10401 For instance, if the stack starts at absolute address \fB0x80000000\fR
10402 and grows downwards, you can use the flags
10403 \&\fB\-fstack-limit-symbol=_\|_stack_limit\fR and
10404 \&\fB\-Wl,\-\-defsym,_\|_stack_limit=0x7ffe0000\fR to enforce a stack limit
10405 of 128KB.  Note that this may only work with the \s-1GNU\s0 linker.
10406 .Ip "\fB\-fargument-alias\fR" 4
10407 .IX Item "-fargument-alias"
10408 .PD 0
10409 .Ip "\fB\-fargument-noalias\fR" 4
10410 .IX Item "-fargument-noalias"
10411 .Ip "\fB\-fargument-noalias-global\fR" 4
10412 .IX Item "-fargument-noalias-global"
10414 Specify the possible relationships among parameters and between
10415 parameters and global data.
10417 \&\fB\-fargument-alias\fR specifies that arguments (parameters) may
10418 alias each other and may alias global storage.\fB\-fargument-noalias\fR specifies that arguments do not alias
10419 each other, but may alias global storage.\fB\-fargument-noalias-global\fR specifies that arguments do not
10420 alias each other and do not alias global storage.
10422 Each language will automatically use whatever option is required by
10423 the language standard.  You should not need to use these options yourself.
10424 .Ip "\fB\-fleading-underscore\fR" 4
10425 .IX Item "-fleading-underscore"
10426 This option and its counterpart, \fB\-fno-leading-underscore\fR, forcibly
10427 change the way C symbols are represented in the object file.  One use
10428 is to help link with legacy assembly code.
10430 \&\fBWarning:\fR the \fB\-fleading-underscore\fR switch causes \s-1GCC\s0 to
10431 generate code that is not binary compatible with code generated without that
10432 switch.  Use it to conform to a non-default application binary interface.
10433 Not all targets provide complete support for this switch.
10434 .Ip "\fB\-ftls-model=\fR\fImodel\fR" 4
10435 .IX Item "-ftls-model=model"
10436 Alter the thread-local storage model to be used.
10437 The \fImodel\fR argument should be one of \f(CW\*(C`global\-dynamic\*(C'\fR,
10438 \&\f(CW\*(C`local\-dynamic\*(C'\fR, \f(CW\*(C`initial\-exec\*(C'\fR or \f(CW\*(C`local\-exec\*(C'\fR.
10440 The default without \fB\-fpic\fR is \f(CW\*(C`initial\-exec\*(C'\fR; with
10441 \&\fB\-fpic\fR the default is \f(CW\*(C`global\-dynamic\*(C'\fR.
10442 .SH "ENVIRONMENT"
10443 .IX Header "ENVIRONMENT"
10444 This section describes several environment variables that affect how \s-1GCC\s0
10445 operates.  Some of them work by specifying directories or prefixes to use
10446 when searching for various kinds of files.  Some are used to specify other
10447 aspects of the compilation environment.
10449 Note that you can also specify places to search using options such as
10450 \&\fB\-B\fR, \fB\-I\fR and \fB\-L\fR.  These
10451 take precedence over places specified using environment variables, which
10452 in turn take precedence over those specified by the configuration of \s-1GCC\s0.
10453 .Ip "\fB\s-1LANG\s0\fR" 4
10454 .IX Item "LANG"
10455 .PD 0
10456 .Ip "\fB\s-1LC_CTYPE\s0\fR" 4
10457 .IX Item "LC_CTYPE"
10458 .Ip "\fB\s-1LC_MESSAGES\s0\fR" 4
10459 .IX Item "LC_MESSAGES"
10460 .Ip "\fB\s-1LC_ALL\s0\fR" 4
10461 .IX Item "LC_ALL"
10463 These environment variables control the way that \s-1GCC\s0 uses
10464 localization information that allow \s-1GCC\s0 to work with different
10465 national conventions.  \s-1GCC\s0 inspects the locale categories
10466 \&\fB\s-1LC_CTYPE\s0\fR and \fB\s-1LC_MESSAGES\s0\fR if it has been configured to do
10467 so.  These locale categories can be set to any value supported by your
10468 installation.  A typical value is \fBen_UK\fR for English in the United
10469 Kingdom.
10471 The \fB\s-1LC_CTYPE\s0\fR environment variable specifies character
10472 classification.  \s-1GCC\s0 uses it to determine the character boundaries in
10473 a string; this is needed for some multibyte encodings that contain quote
10474 and escape characters that would otherwise be interpreted as a string
10475 end or escape.
10477 The \fB\s-1LC_MESSAGES\s0\fR environment variable specifies the language to
10478 use in diagnostic messages.
10480 If the \fB\s-1LC_ALL\s0\fR environment variable is set, it overrides the value
10481 of \fB\s-1LC_CTYPE\s0\fR and \fB\s-1LC_MESSAGES\s0\fR; otherwise, \fB\s-1LC_CTYPE\s0\fR
10482 and \fB\s-1LC_MESSAGES\s0\fR default to the value of the \fB\s-1LANG\s0\fR
10483 environment variable.  If none of these variables are set, \s-1GCC\s0
10484 defaults to traditional C English behavior.
10485 .Ip "\fB\s-1TMPDIR\s0\fR" 4
10486 .IX Item "TMPDIR"
10487 If \fB\s-1TMPDIR\s0\fR is set, it specifies the directory to use for temporary
10488 files.  \s-1GCC\s0 uses temporary files to hold the output of one stage of
10489 compilation which is to be used as input to the next stage: for example,
10490 the output of the preprocessor, which is the input to the compiler
10491 proper.
10492 .Ip "\fB\s-1GCC_EXEC_PREFIX\s0\fR" 4
10493 .IX Item "GCC_EXEC_PREFIX"
10494 If \fB\s-1GCC_EXEC_PREFIX\s0\fR is set, it specifies a prefix to use in the
10495 names of the subprograms executed by the compiler.  No slash is added
10496 when this prefix is combined with the name of a subprogram, but you can
10497 specify a prefix that ends with a slash if you wish.
10499 If \fB\s-1GCC_EXEC_PREFIX\s0\fR is not set, \s-1GCC\s0 will attempt to figure out
10500 an appropriate prefix to use based on the pathname it was invoked with.
10502 If \s-1GCC\s0 cannot find the subprogram using the specified prefix, it
10503 tries looking in the usual places for the subprogram.
10505 The default value of \fB\s-1GCC_EXEC_PREFIX\s0\fR is
10506 \&\fI\fIprefix\fI/lib/gcc/\fR where \fIprefix\fR is the value
10507 of \f(CW\*(C`prefix\*(C'\fR when you ran the \fIconfigure\fR script.
10509 Other prefixes specified with \fB\-B\fR take precedence over this prefix.
10511 This prefix is also used for finding files such as \fIcrt0.o\fR that are
10512 used for linking.
10514 In addition, the prefix is used in an unusual way in finding the
10515 directories to search for header files.  For each of the standard
10516 directories whose name normally begins with \fB/usr/local/lib/gcc\fR
10517 (more precisely, with the value of \fB\s-1GCC_INCLUDE_DIR\s0\fR), \s-1GCC\s0 tries
10518 replacing that beginning with the specified prefix to produce an
10519 alternate directory name.  Thus, with \fB\-Bfoo/\fR, \s-1GCC\s0 will search
10520 \&\fIfoo/bar\fR where it would normally search \fI/usr/local/lib/bar\fR.
10521 These alternate directories are searched first; the standard directories
10522 come next.
10523 .Ip "\fB\s-1COMPILER_PATH\s0\fR" 4
10524 .IX Item "COMPILER_PATH"
10525 The value of \fB\s-1COMPILER_PATH\s0\fR is a colon-separated list of
10526 directories, much like \fB\s-1PATH\s0\fR.  \s-1GCC\s0 tries the directories thus
10527 specified when searching for subprograms, if it can't find the
10528 subprograms using \fB\s-1GCC_EXEC_PREFIX\s0\fR.
10529 .Ip "\fB\s-1LIBRARY_PATH\s0\fR" 4
10530 .IX Item "LIBRARY_PATH"
10531 The value of \fB\s-1LIBRARY_PATH\s0\fR is a colon-separated list of
10532 directories, much like \fB\s-1PATH\s0\fR.  When configured as a native compiler,
10533 \&\s-1GCC\s0 tries the directories thus specified when searching for special
10534 linker files, if it can't find them using \fB\s-1GCC_EXEC_PREFIX\s0\fR.  Linking
10535 using \s-1GCC\s0 also uses these directories when searching for ordinary
10536 libraries for the \fB\-l\fR option (but directories specified with
10537 \&\fB\-L\fR come first).
10538 .Ip "\fB\s-1LANG\s0\fR" 4
10539 .IX Item "LANG"
10540 This variable is used to pass locale information to the compiler.  One way in
10541 which this information is used is to determine the character set to be used
10542 when character literals, string literals and comments are parsed in C and \*(C+.
10543 When the compiler is configured to allow multibyte characters,
10544 the following values for \fB\s-1LANG\s0\fR are recognized:
10545 .RS 4
10546 .Ip "\fBC-JIS\fR" 4
10547 .IX Item "C-JIS"
10548 Recognize \s-1JIS\s0 characters.
10549 .Ip "\fBC-SJIS\fR" 4
10550 .IX Item "C-SJIS"
10551 Recognize \s-1SJIS\s0 characters.
10552 .Ip "\fBC-EUCJP\fR" 4
10553 .IX Item "C-EUCJP"
10554 Recognize \s-1EUCJP\s0 characters.
10556 .RS 4
10558 If \fB\s-1LANG\s0\fR is not defined, or if it has some other value, then the
10559 compiler will use mblen and mbtowc as defined by the default locale to
10560 recognize and translate multibyte characters.
10563 Some additional environments variables affect the behavior of the
10564 preprocessor.
10565 .Ip "\fB\s-1CPATH\s0\fR" 4
10566 .IX Item "CPATH"
10567 .PD 0
10568 .Ip "\fBC_INCLUDE_PATH\fR" 4
10569 .IX Item "C_INCLUDE_PATH"
10570 .Ip "\fB\s-1CPLUS_INCLUDE_PATH\s0\fR" 4
10571 .IX Item "CPLUS_INCLUDE_PATH"
10572 .Ip "\fB\s-1OBJC_INCLUDE_PATH\s0\fR" 4
10573 .IX Item "OBJC_INCLUDE_PATH"
10575 Each variable's value is a list of directories separated by a special
10576 character, much like \fB\s-1PATH\s0\fR, in which to look for header files.
10577 The special character, \f(CW\*(C`PATH_SEPARATOR\*(C'\fR, is target-dependent and
10578 determined at \s-1GCC\s0 build time.  For Microsoft Windows-based targets it is a
10579 semicolon, and for almost all other targets it is a colon.
10581 \&\fB\s-1CPATH\s0\fR specifies a list of directories to be searched as if
10582 specified with \fB\-I\fR, but after any paths given with \fB\-I\fR
10583 options on the command line.  This environment variable is used
10584 regardless of which language is being preprocessed.
10586 The remaining environment variables apply only when preprocessing the
10587 particular language indicated.  Each specifies a list of directories
10588 to be searched as if specified with \fB\-isystem\fR, but after any
10589 paths given with \fB\-isystem\fR options on the command line.
10591 In all these variables, an empty element instructs the compiler to
10592 search its current working directory.  Empty elements can appear at the
10593 beginning or end of a path.  For instance, if the value of
10594 \&\fB\s-1CPATH\s0\fR is \f(CW\*(C`:/special/include\*(C'\fR, that has the same
10595 effect as \fB\-I.\ \-I/special/include\fR.
10596 .Ip "\fB\s-1DEPENDENCIES_OUTPUT\s0\fR" 4
10597 .IX Item "DEPENDENCIES_OUTPUT"
10598 If this variable is set, its value specifies how to output
10599 dependencies for Make based on the non-system header files processed
10600 by the compiler.  System header files are ignored in the dependency
10601 output.
10603 The value of \fB\s-1DEPENDENCIES_OUTPUT\s0\fR can be just a file name, in
10604 which case the Make rules are written to that file, guessing the target
10605 name from the source file name.  Or the value can have the form
10606 \&\fIfile\fR\fB \fR\fItarget\fR, in which case the rules are written to
10607 file \fIfile\fR using \fItarget\fR as the target name.
10609 In other words, this environment variable is equivalent to combining
10610 the options \fB\-MM\fR and \fB\-MF\fR,
10611 with an optional \fB\-MT\fR switch too.
10612 .Ip "\fB\s-1SUNPRO_DEPENDENCIES\s0\fR" 4
10613 .IX Item "SUNPRO_DEPENDENCIES"
10614 This variable is the same as \fB\s-1DEPENDENCIES_OUTPUT\s0\fR (see above),
10615 except that system header files are not ignored, so it implies
10616 \&\fB\-M\fR rather than \fB\-MM\fR.  However, the dependence on the
10617 main input file is omitted.
10618 .SH "BUGS"
10619 .IX Header "BUGS"
10620 For instructions on reporting bugs, see
10621 <\fBhttp://gcc.gnu.org/bugs.html\fR>.  Use of the \fBgccbug\fR
10622 script to report bugs is recommended.
10623 .SH "FOOTNOTES"
10624 .IX Header "FOOTNOTES"
10625 .Ip "1." 4
10626 On some systems, \fBgcc \-shared\fR
10627 needs to build supplementary stub code for constructors to work.  On
10628 multi-libbed systems, \fBgcc \-shared\fR must select the correct support
10629 libraries to link against.  Failing to supply the correct flags may lead
10630 to subtle defects.  Supplying them in cases where they are not necessary
10631 is innocuous.
10632 .SH "SEE ALSO"
10633 .IX Header "SEE ALSO"
10634 \&\fIgpl\fR\|(7), \fIgfdl\fR\|(7), \fIfsf-funding\fR\|(7),
10635 \&\fIcpp\fR\|(1), \fIgcov\fR\|(1), \fIg77\fR\|(1), \fIas\fR\|(1), \fIld\fR\|(1), \fIgdb\fR\|(1), \fIadb\fR\|(1), \fIdbx\fR\|(1), \fIsdb\fR\|(1)
10636 and the Info entries for \fIgcc\fR, \fIcpp\fR, \fIg77\fR, \fIas\fR,
10637 \&\fIld\fR, \fIbinutils\fR and \fIgdb\fR.
10638 .SH "AUTHOR"
10639 .IX Header "AUTHOR"
10640 See the Info entry for \fBgcc\fR, or
10641 <\fBhttp://gcc.gnu.org/onlinedocs/gcc/Contributors.html\fR>,
10642 for contributors to \s-1GCC\s0.
10643 .SH "COPYRIGHT"
10644 .IX Header "COPYRIGHT"
10645 Copyright (c) 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997,
10646 1998, 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
10648 Permission is granted to copy, distribute and/or modify this document
10649 under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.2 or
10650 any later version published by the Free Software Foundation; with the
10651 Invariant Sections being ``\s-1GNU\s0 General Public License'' and ``Funding
10652 Free Software'', the Front-Cover texts being (a) (see below), and with
10653 the Back-Cover Texts being (b) (see below).  A copy of the license is
10654 included in the \fIgfdl\fR\|(7) man page.
10656 (a) The \s-1FSF\s0's Front-Cover Text is:
10658 .Vb 1
10659 \&     A GNU Manual
10661 (b) The \s-1FSF\s0's Back-Cover Text is:
10663 .Vb 3
10664 \&     You have freedom to copy and modify this GNU Manual, like GNU
10665 \&     software.  Copies published by the Free Software Foundation raise
10666 \&     funds for GNU development.