1 This is doc/gcc.info, produced by makeinfo version 4.7 from
2 /scratch/mitchell/gcc-releases/gcc-4.0.0/gcc-4.0.0/gcc/doc/gcc.texi.
4 Copyright (C) 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
5 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
7 Permission is granted to copy, distribute and/or modify this document
8 under the terms of the GNU Free Documentation License, Version 1.2 or
9 any later version published by the Free Software Foundation; with the
10 Invariant Sections being "GNU General Public License" and "Funding Free
11 Software", the Front-Cover texts being (a) (see below), and with the
12 Back-Cover Texts being (b) (see below). A copy of the license is
13 included in the section entitled "GNU Free Documentation License".
15 (a) The FSF's Front-Cover Text is:
19 (b) The FSF's Back-Cover Text is:
21 You have freedom to copy and modify this GNU Manual, like GNU
22 software. Copies published by the Free Software Foundation raise
23 funds for GNU development.
25 INFO-DIR-SECTION Programming
27 * gcc: (gcc). The GNU Compiler Collection.
29 This file documents the use of the GNU compilers.
31 Copyright (C) 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
32 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
34 Permission is granted to copy, distribute and/or modify this document
35 under the terms of the GNU Free Documentation License, Version 1.2 or
36 any later version published by the Free Software Foundation; with the
37 Invariant Sections being "GNU General Public License" and "Funding Free
38 Software", the Front-Cover texts being (a) (see below), and with the
39 Back-Cover Texts being (b) (see below). A copy of the license is
40 included in the section entitled "GNU Free Documentation License".
42 (a) The FSF's Front-Cover Text is:
46 (b) The FSF's Back-Cover Text is:
48 You have freedom to copy and modify this GNU Manual, like GNU
49 software. Copies published by the Free Software Foundation raise
50 funds for GNU development.
54 File: gcc.info, Node: Top, Next: G++ and GCC, Up: (DIR)
59 This manual documents how to use the GNU compilers, as well as their
60 features and incompatibilities, and how to report bugs. It corresponds
61 to GCC version 4.0.0. The internals of the GNU compilers, including
62 how to port them to new targets and some information about how to write
63 front ends for new languages, are documented in a separate manual.
64 *Note Introduction: (gccint)Top.
68 * G++ and GCC:: You can compile C or C++ programs.
69 * Standards:: Language standards supported by GCC.
70 * Invoking GCC:: Command options supported by `gcc'.
71 * C Implementation:: How GCC implements the ISO C specification.
72 * C Extensions:: GNU extensions to the C language family.
73 * C++ Extensions:: GNU extensions to the C++ language.
74 * Objective-C:: GNU Objective-C runtime features.
75 * Compatibility:: Binary Compatibility
76 * Gcov:: `gcov'---a test coverage program.
77 * Trouble:: If you have trouble using GCC.
78 * Bugs:: How, why and where to report bugs.
79 * Service:: How to find suppliers of support for GCC.
80 * Contributing:: How to contribute to testing and developing GCC.
82 * Funding:: How to help assure funding for free software.
83 * GNU Project:: The GNU Project and GNU/Linux.
85 * Copying:: GNU General Public License says
86 how you can copy and share GCC.
87 * GNU Free Documentation License:: How you can copy and share this manual.
88 * Contributors:: People who have contributed to GCC.
90 * Option Index:: Index to command line options.
91 * Keyword Index:: Index of concepts and symbol names.
94 File: gcc.info, Node: G++ and GCC, Next: Standards, Prev: Top, Up: Top
96 1 Programming Languages Supported by GCC
97 ****************************************
99 GCC stands for "GNU Compiler Collection". GCC is an integrated
100 distribution of compilers for several major programming languages.
101 These languages currently include C, C++, Objective-C, Objective-C++,
102 Java, Fortran, and Ada.
104 The abbreviation "GCC" has multiple meanings in common use. The
105 current official meaning is "GNU Compiler Collection", which refers
106 generically to the complete suite of tools. The name historically stood
107 for "GNU C Compiler", and this usage is still common when the emphasis
108 is on compiling C programs. Finally, the name is also used when
109 speaking of the "language-independent" component of GCC: code shared
110 among the compilers for all supported languages.
112 The language-independent component of GCC includes the majority of the
113 optimizers, as well as the "back ends" that generate machine code for
116 The part of a compiler that is specific to a particular language is
117 called the "front end". In addition to the front ends that are
118 integrated components of GCC, there are several other front ends that
119 are maintained separately. These support languages such as Pascal,
120 Mercury, and COBOL. To use these, they must be built together with GCC
123 Most of the compilers for languages other than C have their own names.
124 The C++ compiler is G++, the Ada compiler is GNAT, and so on. When we
125 talk about compiling one of those languages, we might refer to that
126 compiler by its own name, or as GCC. Either is correct.
128 Historically, compilers for many languages, including C++ and Fortran,
129 have been implemented as "preprocessors" which emit another high level
130 language such as C. None of the compilers included in GCC are
131 implemented this way; they all generate machine code directly. This
132 sort of preprocessor should not be confused with the "C preprocessor",
133 which is an integral feature of the C, C++, Objective-C and
134 Objective-C++ languages.
137 File: gcc.info, Node: Standards, Next: Invoking GCC, Prev: G++ and GCC, Up: Top
139 2 Language Standards Supported by GCC
140 *************************************
142 For each language compiled by GCC for which there is a standard, GCC
143 attempts to follow one or more versions of that standard, possibly with
144 some exceptions, and possibly with some extensions.
146 GCC supports three versions of the C standard, although support for
147 the most recent version is not yet complete.
149 The original ANSI C standard (X3.159-1989) was ratified in 1989 and
150 published in 1990. This standard was ratified as an ISO standard
151 (ISO/IEC 9899:1990) later in 1990. There were no technical differences
152 between these publications, although the sections of the ANSI standard
153 were renumbered and became clauses in the ISO standard. This standard,
154 in both its forms, is commonly known as "C89", or occasionally as
155 "C90", from the dates of ratification. The ANSI standard, but not the
156 ISO standard, also came with a Rationale document. To select this
157 standard in GCC, use one of the options `-ansi', `-std=c89' or
158 `-std=iso9899:1990'; to obtain all the diagnostics required by the
159 standard, you should also specify `-pedantic' (or `-pedantic-errors' if
160 you want them to be errors rather than warnings). *Note Options
161 Controlling C Dialect: C Dialect Options.
163 Errors in the 1990 ISO C standard were corrected in two Technical
164 Corrigenda published in 1994 and 1996. GCC does not support the
167 An amendment to the 1990 standard was published in 1995. This
168 amendment added digraphs and `__STDC_VERSION__' to the language, but
169 otherwise concerned the library. This amendment is commonly known as
170 "AMD1"; the amended standard is sometimes known as "C94" or "C95". To
171 select this standard in GCC, use the option `-std=iso9899:199409'
172 (with, as for other standard versions, `-pedantic' to receive all
173 required diagnostics).
175 A new edition of the ISO C standard was published in 1999 as ISO/IEC
176 9899:1999, and is commonly known as "C99". GCC has incomplete support
177 for this standard version; see
178 `http://gcc.gnu.org/gcc-4.0/c99status.html' for details. To select this
179 standard, use `-std=c99' or `-std=iso9899:1999'. (While in
180 development, drafts of this standard version were referred to as "C9X".)
182 Errors in the 1999 ISO C standard were corrected in two Technical
183 Corrigenda published in 2001 and 2004. GCC does not support the
186 By default, GCC provides some extensions to the C language that on
187 rare occasions conflict with the C standard. *Note Extensions to the C
188 Language Family: C Extensions. Use of the `-std' options listed above
189 will disable these extensions where they conflict with the C standard
190 version selected. You may also select an extended version of the C
191 language explicitly with `-std=gnu89' (for C89 with GNU extensions) or
192 `-std=gnu99' (for C99 with GNU extensions). The default, if no C
193 language dialect options are given, is `-std=gnu89'; this will change to
194 `-std=gnu99' in some future release when the C99 support is complete.
195 Some features that are part of the C99 standard are accepted as
196 extensions in C89 mode.
198 The ISO C standard defines (in clause 4) two classes of conforming
199 implementation. A "conforming hosted implementation" supports the
200 whole standard including all the library facilities; a "conforming
201 freestanding implementation" is only required to provide certain
202 library facilities: those in `<float.h>', `<limits.h>', `<stdarg.h>',
203 and `<stddef.h>'; since AMD1, also those in `<iso646.h>'; and in C99,
204 also those in `<stdbool.h>' and `<stdint.h>'. In addition, complex
205 types, added in C99, are not required for freestanding implementations.
206 The standard also defines two environments for programs, a
207 "freestanding environment", required of all implementations and which
208 may not have library facilities beyond those required of freestanding
209 implementations, where the handling of program startup and termination
210 are implementation-defined, and a "hosted environment", which is not
211 required, in which all the library facilities are provided and startup
212 is through a function `int main (void)' or `int main (int, char *[])'.
213 An OS kernel would be a freestanding environment; a program using the
214 facilities of an operating system would normally be in a hosted
217 GCC aims towards being usable as a conforming freestanding
218 implementation, or as the compiler for a conforming hosted
219 implementation. By default, it will act as the compiler for a hosted
220 implementation, defining `__STDC_HOSTED__' as `1' and presuming that
221 when the names of ISO C functions are used, they have the semantics
222 defined in the standard. To make it act as a conforming freestanding
223 implementation for a freestanding environment, use the option
224 `-ffreestanding'; it will then define `__STDC_HOSTED__' to `0' and not
225 make assumptions about the meanings of function names from the standard
226 library, with exceptions noted below. To build an OS kernel, you may
227 well still need to make your own arrangements for linking and startup.
228 *Note Options Controlling C Dialect: C Dialect Options.
230 GCC does not provide the library facilities required only of hosted
231 implementations, nor yet all the facilities required by C99 of
232 freestanding implementations; to use the facilities of a hosted
233 environment, you will need to find them elsewhere (for example, in the
234 GNU C library). *Note Standard Libraries: Standard Libraries.
236 Most of the compiler support routines used by GCC are present in
237 `libgcc', but there are a few exceptions. GCC requires the
238 freestanding environment provide `memcpy', `memmove', `memset' and
239 `memcmp'. Finally, if `__builtin_trap' is used, and the target does
240 not implement the `trap' pattern, then GCC will emit a call to `abort'.
242 For references to Technical Corrigenda, Rationale documents and
243 information concerning the history of C that is available online, see
244 `http://gcc.gnu.org/readings.html'
246 There is no formal written standard for Objective-C or Objective-C++.
247 The most authoritative manual is "Object-Oriented Programming and the
248 Objective-C Language", available at a number of web sites:
251 `http://developer.apple.com/documentation/Cocoa/Conceptual/ObjectiveC/'
252 is a recent (and periodically updated) version;
254 * `http://www.toodarkpark.org/computers/objc/' is an older example;
256 * `http://www.gnustep.org' and `http://gcc.gnu.org/readings.html'
257 have additional useful information.
259 There is no standard for treelang, which is a sample language front end
260 for GCC. Its only purpose is as a sample for people wishing to write a
261 new language for GCC. The language is documented in
262 `gcc/treelang/treelang.texi' which can be turned into info or HTML
265 *Note GNAT Reference Manual: (gnat_rm)Top, for information on standard
266 conformance and compatibility of the Ada compiler.
268 *Note Standards: (gfortran)Standards, for details of standards
269 supported by `gfortran'.
271 *Note Compatibility with the Java Platform: (gcj)Compatibility, for
272 details of compatibility between `gcj' and the Java Platform.
275 File: gcc.info, Node: Invoking GCC, Next: C Implementation, Prev: Standards, Up: Top
277 3 GCC Command Options
278 *********************
280 When you invoke GCC, it normally does preprocessing, compilation,
281 assembly and linking. The "overall options" allow you to stop this
282 process at an intermediate stage. For example, the `-c' option says
283 not to run the linker. Then the output consists of object files output
286 Other options are passed on to one stage of processing. Some options
287 control the preprocessor and others the compiler itself. Yet other
288 options control the assembler and linker; most of these are not
289 documented here, since you rarely need to use any of them.
291 Most of the command line options that you can use with GCC are useful
292 for C programs; when an option is only useful with another language
293 (usually C++), the explanation says so explicitly. If the description
294 for a particular option does not mention a source language, you can use
295 that option with all supported languages.
297 *Note Compiling C++ Programs: Invoking G++, for a summary of special
298 options for compiling C++ programs.
300 The `gcc' program accepts options and file names as operands. Many
301 options have multi-letter names; therefore multiple single-letter
302 options may _not_ be grouped: `-dr' is very different from `-d -r'.
304 You can mix options and other arguments. For the most part, the order
305 you use doesn't matter. Order does matter when you use several options
306 of the same kind; for example, if you specify `-L' more than once, the
307 directories are searched in the order specified.
309 Many options have long names starting with `-f' or with `-W'--for
310 example, `-fforce-mem', `-fstrength-reduce', `-Wformat' and so on.
311 Most of these have both positive and negative forms; the negative form
312 of `-ffoo' would be `-fno-foo'. This manual documents only one of
313 these two forms, whichever one is not the default.
315 *Note Option Index::, for an index to GCC's options.
319 * Option Summary:: Brief list of all options, without explanations.
320 * Overall Options:: Controlling the kind of output:
321 an executable, object files, assembler files,
322 or preprocessed source.
323 * Invoking G++:: Compiling C++ programs.
324 * C Dialect Options:: Controlling the variant of C language compiled.
325 * C++ Dialect Options:: Variations on C++.
326 * Objective-C and Objective-C++ Dialect Options:: Variations on Objective-C
328 * Language Independent Options:: Controlling how diagnostics should be
330 * Warning Options:: How picky should the compiler be?
331 * Debugging Options:: Symbol tables, measurements, and debugging dumps.
332 * Optimize Options:: How much optimization?
333 * Preprocessor Options:: Controlling header files and macro definitions.
334 Also, getting dependency information for Make.
335 * Assembler Options:: Passing options to the assembler.
336 * Link Options:: Specifying libraries and so on.
337 * Directory Options:: Where to find header files and libraries.
338 Where to find the compiler executable files.
339 * Spec Files:: How to pass switches to sub-processes.
340 * Target Options:: Running a cross-compiler, or an old version of GCC.
341 * Submodel Options:: Specifying minor hardware or convention variations,
342 such as 68010 vs 68020.
343 * Code Gen Options:: Specifying conventions for function calls, data layout
345 * Environment Variables:: Env vars that affect GCC.
346 * Precompiled Headers:: Compiling a header once, and using it many times.
347 * Running Protoize:: Automatically adding or removing function prototypes.
350 File: gcc.info, Node: Option Summary, Next: Overall Options, Up: Invoking GCC
355 Here is a summary of all the options, grouped by type. Explanations are
356 in the following sections.
359 *Note Options Controlling the Kind of Output: Overall Options.
360 -c -S -E -o FILE -combine -pipe -pass-exit-codes
361 -x LANGUAGE -v -### --help --target-help --version
364 *Note Options Controlling C Dialect: C Dialect Options.
365 -ansi -std=STANDARD -aux-info FILENAME
366 -fno-asm -fno-builtin -fno-builtin-FUNCTION
367 -fhosted -ffreestanding -fms-extensions
368 -trigraphs -no-integrated-cpp -traditional -traditional-cpp
369 -fallow-single-precision -fcond-mismatch
370 -fsigned-bitfields -fsigned-char
371 -funsigned-bitfields -funsigned-char
373 _C++ Language Options_
374 *Note Options Controlling C++ Dialect: C++ Dialect Options.
375 -fabi-version=N -fno-access-control -fcheck-new
376 -fconserve-space -fno-const-strings
377 -fno-elide-constructors
378 -fno-enforce-eh-specs
379 -ffor-scope -fno-for-scope -fno-gnu-keywords
380 -fno-implicit-templates
381 -fno-implicit-inline-templates
382 -fno-implement-inlines -fms-extensions
383 -fno-nonansi-builtins -fno-operator-names
384 -fno-optional-diags -fpermissive
385 -frepo -fno-rtti -fstats -ftemplate-depth-N
386 -fno-threadsafe-statics -fuse-cxa-atexit -fno-weak -nostdinc++
387 -fno-default-inline -fvisibility-inlines-hidden
388 -Wabi -Wctor-dtor-privacy
389 -Wnon-virtual-dtor -Wreorder
390 -Weffc++ -Wno-deprecated
391 -Wno-non-template-friend -Wold-style-cast
392 -Woverloaded-virtual -Wno-pmf-conversions
395 _Objective-C and Objective-C++ Language Options_
396 *Note Options Controlling Objective-C and Objective-C++ Dialects:
397 Objective-C and Objective-C++ Dialect Options.
398 -fconstant-string-class=CLASS-NAME
399 -fgnu-runtime -fnext-runtime
402 -freplace-objc-classes
405 -Wno-protocol -Wselector -Wundeclared-selector
407 _Language Independent Options_
408 *Note Options to Control Diagnostic Messages Formatting: Language
411 -fdiagnostics-show-location=[once|every-line]
414 *Note Options to Request or Suppress Warnings: Warning Options.
415 -fsyntax-only -pedantic -pedantic-errors
416 -w -Wextra -Wall -Waggregate-return
417 -Wcast-align -Wcast-qual -Wchar-subscripts -Wcomment
418 -Wconversion -Wno-deprecated-declarations
419 -Wdisabled-optimization -Wno-div-by-zero -Wno-endif-labels
420 -Werror -Werror-implicit-function-declaration
421 -Wfatal-errors -Wfloat-equal -Wformat -Wformat=2
422 -Wno-format-extra-args -Wformat-nonliteral
423 -Wformat-security -Wformat-y2k
424 -Wimplicit -Wimplicit-function-declaration -Wimplicit-int
425 -Wimport -Wno-import -Winit-self -Winline
426 -Wno-invalid-offsetof -Winvalid-pch
427 -Wlarger-than-LEN -Wlong-long
428 -Wmain -Wmissing-braces -Wmissing-field-initializers
429 -Wmissing-format-attribute -Wmissing-include-dirs
431 -Wno-multichar -Wnonnull -Wpacked -Wpadded
432 -Wparentheses -Wpointer-arith -Wredundant-decls
433 -Wreturn-type -Wsequence-point -Wshadow
434 -Wsign-compare -Wstrict-aliasing -Wstrict-aliasing=2
435 -Wswitch -Wswitch-default -Wswitch-enum
436 -Wsystem-headers -Wtrigraphs -Wundef -Wuninitialized
437 -Wunknown-pragmas -Wunreachable-code
438 -Wunused -Wunused-function -Wunused-label -Wunused-parameter
439 -Wunused-value -Wunused-variable -Wwrite-strings
442 _C-only Warning Options_
443 -Wbad-function-cast -Wmissing-declarations
444 -Wmissing-prototypes -Wnested-externs -Wold-style-definition
445 -Wstrict-prototypes -Wtraditional
446 -Wdeclaration-after-statement -Wno-pointer-sign
449 *Note Options for Debugging Your Program or GCC: Debugging Options.
450 -dLETTERS -dumpspecs -dumpmachine -dumpversion
451 -fdump-unnumbered -fdump-translation-unit[-N]
452 -fdump-class-hierarchy[-N]
453 -fdump-ipa-all -fdump-ipa-cgraph
455 -fdump-tree-original[-N]
456 -fdump-tree-optimized[-N]
457 -fdump-tree-inlined[-N]
458 -fdump-tree-cfg -fdump-tree-vcg -fdump-tree-alias
460 -fdump-tree-ssa[-N] -fdump-tree-pre[-N]
461 -fdump-tree-ccp[-N] -fdump-tree-dce[-N]
462 -fdump-tree-gimple[-raw] -fdump-tree-mudflap[-N]
465 -fdump-tree-phiopt[-N]
466 -fdump-tree-forwprop[-N]
467 -fdump-tree-copyrename[-N]
468 -fdump-tree-nrv -fdump-tree-vect
471 -ftree-vectorizer-verbose=N
472 -feliminate-dwarf2-dups -feliminate-unused-debug-types
473 -feliminate-unused-debug-symbols -fmem-report -fprofile-arcs -ftree-based-profiling
474 -frandom-seed=STRING -fsched-verbose=N
475 -ftest-coverage -ftime-report -fvar-tracking
476 -g -gLEVEL -gcoff -gdwarf-2
477 -ggdb -gstabs -gstabs+ -gvms -gxcoff -gxcoff+
478 -p -pg -print-file-name=LIBRARY -print-libgcc-file-name
479 -print-multi-directory -print-multi-lib
480 -print-prog-name=PROGRAM -print-search-dirs -Q
483 _Optimization Options_
484 *Note Options that Control Optimization: Optimize Options.
485 -falign-functions=N -falign-jumps=N
486 -falign-labels=N -falign-loops=N
487 -fbounds-check -fmudflap -fmudflapth -fmudflapir
488 -fbranch-probabilities -fprofile-values -fvpt -fbranch-target-load-optimize
489 -fbranch-target-load-optimize2 -fbtr-bb-exclusive
490 -fcaller-saves -fcprop-registers -fcse-follow-jumps
491 -fcse-skip-blocks -fcx-limited-range -fdata-sections
492 -fdelayed-branch -fdelete-null-pointer-checks
493 -fexpensive-optimizations -ffast-math -ffloat-store
494 -fforce-addr -fforce-mem -ffunction-sections
495 -fgcse -fgcse-lm -fgcse-sm -fgcse-las -fgcse-after-reload
496 -floop-optimize -fcrossjumping -fif-conversion -fif-conversion2
497 -finline-functions -finline-limit=N -fkeep-inline-functions
498 -fkeep-static-consts -fmerge-constants -fmerge-all-constants
499 -fmodulo-sched -fno-branch-count-reg
500 -fno-default-inline -fno-defer-pop -floop-optimize2 -fmove-loop-invariants
501 -fno-function-cse -fno-guess-branch-probability
502 -fno-inline -fno-math-errno -fno-peephole -fno-peephole2
503 -funsafe-math-optimizations -ffinite-math-only
504 -fno-trapping-math -fno-zero-initialized-in-bss
505 -fomit-frame-pointer -foptimize-register-move
506 -foptimize-sibling-calls -fprefetch-loop-arrays
507 -fprofile-generate -fprofile-use
508 -fregmove -frename-registers
509 -freorder-blocks -freorder-blocks-and-partition -freorder-functions
510 -frerun-cse-after-loop -frerun-loop-opt
511 -frounding-math -fschedule-insns -fschedule-insns2
512 -fno-sched-interblock -fno-sched-spec -fsched-spec-load
513 -fsched-spec-load-dangerous
514 -fsched-stalled-insns=N -sched-stalled-insns-dep=N
515 -fsched2-use-superblocks
516 -fsched2-use-traces -freschedule-modulo-scheduled-loops
517 -fsignaling-nans -fsingle-precision-constant -fspeculative-prefetching
518 -fstrength-reduce -fstrict-aliasing -ftracer -fthread-jumps
519 -funroll-all-loops -funroll-loops -fpeel-loops
520 -fsplit-ivs-in-unroller -funswitch-loops
521 -fvariable-expansion-in-unroller
522 -ftree-pre -ftree-ccp -ftree-dce -ftree-loop-optimize
523 -ftree-loop-linear -ftree-loop-im -ftree-loop-ivcanon -fivopts
524 -ftree-dominator-opts -ftree-dse -ftree-copyrename
525 -ftree-ch -ftree-sra -ftree-ter -ftree-lrs -ftree-fre -ftree-vectorize
528 -O -O0 -O1 -O2 -O3 -Os
530 _Preprocessor Options_
531 *Note Options Controlling the Preprocessor: Preprocessor Options.
537 -include FILE -imacros FILE
538 -iprefix FILE -iwithprefix DIR
539 -iwithprefixbefore DIR -isystem DIR
540 -M -MM -MF -MG -MP -MQ -MT -nostdinc
541 -P -fworking-directory -remap
542 -trigraphs -undef -UMACRO -Wp,OPTION
543 -Xpreprocessor OPTION
546 *Note Passing Options to the Assembler: Assembler Options.
547 -Wa,OPTION -Xassembler OPTION
550 *Note Options for Linking: Link Options.
551 OBJECT-FILE-NAME -lLIBRARY
552 -nostartfiles -nodefaultlibs -nostdlib -pie
553 -s -static -static-libgcc -shared -shared-libgcc -symbolic
554 -Wl,OPTION -Xlinker OPTION
558 *Note Options for Directory Search: Directory Options.
559 -BPREFIX -IDIR -iquoteDIR -LDIR -specs=FILE -I-
562 *Note Target Options::.
563 -V VERSION -b MACHINE
565 _Machine Dependent Options_
566 *Note Hardware Models and Configurations: Submodel Options.
570 -mmangle-cpu -mcpu=CPU -mtext=TEXT-SECTION
571 -mdata=DATA-SECTION -mrodata=READONLY-DATA-SECTION
574 -mapcs-frame -mno-apcs-frame
576 -mapcs-stack-check -mno-apcs-stack-check
577 -mapcs-float -mno-apcs-float
578 -mapcs-reentrant -mno-apcs-reentrant
579 -msched-prolog -mno-sched-prolog
580 -mlittle-endian -mbig-endian -mwords-little-endian
581 -mfloat-abi=NAME -msoft-float -mhard-float -mfpe
582 -mthumb-interwork -mno-thumb-interwork
583 -mcpu=NAME -march=NAME -mfpu=NAME
584 -mstructure-size-boundary=N
586 -mlong-calls -mno-long-calls
587 -msingle-pic-base -mno-single-pic-base
590 -mcirrus-fix-invalid-insns -mno-cirrus-fix-invalid-insns
593 -mtpcs-frame -mtpcs-leaf-frame
594 -mcaller-super-interworking -mcallee-super-interworking
597 -mmcu=MCU -msize -minit-stack=N -mno-interrupts
598 -mcall-prologues -mno-tablejump -mtiny-stack -mint8
601 -mcpu=CPU -march=CPU -mtune=CPU
602 -mmax-stack-frame=N -melinux-stacksize=N
603 -metrax4 -metrax100 -mpdebug -mcc-init -mno-side-effects
604 -mstack-align -mdata-align -mconst-align
605 -m32-bit -m16-bit -m8-bit -mno-prologue-epilogue -mno-gotplt
606 -melf -maout -melinux -mlinux -sim -sim2
607 -mmul-bug-workaround -mno-mul-bug-workaround
610 -all_load -allowable_client -arch -arch_errors_fatal
611 -arch_only -bind_at_load -bundle -bundle_loader
612 -client_name -compatibility_version -current_version
614 -dependency-file -dylib_file -dylinker_install_name
615 -dynamic -dynamiclib -exported_symbols_list
616 -filelist -flat_namespace -force_cpusubtype_ALL
617 -force_flat_namespace -headerpad_max_install_names
618 -image_base -init -install_name -keep_private_externs
619 -multi_module -multiply_defined -multiply_defined_unused
620 -noall_load -no_dead_strip_inits_and_terms
621 -nofixprebinding -nomultidefs -noprebind -noseglinkedit
622 -pagezero_size -prebind -prebind_all_twolevel_modules
623 -private_bundle -read_only_relocs -sectalign
624 -sectobjectsymbols -whyload -seg1addr
625 -sectcreate -sectobjectsymbols -sectorder
626 -segaddr -segs_read_only_addr -segs_read_write_addr
627 -seg_addr_table -seg_addr_table_filename -seglinkedit
628 -segprot -segs_read_only_addr -segs_read_write_addr
629 -single_module -static -sub_library -sub_umbrella
630 -twolevel_namespace -umbrella -undefined
631 -unexported_symbols_list -weak_reference_mismatches
632 -whatsloaded -F -gused -gfull -mone-byte-bool
635 -mno-fp-regs -msoft-float -malpha-as -mgas
636 -mieee -mieee-with-inexact -mieee-conformant
637 -mfp-trap-mode=MODE -mfp-rounding-mode=MODE
638 -mtrap-precision=MODE -mbuild-constants
639 -mcpu=CPU-TYPE -mtune=CPU-TYPE
640 -mbwx -mmax -mfix -mcix
641 -mfloat-vax -mfloat-ieee
642 -mexplicit-relocs -msmall-data -mlarge-data
643 -msmall-text -mlarge-text
644 -mmemory-latency=TIME
646 _DEC Alpha/VMS Options_
650 -mgpr-32 -mgpr-64 -mfpr-32 -mfpr-64
651 -mhard-float -msoft-float
652 -malloc-cc -mfixed-cc -mdword -mno-dword
654 -mmedia -mno-media -mmuladd -mno-muladd
655 -mfdpic -minline-plt -mgprel-ro -multilib-library-pic
656 -mlinked-fp -mlong-calls -malign-labels
657 -mlibrary-pic -macc-4 -macc-8
658 -mpack -mno-pack -mno-eflags -mcond-move -mno-cond-move
659 -mscc -mno-scc -mcond-exec -mno-cond-exec
660 -mvliw-branch -mno-vliw-branch
661 -mmulti-cond-exec -mno-multi-cond-exec -mnested-cond-exec
662 -mno-nested-cond-exec -mtomcat-stats
667 -mrelax -mh -ms -mn -mint32 -malign-300
670 -march=ARCHITECTURE-TYPE
671 -mbig-switch -mdisable-fpregs -mdisable-indexing
672 -mfast-indirect-calls -mgas -mgnu-ld -mhp-ld
673 -mfixed-range=REGISTER-RANGE
674 -mjump-in-delay -mlinker-opt -mlong-calls
675 -mlong-load-store -mno-big-switch -mno-disable-fpregs
676 -mno-disable-indexing -mno-fast-indirect-calls -mno-gas
677 -mno-jump-in-delay -mno-long-load-store
678 -mno-portable-runtime -mno-soft-float
679 -mno-space-regs -msoft-float -mpa-risc-1-0
680 -mpa-risc-1-1 -mpa-risc-2-0 -mportable-runtime
681 -mschedule=CPU-TYPE -mspace-regs -msio -mwsio
682 -munix=UNIX-STD -nolibdld -static -threads
684 _i386 and x86-64 Options_
685 -mtune=CPU-TYPE -march=CPU-TYPE
687 -masm=DIALECT -mno-fancy-math-387
688 -mno-fp-ret-in-387 -msoft-float -msvr3-shlib
689 -mno-wide-multiply -mrtd -malign-double
690 -mpreferred-stack-boundary=NUM
691 -mmmx -msse -msse2 -msse3 -m3dnow
692 -mthreads -mno-align-stringops -minline-all-stringops
693 -mpush-args -maccumulate-outgoing-args -m128bit-long-double
694 -m96bit-long-double -mregparm=NUM -momit-leaf-frame-pointer
695 -mno-red-zone -mno-tls-direct-seg-refs
700 -mbig-endian -mlittle-endian -mgnu-as -mgnu-ld -mno-pic
701 -mvolatile-asm-stop -mregister-names -mno-sdata
702 -mconstant-gp -mauto-pic -minline-float-divide-min-latency
703 -minline-float-divide-max-throughput
704 -minline-int-divide-min-latency
705 -minline-int-divide-max-throughput
706 -minline-sqrt-min-latency -minline-sqrt-max-throughput
707 -mno-dwarf2-asm -mearly-stop-bits
708 -mfixed-range=REGISTER-RANGE -mtls-size=TLS-SIZE
709 -mtune=CPU-TYPE -mt -pthread -milp32 -mlp64
714 -malign-loops -mno-align-loops
717 -mmodel=CODE-SIZE-MODEL-TYPE
719 -mno-flush-func -mflush-func=NAME
720 -mno-flush-trap -mflush-trap=NUMBER
724 -m68000 -m68020 -m68020-40 -m68020-60 -m68030 -m68040
725 -m68060 -mcpu32 -m5200 -m68881 -mbitfield -mc68000 -mc68020
726 -mnobitfield -mrtd -mshort -msoft-float -mpcrel
727 -malign-int -mstrict-align -msep-data -mno-sep-data
728 -mshared-library-id=n -mid-shared-library -mno-id-shared-library
731 -m6811 -m6812 -m68hc11 -m68hc12 -m68hcs12
732 -mauto-incdec -minmax -mlong-calls -mshort
733 -msoft-reg-count=COUNT
736 -mhardlit -mno-hardlit -mdiv -mno-div -mrelax-immediates
737 -mno-relax-immediates -mwide-bitfields -mno-wide-bitfields
738 -m4byte-functions -mno-4byte-functions -mcallgraph-data
739 -mno-callgraph-data -mslow-bytes -mno-slow-bytes -mno-lsim
740 -mlittle-endian -mbig-endian -m210 -m340 -mstack-increment
743 -EL -EB -march=ARCH -mtune=ARCH
744 -mips1 -mips2 -mips3 -mips4 -mips32 -mips32r2 -mips64
745 -mips16 -mno-mips16 -mabi=ABI -mabicalls -mno-abicalls
746 -mxgot -mno-xgot -mgp32 -mgp64 -mfp32 -mfp64
747 -mhard-float -msoft-float -msingle-float -mdouble-float
748 -mpaired-single -mips3d
749 -mint64 -mlong64 -mlong32 -msym32 -mno-sym32
750 -GNUM -membedded-data -mno-embedded-data
751 -muninit-const-in-rodata -mno-uninit-const-in-rodata
752 -msplit-addresses -mno-split-addresses
753 -mexplicit-relocs -mno-explicit-relocs
754 -mcheck-zero-division -mno-check-zero-division
755 -mdivide-traps -mdivide-breaks
756 -mmemcpy -mno-memcpy -mlong-calls -mno-long-calls
757 -mmad -mno-mad -mfused-madd -mno-fused-madd -nocpp
758 -mfix-r4000 -mno-fix-r4000 -mfix-r4400 -mno-fix-r4400
759 -mfix-vr4120 -mno-fix-vr4120 -mfix-vr4130
760 -mfix-sb1 -mno-fix-sb1
761 -mflush-func=FUNC -mno-flush-func
762 -mbranch-likely -mno-branch-likely
763 -mfp-exceptions -mno-fp-exceptions
764 -mvr4130-align -mno-vr4130-align
767 -mlibfuncs -mno-libfuncs -mepsilon -mno-epsilon -mabi=gnu
768 -mabi=mmixware -mzero-extend -mknuthdiv -mtoplevel-symbols
769 -melf -mbranch-predict -mno-branch-predict -mbase-addresses
770 -mno-base-addresses -msingle-exit -mno-single-exit
773 -mmult-bug -mno-mult-bug
779 -m32032 -m32332 -m32532 -m32081 -m32381
780 -mmult-add -mnomult-add -msoft-float -mrtd -mnortd
781 -mregparam -mnoregparam -msb -mnosb
782 -mbitfield -mnobitfield -mhimem -mnohimem
785 -mfpu -msoft-float -mac0 -mno-ac0 -m40 -m45 -m10
786 -mbcopy -mbcopy-builtin -mint32 -mno-int16
787 -mint16 -mno-int32 -mfloat32 -mno-float64
788 -mfloat64 -mno-float32 -mabshi -mno-abshi
789 -mbranch-expensive -mbranch-cheap
790 -msplit -mno-split -munix-asm -mdec-asm
792 _PowerPC Options_ See RS/6000 and PowerPC Options.
794 _RS/6000 and PowerPC Options_
797 -mpower -mno-power -mpower2 -mno-power2
798 -mpowerpc -mpowerpc64 -mno-powerpc
799 -maltivec -mno-altivec
800 -mpowerpc-gpopt -mno-powerpc-gpopt
801 -mpowerpc-gfxopt -mno-powerpc-gfxopt
802 -mnew-mnemonics -mold-mnemonics
803 -mfull-toc -mminimal-toc -mno-fp-in-toc -mno-sum-in-toc
804 -m64 -m32 -mxl-compat -mno-xl-compat -mpe
805 -malign-power -malign-natural
806 -msoft-float -mhard-float -mmultiple -mno-multiple
807 -mstring -mno-string -mupdate -mno-update
808 -mfused-madd -mno-fused-madd -mbit-align -mno-bit-align
809 -mstrict-align -mno-strict-align -mrelocatable
810 -mno-relocatable -mrelocatable-lib -mno-relocatable-lib
811 -mtoc -mno-toc -mlittle -mlittle-endian -mbig -mbig-endian
813 -mprioritize-restricted-insns=PRIORITY
814 -msched-costly-dep=DEPENDENCE_TYPE
815 -minsert-sched-nops=SCHEME
816 -mcall-sysv -mcall-netbsd
817 -maix-struct-return -msvr4-struct-return
818 -mabi=altivec -mabi=no-altivec
819 -mabi=spe -mabi=no-spe
822 -mfloat-gprs=yes -mfloat-gprs=no -mfloat-gprs=single -mfloat-gprs=double
823 -mprototype -mno-prototype
824 -msim -mmvme -mads -myellowknife -memb -msdata
825 -msdata=OPT -mvxworks -mwindiss -G NUM -pthread
827 _S/390 and zSeries Options_
828 -mtune=CPU-TYPE -march=CPU-TYPE
829 -mhard-float -msoft-float -mbackchain -mno-backchain
830 -mpacked-stack -mno-packed-stack
831 -msmall-exec -mno-small-exec -mmvcle -mno-mvcle
832 -m64 -m31 -mdebug -mno-debug -mesa -mzarch
833 -mtpf-trace -mno-tpf-trace -mfused-madd -mno-fused-madd
834 -mwarn-framesize -mwarn-dynamicstack -mstack-size -mstack-guard
837 -m1 -m2 -m2e -m3 -m3e
838 -m4-nofpu -m4-single-only -m4-single -m4
839 -m4a-nofpu -m4a-single-only -m4a-single -m4a -m4al
840 -m5-64media -m5-64media-nofpu
841 -m5-32media -m5-32media-nofpu
842 -m5-compact -m5-compact-nofpu
843 -mb -ml -mdalign -mrelax
844 -mbigtable -mfmovd -mhitachi -mrenesas -mno-renesas -mnomacsave
845 -mieee -misize -mpadstruct -mspace
846 -mprefergot -musermode
852 -m32 -m64 -mapp-regs -mno-app-regs
853 -mfaster-structs -mno-faster-structs
854 -mfpu -mno-fpu -mhard-float -msoft-float
855 -mhard-quad-float -msoft-quad-float
856 -mimpure-text -mno-impure-text -mlittle-endian
857 -mstack-bias -mno-stack-bias
858 -munaligned-doubles -mno-unaligned-doubles
859 -mv8plus -mno-v8plus -mvis -mno-vis
863 -Qy -Qn -YP,PATHS -Ym,DIR
865 _TMS320C3x/C4x Options_
866 -mcpu=CPU -mbig -msmall -mregparm -mmemparm
867 -mfast-fix -mmpyi -mbk -mti -mdp-isr-reload
868 -mrpts=COUNT -mrptb -mdb -mloop-unsigned
869 -mparallel-insns -mparallel-mpy -mpreserve-float
872 -mlong-calls -mno-long-calls -mep -mno-ep
873 -mprolog-function -mno-prolog-function -mspace
874 -mtda=N -msda=N -mzda=N
875 -mapp-regs -mno-app-regs
876 -mdisable-callt -mno-disable-callt
884 _x86-64 Options_ See i386 and x86-64 Options.
890 -mconst16 -mno-const16
891 -mfused-madd -mno-fused-madd
892 -mtext-section-literals -mno-text-section-literals
893 -mtarget-align -mno-target-align
894 -mlongcalls -mno-longcalls
896 _zSeries Options_ See S/390 and zSeries Options.
898 _Code Generation Options_
899 *Note Options for Code Generation Conventions: Code Gen Options.
900 -fcall-saved-REG -fcall-used-REG
901 -ffixed-REG -fexceptions
902 -fnon-call-exceptions -funwind-tables
903 -fasynchronous-unwind-tables
904 -finhibit-size-directive -finstrument-functions
905 -fno-common -fno-ident
906 -fpcc-struct-return -fpic -fPIC -fpie -fPIE
907 -freg-struct-return -fshared-data -fshort-enums
908 -fshort-double -fshort-wchar
909 -fverbose-asm -fpack-struct[=N] -fstack-check
910 -fstack-limit-register=REG -fstack-limit-symbol=SYM
911 -fargument-alias -fargument-noalias
912 -fargument-noalias-global -fleading-underscore
914 -ftrapv -fwrapv -fbounds-check
920 * Overall Options:: Controlling the kind of output:
921 an executable, object files, assembler files,
922 or preprocessed source.
923 * C Dialect Options:: Controlling the variant of C language compiled.
924 * C++ Dialect Options:: Variations on C++.
925 * Objective-C and Objective-C++ Dialect Options:: Variations on Objective-C
927 * Language Independent Options:: Controlling how diagnostics should be
929 * Warning Options:: How picky should the compiler be?
930 * Debugging Options:: Symbol tables, measurements, and debugging dumps.
931 * Optimize Options:: How much optimization?
932 * Preprocessor Options:: Controlling header files and macro definitions.
933 Also, getting dependency information for Make.
934 * Assembler Options:: Passing options to the assembler.
935 * Link Options:: Specifying libraries and so on.
936 * Directory Options:: Where to find header files and libraries.
937 Where to find the compiler executable files.
938 * Spec Files:: How to pass switches to sub-processes.
939 * Target Options:: Running a cross-compiler, or an old version of GCC.
942 File: gcc.info, Node: Overall Options, Next: Invoking G++, Prev: Option Summary, Up: Invoking GCC
944 3.2 Options Controlling the Kind of Output
945 ==========================================
947 Compilation can involve up to four stages: preprocessing, compilation
948 proper, assembly and linking, always in that order. GCC is capable of
949 preprocessing and compiling several files either into several assembler
950 input files, or into one assembler input file; then each assembler
951 input file produces an object file, and linking combines all the object
952 files (those newly compiled, and those specified as input) into an
955 For any given input file, the file name suffix determines what kind of
959 C source code which must be preprocessed.
962 C source code which should not be preprocessed.
965 C++ source code which should not be preprocessed.
968 Objective-C source code. Note that you must link with the
969 `libobjc' library to make an Objective-C program work.
972 Objective-C source code which should not be preprocessed.
976 Objective-C++ source code. Note that you must link with the
977 `libobjc' library to make an Objective-C++ program work. Note
978 that `.M' refers to a literal capital M.
981 Objective-C++ source code which should not be preprocessed.
984 C, C++, Objective-C or Objective-C++ header file to be turned into
985 a precompiled header.
994 C++ source code which must be preprocessed. Note that in `.cxx',
995 the last two letters must both be literally `x'. Likewise, `.C'
996 refers to a literal capital C.
1000 C++ header file to be turned into a precompiled header.
1005 Fortran source code which should not be preprocessed.
1010 Fortran source code which must be preprocessed (with the
1011 traditional preprocessor).
1014 Fortran source code which must be preprocessed with a RATFOR
1015 preprocessor (not included with GCC).
1019 Fortran 90/95 source code which should not be preprocessed.
1022 Ada source code file which contains a library unit declaration (a
1023 declaration of a package, subprogram, or generic, or a generic
1024 instantiation), or a library unit renaming declaration (a package,
1025 generic, or subprogram renaming declaration). Such files are also
1029 Ada source code file containing a library unit body (a subprogram
1030 or package body). Such files are also called "bodies".
1036 Assembler code which must be preprocessed.
1039 An object file to be fed straight into linking. Any file name
1040 with no recognized suffix is treated this way.
1042 You can specify the input language explicitly with the `-x' option:
1045 Specify explicitly the LANGUAGE for the following input files
1046 (rather than letting the compiler choose a default based on the
1047 file name suffix). This option applies to all following input
1048 files until the next `-x' option. Possible values for LANGUAGE
1050 c c-header c-cpp-output
1051 c++ c++-header c++-cpp-output
1052 objective-c objective-c-header objective-c-cpp-output
1053 objective-c++ objective-c++-header objective-c++-cpp-output
1054 assembler assembler-with-cpp
1056 f77 f77-cpp-input ratfor
1062 Turn off any specification of a language, so that subsequent files
1063 are handled according to their file name suffixes (as they are if
1064 `-x' has not been used at all).
1067 Normally the `gcc' program will exit with the code of 1 if any
1068 phase of the compiler returns a non-success return code. If you
1069 specify `-pass-exit-codes', the `gcc' program will instead return
1070 with numerically highest error produced by any phase that returned
1071 an error indication.
1073 If you only want some of the stages of compilation, you can use `-x'
1074 (or filename suffixes) to tell `gcc' where to start, and one of the
1075 options `-c', `-S', or `-E' to say where `gcc' is to stop. Note that
1076 some combinations (for example, `-x cpp-output -E') instruct `gcc' to
1080 Compile or assemble the source files, but do not link. The linking
1081 stage simply is not done. The ultimate output is in the form of an
1082 object file for each source file.
1084 By default, the object file name for a source file is made by
1085 replacing the suffix `.c', `.i', `.s', etc., with `.o'.
1087 Unrecognized input files, not requiring compilation or assembly,
1091 Stop after the stage of compilation proper; do not assemble. The
1092 output is in the form of an assembler code file for each
1093 non-assembler input file specified.
1095 By default, the assembler file name for a source file is made by
1096 replacing the suffix `.c', `.i', etc., with `.s'.
1098 Input files that don't require compilation are ignored.
1101 Stop after the preprocessing stage; do not run the compiler
1102 proper. The output is in the form of preprocessed source code,
1103 which is sent to the standard output.
1105 Input files which don't require preprocessing are ignored.
1108 Place output in file FILE. This applies regardless to whatever
1109 sort of output is being produced, whether it be an executable file,
1110 an object file, an assembler file or preprocessed C code.
1112 If `-o' is not specified, the default is to put an executable file
1113 in `a.out', the object file for `SOURCE.SUFFIX' in `SOURCE.o', its
1114 assembler file in `SOURCE.s', a precompiled header file in
1115 `SOURCE.SUFFIX.gch', and all preprocessed C source on standard
1119 Print (on standard error output) the commands executed to run the
1120 stages of compilation. Also print the version number of the
1121 compiler driver program and of the preprocessor and the compiler
1125 Like `-v' except the commands are not executed and all command
1126 arguments are quoted. This is useful for shell scripts to capture
1127 the driver-generated command lines.
1130 Use pipes rather than temporary files for communication between the
1131 various stages of compilation. This fails to work on some systems
1132 where the assembler is unable to read from a pipe; but the GNU
1133 assembler has no trouble.
1136 If you are compiling multiple source files, this option tells the
1137 driver to pass all the source files to the compiler at once (for
1138 those languages for which the compiler can handle this). This
1139 will allow intermodule analysis (IMA) to be performed by the
1140 compiler. Currently the only language for which this is supported
1141 is C. If you pass source files for multiple languages to the
1142 driver, using this option, the driver will invoke the compiler(s)
1143 that support IMA once each, passing each compiler all the source
1144 files appropriate for it. For those languages that do not support
1145 IMA this option will be ignored, and the compiler will be invoked
1146 once for each source file in that language. If you use this
1147 option in conjunction with `-save-temps', the compiler will
1148 generate multiple pre-processed files (one for each source file),
1149 but only one (combined) `.o' or `.s' file.
1152 Print (on the standard output) a description of the command line
1153 options understood by `gcc'. If the `-v' option is also specified
1154 then `--help' will also be passed on to the various processes
1155 invoked by `gcc', so that they can display the command line options
1156 they accept. If the `-Wextra' option is also specified then
1157 command line options which have no documentation associated with
1158 them will also be displayed.
1161 Print (on the standard output) a description of target specific
1162 command line options for each tool.
1165 Display the version number and copyrights of the invoked GCC.
1168 File: gcc.info, Node: Invoking G++, Next: C Dialect Options, Prev: Overall Options, Up: Invoking GCC
1170 3.3 Compiling C++ Programs
1171 ==========================
1173 C++ source files conventionally use one of the suffixes `.C', `.cc',
1174 `.cpp', `.CPP', `.c++', `.cp', or `.cxx'; C++ header files often use
1175 `.hh' or `.H'; and preprocessed C++ files use the suffix `.ii'. GCC
1176 recognizes files with these names and compiles them as C++ programs
1177 even if you call the compiler the same way as for compiling C programs
1178 (usually with the name `gcc').
1180 However, C++ programs often require class libraries as well as a
1181 compiler that understands the C++ language--and under some
1182 circumstances, you might want to compile programs or header files from
1183 standard input, or otherwise without a suffix that flags them as C++
1184 programs. You might also like to precompile a C header file with a
1185 `.h' extension to be used in C++ compilations. `g++' is a program that
1186 calls GCC with the default language set to C++, and automatically
1187 specifies linking against the C++ library. On many systems, `g++' is
1188 also installed with the name `c++'.
1190 When you compile C++ programs, you may specify many of the same
1191 command-line options that you use for compiling programs in any
1192 language; or command-line options meaningful for C and related
1193 languages; or options that are meaningful only for C++ programs. *Note
1194 Options Controlling C Dialect: C Dialect Options, for explanations of
1195 options for languages related to C. *Note Options Controlling C++
1196 Dialect: C++ Dialect Options, for explanations of options that are
1197 meaningful only for C++ programs.
1200 File: gcc.info, Node: C Dialect Options, Next: C++ Dialect Options, Prev: Invoking G++, Up: Invoking GCC
1202 3.4 Options Controlling C Dialect
1203 =================================
1205 The following options control the dialect of C (or languages derived
1206 from C, such as C++, Objective-C and Objective-C++) that the compiler
1210 In C mode, support all ISO C90 programs. In C++ mode, remove GNU
1211 extensions that conflict with ISO C++.
1213 This turns off certain features of GCC that are incompatible with
1214 ISO C90 (when compiling C code), or of standard C++ (when
1215 compiling C++ code), such as the `asm' and `typeof' keywords, and
1216 predefined macros such as `unix' and `vax' that identify the type
1217 of system you are using. It also enables the undesirable and
1218 rarely used ISO trigraph feature. For the C compiler, it disables
1219 recognition of C++ style `//' comments as well as the `inline'
1222 The alternate keywords `__asm__', `__extension__', `__inline__'
1223 and `__typeof__' continue to work despite `-ansi'. You would not
1224 want to use them in an ISO C program, of course, but it is useful
1225 to put them in header files that might be included in compilations
1226 done with `-ansi'. Alternate predefined macros such as `__unix__'
1227 and `__vax__' are also available, with or without `-ansi'.
1229 The `-ansi' option does not cause non-ISO programs to be rejected
1230 gratuitously. For that, `-pedantic' is required in addition to
1231 `-ansi'. *Note Warning Options::.
1233 The macro `__STRICT_ANSI__' is predefined when the `-ansi' option
1234 is used. Some header files may notice this macro and refrain from
1235 declaring certain functions or defining certain macros that the
1236 ISO standard doesn't call for; this is to avoid interfering with
1237 any programs that might use these names for other things.
1239 Functions which would normally be built in but do not have
1240 semantics defined by ISO C (such as `alloca' and `ffs') are not
1241 built-in functions with `-ansi' is used. *Note Other built-in
1242 functions provided by GCC: Other Builtins, for details of the
1246 Determine the language standard. This option is currently only
1247 supported when compiling C or C++. A value for this option must be
1248 provided; possible values are
1252 ISO C90 (same as `-ansi').
1255 ISO C90 as modified in amendment 1.
1261 ISO C99. Note that this standard is not yet fully supported;
1262 see `http://gcc.gnu.org/gcc-4.0/c99status.html' for more
1263 information. The names `c9x' and `iso9899:199x' are
1267 Default, ISO C90 plus GNU extensions (including some C99
1272 ISO C99 plus GNU extensions. When ISO C99 is fully
1273 implemented in GCC, this will become the default. The name
1274 `gnu9x' is deprecated.
1277 The 1998 ISO C++ standard plus amendments.
1280 The same as `-std=c++98' plus GNU extensions. This is the
1281 default for C++ code.
1283 Even when this option is not specified, you can still use some of
1284 the features of newer standards in so far as they do not conflict
1285 with previous C standards. For example, you may use
1286 `__restrict__' even when `-std=c99' is not specified.
1288 The `-std' options specifying some version of ISO C have the same
1289 effects as `-ansi', except that features that were not in ISO C90
1290 but are in the specified version (for example, `//' comments and
1291 the `inline' keyword in ISO C99) are not disabled.
1293 *Note Language Standards Supported by GCC: Standards, for details
1294 of these standard versions.
1296 `-aux-info FILENAME'
1297 Output to the given filename prototyped declarations for all
1298 functions declared and/or defined in a translation unit, including
1299 those in header files. This option is silently ignored in any
1300 language other than C.
1302 Besides declarations, the file indicates, in comments, the origin
1303 of each declaration (source file and line), whether the
1304 declaration was implicit, prototyped or unprototyped (`I', `N' for
1305 new or `O' for old, respectively, in the first character after the
1306 line number and the colon), and whether it came from a declaration
1307 or a definition (`C' or `F', respectively, in the following
1308 character). In the case of function definitions, a K&R-style list
1309 of arguments followed by their declarations is also provided,
1310 inside comments, after the declaration.
1313 Do not recognize `asm', `inline' or `typeof' as a keyword, so that
1314 code can use these words as identifiers. You can use the keywords
1315 `__asm__', `__inline__' and `__typeof__' instead. `-ansi' implies
1318 In C++, this switch only affects the `typeof' keyword, since `asm'
1319 and `inline' are standard keywords. You may want to use the
1320 `-fno-gnu-keywords' flag instead, which has the same effect. In
1321 C99 mode (`-std=c99' or `-std=gnu99'), this switch only affects
1322 the `asm' and `typeof' keywords, since `inline' is a standard
1326 `-fno-builtin-FUNCTION'
1327 Don't recognize built-in functions that do not begin with
1328 `__builtin_' as prefix. *Note Other built-in functions provided
1329 by GCC: Other Builtins, for details of the functions affected,
1330 including those which are not built-in functions when `-ansi' or
1331 `-std' options for strict ISO C conformance are used because they
1332 do not have an ISO standard meaning.
1334 GCC normally generates special code to handle certain built-in
1335 functions more efficiently; for instance, calls to `alloca' may
1336 become single instructions that adjust the stack directly, and
1337 calls to `memcpy' may become inline copy loops. The resulting
1338 code is often both smaller and faster, but since the function
1339 calls no longer appear as such, you cannot set a breakpoint on
1340 those calls, nor can you change the behavior of the functions by
1341 linking with a different library. In addition, when a function is
1342 recognized as a built-in function, GCC may use information about
1343 that function to warn about problems with calls to that function,
1344 or to generate more efficient code, even if the resulting code
1345 still contains calls to that function. For example, warnings are
1346 given with `-Wformat' for bad calls to `printf', when `printf' is
1347 built in, and `strlen' is known not to modify global memory.
1349 With the `-fno-builtin-FUNCTION' option only the built-in function
1350 FUNCTION is disabled. FUNCTION must not begin with `__builtin_'.
1351 If a function is named this is not built-in in this version of
1352 GCC, this option is ignored. There is no corresponding
1353 `-fbuiltin-FUNCTION' option; if you wish to enable built-in
1354 functions selectively when using `-fno-builtin' or
1355 `-ffreestanding', you may define macros such as:
1357 #define abs(n) __builtin_abs ((n))
1358 #define strcpy(d, s) __builtin_strcpy ((d), (s))
1361 Assert that compilation takes place in a hosted environment. This
1362 implies `-fbuiltin'. A hosted environment is one in which the
1363 entire standard library is available, and in which `main' has a
1364 return type of `int'. Examples are nearly everything except a
1365 kernel. This is equivalent to `-fno-freestanding'.
1368 Assert that compilation takes place in a freestanding environment.
1369 This implies `-fno-builtin'. A freestanding environment is one
1370 in which the standard library may not exist, and program startup
1371 may not necessarily be at `main'. The most obvious example is an
1372 OS kernel. This is equivalent to `-fno-hosted'.
1374 *Note Language Standards Supported by GCC: Standards, for details
1375 of freestanding and hosted environments.
1378 Accept some non-standard constructs used in Microsoft header files.
1380 Some cases of unnamed fields in structures and unions are only
1381 accepted with this option. *Note Unnamed struct/union fields
1382 within structs/unions: Unnamed Fields, for details.
1385 Support ISO C trigraphs. The `-ansi' option (and `-std' options
1386 for strict ISO C conformance) implies `-trigraphs'.
1388 `-no-integrated-cpp'
1389 Performs a compilation in two passes: preprocessing and compiling.
1390 This option allows a user supplied "cc1", "cc1plus", or "cc1obj"
1391 via the `-B' option. The user supplied compilation step can then
1392 add in an additional preprocessing step after normal preprocessing
1393 but before compiling. The default is to use the integrated cpp
1396 The semantics of this option will change if "cc1", "cc1plus", and
1397 "cc1obj" are merged.
1401 Formerly, these options caused GCC to attempt to emulate a
1402 pre-standard C compiler. They are now only supported with the
1403 `-E' switch. The preprocessor continues to support a pre-standard
1404 mode. See the GNU CPP manual for details.
1407 Allow conditional expressions with mismatched types in the second
1408 and third arguments. The value of such an expression is void.
1409 This option is not supported for C++.
1412 Let the type `char' be unsigned, like `unsigned char'.
1414 Each kind of machine has a default for what `char' should be. It
1415 is either like `unsigned char' by default or like `signed char' by
1418 Ideally, a portable program should always use `signed char' or
1419 `unsigned char' when it depends on the signedness of an object.
1420 But many programs have been written to use plain `char' and expect
1421 it to be signed, or expect it to be unsigned, depending on the
1422 machines they were written for. This option, and its inverse, let
1423 you make such a program work with the opposite default.
1425 The type `char' is always a distinct type from each of `signed
1426 char' or `unsigned char', even though its behavior is always just
1427 like one of those two.
1430 Let the type `char' be signed, like `signed char'.
1432 Note that this is equivalent to `-fno-unsigned-char', which is the
1433 negative form of `-funsigned-char'. Likewise, the option
1434 `-fno-signed-char' is equivalent to `-funsigned-char'.
1436 `-fsigned-bitfields'
1437 `-funsigned-bitfields'
1438 `-fno-signed-bitfields'
1439 `-fno-unsigned-bitfields'
1440 These options control whether a bit-field is signed or unsigned,
1441 when the declaration does not use either `signed' or `unsigned'.
1442 By default, such a bit-field is signed, because this is
1443 consistent: the basic integer types such as `int' are signed types.
1446 File: gcc.info, Node: C++ Dialect Options, Next: Objective-C and Objective-C++ Dialect Options, Prev: C Dialect Options, Up: Invoking GCC
1448 3.5 Options Controlling C++ Dialect
1449 ===================================
1451 This section describes the command-line options that are only meaningful
1452 for C++ programs; but you can also use most of the GNU compiler options
1453 regardless of what language your program is in. For example, you might
1454 compile a file `firstClass.C' like this:
1456 g++ -g -frepo -O -c firstClass.C
1458 In this example, only `-frepo' is an option meant only for C++
1459 programs; you can use the other options with any language supported by
1462 Here is a list of options that are _only_ for compiling C++ programs:
1465 Use version N of the C++ ABI. Version 2 is the version of the C++
1466 ABI that first appeared in G++ 3.4. Version 1 is the version of
1467 the C++ ABI that first appeared in G++ 3.2. Version 0 will always
1468 be the version that conforms most closely to the C++ ABI
1469 specification. Therefore, the ABI obtained using version 0 will
1470 change as ABI bugs are fixed.
1472 The default is version 2.
1474 `-fno-access-control'
1475 Turn off all access checking. This switch is mainly useful for
1476 working around bugs in the access control code.
1479 Check that the pointer returned by `operator new' is non-null
1480 before attempting to modify the storage allocated. This check is
1481 normally unnecessary because the C++ standard specifies that
1482 `operator new' will only return `0' if it is declared `throw()',
1483 in which case the compiler will always check the return value even
1484 without this option. In all other cases, when `operator new' has
1485 a non-empty exception specification, memory exhaustion is
1486 signalled by throwing `std::bad_alloc'. See also `new (nothrow)'.
1489 Put uninitialized or runtime-initialized global variables into the
1490 common segment, as C does. This saves space in the executable at
1491 the cost of not diagnosing duplicate definitions. If you compile
1492 with this flag and your program mysteriously crashes after
1493 `main()' has completed, you may have an object that is being
1494 destroyed twice because two definitions were merged.
1496 This option is no longer useful on most targets, now that support
1497 has been added for putting variables into BSS without making them
1500 `-fno-const-strings'
1501 Give string constants type `char *' instead of type `const char
1502 *'. By default, G++ uses type `const char *' as required by the
1503 standard. Even if you use `-fno-const-strings', you cannot
1504 actually modify the value of a string constant.
1506 This option might be removed in a future release of G++. For
1507 maximum portability, you should structure your code so that it
1508 works with string constants that have type `const char *'.
1510 `-fno-elide-constructors'
1511 The C++ standard allows an implementation to omit creating a
1512 temporary which is only used to initialize another object of the
1513 same type. Specifying this option disables that optimization, and
1514 forces G++ to call the copy constructor in all cases.
1516 `-fno-enforce-eh-specs'
1517 Don't check for violation of exception specifications at runtime.
1518 This option violates the C++ standard, but may be useful for
1519 reducing code size in production builds, much like defining
1520 `NDEBUG'. The compiler will still optimize based on the exception
1525 If `-ffor-scope' is specified, the scope of variables declared in
1526 a for-init-statement is limited to the `for' loop itself, as
1527 specified by the C++ standard. If `-fno-for-scope' is specified,
1528 the scope of variables declared in a for-init-statement extends to
1529 the end of the enclosing scope, as was the case in old versions of
1530 G++, and other (traditional) implementations of C++.
1532 The default if neither flag is given to follow the standard, but
1533 to allow and give a warning for old-style code that would
1534 otherwise be invalid, or have different behavior.
1537 Do not recognize `typeof' as a keyword, so that code can use this
1538 word as an identifier. You can use the keyword `__typeof__'
1539 instead. `-ansi' implies `-fno-gnu-keywords'.
1541 `-fno-implicit-templates'
1542 Never emit code for non-inline templates which are instantiated
1543 implicitly (i.e. by use); only emit code for explicit
1544 instantiations. *Note Template Instantiation::, for more
1547 `-fno-implicit-inline-templates'
1548 Don't emit code for implicit instantiations of inline templates,
1549 either. The default is to handle inlines differently so that
1550 compiles with and without optimization will need the same set of
1551 explicit instantiations.
1553 `-fno-implement-inlines'
1554 To save space, do not emit out-of-line copies of inline functions
1555 controlled by `#pragma implementation'. This will cause linker
1556 errors if these functions are not inlined everywhere they are
1560 Disable pedantic warnings about constructs used in MFC, such as
1561 implicit int and getting a pointer to member function via
1562 non-standard syntax.
1564 `-fno-nonansi-builtins'
1565 Disable built-in declarations of functions that are not mandated by
1566 ANSI/ISO C. These include `ffs', `alloca', `_exit', `index',
1567 `bzero', `conjf', and other related functions.
1569 `-fno-operator-names'
1570 Do not treat the operator name keywords `and', `bitand', `bitor',
1571 `compl', `not', `or' and `xor' as synonyms as keywords.
1573 `-fno-optional-diags'
1574 Disable diagnostics that the standard says a compiler does not
1575 need to issue. Currently, the only such diagnostic issued by G++
1576 is the one for a name having multiple meanings within a class.
1579 Downgrade some diagnostics about nonconformant code from errors to
1580 warnings. Thus, using `-fpermissive' will allow some
1581 nonconforming code to compile.
1584 Enable automatic template instantiation at link time. This option
1585 also implies `-fno-implicit-templates'. *Note Template
1586 Instantiation::, for more information.
1589 Disable generation of information about every class with virtual
1590 functions for use by the C++ runtime type identification features
1591 (`dynamic_cast' and `typeid'). If you don't use those parts of
1592 the language, you can save some space by using this flag. Note
1593 that exception handling uses the same information, but it will
1594 generate it as needed.
1597 Emit statistics about front-end processing at the end of the
1598 compilation. This information is generally only useful to the G++
1601 `-ftemplate-depth-N'
1602 Set the maximum instantiation depth for template classes to N. A
1603 limit on the template instantiation depth is needed to detect
1604 endless recursions during template class instantiation. ANSI/ISO
1605 C++ conforming programs must not rely on a maximum depth greater
1608 `-fno-threadsafe-statics'
1609 Do not emit the extra code to use the routines specified in the C++
1610 ABI for thread-safe initialization of local statics. You can use
1611 this option to reduce code size slightly in code that doesn't need
1615 Register destructors for objects with static storage duration with
1616 the `__cxa_atexit' function rather than the `atexit' function.
1617 This option is required for fully standards-compliant handling of
1618 static destructors, but will only work if your C library supports
1621 `-fvisibility-inlines-hidden'
1622 Causes all inlined methods to be marked with `__attribute__
1623 ((visibility ("hidden")))' so that they do not appear in the
1624 export table of a DSO and do not require a PLT indirection when
1625 used within the DSO. Enabling this option can have a dramatic
1626 effect on load and link times of a DSO as it massively reduces the
1627 size of the dynamic export table when the library makes heavy use
1628 of templates. While it can cause bloating through duplication of
1629 code within each DSO where it is used, often the wastage is less
1630 than the considerable space occupied by a long symbol name in the
1631 export table which is typical when using templates and namespaces.
1632 For even more savings, combine with the `-fvisibility=hidden'
1636 Do not use weak symbol support, even if it is provided by the
1637 linker. By default, G++ will use weak symbols if they are
1638 available. This option exists only for testing, and should not be
1639 used by end-users; it will result in inferior code and has no
1640 benefits. This option may be removed in a future release of G++.
1643 Do not search for header files in the standard directories
1644 specific to C++, but do still search the other standard
1645 directories. (This option is used when building the C++ library.)
1647 In addition, these optimization, warning, and code generation options
1648 have meanings only for C++ programs:
1650 `-fno-default-inline'
1651 Do not assume `inline' for functions defined inside a class scope.
1652 *Note Options That Control Optimization: Optimize Options. Note
1653 that these functions will have linkage like inline functions; they
1654 just won't be inlined by default.
1657 Warn when G++ generates code that is probably not compatible with
1658 the vendor-neutral C++ ABI. Although an effort has been made to
1659 warn about all such cases, there are probably some cases that are
1660 not warned about, even though G++ is generating incompatible code.
1661 There may also be cases where warnings are emitted even though
1662 the code that is generated will be compatible.
1664 You should rewrite your code to avoid these warnings if you are
1665 concerned about the fact that code generated by G++ may not be
1666 binary compatible with code generated by other compilers.
1668 The known incompatibilities at this point include:
1670 * Incorrect handling of tail-padding for bit-fields. G++ may
1671 attempt to pack data into the same byte as a base class. For
1674 struct A { virtual void f(); int f1 : 1; };
1675 struct B : public A { int f2 : 1; };
1677 In this case, G++ will place `B::f2' into the same byte
1678 as`A::f1'; other compilers will not. You can avoid this
1679 problem by explicitly padding `A' so that its size is a
1680 multiple of the byte size on your platform; that will cause
1681 G++ and other compilers to layout `B' identically.
1683 * Incorrect handling of tail-padding for virtual bases. G++
1684 does not use tail padding when laying out virtual bases. For
1687 struct A { virtual void f(); char c1; };
1688 struct B { B(); char c2; };
1689 struct C : public A, public virtual B {};
1691 In this case, G++ will not place `B' into the tail-padding for
1692 `A'; other compilers will. You can avoid this problem by
1693 explicitly padding `A' so that its size is a multiple of its
1694 alignment (ignoring virtual base classes); that will cause
1695 G++ and other compilers to layout `C' identically.
1697 * Incorrect handling of bit-fields with declared widths greater
1698 than that of their underlying types, when the bit-fields
1699 appear in a union. For example:
1701 union U { int i : 4096; };
1703 Assuming that an `int' does not have 4096 bits, G++ will make
1704 the union too small by the number of bits in an `int'.
1706 * Empty classes can be placed at incorrect offsets. For
1716 struct C : public B, public A {};
1718 G++ will place the `A' base class of `C' at a nonzero offset;
1719 it should be placed at offset zero. G++ mistakenly believes
1720 that the `A' data member of `B' is already at offset zero.
1722 * Names of template functions whose types involve `typename' or
1723 template template parameters can be mangled incorrectly.
1725 template <typename Q>
1726 void f(typename Q::X) {}
1728 template <template <typename> class Q>
1729 void f(typename Q<int>::X) {}
1731 Instantiations of these templates may be mangled incorrectly.
1734 `-Wctor-dtor-privacy (C++ only)'
1735 Warn when a class seems unusable because all the constructors or
1736 destructors in that class are private, and it has neither friends
1737 nor public static member functions.
1739 `-Wnon-virtual-dtor (C++ only)'
1740 Warn when a class appears to be polymorphic, thereby requiring a
1741 virtual destructor, yet it declares a non-virtual one. This
1742 warning is enabled by `-Wall'.
1744 `-Wreorder (C++ only)'
1745 Warn when the order of member initializers given in the code does
1746 not match the order in which they must be executed. For instance:
1751 A(): j (0), i (1) { }
1754 The compiler will rearrange the member initializers for `i' and
1755 `j' to match the declaration order of the members, emitting a
1756 warning to that effect. This warning is enabled by `-Wall'.
1758 The following `-W...' options are not affected by `-Wall'.
1760 `-Weffc++ (C++ only)'
1761 Warn about violations of the following style guidelines from Scott
1762 Meyers' `Effective C++' book:
1764 * Item 11: Define a copy constructor and an assignment
1765 operator for classes with dynamically allocated memory.
1767 * Item 12: Prefer initialization to assignment in constructors.
1769 * Item 14: Make destructors virtual in base classes.
1771 * Item 15: Have `operator=' return a reference to `*this'.
1773 * Item 23: Don't try to return a reference when you must
1777 Also warn about violations of the following style guidelines from
1778 Scott Meyers' `More Effective C++' book:
1780 * Item 6: Distinguish between prefix and postfix forms of
1781 increment and decrement operators.
1783 * Item 7: Never overload `&&', `||', or `,'.
1786 When selecting this option, be aware that the standard library
1787 headers do not obey all of these guidelines; use `grep -v' to
1788 filter out those warnings.
1790 `-Wno-deprecated (C++ only)'
1791 Do not warn about usage of deprecated features. *Note Deprecated
1794 `-Wno-non-template-friend (C++ only)'
1795 Disable warnings when non-templatized friend functions are declared
1796 within a template. Since the advent of explicit template
1797 specification support in G++, if the name of the friend is an
1798 unqualified-id (i.e., `friend foo(int)'), the C++ language
1799 specification demands that the friend declare or define an
1800 ordinary, nontemplate function. (Section 14.5.3). Before G++
1801 implemented explicit specification, unqualified-ids could be
1802 interpreted as a particular specialization of a templatized
1803 function. Because this non-conforming behavior is no longer the
1804 default behavior for G++, `-Wnon-template-friend' allows the
1805 compiler to check existing code for potential trouble spots and is
1806 on by default. This new compiler behavior can be turned off with
1807 `-Wno-non-template-friend' which keeps the conformant compiler code
1808 but disables the helpful warning.
1810 `-Wold-style-cast (C++ only)'
1811 Warn if an old-style (C-style) cast to a non-void type is used
1812 within a C++ program. The new-style casts (`static_cast',
1813 `reinterpret_cast', and `const_cast') are less vulnerable to
1814 unintended effects and much easier to search for.
1816 `-Woverloaded-virtual (C++ only)'
1817 Warn when a function declaration hides virtual functions from a
1818 base class. For example, in:
1824 struct B: public A {
1828 the `A' class version of `f' is hidden in `B', and code like:
1833 will fail to compile.
1835 `-Wno-pmf-conversions (C++ only)'
1836 Disable the diagnostic for converting a bound pointer to member
1837 function to a plain pointer.
1839 `-Wsign-promo (C++ only)'
1840 Warn when overload resolution chooses a promotion from unsigned or
1841 enumerated type to a signed type, over a conversion to an unsigned
1842 type of the same size. Previous versions of G++ would try to
1843 preserve unsignedness, but the standard mandates the current
1848 A& operator = (int);
1857 In this example, G++ will synthesize a default `A& operator =
1858 (const A&);', while cfront will use the user-defined `operator ='.
1861 File: gcc.info, Node: Objective-C and Objective-C++ Dialect Options, Next: Language Independent Options, Prev: C++ Dialect Options, Up: Invoking GCC
1863 3.6 Options Controlling Objective-C and Objective-C++ Dialects
1864 ==============================================================
1866 (NOTE: This manual does not describe the Objective-C and Objective-C++
1867 languages themselves. See *Note Language Standards Supported by GCC:
1868 Standards, for references.)
1870 This section describes the command-line options that are only
1871 meaningful for Objective-C and Objective-C++ programs, but you can also
1872 use most of the language-independent GNU compiler options. For
1873 example, you might compile a file `some_class.m' like this:
1875 gcc -g -fgnu-runtime -O -c some_class.m
1877 In this example, `-fgnu-runtime' is an option meant only for
1878 Objective-C and Objective-C++ programs; you can use the other options
1879 with any language supported by GCC.
1881 Note that since Objective-C is an extension of the C language,
1882 Objective-C compilations may also use options specific to the C
1883 front-end (e.g., `-Wtraditional'). Similarly, Objective-C++
1884 compilations may use C++-specific options (e.g., `-Wabi').
1886 Here is a list of options that are _only_ for compiling Objective-C
1887 and Objective-C++ programs:
1889 `-fconstant-string-class=CLASS-NAME'
1890 Use CLASS-NAME as the name of the class to instantiate for each
1891 literal string specified with the syntax `@"..."'. The default
1892 class name is `NXConstantString' if the GNU runtime is being used,
1893 and `NSConstantString' if the NeXT runtime is being used (see
1894 below). The `-fconstant-cfstrings' option, if also present, will
1895 override the `-fconstant-string-class' setting and cause `@"..."'
1896 literals to be laid out as constant CoreFoundation strings.
1899 Generate object code compatible with the standard GNU Objective-C
1900 runtime. This is the default for most types of systems.
1903 Generate output compatible with the NeXT runtime. This is the
1904 default for NeXT-based systems, including Darwin and Mac OS X.
1905 The macro `__NEXT_RUNTIME__' is predefined if (and only if) this
1908 `-fno-nil-receivers'
1909 Assume that all Objective-C message dispatches (e.g., `[receiver
1910 message:arg]') in this translation unit ensure that the receiver
1911 is not `nil'. This allows for more efficient entry points in the
1912 runtime to be used. Currently, this option is only available in
1913 conjunction with the NeXT runtime on Mac OS X 10.3 and later.
1916 Enable syntactic support for structured exception handling in
1917 Objective-C, similar to what is offered by C++ and Java.
1918 Currently, this option is only available in conjunction with the
1919 NeXT runtime on Mac OS X 10.3 and later.
1926 @catch (AnObjCClass *exc) {
1933 @catch (AnotherClass *exc) {
1936 @catch (id allOthers) {
1945 The `@throw' statement may appear anywhere in an Objective-C or
1946 Objective-C++ program; when used inside of a `@catch' block, the
1947 `@throw' may appear without an argument (as shown above), in which
1948 case the object caught by the `@catch' will be rethrown.
1950 Note that only (pointers to) Objective-C objects may be thrown and
1951 caught using this scheme. When an object is thrown, it will be
1952 caught by the nearest `@catch' clause capable of handling objects
1953 of that type, analogously to how `catch' blocks work in C++ and
1954 Java. A `@catch(id ...)' clause (as shown above) may also be
1955 provided to catch any and all Objective-C exceptions not caught by
1956 previous `@catch' clauses (if any).
1958 The `@finally' clause, if present, will be executed upon exit from
1959 the immediately preceding `@try ... @catch' section. This will
1960 happen regardless of whether any exceptions are thrown, caught or
1961 rethrown inside the `@try ... @catch' section, analogously to the
1962 behavior of the `finally' clause in Java.
1964 There are several caveats to using the new exception mechanism:
1966 * Although currently designed to be binary compatible with
1967 `NS_HANDLER'-style idioms provided by the `NSException'
1968 class, the new exceptions can only be used on Mac OS X 10.3
1969 (Panther) and later systems, due to additional functionality
1970 needed in the (NeXT) Objective-C runtime.
1972 * As mentioned above, the new exceptions do not support handling
1973 types other than Objective-C objects. Furthermore, when
1974 used from Objective-C++, the Objective-C exception model does
1975 not interoperate with C++ exceptions at this time. This
1976 means you cannot `@throw' an exception from Objective-C and
1977 `catch' it in C++, or vice versa (i.e., `throw ... @catch').
1979 The `-fobjc-exceptions' switch also enables the use of
1980 synchronization blocks for thread-safe execution:
1982 @synchronized (ObjCClass *guard) {
1986 Upon entering the `@synchronized' block, a thread of execution
1987 shall first check whether a lock has been placed on the
1988 corresponding `guard' object by another thread. If it has, the
1989 current thread shall wait until the other thread relinquishes its
1990 lock. Once `guard' becomes available, the current thread will
1991 place its own lock on it, execute the code contained in the
1992 `@synchronized' block, and finally relinquish the lock (thereby
1993 making `guard' available to other threads).
1995 Unlike Java, Objective-C does not allow for entire methods to be
1996 marked `@synchronized'. Note that throwing exceptions out of
1997 `@synchronized' blocks is allowed, and will cause the guarding
1998 object to be unlocked properly.
2000 `-freplace-objc-classes'
2001 Emit a special marker instructing `ld(1)' not to statically link in
2002 the resulting object file, and allow `dyld(1)' to load it in at
2003 run time instead. This is used in conjunction with the
2004 Fix-and-Continue debugging mode, where the object file in question
2005 may be recompiled and dynamically reloaded in the course of
2006 program execution, without the need to restart the program itself.
2007 Currently, Fix-and-Continue functionality is only available in
2008 conjunction with the NeXT runtime on Mac OS X 10.3 and later.
2011 When compiling for the NeXT runtime, the compiler ordinarily
2012 replaces calls to `objc_getClass("...")' (when the name of the
2013 class is known at compile time) with static class references that
2014 get initialized at load time, which improves run-time performance.
2015 Specifying the `-fzero-link' flag suppresses this behavior and
2016 causes calls to `objc_getClass("...")' to be retained. This is
2017 useful in Zero-Link debugging mode, since it allows for individual
2018 class implementations to be modified during program execution.
2021 Dump interface declarations for all classes seen in the source
2022 file to a file named `SOURCENAME.decl'.
2025 If a class is declared to implement a protocol, a warning is
2026 issued for every method in the protocol that is not implemented by
2027 the class. The default behavior is to issue a warning for every
2028 method not explicitly implemented in the class, even if a method
2029 implementation is inherited from the superclass. If you use the
2030 `-Wno-protocol' option, then methods inherited from the superclass
2031 are considered to be implemented, and no warning is issued for
2035 Warn if multiple methods of different types for the same selector
2036 are found during compilation. The check is performed on the list
2037 of methods in the final stage of compilation. Additionally, a
2038 check is performed for each selector appearing in a
2039 `@selector(...)' expression, and a corresponding method for that
2040 selector has been found during compilation. Because these checks
2041 scan the method table only at the end of compilation, these
2042 warnings are not produced if the final stage of compilation is not
2043 reached, for example because an error is found during compilation,
2044 or because the `-fsyntax-only' option is being used.
2046 `-Wundeclared-selector'
2047 Warn if a `@selector(...)' expression referring to an undeclared
2048 selector is found. A selector is considered undeclared if no
2049 method with that name has been declared before the
2050 `@selector(...)' expression, either explicitly in an `@interface'
2051 or `@protocol' declaration, or implicitly in an `@implementation'
2052 section. This option always performs its checks as soon as a
2053 `@selector(...)' expression is found, while `-Wselector' only
2054 performs its checks in the final stage of compilation. This also
2055 enforces the coding style convention that methods and selectors
2056 must be declared before being used.
2058 `-print-objc-runtime-info'
2059 Generate C header describing the largest structure that is passed
2064 File: gcc.info, Node: Language Independent Options, Next: Warning Options, Prev: Objective-C and Objective-C++ Dialect Options, Up: Invoking GCC
2066 3.7 Options to Control Diagnostic Messages Formatting
2067 =====================================================
2069 Traditionally, diagnostic messages have been formatted irrespective of
2070 the output device's aspect (e.g. its width, ...). The options described
2071 below can be used to control the diagnostic messages formatting
2072 algorithm, e.g. how many characters per line, how often source location
2073 information should be reported. Right now, only the C++ front end can
2074 honor these options. However it is expected, in the near future, that
2075 the remaining front ends would be able to digest them correctly.
2077 `-fmessage-length=N'
2078 Try to format error messages so that they fit on lines of about N
2079 characters. The default is 72 characters for `g++' and 0 for the
2080 rest of the front ends supported by GCC. If N is zero, then no
2081 line-wrapping will be done; each error message will appear on a
2084 `-fdiagnostics-show-location=once'
2085 Only meaningful in line-wrapping mode. Instructs the diagnostic
2086 messages reporter to emit _once_ source location information; that
2087 is, in case the message is too long to fit on a single physical
2088 line and has to be wrapped, the source location won't be emitted
2089 (as prefix) again, over and over, in subsequent continuation
2090 lines. This is the default behavior.
2092 `-fdiagnostics-show-location=every-line'
2093 Only meaningful in line-wrapping mode. Instructs the diagnostic
2094 messages reporter to emit the same source location information (as
2095 prefix) for physical lines that result from the process of breaking
2096 a message which is too long to fit on a single line.
2100 File: gcc.info, Node: Warning Options, Next: Debugging Options, Prev: Language Independent Options, Up: Invoking GCC
2102 3.8 Options to Request or Suppress Warnings
2103 ===========================================
2105 Warnings are diagnostic messages that report constructions which are
2106 not inherently erroneous but which are risky or suggest there may have
2109 You can request many specific warnings with options beginning `-W',
2110 for example `-Wimplicit' to request warnings on implicit declarations.
2111 Each of these specific warning options also has a negative form
2112 beginning `-Wno-' to turn off warnings; for example, `-Wno-implicit'.
2113 This manual lists only one of the two forms, whichever is not the
2116 The following options control the amount and kinds of warnings produced
2117 by GCC; for further, language-specific options also refer to *Note C++
2118 Dialect Options:: and *Note Objective-C and Objective-C++ Dialect
2122 Check the code for syntax errors, but don't do anything beyond
2126 Issue all the warnings demanded by strict ISO C and ISO C++;
2127 reject all programs that use forbidden extensions, and some other
2128 programs that do not follow ISO C and ISO C++. For ISO C, follows
2129 the version of the ISO C standard specified by any `-std' option
2132 Valid ISO C and ISO C++ programs should compile properly with or
2133 without this option (though a rare few will require `-ansi' or a
2134 `-std' option specifying the required version of ISO C). However,
2135 without this option, certain GNU extensions and traditional C and
2136 C++ features are supported as well. With this option, they are
2139 `-pedantic' does not cause warning messages for use of the
2140 alternate keywords whose names begin and end with `__'. Pedantic
2141 warnings are also disabled in the expression that follows
2142 `__extension__'. However, only system header files should use
2143 these escape routes; application programs should avoid them.
2144 *Note Alternate Keywords::.
2146 Some users try to use `-pedantic' to check programs for strict ISO
2147 C conformance. They soon find that it does not do quite what they
2148 want: it finds some non-ISO practices, but not all--only those for
2149 which ISO C _requires_ a diagnostic, and some others for which
2150 diagnostics have been added.
2152 A feature to report any failure to conform to ISO C might be
2153 useful in some instances, but would require considerable
2154 additional work and would be quite different from `-pedantic'. We
2155 don't have plans to support such a feature in the near future.
2157 Where the standard specified with `-std' represents a GNU extended
2158 dialect of C, such as `gnu89' or `gnu99', there is a corresponding
2159 "base standard", the version of ISO C on which the GNU extended
2160 dialect is based. Warnings from `-pedantic' are given where they
2161 are required by the base standard. (It would not make sense for
2162 such warnings to be given only for features not in the specified
2163 GNU C dialect, since by definition the GNU dialects of C include
2164 all features the compiler supports with the given option, and
2165 there would be nothing to warn about.)
2168 Like `-pedantic', except that errors are produced rather than
2172 Inhibit all warning messages.
2175 Inhibit warning messages about the use of `#import'.
2178 Warn if an array subscript has type `char'. This is a common cause
2179 of error, as programmers often forget that this type is signed on
2180 some machines. This warning is enabled by `-Wall'.
2183 Warn whenever a comment-start sequence `/*' appears in a `/*'
2184 comment, or whenever a Backslash-Newline appears in a `//' comment.
2185 This warning is enabled by `-Wall'.
2188 This option causes the compiler to abort compilation on the first
2189 error occurred rather than trying to keep going and printing
2190 further error messages.
2193 Check calls to `printf' and `scanf', etc., to make sure that the
2194 arguments supplied have types appropriate to the format string
2195 specified, and that the conversions specified in the format string
2196 make sense. This includes standard functions, and others
2197 specified by format attributes (*note Function Attributes::), in
2198 the `printf', `scanf', `strftime' and `strfmon' (an X/Open
2199 extension, not in the C standard) families (or other
2200 target-specific families). Which functions are checked without
2201 format attributes having been specified depends on the standard
2202 version selected, and such checks of functions without the
2203 attribute specified are disabled by `-ffreestanding' or
2206 The formats are checked against the format features supported by
2207 GNU libc version 2.2. These include all ISO C90 and C99 features,
2208 as well as features from the Single Unix Specification and some
2209 BSD and GNU extensions. Other library implementations may not
2210 support all these features; GCC does not support warning about
2211 features that go beyond a particular library's limitations.
2212 However, if `-pedantic' is used with `-Wformat', warnings will be
2213 given about format features not in the selected standard version
2214 (but not for `strfmon' formats, since those are not in any version
2215 of the C standard). *Note Options Controlling C Dialect: C
2218 Since `-Wformat' also checks for null format arguments for several
2219 functions, `-Wformat' also implies `-Wnonnull'.
2221 `-Wformat' is included in `-Wall'. For more control over some
2222 aspects of format checking, the options `-Wformat-y2k',
2223 `-Wno-format-extra-args', `-Wno-format-zero-length',
2224 `-Wformat-nonliteral', `-Wformat-security', and `-Wformat=2' are
2225 available, but are not included in `-Wall'.
2228 If `-Wformat' is specified, also warn about `strftime' formats
2229 which may yield only a two-digit year.
2231 `-Wno-format-extra-args'
2232 If `-Wformat' is specified, do not warn about excess arguments to a
2233 `printf' or `scanf' format function. The C standard specifies
2234 that such arguments are ignored.
2236 Where the unused arguments lie between used arguments that are
2237 specified with `$' operand number specifications, normally
2238 warnings are still given, since the implementation could not know
2239 what type to pass to `va_arg' to skip the unused arguments.
2240 However, in the case of `scanf' formats, this option will suppress
2241 the warning if the unused arguments are all pointers, since the
2242 Single Unix Specification says that such unused arguments are
2245 `-Wno-format-zero-length'
2246 If `-Wformat' is specified, do not warn about zero-length formats.
2247 The C standard specifies that zero-length formats are allowed.
2249 `-Wformat-nonliteral'
2250 If `-Wformat' is specified, also warn if the format string is not a
2251 string literal and so cannot be checked, unless the format function
2252 takes its format arguments as a `va_list'.
2255 If `-Wformat' is specified, also warn about uses of format
2256 functions that represent possible security problems. At present,
2257 this warns about calls to `printf' and `scanf' functions where the
2258 format string is not a string literal and there are no format
2259 arguments, as in `printf (foo);'. This may be a security hole if
2260 the format string came from untrusted input and contains `%n'.
2261 (This is currently a subset of what `-Wformat-nonliteral' warns
2262 about, but in future warnings may be added to `-Wformat-security'
2263 that are not included in `-Wformat-nonliteral'.)
2266 Enable `-Wformat' plus format checks not included in `-Wformat'.
2267 Currently equivalent to `-Wformat -Wformat-nonliteral
2268 -Wformat-security -Wformat-y2k'.
2271 Warn about passing a null pointer for arguments marked as
2272 requiring a non-null value by the `nonnull' function attribute.
2274 `-Wnonnull' is included in `-Wall' and `-Wformat'. It can be
2275 disabled with the `-Wno-nonnull' option.
2277 `-Winit-self (C, C++, Objective-C and Objective-C++ only)'
2278 Warn about uninitialized variables which are initialized with
2279 themselves. Note this option can only be used with the
2280 `-Wuninitialized' option, which in turn only works with `-O1' and
2283 For example, GCC will warn about `i' being uninitialized in the
2284 following snippet only when `-Winit-self' has been specified:
2292 Warn when a declaration does not specify a type. This warning is
2295 `-Wimplicit-function-declaration'
2296 `-Werror-implicit-function-declaration'
2297 Give a warning (or error) whenever a function is used before being
2298 declared. The form `-Wno-error-implicit-function-declaration' is
2299 not supported. This warning is enabled by `-Wall' (as a warning,
2303 Same as `-Wimplicit-int' and `-Wimplicit-function-declaration'.
2304 This warning is enabled by `-Wall'.
2307 Warn if the type of `main' is suspicious. `main' should be a
2308 function with external linkage, returning int, taking either zero
2309 arguments, two, or three arguments of appropriate types. This
2310 warning is enabled by `-Wall'.
2313 Warn if an aggregate or union initializer is not fully bracketed.
2314 In the following example, the initializer for `a' is not fully
2315 bracketed, but that for `b' is fully bracketed.
2317 int a[2][2] = { 0, 1, 2, 3 };
2318 int b[2][2] = { { 0, 1 }, { 2, 3 } };
2320 This warning is enabled by `-Wall'.
2322 `-Wmissing-include-dirs (C, C++, Objective-C and Objective-C++ only)'
2323 Warn if a user-supplied include directory does not exist.
2326 Warn if parentheses are omitted in certain contexts, such as when
2327 there is an assignment in a context where a truth value is
2328 expected, or when operators are nested whose precedence people
2329 often get confused about. Only the warning for an assignment used
2330 as a truth value is supported when compiling C++; the other
2331 warnings are only supported when compiling C.
2333 Also warn if a comparison like `x<=y<=z' appears; this is
2334 equivalent to `(x<=y ? 1 : 0) <= z', which is a different
2335 interpretation from that of ordinary mathematical notation.
2337 Also warn about constructions where there may be confusion to which
2338 `if' statement an `else' branch belongs. Here is an example of
2349 In C, every `else' branch belongs to the innermost possible `if'
2350 statement, which in this example is `if (b)'. This is often not
2351 what the programmer expected, as illustrated in the above example
2352 by indentation the programmer chose. When there is the potential
2353 for this confusion, GCC will issue a warning when this flag is
2354 specified. To eliminate the warning, add explicit braces around
2355 the innermost `if' statement so there is no way the `else' could
2356 belong to the enclosing `if'. The resulting code would look like
2369 This warning is enabled by `-Wall'.
2372 Warn about code that may have undefined semantics because of
2373 violations of sequence point rules in the C standard.
2375 The C standard defines the order in which expressions in a C
2376 program are evaluated in terms of "sequence points", which
2377 represent a partial ordering between the execution of parts of the
2378 program: those executed before the sequence point, and those
2379 executed after it. These occur after the evaluation of a full
2380 expression (one which is not part of a larger expression), after
2381 the evaluation of the first operand of a `&&', `||', `? :' or `,'
2382 (comma) operator, before a function is called (but after the
2383 evaluation of its arguments and the expression denoting the called
2384 function), and in certain other places. Other than as expressed
2385 by the sequence point rules, the order of evaluation of
2386 subexpressions of an expression is not specified. All these rules
2387 describe only a partial order rather than a total order, since,
2388 for example, if two functions are called within one expression
2389 with no sequence point between them, the order in which the
2390 functions are called is not specified. However, the standards
2391 committee have ruled that function calls do not overlap.
2393 It is not specified when between sequence points modifications to
2394 the values of objects take effect. Programs whose behavior
2395 depends on this have undefined behavior; the C standard specifies
2396 that "Between the previous and next sequence point an object shall
2397 have its stored value modified at most once by the evaluation of
2398 an expression. Furthermore, the prior value shall be read only to
2399 determine the value to be stored.". If a program breaks these
2400 rules, the results on any particular implementation are entirely
2403 Examples of code with undefined behavior are `a = a++;', `a[n] =
2404 b[n++]' and `a[i++] = i;'. Some more complicated cases are not
2405 diagnosed by this option, and it may give an occasional false
2406 positive result, but in general it has been found fairly effective
2407 at detecting this sort of problem in programs.
2409 The present implementation of this option only works for C
2410 programs. A future implementation may also work for C++ programs.
2412 The C standard is worded confusingly, therefore there is some
2413 debate over the precise meaning of the sequence point rules in
2414 subtle cases. Links to discussions of the problem, including
2415 proposed formal definitions, may be found on the GCC readings
2416 page, at `http://gcc.gnu.org/readings.html'.
2418 This warning is enabled by `-Wall'.
2421 Warn whenever a function is defined with a return-type that
2422 defaults to `int'. Also warn about any `return' statement with no
2423 return-value in a function whose return-type is not `void'.
2425 For C, also warn if the return type of a function has a type
2426 qualifier such as `const'. Such a type qualifier has no effect,
2427 since the value returned by a function is not an lvalue. ISO C
2428 prohibits qualified `void' return types on function definitions,
2429 so such return types always receive a warning even without this
2432 For C++, a function without return type always produces a
2433 diagnostic message, even when `-Wno-return-type' is specified.
2434 The only exceptions are `main' and functions defined in system
2437 This warning is enabled by `-Wall'.
2440 Warn whenever a `switch' statement has an index of enumerated type
2441 and lacks a `case' for one or more of the named codes of that
2442 enumeration. (The presence of a `default' label prevents this
2443 warning.) `case' labels outside the enumeration range also
2444 provoke warnings when this option is used. This warning is
2448 Warn whenever a `switch' statement does not have a `default' case.
2451 Warn whenever a `switch' statement has an index of enumerated type
2452 and lacks a `case' for one or more of the named codes of that
2453 enumeration. `case' labels outside the enumeration range also
2454 provoke warnings when this option is used.
2457 Warn if any trigraphs are encountered that might change the
2458 meaning of the program (trigraphs within comments are not warned
2459 about). This warning is enabled by `-Wall'.
2462 Warn whenever a static function is declared but not defined or a
2463 non\-inline static function is unused. This warning is enabled by
2467 Warn whenever a label is declared but not used. This warning is
2470 To suppress this warning use the `unused' attribute (*note
2471 Variable Attributes::).
2473 `-Wunused-parameter'
2474 Warn whenever a function parameter is unused aside from its
2477 To suppress this warning use the `unused' attribute (*note
2478 Variable Attributes::).
2481 Warn whenever a local variable or non-constant static variable is
2482 unused aside from its declaration This warning is enabled by
2485 To suppress this warning use the `unused' attribute (*note
2486 Variable Attributes::).
2489 Warn whenever a statement computes a result that is explicitly not
2490 used. This warning is enabled by `-Wall'.
2492 To suppress this warning cast the expression to `void'.
2495 All the above `-Wunused' options combined.
2497 In order to get a warning about an unused function parameter, you
2498 must either specify `-Wextra -Wunused' (note that `-Wall' implies
2499 `-Wunused'), or separately specify `-Wunused-parameter'.
2502 Warn if an automatic variable is used without first being
2503 initialized or if a variable may be clobbered by a `setjmp' call.
2505 These warnings are possible only in optimizing compilation,
2506 because they require data flow information that is computed only
2507 when optimizing. If you don't specify `-O', you simply won't get
2510 If you want to warn about code which uses the uninitialized value
2511 of the variable in its own initializer, use the `-Winit-self'
2514 These warnings occur only for variables that are candidates for
2515 register allocation. Therefore, they do not occur for a variable
2516 that is declared `volatile', or whose address is taken, or whose
2517 size is other than 1, 2, 4 or 8 bytes. Also, they do not occur for
2518 structures, unions or arrays, even when they are in registers.
2520 Note that there may be no warning about a variable that is used
2521 only to compute a value that itself is never used, because such
2522 computations may be deleted by data flow analysis before the
2523 warnings are printed.
2525 These warnings are made optional because GCC is not smart enough
2526 to see all the reasons why the code might be correct despite
2527 appearing to have an error. Here is one example of how this can
2543 If the value of `y' is always 1, 2 or 3, then `x' is always
2544 initialized, but GCC doesn't know this. Here is another common
2549 if (change_y) save_y = y, y = new_y;
2551 if (change_y) y = save_y;
2554 This has no bug because `save_y' is used only if it is set.
2556 This option also warns when a non-volatile automatic variable
2557 might be changed by a call to `longjmp'. These warnings as well
2558 are possible only in optimizing compilation.
2560 The compiler sees only the calls to `setjmp'. It cannot know
2561 where `longjmp' will be called; in fact, a signal handler could
2562 call it at any point in the code. As a result, you may get a
2563 warning even when there is in fact no problem because `longjmp'
2564 cannot in fact be called at the place which would cause a problem.
2566 Some spurious warnings can be avoided if you declare all the
2567 functions you use that never return as `noreturn'. *Note Function
2570 This warning is enabled by `-Wall'.
2573 Warn when a #pragma directive is encountered which is not
2574 understood by GCC. If this command line option is used, warnings
2575 will even be issued for unknown pragmas in system header files.
2576 This is not the case if the warnings were only enabled by the
2577 `-Wall' command line option.
2580 This option is only active when `-fstrict-aliasing' is active. It
2581 warns about code which might break the strict aliasing rules that
2582 the compiler is using for optimization. The warning does not
2583 catch all cases, but does attempt to catch the more common
2584 pitfalls. It is included in `-Wall'.
2586 `-Wstrict-aliasing=2'
2587 This option is only active when `-fstrict-aliasing' is active. It
2588 warns about all code which might break the strict aliasing rules
2589 that the compiler is using for optimization. This warning catches
2590 all cases, but it will also give a warning for some ambiguous
2591 cases that are safe.
2594 All of the above `-W' options combined. This enables all the
2595 warnings about constructions that some users consider
2596 questionable, and that are easy to avoid (or modify to prevent the
2597 warning), even in conjunction with macros. This also enables some
2598 language-specific warnings described in *Note C++ Dialect
2599 Options:: and *Note Objective-C and Objective-C++ Dialect
2602 The following `-W...' options are not implied by `-Wall'. Some of
2603 them warn about constructions that users generally do not consider
2604 questionable, but which occasionally you might wish to check for;
2605 others warn about constructions that are necessary or hard to avoid in
2606 some cases, and there is no simple way to modify the code to suppress
2610 (This option used to be called `-W'. The older name is still
2611 supported, but the newer name is more descriptive.) Print extra
2612 warning messages for these events:
2614 * A function can return either with or without a value.
2615 (Falling off the end of the function body is considered
2616 returning without a value.) For example, this function would
2617 evoke such a warning:
2625 * An expression-statement or the left-hand side of a comma
2626 expression contains no side effects. To suppress the
2627 warning, cast the unused expression to void. For example, an
2628 expression such as `x[i,j]' will cause a warning, but
2629 `x[(void)i,j]' will not.
2631 * An unsigned value is compared against zero with `<' or `>='.
2633 * Storage-class specifiers like `static' are not the first
2634 things in a declaration. According to the C Standard, this
2635 usage is obsolescent.
2637 * If `-Wall' or `-Wunused' is also specified, warn about unused
2640 * A comparison between signed and unsigned values could produce
2641 an incorrect result when the signed value is converted to
2642 unsigned. (But don't warn if `-Wno-sign-compare' is also
2645 * An aggregate has an initializer which does not initialize all
2646 members. This warning can be independently controlled by
2647 `-Wmissing-field-initializers'.
2649 * A function parameter is declared without a type specifier in
2650 K&R-style functions:
2654 * An empty body occurs in an `if' or `else' statement.
2656 * A pointer is compared against integer zero with `<', `<=',
2659 * A variable might be changed by `longjmp' or `vfork'.
2661 * Any of several floating-point events that often indicate
2662 errors, such as overflow, underflow, loss of precision, etc.
2664 * (C++ only) An enumerator and a non-enumerator both appear in
2665 a conditional expression.
2667 * (C++ only) A non-static reference or non-static `const'
2668 member appears in a class without constructors.
2670 * (C++ only) Ambiguous virtual bases.
2672 * (C++ only) Subscripting an array which has been declared
2675 * (C++ only) Taking the address of a variable which has been
2676 declared `register'.
2678 * (C++ only) A base class is not initialized in a derived
2679 class' copy constructor.
2682 Do not warn about compile-time integer division by zero. Floating
2683 point division by zero is not warned about, as it can be a
2684 legitimate way of obtaining infinities and NaNs.
2687 Print warning messages for constructs found in system header files.
2688 Warnings from system headers are normally suppressed, on the
2689 assumption that they usually do not indicate real problems and
2690 would only make the compiler output harder to read. Using this
2691 command line option tells GCC to emit warnings from system headers
2692 as if they occurred in user code. However, note that using
2693 `-Wall' in conjunction with this option will _not_ warn about
2694 unknown pragmas in system headers--for that, `-Wunknown-pragmas'
2698 Warn if floating point values are used in equality comparisons.
2700 The idea behind this is that sometimes it is convenient (for the
2701 programmer) to consider floating-point values as approximations to
2702 infinitely precise real numbers. If you are doing this, then you
2703 need to compute (by analyzing the code, or in some other way) the
2704 maximum or likely maximum error that the computation introduces,
2705 and allow for it when performing comparisons (and when producing
2706 output, but that's a different problem). In particular, instead
2707 of testing for equality, you would check to see whether the two
2708 values have ranges that overlap; and this is done with the
2709 relational operators, so equality comparisons are probably
2712 `-Wtraditional (C only)'
2713 Warn about certain constructs that behave differently in
2714 traditional and ISO C. Also warn about ISO C constructs that have
2715 no traditional C equivalent, and/or problematic constructs which
2718 * Macro parameters that appear within string literals in the
2719 macro body. In traditional C macro replacement takes place
2720 within string literals, but does not in ISO C.
2722 * In traditional C, some preprocessor directives did not exist.
2723 Traditional preprocessors would only consider a line to be a
2724 directive if the `#' appeared in column 1 on the line.
2725 Therefore `-Wtraditional' warns about directives that
2726 traditional C understands but would ignore because the `#'
2727 does not appear as the first character on the line. It also
2728 suggests you hide directives like `#pragma' not understood by
2729 traditional C by indenting them. Some traditional
2730 implementations would not recognize `#elif', so it suggests
2731 avoiding it altogether.
2733 * A function-like macro that appears without arguments.
2735 * The unary plus operator.
2737 * The `U' integer constant suffix, or the `F' or `L' floating
2738 point constant suffixes. (Traditional C does support the `L'
2739 suffix on integer constants.) Note, these suffixes appear in
2740 macros defined in the system headers of most modern systems,
2741 e.g. the `_MIN'/`_MAX' macros in `<limits.h>'. Use of these
2742 macros in user code might normally lead to spurious warnings,
2743 however GCC's integrated preprocessor has enough context to
2744 avoid warning in these cases.
2746 * A function declared external in one block and then used after
2747 the end of the block.
2749 * A `switch' statement has an operand of type `long'.
2751 * A non-`static' function declaration follows a `static' one.
2752 This construct is not accepted by some traditional C
2755 * The ISO type of an integer constant has a different width or
2756 signedness from its traditional type. This warning is only
2757 issued if the base of the constant is ten. I.e. hexadecimal
2758 or octal values, which typically represent bit patterns, are
2761 * Usage of ISO string concatenation is detected.
2763 * Initialization of automatic aggregates.
2765 * Identifier conflicts with labels. Traditional C lacks a
2766 separate namespace for labels.
2768 * Initialization of unions. If the initializer is zero, the
2769 warning is omitted. This is done under the assumption that
2770 the zero initializer in user code appears conditioned on e.g.
2771 `__STDC__' to avoid missing initializer warnings and relies
2772 on default initialization to zero in the traditional C case.
2774 * Conversions by prototypes between fixed/floating point values
2775 and vice versa. The absence of these prototypes when
2776 compiling with traditional C would cause serious problems.
2777 This is a subset of the possible conversion warnings, for the
2778 full set use `-Wconversion'.
2780 * Use of ISO C style function definitions. This warning
2781 intentionally is _not_ issued for prototype declarations or
2782 variadic functions because these ISO C features will appear
2783 in your code when using libiberty's traditional C
2784 compatibility macros, `PARAMS' and `VPARAMS'. This warning
2785 is also bypassed for nested functions because that feature is
2786 already a GCC extension and thus not relevant to traditional
2789 `-Wdeclaration-after-statement (C only)'
2790 Warn when a declaration is found after a statement in a block.
2791 This construct, known from C++, was introduced with ISO C99 and is
2792 by default allowed in GCC. It is not supported by ISO C90 and was
2793 not supported by GCC versions before GCC 3.0. *Note Mixed
2797 Warn if an undefined identifier is evaluated in an `#if' directive.
2800 Do not warn whenever an `#else' or an `#endif' are followed by
2804 Warn whenever a local variable shadows another local variable,
2805 parameter or global variable or whenever a built-in function is
2809 Warn whenever an object of larger than LEN bytes is defined.
2812 Warn about anything that depends on the "size of" a function type
2813 or of `void'. GNU C assigns these types a size of 1, for
2814 convenience in calculations with `void *' pointers and pointers to
2817 `-Wbad-function-cast (C only)'
2818 Warn whenever a function call is cast to a non-matching type. For
2819 example, warn if `int malloc()' is cast to `anything *'.
2822 Warn whenever a pointer is cast so as to remove a type qualifier
2823 from the target type. For example, warn if a `const char *' is
2824 cast to an ordinary `char *'.
2827 Warn whenever a pointer is cast such that the required alignment
2828 of the target is increased. For example, warn if a `char *' is
2829 cast to an `int *' on machines where integers can only be accessed
2830 at two- or four-byte boundaries.
2833 When compiling C, give string constants the type `const
2834 char[LENGTH]' so that copying the address of one into a
2835 non-`const' `char *' pointer will get a warning; when compiling
2836 C++, warn about the deprecated conversion from string constants to
2837 `char *'. These warnings will help you find at compile time code
2838 that can try to write into a string constant, but only if you have
2839 been very careful about using `const' in declarations and
2840 prototypes. Otherwise, it will just be a nuisance; this is why we
2841 did not make `-Wall' request these warnings.
2844 Warn if a prototype causes a type conversion that is different
2845 from what would happen to the same argument in the absence of a
2846 prototype. This includes conversions of fixed point to floating
2847 and vice versa, and conversions changing the width or signedness
2848 of a fixed point argument except when the same as the default
2851 Also, warn if a negative integer constant expression is implicitly
2852 converted to an unsigned type. For example, warn about the
2853 assignment `x = -1' if `x' is unsigned. But do not warn about
2854 explicit casts like `(unsigned) -1'.
2857 Warn when a comparison between signed and unsigned values could
2858 produce an incorrect result when the signed value is converted to
2859 unsigned. This warning is also enabled by `-Wextra'; to get the
2860 other warnings of `-Wextra' without this warning, use `-Wextra
2863 `-Waggregate-return'
2864 Warn if any functions that return structures or unions are defined
2865 or called. (In languages where you can return an array, this also
2868 `-Wstrict-prototypes (C only)'
2869 Warn if a function is declared or defined without specifying the
2870 argument types. (An old-style function definition is permitted
2871 without a warning if preceded by a declaration which specifies the
2874 `-Wold-style-definition (C only)'
2875 Warn if an old-style function definition is used. A warning is
2876 given even if there is a previous prototype.
2878 `-Wmissing-prototypes (C only)'
2879 Warn if a global function is defined without a previous prototype
2880 declaration. This warning is issued even if the definition itself
2881 provides a prototype. The aim is to detect global functions that
2882 fail to be declared in header files.
2884 `-Wmissing-declarations (C only)'
2885 Warn if a global function is defined without a previous
2886 declaration. Do so even if the definition itself provides a
2887 prototype. Use this option to detect global functions that are
2888 not declared in header files.
2890 `-Wmissing-field-initializers'
2891 Warn if a structure's initializer has some fields missing. For
2892 example, the following code would cause such a warning, because
2893 `x.h' is implicitly zero:
2895 struct s { int f, g, h; };
2896 struct s x = { 3, 4 };
2898 This option does not warn about designated initializers, so the
2899 following modification would not trigger a warning:
2901 struct s { int f, g, h; };
2902 struct s x = { .f = 3, .g = 4 };
2904 This warning is included in `-Wextra'. To get other `-Wextra'
2905 warnings without this one, use `-Wextra
2906 -Wno-missing-field-initializers'.
2908 `-Wmissing-noreturn'
2909 Warn about functions which might be candidates for attribute
2910 `noreturn'. Note these are only possible candidates, not absolute
2911 ones. Care should be taken to manually verify functions actually
2912 do not ever return before adding the `noreturn' attribute,
2913 otherwise subtle code generation bugs could be introduced. You
2914 will not get a warning for `main' in hosted C environments.
2916 `-Wmissing-format-attribute'
2917 If `-Wformat' is enabled, also warn about functions which might be
2918 candidates for `format' attributes. Note these are only possible
2919 candidates, not absolute ones. GCC will guess that `format'
2920 attributes might be appropriate for any function that calls a
2921 function like `vprintf' or `vscanf', but this might not always be
2922 the case, and some functions for which `format' attributes are
2923 appropriate may not be detected. This option has no effect unless
2924 `-Wformat' is enabled (possibly by `-Wall').
2927 Do not warn if a multicharacter constant (`'FOOF'') is used.
2928 Usually they indicate a typo in the user's code, as they have
2929 implementation-defined values, and should not be used in portable
2932 `-Wno-deprecated-declarations'
2933 Do not warn about uses of functions, variables, and types marked as
2934 deprecated by using the `deprecated' attribute. (*note Function
2935 Attributes::, *note Variable Attributes::, *note Type
2939 Warn if a structure is given the packed attribute, but the packed
2940 attribute has no effect on the layout or size of the structure.
2941 Such structures may be mis-aligned for little benefit. For
2942 instance, in this code, the variable `f.x' in `struct bar' will be
2943 misaligned even though `struct bar' does not itself have the
2949 } __attribute__((packed));
2956 Warn if padding is included in a structure, either to align an
2957 element of the structure or to align the whole structure.
2958 Sometimes when this happens it is possible to rearrange the fields
2959 of the structure to reduce the padding and so make the structure
2963 Warn if anything is declared more than once in the same scope,
2964 even in cases where multiple declaration is valid and changes
2967 `-Wnested-externs (C only)'
2968 Warn if an `extern' declaration is encountered within a function.
2970 `-Wunreachable-code'
2971 Warn if the compiler detects that code will never be executed.
2973 This option is intended to warn when the compiler detects that at
2974 least a whole line of source code will never be executed, because
2975 some condition is never satisfied or because it is after a
2976 procedure that never returns.
2978 It is possible for this option to produce a warning even though
2979 there are circumstances under which part of the affected line can
2980 be executed, so care should be taken when removing
2981 apparently-unreachable code.
2983 For instance, when a function is inlined, a warning may mean that
2984 the line is unreachable in only one inlined copy of the function.
2986 This option is not made part of `-Wall' because in a debugging
2987 version of a program there is often substantial code which checks
2988 correct functioning of the program and is, hopefully, unreachable
2989 because the program does work. Another common use of unreachable
2990 code is to provide behavior which is selectable at compile-time.
2993 Warn if a function can not be inlined and it was declared as
2994 inline. Even with this option, the compiler will not warn about
2995 failures to inline functions declared in system headers.
2997 The compiler uses a variety of heuristics to determine whether or
2998 not to inline a function. For example, the compiler takes into
2999 account the size of the function being inlined and the amount of
3000 inlining that has already been done in the current function.
3001 Therefore, seemingly insignificant changes in the source program
3002 can cause the warnings produced by `-Winline' to appear or
3005 `-Wno-invalid-offsetof (C++ only)'
3006 Suppress warnings from applying the `offsetof' macro to a non-POD
3007 type. According to the 1998 ISO C++ standard, applying `offsetof'
3008 to a non-POD type is undefined. In existing C++ implementations,
3009 however, `offsetof' typically gives meaningful results even when
3010 applied to certain kinds of non-POD types. (Such as a simple
3011 `struct' that fails to be a POD type only by virtue of having a
3012 constructor.) This flag is for users who are aware that they are
3013 writing nonportable code and who have deliberately chosen to
3014 ignore the warning about it.
3016 The restrictions on `offsetof' may be relaxed in a future version
3017 of the C++ standard.
3020 Warn if a precompiled header (*note Precompiled Headers::) is
3021 found in the search path but can't be used.
3024 Warn if `long long' type is used. This is default. To inhibit
3025 the warning messages, use `-Wno-long-long'. Flags `-Wlong-long'
3026 and `-Wno-long-long' are taken into account only when `-pedantic'
3030 Warn if variadic macros are used in pedantic ISO C90 mode, or the
3031 GNU alternate syntax when in pedantic ISO C99 mode. This is
3032 default. To inhibit the warning messages, use
3033 `-Wno-variadic-macros'.
3035 `-Wdisabled-optimization'
3036 Warn if a requested optimization pass is disabled. This warning
3037 does not generally indicate that there is anything wrong with your
3038 code; it merely indicates that GCC's optimizers were unable to
3039 handle the code effectively. Often, the problem is that your code
3040 is too big or too complex; GCC will refuse to optimize programs
3041 when the optimization itself is likely to take inordinate amounts
3045 Don't warn for pointer argument passing or assignment with
3046 different signedness. Only useful in the negative form since this
3047 warning is enabled by default. This option is only supported for
3051 Make all warnings into errors.
3054 File: gcc.info, Node: Debugging Options, Next: Optimize Options, Prev: Warning Options, Up: Invoking GCC
3056 3.9 Options for Debugging Your Program or GCC
3057 =============================================
3059 GCC has various special options that are used for debugging either your
3063 Produce debugging information in the operating system's native
3064 format (stabs, COFF, XCOFF, or DWARF 2). GDB can work with this
3065 debugging information.
3067 On most systems that use stabs format, `-g' enables use of extra
3068 debugging information that only GDB can use; this extra information
3069 makes debugging work better in GDB but will probably make other
3070 debuggers crash or refuse to read the program. If you want to
3071 control for certain whether to generate the extra information, use
3072 `-gstabs+', `-gstabs', `-gxcoff+', `-gxcoff', or `-gvms' (see
3075 GCC allows you to use `-g' with `-O'. The shortcuts taken by
3076 optimized code may occasionally produce surprising results: some
3077 variables you declared may not exist at all; flow of control may
3078 briefly move where you did not expect it; some statements may not
3079 be executed because they compute constant results or their values
3080 were already at hand; some statements may execute in different
3081 places because they were moved out of loops.
3083 Nevertheless it proves possible to debug optimized output. This
3084 makes it reasonable to use the optimizer for programs that might
3087 The following options are useful when GCC is generated with the
3088 capability for more than one debugging format.
3091 Produce debugging information for use by GDB. This means to use
3092 the most expressive format available (DWARF 2, stabs, or the
3093 native format if neither of those are supported), including GDB
3094 extensions if at all possible.
3097 Produce debugging information in stabs format (if that is
3098 supported), without GDB extensions. This is the format used by
3099 DBX on most BSD systems. On MIPS, Alpha and System V Release 4
3100 systems this option produces stabs debugging output which is not
3101 understood by DBX or SDB. On System V Release 4 systems this
3102 option requires the GNU assembler.
3104 `-feliminate-unused-debug-symbols'
3105 Produce debugging information in stabs format (if that is
3106 supported), for only symbols that are actually used.
3109 Produce debugging information in stabs format (if that is
3110 supported), using GNU extensions understood only by the GNU
3111 debugger (GDB). The use of these extensions is likely to make
3112 other debuggers crash or refuse to read the program.
3115 Produce debugging information in COFF format (if that is
3116 supported). This is the format used by SDB on most System V
3117 systems prior to System V Release 4.
3120 Produce debugging information in XCOFF format (if that is
3121 supported). This is the format used by the DBX debugger on IBM
3125 Produce debugging information in XCOFF format (if that is
3126 supported), using GNU extensions understood only by the GNU
3127 debugger (GDB). The use of these extensions is likely to make
3128 other debuggers crash or refuse to read the program, and may cause
3129 assemblers other than the GNU assembler (GAS) to fail with an
3133 Produce debugging information in DWARF version 2 format (if that is
3134 supported). This is the format used by DBX on IRIX 6. With this
3135 option, GCC uses features of DWARF version 3 when they are useful;
3136 version 3 is upward compatible with version 2, but may still cause
3137 problems for older debuggers.
3140 Produce debugging information in VMS debug format (if that is
3141 supported). This is the format used by DEBUG on VMS systems.
3149 Request debugging information and also use LEVEL to specify how
3150 much information. The default level is 2.
3152 Level 1 produces minimal information, enough for making backtraces
3153 in parts of the program that you don't plan to debug. This
3154 includes descriptions of functions and external variables, but no
3155 information about local variables and no line numbers.
3157 Level 3 includes extra information, such as all the macro
3158 definitions present in the program. Some debuggers support macro
3159 expansion when you use `-g3'.
3161 `-gdwarf-2' does not accept a concatenated debug level, because
3162 GCC used to support an option `-gdwarf' that meant to generate
3163 debug information in version 1 of the DWARF format (which is very
3164 different from version 2), and it would have been too confusing.
3165 That debug format is long obsolete, but the option cannot be
3166 changed now. Instead use an additional `-gLEVEL' option to change
3167 the debug level for DWARF2.
3169 `-feliminate-dwarf2-dups'
3170 Compress DWARF2 debugging information by eliminating duplicated
3171 information about each symbol. This option only makes sense when
3172 generating DWARF2 debugging information with `-gdwarf-2'.
3175 Generate extra code to write profile information suitable for the
3176 analysis program `prof'. You must use this option when compiling
3177 the source files you want data about, and you must also use it when
3181 Generate extra code to write profile information suitable for the
3182 analysis program `gprof'. You must use this option when compiling
3183 the source files you want data about, and you must also use it when
3187 Makes the compiler print out each function name as it is compiled,
3188 and print some statistics about each pass when it finishes.
3191 Makes the compiler print some statistics about the time consumed
3192 by each pass when it finishes.
3195 Makes the compiler print some statistics about permanent memory
3196 allocation when it finishes.
3199 Add code so that program flow "arcs" are instrumented. During
3200 execution the program records how many times each branch and call
3201 is executed and how many times it is taken or returns. When the
3202 compiled program exits it saves this data to a file called
3203 `AUXNAME.gcda' for each source file. The data may be used for
3204 profile-directed optimizations (`-fbranch-probabilities'), or for
3205 test coverage analysis (`-ftest-coverage'). Each object file's
3206 AUXNAME is generated from the name of the output file, if
3207 explicitly specified and it is not the final executable, otherwise
3208 it is the basename of the source file. In both cases any suffix
3209 is removed (e.g. `foo.gcda' for input file `dir/foo.c', or
3210 `dir/foo.gcda' for output file specified as `-o dir/foo.o').
3212 * Compile the source files with `-fprofile-arcs' plus
3213 optimization and code generation options. For test coverage
3214 analysis, use the additional `-ftest-coverage' option. You
3215 do not need to profile every source file in a program.
3217 * Link your object files with `-lgcov' or `-fprofile-arcs' (the
3218 latter implies the former).
3220 * Run the program on a representative workload to generate the
3221 arc profile information. This may be repeated any number of
3222 times. You can run concurrent instances of your program, and
3223 provided that the file system supports locking, the data
3224 files will be correctly updated. Also `fork' calls are
3225 detected and correctly handled (double counting will not
3228 * For profile-directed optimizations, compile the source files
3229 again with the same optimization and code generation options
3230 plus `-fbranch-probabilities' (*note Options that Control
3231 Optimization: Optimize Options.).
3233 * For test coverage analysis, use `gcov' to produce human
3234 readable information from the `.gcno' and `.gcda' files.
3235 Refer to the `gcov' documentation for further information.
3238 With `-fprofile-arcs', for each function of your program GCC
3239 creates a program flow graph, then finds a spanning tree for the
3240 graph. Only arcs that are not on the spanning tree have to be
3241 instrumented: the compiler adds code to count the number of times
3242 that these arcs are executed. When an arc is the only exit or
3243 only entrance to a block, the instrumentation code can be added to
3244 the block; otherwise, a new basic block must be created to hold
3245 the instrumentation code.
3247 `-ftree-based-profiling'
3248 This option is used in addition to `-fprofile-arcs' or
3249 `-fbranch-probabilities' to control whether those optimizations
3250 are performed on a tree-based or rtl-based internal representation.
3251 If you use this option when compiling with `-fprofile-arcs', you
3252 must also use it when compiling later with
3253 `-fbranch-probabilities'. Currently the tree-based optimization
3254 is in an early stage of development, and this option is
3255 recommended only for those people working on improving it.
3258 Produce a notes file that the `gcov' code-coverage utility (*note
3259 `gcov'--a Test Coverage Program: Gcov.) can use to show program
3260 coverage. Each source file's note file is called `AUXNAME.gcno'.
3261 Refer to the `-fprofile-arcs' option above for a description of
3262 AUXNAME and instructions on how to generate test coverage data.
3263 Coverage data will match the source files more closely, if you do
3269 Says to make debugging dumps during compilation at times specified
3270 by LETTERS. This is used for debugging the RTL-based passes of
3271 the compiler. The file names for most of the dumps are made by
3272 appending a pass number and a word to the DUMPNAME. DUMPNAME is
3273 generated from the name of the output file, if explicitly
3274 specified and it is not an executable, otherwise it is the
3275 basename of the source file.
3277 Most debug dumps can be enabled either passing a letter to the `-d'
3278 option, or with a long `-fdump-rtl' switch; here are the possible
3279 letters for use in LETTERS and PASS, and their meanings:
3282 Annotate the assembler output with miscellaneous debugging
3287 Dump after computing branch probabilities, to `FILE.09.bp'.
3291 Dump after block reordering, to `FILE.30.bbro'.
3294 `-fdump-rtl-combine'
3295 Dump after instruction combination, to the file
3301 `-dC' and `-fdump-rtl-ce1' enable dumping after the first if
3302 conversion, to the file `FILE.11.ce1'. `-dC' and
3303 `-fdump-rtl-ce2' enable dumping after the second if
3304 conversion, to the file `FILE.18.ce2'.
3309 `-dd' and `-fdump-rtl-btl' enable dumping after branch target
3310 load optimization, to `FILE.31.btl'. `-dd' and
3311 `-fdump-rtl-dbr' enable dumping after delayed branch
3312 scheduling, to `FILE.36.dbr'.
3315 Dump all macro definitions, at the end of preprocessing, in
3316 addition to normal output.
3320 Dump after the third if conversion, to `FILE.28.ce3'.
3325 `-df' and `-fdump-rtl-cfg' enable dumping after control and
3326 data flow analysis, to `FILE.08.cfg'. `-df' and
3327 `-fdump-rtl-cfg' enable dumping dump after life analysis, to
3332 Dump after global register allocation, to `FILE.23.greg'.
3337 `-dG' and `-fdump-rtl-gcse' enable dumping after GCSE, to
3338 `FILE.05.gcse'. `-dG' and `-fdump-rtl-bypass' enable dumping
3339 after jump bypassing and control flow optimizations, to
3344 Dump after finalization of EH handling code, to `FILE.02.eh'.
3347 `-fdump-rtl-sibling'
3348 Dump after sibling call optimizations, to `FILE.01.sibling'.
3352 Dump after the first jump optimization, to `FILE.03.jump'.
3356 Dump after conversion from registers to stack, to
3361 Dump after local register allocation, to `FILE.22.lreg'.
3366 `-dL' and `-fdump-rtl-loop' enable dumping after the first
3367 loop optimization pass, to `FILE.06.loop'. `-dL' and
3368 `-fdump-rtl-loop2' enable dumping after the second pass, to
3373 Dump after modulo scheduling, to `FILE.20.sms'.
3377 Dump after performing the machine dependent reorganization
3378 pass, to `FILE.35.mach'.
3382 Dump after register renumbering, to `FILE.29.rnreg'.
3385 `-fdump-rtl-regmove'
3386 Dump after the register move pass, to `FILE.19.regmove'.
3389 `-fdump-rtl-postreload'
3390 Dump after post-reload optimizations, to `FILE.24.postreload'.
3394 Dump after RTL generation, to `FILE.00.expand'.
3398 Dump after the second scheduling pass, to `FILE.32.sched2'.
3402 Dump after CSE (including the jump optimization that
3403 sometimes follows CSE), to `FILE.04.cse'.
3407 Dump after the first scheduling pass, to `FILE.21.sched'.
3411 Dump after the second CSE pass (including the jump
3412 optimization that sometimes follows CSE), to `FILE.15.cse2'.
3416 Dump after running tracer, to `FILE.12.tracer'.
3420 `-fdump-rtl-vartrack'
3421 `-dV' and `-fdump-rtl-vpt' enable dumping after the value
3422 profile transformations, to `FILE.10.vpt'. `-dV' and
3423 `-fdump-rtl-vartrack' enable dumping after variable tracking,
3424 to `FILE.34.vartrack'.
3428 Dump after the second flow pass, to `FILE.26.flow2'.
3431 `-fdump-rtl-peephole2'
3432 Dump after the peephole pass, to `FILE.27.peephole2'.
3436 Dump after live range splitting, to `FILE.14.web'.
3440 Produce all the dumps listed above.
3443 Produce a core dump whenever an error occurs.
3446 Print statistics on memory usage, at the end of the run, to
3450 Annotate the assembler output with a comment indicating which
3451 pattern and alternative was used. The length of each
3452 instruction is also printed.
3455 Dump the RTL in the assembler output as a comment before each
3456 instruction. Also turns on `-dp' annotation.
3459 For each of the other indicated dump files (either with `-d'
3460 or `-fdump-rtl-PASS'), dump a representation of the control
3461 flow graph suitable for viewing with VCG to `FILE.PASS.vcg'.
3464 Just generate RTL for a function instead of compiling it.
3465 Usually used with `r' (`-fdump-rtl-expand').
3468 Dump debugging information during parsing, to standard error.
3471 When doing debugging dumps (see `-d' option above), suppress
3472 instruction numbers and line number note output. This makes it
3473 more feasible to use diff on debugging dumps for compiler
3474 invocations with different options, in particular with and without
3477 `-fdump-translation-unit (C and C++ only)'
3478 `-fdump-translation-unit-OPTIONS (C and C++ only)'
3479 Dump a representation of the tree structure for the entire
3480 translation unit to a file. The file name is made by appending
3481 `.tu' to the source file name. If the `-OPTIONS' form is used,
3482 OPTIONS controls the details of the dump as described for the
3483 `-fdump-tree' options.
3485 `-fdump-class-hierarchy (C++ only)'
3486 `-fdump-class-hierarchy-OPTIONS (C++ only)'
3487 Dump a representation of each class's hierarchy and virtual
3488 function table layout to a file. The file name is made by
3489 appending `.class' to the source file name. If the `-OPTIONS'
3490 form is used, OPTIONS controls the details of the dump as
3491 described for the `-fdump-tree' options.
3494 Control the dumping at various stages of inter-procedural analysis
3495 language tree to a file. The file name is generated by appending
3496 a switch specific suffix to the source file name. The following
3500 Enables all inter-procedural analysis dumps; currently the
3501 only produced dump is the `cgraph' dump.
3504 Dumps information about call-graph optimization, unused
3505 function removal, and inlining decisions.
3507 `-fdump-tree-SWITCH (C and C++ only)'
3508 `-fdump-tree-SWITCH-OPTIONS (C and C++ only)'
3509 Control the dumping at various stages of processing the
3510 intermediate language tree to a file. The file name is generated
3511 by appending a switch specific suffix to the source file name. If
3512 the `-OPTIONS' form is used, OPTIONS is a list of `-' separated
3513 options that control the details of the dump. Not all options are
3514 applicable to all dumps, those which are not meaningful will be
3515 ignored. The following options are available
3518 Print the address of each node. Usually this is not
3519 meaningful as it changes according to the environment and
3520 source file. Its primary use is for tying up a dump file
3521 with a debug environment.
3524 Inhibit dumping of members of a scope or body of a function
3525 merely because that scope has been reached. Only dump such
3526 items when they are directly reachable by some other path.
3527 When dumping pretty-printed trees, this option inhibits
3528 dumping the bodies of control structures.
3531 Print a raw representation of the tree. By default, trees are
3532 pretty-printed into a C-like representation.
3535 Enable more detailed dumps (not honored by every dump option).
3538 Enable dumping various statistics about the pass (not honored
3539 by every dump option).
3542 Enable showing basic block boundaries (disabled in raw dumps).
3545 Enable showing virtual operands for every statement.
3548 Enable showing line numbers for statements.
3551 Enable showing the unique ID (`DECL_UID') for each variable.
3554 Turn on all options, except `raw', `slim' and `lineno'.
3556 The following tree dumps are possible:
3558 Dump before any tree based optimization, to `FILE.original'.
3561 Dump after all tree based optimization, to `FILE.optimized'.
3564 Dump after function inlining, to `FILE.inlined'.
3567 Dump each function before and after the gimplification pass
3568 to a file. The file name is made by appending `.gimple' to
3569 the source file name.
3572 Dump the control flow graph of each function to a file. The
3573 file name is made by appending `.cfg' to the source file name.
3576 Dump the control flow graph of each function to a file in VCG
3577 format. The file name is made by appending `.vcg' to the
3578 source file name. Note that if the file contains more than
3579 one function, the generated file cannot be used directly by
3580 VCG. You will need to cut and paste each function's graph
3581 into its own separate file first.
3584 Dump each function after copying loop headers. The file name
3585 is made by appending `.ch' to the source file name.
3588 Dump SSA related information to a file. The file name is
3589 made by appending `.ssa' to the source file name.
3592 Dump aliasing information for each function. The file name
3593 is made by appending `.alias' to the source file name.
3596 Dump each function after CCP. The file name is made by
3597 appending `.ccp' to the source file name.
3600 Dump trees after partial redundancy elimination. The file
3601 name is made by appending `.pre' to the source file name.
3604 Dump trees after full redundancy elimination. The file name
3605 is made by appending `.fre' to the source file name.
3608 Dump each function after dead code elimination. The file
3609 name is made by appending `.dce' to the source file name.
3612 Dump each function after adding mudflap instrumentation. The
3613 file name is made by appending `.mudflap' to the source file
3617 Dump each function after performing scalar replacement of
3618 aggregates. The file name is made by appending `.sra' to the
3622 Dump each function after applying dominator tree
3623 optimizations. The file name is made by appending `.dom' to
3624 the source file name.
3627 Dump each function after applying dead store elimination.
3628 The file name is made by appending `.dse' to the source file
3632 Dump each function after optimizing PHI nodes into
3633 straightline code. The file name is made by appending
3634 `.phiopt' to the source file name.
3637 Dump each function after forward propagating single use
3638 variables. The file name is made by appending `.forwprop' to
3639 the source file name.
3642 Dump each function after applying the copy rename
3643 optimization. The file name is made by appending
3644 `.copyrename' to the source file name.
3647 Dump each function after applying the named return value
3648 optimization on generic trees. The file name is made by
3649 appending `.nrv' to the source file name.
3652 Dump each function after applying vectorization of loops.
3653 The file name is made by appending `.vect' to the source file
3657 Enable all the available tree dumps with the flags provided
3660 `-ftree-vectorizer-verbose=N'
3661 This option controls the amount of debugging output the vectorizer
3662 prints. This information is written to standard error, unless
3663 `-fdump-tree-all' or `-fdump-tree-vect' is specified, in which
3664 case it is output to the usual dump listing file, `.vect'.
3666 `-frandom-seed=STRING'
3667 This option provides a seed that GCC uses when it would otherwise
3668 use random numbers. It is used to generate certain symbol names
3669 that have to be different in every compiled file. It is also used
3670 to place unique stamps in coverage data files and the object files
3671 that produce them. You can use the `-frandom-seed' option to
3672 produce reproducibly identical object files.
3674 The STRING should be different for every file you compile.
3677 On targets that use instruction scheduling, this option controls
3678 the amount of debugging output the scheduler prints. This
3679 information is written to standard error, unless `-dS' or `-dR' is
3680 specified, in which case it is output to the usual dump listing
3681 file, `.sched' or `.sched2' respectively. However for N greater
3682 than nine, the output is always printed to standard error.
3684 For N greater than zero, `-fsched-verbose' outputs the same
3685 information as `-dRS'. For N greater than one, it also output
3686 basic block probabilities, detailed ready list information and
3687 unit/insn info. For N greater than two, it includes RTL at abort
3688 point, control-flow and regions info. And for N over four,
3689 `-fsched-verbose' also includes dependence info.
3692 Store the usual "temporary" intermediate files permanently; place
3693 them in the current directory and name them based on the source
3694 file. Thus, compiling `foo.c' with `-c -save-temps' would produce
3695 files `foo.i' and `foo.s', as well as `foo.o'. This creates a
3696 preprocessed `foo.i' output file even though the compiler now
3697 normally uses an integrated preprocessor.
3699 When used in combination with the `-x' command line option,
3700 `-save-temps' is sensible enough to avoid over writing an input
3701 source file with the same extension as an intermediate file. The
3702 corresponding intermediate file may be obtained by renaming the
3703 source file before using `-save-temps'.
3706 Report the CPU time taken by each subprocess in the compilation
3707 sequence. For C source files, this is the compiler proper and
3708 assembler (plus the linker if linking is done). The output looks
3714 The first number on each line is the "user time", that is time
3715 spent executing the program itself. The second number is "system
3716 time", time spent executing operating system routines on behalf of
3717 the program. Both numbers are in seconds.
3720 Run variable tracking pass. It computes where variables are
3721 stored at each position in code. Better debugging information is
3722 then generated (if the debugging information format supports this
3725 It is enabled by default when compiling with optimization (`-Os',
3726 `-O', `-O2', ...), debugging information (`-g') and the debug info
3729 `-print-file-name=LIBRARY'
3730 Print the full absolute name of the library file LIBRARY that
3731 would be used when linking--and don't do anything else. With this
3732 option, GCC does not compile or link anything; it just prints the
3735 `-print-multi-directory'
3736 Print the directory name corresponding to the multilib selected by
3737 any other switches present in the command line. This directory is
3738 supposed to exist in `GCC_EXEC_PREFIX'.
3741 Print the mapping from multilib directory names to compiler
3742 switches that enable them. The directory name is separated from
3743 the switches by `;', and each switch starts with an `@' instead of
3744 the `-', without spaces between multiple switches. This is
3745 supposed to ease shell-processing.
3747 `-print-prog-name=PROGRAM'
3748 Like `-print-file-name', but searches for a program such as `cpp'.
3750 `-print-libgcc-file-name'
3751 Same as `-print-file-name=libgcc.a'.
3753 This is useful when you use `-nostdlib' or `-nodefaultlibs' but
3754 you do want to link with `libgcc.a'. You can do
3756 gcc -nostdlib FILES... `gcc -print-libgcc-file-name`
3758 `-print-search-dirs'
3759 Print the name of the configured installation directory and a list
3760 of program and library directories `gcc' will search--and don't do
3763 This is useful when `gcc' prints the error message `installation
3764 problem, cannot exec cpp0: No such file or directory'. To resolve
3765 this you either need to put `cpp0' and the other compiler
3766 components where `gcc' expects to find them, or you can set the
3767 environment variable `GCC_EXEC_PREFIX' to the directory where you
3768 installed them. Don't forget the trailing `/'. *Note Environment
3772 Print the compiler's target machine (for example,
3773 `i686-pc-linux-gnu')--and don't do anything else.
3776 Print the compiler version (for example, `3.0')--and don't do
3780 Print the compiler's built-in specs--and don't do anything else.
3781 (This is used when GCC itself is being built.) *Note Spec Files::.
3783 `-feliminate-unused-debug-types'
3784 Normally, when producing DWARF2 output, GCC will emit debugging
3785 information for all types declared in a compilation unit,
3786 regardless of whether or not they are actually used in that
3787 compilation unit. Sometimes this is useful, such as if, in the
3788 debugger, you want to cast a value to a type that is not actually
3789 used in your program (but is declared). More often, however, this
3790 results in a significant amount of wasted space. With this
3791 option, GCC will avoid producing debug symbol output for types
3792 that are nowhere used in the source file being compiled.
3795 File: gcc.info, Node: Optimize Options, Next: Preprocessor Options, Prev: Debugging Options, Up: Invoking GCC
3797 3.10 Options That Control Optimization
3798 ======================================
3800 These options control various sorts of optimizations.
3802 Without any optimization option, the compiler's goal is to reduce the
3803 cost of compilation and to make debugging produce the expected results.
3804 Statements are independent: if you stop the program with a breakpoint
3805 between statements, you can then assign a new value to any variable or
3806 change the program counter to any other statement in the function and
3807 get exactly the results you would expect from the source code.
3809 Turning on optimization flags makes the compiler attempt to improve
3810 the performance and/or code size at the expense of compilation time and
3811 possibly the ability to debug the program.
3813 The compiler performs optimization based on the knowledge it has of
3814 the program. Optimization levels `-O2' and above, in particular,
3815 enable _unit-at-a-time_ mode, which allows the compiler to consider
3816 information gained from later functions in the file when compiling a
3817 function. Compiling multiple files at once to a single output file in
3818 _unit-at-a-time_ mode allows the compiler to use information gained
3819 from all of the files when compiling each of them.
3821 Not all optimizations are controlled directly by a flag. Only
3822 optimizations that have a flag are listed.
3826 Optimize. Optimizing compilation takes somewhat more time, and a
3827 lot more memory for a large function.
3829 With `-O', the compiler tries to reduce code size and execution
3830 time, without performing any optimizations that take a great deal
3831 of compilation time.
3833 `-O' turns on the following optimization flags:
3836 -fguess-branch-probability
3843 -ftree-dominator-opts
3853 `-O' also turns on `-fomit-frame-pointer' on machines where doing
3854 so does not interfere with debugging.
3856 `-O' doesn't turn on `-ftree-sra' for the Ada compiler. This
3857 option must be explicitly specified on the command line to be
3858 enabled for the Ada compiler.
3861 Optimize even more. GCC performs nearly all supported
3862 optimizations that do not involve a space-speed tradeoff. The
3863 compiler does not perform loop unrolling or function inlining when
3864 you specify `-O2'. As compared to `-O', this option increases
3865 both compilation time and the performance of the generated code.
3867 `-O2' turns on all optimization flags specified by `-O'. It also
3868 turns on the following optimization flags:
3871 -foptimize-sibling-calls
3872 -fcse-follow-jumps -fcse-skip-blocks
3874 -fexpensive-optimizations
3876 -frerun-cse-after-loop -frerun-loop-opt
3880 -fschedule-insns -fschedule-insns2
3881 -fsched-interblock -fsched-spec
3884 -fdelete-null-pointer-checks
3885 -freorder-blocks -freorder-functions
3887 -falign-functions -falign-jumps
3888 -falign-loops -falign-labels
3891 Please note the warning under `-fgcse' about invoking `-O2' on
3892 programs that use computed gotos.
3895 Optimize yet more. `-O3' turns on all optimizations specified by
3896 `-O2' and also turns on the `-finline-functions',
3897 `-funswitch-loops' and `-fgcse-after-reload' options.
3900 Do not optimize. This is the default.
3903 Optimize for size. `-Os' enables all `-O2' optimizations that do
3904 not typically increase code size. It also performs further
3905 optimizations designed to reduce code size.
3907 `-Os' disables the following optimization flags:
3908 -falign-functions -falign-jumps -falign-loops
3909 -falign-labels -freorder-blocks -freorder-blocks-and-partition -fprefetch-loop-arrays
3911 If you use multiple `-O' options, with or without level numbers,
3912 the last such option is the one that is effective.
3914 Options of the form `-fFLAG' specify machine-independent flags. Most
3915 flags have both positive and negative forms; the negative form of
3916 `-ffoo' would be `-fno-foo'. In the table below, only one of the forms
3917 is listed--the one you typically will use. You can figure out the
3918 other form by either removing `no-' or adding it.
3920 The following options control specific optimizations. They are either
3921 activated by `-O' options or are related to ones that are. You can use
3922 the following flags in the rare cases when "fine-tuning" of
3923 optimizations to be performed is desired.
3925 `-fno-default-inline'
3926 Do not make member functions inline by default merely because they
3927 are defined inside the class scope (C++ only). Otherwise, when
3928 you specify `-O', member functions defined inside class scope are
3929 compiled inline by default; i.e., you don't need to add `inline'
3930 in front of the member function name.
3933 Always pop the arguments to each function call as soon as that
3934 function returns. For machines which must pop arguments after a
3935 function call, the compiler normally lets arguments accumulate on
3936 the stack for several function calls and pops them all at once.
3938 Disabled at levels `-O', `-O2', `-O3', `-Os'.
3941 Force memory operands to be copied into registers before doing
3942 arithmetic on them. This produces better code by making all memory
3943 references potential common subexpressions. When they are not
3944 common subexpressions, instruction combination should eliminate
3945 the separate register-load.
3947 Enabled at levels `-O2', `-O3', `-Os'.
3950 Force memory address constants to be copied into registers before
3951 doing arithmetic on them. This may produce better code just as
3954 `-fomit-frame-pointer'
3955 Don't keep the frame pointer in a register for functions that
3956 don't need one. This avoids the instructions to save, set up and
3957 restore frame pointers; it also makes an extra register available
3958 in many functions. *It also makes debugging impossible on some
3961 On some machines, such as the VAX, this flag has no effect, because
3962 the standard calling sequence automatically handles the frame
3963 pointer and nothing is saved by pretending it doesn't exist. The
3964 machine-description macro `FRAME_POINTER_REQUIRED' controls
3965 whether a target machine supports this flag. *Note Register
3966 Usage: (gccint)Registers.
3968 Enabled at levels `-O', `-O2', `-O3', `-Os'.
3970 `-foptimize-sibling-calls'
3971 Optimize sibling and tail recursive calls.
3973 Enabled at levels `-O2', `-O3', `-Os'.
3976 Don't pay attention to the `inline' keyword. Normally this option
3977 is used to keep the compiler from expanding any functions inline.
3978 Note that if you are not optimizing, no functions can be expanded
3981 `-finline-functions'
3982 Integrate all simple functions into their callers. The compiler
3983 heuristically decides which functions are simple enough to be worth
3984 integrating in this way.
3986 If all calls to a given function are integrated, and the function
3987 is declared `static', then the function is normally not output as
3988 assembler code in its own right.
3990 Enabled at level `-O3'.
3993 By default, GCC limits the size of functions that can be inlined.
3994 This flag allows the control of this limit for functions that are
3995 explicitly marked as inline (i.e., marked with the inline keyword
3996 or defined within the class definition in c++). N is the size of
3997 functions that can be inlined in number of pseudo instructions
3998 (not counting parameter handling). The default value of N is 600.
3999 Increasing this value can result in more inlined code at the cost
4000 of compilation time and memory consumption. Decreasing usually
4001 makes the compilation faster and less code will be inlined (which
4002 presumably means slower programs). This option is particularly
4003 useful for programs that use inlining heavily such as those based
4004 on recursive templates with C++.
4006 Inlining is actually controlled by a number of parameters, which
4007 may be specified individually by using `--param NAME=VALUE'. The
4008 `-finline-limit=N' option sets some of these parameters as follows:
4010 `max-inline-insns-single'
4013 `max-inline-insns-auto'
4017 is set to 130 or N/4, whichever is smaller.
4019 `max-inline-insns-rtl'
4022 See below for a documentation of the individual parameters
4023 controlling inlining.
4025 _Note:_ pseudo instruction represents, in this particular context,
4026 an abstract measurement of function's size. In no way, it
4027 represents a count of assembly instructions and as such its exact
4028 meaning might change from one release to an another.
4030 `-fkeep-inline-functions'
4031 In C, emit `static' functions that are declared `inline' into the
4032 object file, even if the function has been inlined into all of its
4033 callers. This switch does not affect functions using the `extern
4034 inline' extension in GNU C. In C++, emit any and all inline
4035 functions into the object file.
4037 `-fkeep-static-consts'
4038 Emit variables declared `static const' when optimization isn't
4039 turned on, even if the variables aren't referenced.
4041 GCC enables this option by default. If you want to force the
4042 compiler to check if the variable was referenced, regardless of
4043 whether or not optimization is turned on, use the
4044 `-fno-keep-static-consts' option.
4047 Attempt to merge identical constants (string constants and
4048 floating point constants) across compilation units.
4050 This option is the default for optimized compilation if the
4051 assembler and linker support it. Use `-fno-merge-constants' to
4052 inhibit this behavior.
4054 Enabled at levels `-O', `-O2', `-O3', `-Os'.
4056 `-fmerge-all-constants'
4057 Attempt to merge identical constants and identical variables.
4059 This option implies `-fmerge-constants'. In addition to
4060 `-fmerge-constants' this considers e.g. even constant initialized
4061 arrays or initialized constant variables with integral or floating
4062 point types. Languages like C or C++ require each non-automatic
4063 variable to have distinct location, so using this option will
4064 result in non-conforming behavior.
4067 Perform swing modulo scheduling immediately before the first
4068 scheduling pass. This pass looks at innermost loops and reorders
4069 their instructions by overlapping different iterations.
4071 `-fno-branch-count-reg'
4072 Do not use "decrement and branch" instructions on a count register,
4073 but instead generate a sequence of instructions that decrement a
4074 register, compare it against zero, then branch based upon the
4075 result. This option is only meaningful on architectures that
4076 support such instructions, which include x86, PowerPC, IA-64 and
4079 The default is `-fbranch-count-reg', enabled when
4080 `-fstrength-reduce' is enabled.
4083 Do not put function addresses in registers; make each instruction
4084 that calls a constant function contain the function's address
4087 This option results in less efficient code, but some strange hacks
4088 that alter the assembler output may be confused by the
4089 optimizations performed when this option is not used.
4091 The default is `-ffunction-cse'
4093 `-fno-zero-initialized-in-bss'
4094 If the target supports a BSS section, GCC by default puts
4095 variables that are initialized to zero into BSS. This can save
4096 space in the resulting code.
4098 This option turns off this behavior because some programs
4099 explicitly rely on variables going to the data section. E.g., so
4100 that the resulting executable can find the beginning of that
4101 section and/or make assumptions based on that.
4103 The default is `-fzero-initialized-in-bss'.
4106 For front-ends that support it, generate additional code to check
4107 that indices used to access arrays are within the declared range.
4108 This is currently only supported by the Java and Fortran
4109 front-ends, where this option defaults to true and false
4112 `-fmudflap -fmudflapth -fmudflapir'
4113 For front-ends that support it (C and C++), instrument all risky
4114 pointer/array dereferencing operations, some standard library
4115 string/heap functions, and some other associated constructs with
4116 range/validity tests. Modules so instrumented should be immune to
4117 buffer overflows, invalid heap use, and some other classes of C/C++
4118 programming errors. The instrumentation relies on a separate
4119 runtime library (`libmudflap'), which will be linked into a
4120 program if `-fmudflap' is given at link time. Run-time behavior
4121 of the instrumented program is controlled by the `MUDFLAP_OPTIONS'
4122 environment variable. See `env MUDFLAP_OPTIONS=-help a.out' for
4125 Use `-fmudflapth' instead of `-fmudflap' to compile and to link if
4126 your program is multi-threaded. Use `-fmudflapir', in addition to
4127 `-fmudflap' or `-fmudflapth', if instrumentation should ignore
4128 pointer reads. This produces less instrumentation (and therefore
4129 faster execution) and still provides some protection against
4130 outright memory corrupting writes, but allows erroneously read
4131 data to propagate within a program.
4134 Perform the optimizations of loop strength reduction and
4135 elimination of iteration variables.
4137 Enabled at levels `-O2', `-O3', `-Os'.
4140 Perform optimizations where we check to see if a jump branches to a
4141 location where another comparison subsumed by the first is found.
4142 If so, the first branch is redirected to either the destination of
4143 the second branch or a point immediately following it, depending
4144 on whether the condition is known to be true or false.
4146 Enabled at levels `-O2', `-O3', `-Os'.
4148 `-fcse-follow-jumps'
4149 In common subexpression elimination, scan through jump instructions
4150 when the target of the jump is not reached by any other path. For
4151 example, when CSE encounters an `if' statement with an `else'
4152 clause, CSE will follow the jump when the condition tested is
4155 Enabled at levels `-O2', `-O3', `-Os'.
4158 This is similar to `-fcse-follow-jumps', but causes CSE to follow
4159 jumps which conditionally skip over blocks. When CSE encounters a
4160 simple `if' statement with no else clause, `-fcse-skip-blocks'
4161 causes CSE to follow the jump around the body of the `if'.
4163 Enabled at levels `-O2', `-O3', `-Os'.
4165 `-frerun-cse-after-loop'
4166 Re-run common subexpression elimination after loop optimizations
4169 Enabled at levels `-O2', `-O3', `-Os'.
4172 Run the loop optimizer twice.
4174 Enabled at levels `-O2', `-O3', `-Os'.
4177 Perform a global common subexpression elimination pass. This pass
4178 also performs global constant and copy propagation.
4180 _Note:_ When compiling a program using computed gotos, a GCC
4181 extension, you may get better runtime performance if you disable
4182 the global common subexpression elimination pass by adding
4183 `-fno-gcse' to the command line.
4185 Enabled at levels `-O2', `-O3', `-Os'.
4188 When `-fgcse-lm' is enabled, global common subexpression
4189 elimination will attempt to move loads which are only killed by
4190 stores into themselves. This allows a loop containing a
4191 load/store sequence to be changed to a load outside the loop, and
4192 a copy/store within the loop.
4194 Enabled by default when gcse is enabled.
4197 When `-fgcse-sm' is enabled, a store motion pass is run after
4198 global common subexpression elimination. This pass will attempt
4199 to move stores out of loops. When used in conjunction with
4200 `-fgcse-lm', loops containing a load/store sequence can be changed
4201 to a load before the loop and a store after the loop.
4203 Not enabled at any optimization level.
4206 When `-fgcse-las' is enabled, the global common subexpression
4207 elimination pass eliminates redundant loads that come after stores
4208 to the same memory location (both partial and full redundancies).
4210 Not enabled at any optimization level.
4212 `-fgcse-after-reload'
4213 When `-fgcse-after-reload' is enabled, a redundant load elimination
4214 pass is performed after reload. The purpose of this pass is to
4215 cleanup redundant spilling.
4218 Perform loop optimizations: move constant expressions out of
4219 loops, simplify exit test conditions and optionally do
4220 strength-reduction as well.
4222 Enabled at levels `-O', `-O2', `-O3', `-Os'.
4225 Perform loop optimizations using the new loop optimizer. The
4226 optimizations (loop unrolling, peeling and unswitching, loop
4227 invariant motion) are enabled by separate flags.
4230 Perform cross-jumping transformation. This transformation unifies
4231 equivalent code and save code size. The resulting code may or may
4232 not perform better than without cross-jumping.
4234 Enabled at levels `-O2', `-O3', `-Os'.
4237 Attempt to transform conditional jumps into branch-less
4238 equivalents. This include use of conditional moves, min, max, set
4239 flags and abs instructions, and some tricks doable by standard
4240 arithmetics. The use of conditional execution on chips where it
4241 is available is controlled by `if-conversion2'.
4243 Enabled at levels `-O', `-O2', `-O3', `-Os'.
4246 Use conditional execution (where available) to transform
4247 conditional jumps into branch-less equivalents.
4249 Enabled at levels `-O', `-O2', `-O3', `-Os'.
4251 `-fdelete-null-pointer-checks'
4252 Use global dataflow analysis to identify and eliminate useless
4253 checks for null pointers. The compiler assumes that dereferencing
4254 a null pointer would have halted the program. If a pointer is
4255 checked after it has already been dereferenced, it cannot be null.
4257 In some environments, this assumption is not true, and programs can
4258 safely dereference null pointers. Use
4259 `-fno-delete-null-pointer-checks' to disable this optimization for
4260 programs which depend on that behavior.
4262 Enabled at levels `-O2', `-O3', `-Os'.
4264 `-fexpensive-optimizations'
4265 Perform a number of minor optimizations that are relatively
4268 Enabled at levels `-O2', `-O3', `-Os'.
4270 `-foptimize-register-move'
4272 Attempt to reassign register numbers in move instructions and as
4273 operands of other simple instructions in order to maximize the
4274 amount of register tying. This is especially helpful on machines
4275 with two-operand instructions.
4277 Note `-fregmove' and `-foptimize-register-move' are the same
4280 Enabled at levels `-O2', `-O3', `-Os'.
4283 If supported for the target machine, attempt to reorder
4284 instructions to exploit instruction slots available after delayed
4285 branch instructions.
4287 Enabled at levels `-O', `-O2', `-O3', `-Os'.
4290 If supported for the target machine, attempt to reorder
4291 instructions to eliminate execution stalls due to required data
4292 being unavailable. This helps machines that have slow floating
4293 point or memory load instructions by allowing other instructions
4294 to be issued until the result of the load or floating point
4295 instruction is required.
4297 Enabled at levels `-O2', `-O3', `-Os'.
4300 Similar to `-fschedule-insns', but requests an additional pass of
4301 instruction scheduling after register allocation has been done.
4302 This is especially useful on machines with a relatively small
4303 number of registers and where memory load instructions take more
4306 Enabled at levels `-O2', `-O3', `-Os'.
4308 `-fno-sched-interblock'
4309 Don't schedule instructions across basic blocks. This is normally
4310 enabled by default when scheduling before register allocation, i.e.
4311 with `-fschedule-insns' or at `-O2' or higher.
4314 Don't allow speculative motion of non-load instructions. This is
4315 normally enabled by default when scheduling before register
4316 allocation, i.e. with `-fschedule-insns' or at `-O2' or higher.
4319 Allow speculative motion of some load instructions. This only
4320 makes sense when scheduling before register allocation, i.e. with
4321 `-fschedule-insns' or at `-O2' or higher.
4323 `-fsched-spec-load-dangerous'
4324 Allow speculative motion of more load instructions. This only
4325 makes sense when scheduling before register allocation, i.e. with
4326 `-fschedule-insns' or at `-O2' or higher.
4328 `-fsched-stalled-insns=N'
4329 Define how many insns (if any) can be moved prematurely from the
4330 queue of stalled insns into the ready list, during the second
4333 `-fsched-stalled-insns-dep=N'
4334 Define how many insn groups (cycles) will be examined for a
4335 dependency on a stalled insn that is candidate for premature
4336 removal from the queue of stalled insns. Has an effect only
4337 during the second scheduling pass, and only if
4338 `-fsched-stalled-insns' is used and its value is not zero.
4340 `-fsched2-use-superblocks'
4341 When scheduling after register allocation, do use superblock
4342 scheduling algorithm. Superblock scheduling allows motion across
4343 basic block boundaries resulting on faster schedules. This option
4344 is experimental, as not all machine descriptions used by GCC model
4345 the CPU closely enough to avoid unreliable results from the
4348 This only makes sense when scheduling after register allocation,
4349 i.e. with `-fschedule-insns2' or at `-O2' or higher.
4351 `-fsched2-use-traces'
4352 Use `-fsched2-use-superblocks' algorithm when scheduling after
4353 register allocation and additionally perform code duplication in
4354 order to increase the size of superblocks using tracer pass. See
4355 `-ftracer' for details on trace formation.
4357 This mode should produce faster but significantly longer programs.
4358 Also without `-fbranch-probabilities' the traces constructed may
4359 not match the reality and hurt the performance. This only makes
4360 sense when scheduling after register allocation, i.e. with
4361 `-fschedule-insns2' or at `-O2' or higher.
4363 `-freschedule-modulo-scheduled-loops'
4364 The modulo scheduling comes before the traditional scheduling, if
4365 a loop was modulo scheduled we may want to prevent the later
4366 scheduling passes from changing its schedule, we use this option
4370 Enable values to be allocated in registers that will be clobbered
4371 by function calls, by emitting extra instructions to save and
4372 restore the registers around such calls. Such allocation is done
4373 only when it seems to result in better code than would otherwise
4376 This option is always enabled by default on certain machines,
4377 usually those which have no call-preserved registers to use
4380 Enabled at levels `-O2', `-O3', `-Os'.
4383 Perform Partial Redundancy Elimination (PRE) on trees. This flag
4384 is enabled by default at `-O2' and `-O3'.
4387 Perform Full Redundancy Elimination (FRE) on trees. The difference
4388 between FRE and PRE is that FRE only considers expressions that
4389 are computed on all paths leading to the redundant computation.
4390 This analysis faster than PRE, though it exposes fewer
4391 redundancies. This flag is enabled by default at `-O' and higher.
4394 Perform sparse conditional constant propagation (CCP) on trees.
4395 This flag is enabled by default at `-O' and higher.
4398 Perform dead code elimination (DCE) on trees. This flag is
4399 enabled by default at `-O' and higher.
4401 `-ftree-dominator-opts'
4402 Perform dead code elimination (DCE) on trees. This flag is
4403 enabled by default at `-O' and higher.
4406 Perform loop header copying on trees. This is beneficial since it
4407 increases effectiveness of code motion optimizations. It also
4408 saves one jump. This flag is enabled by default at `-O' and
4409 higher. It is not enabled for `-Os', since it usually increases
4412 `-ftree-loop-optimize'
4413 Perform loop optimizations on trees. This flag is enabled by
4414 default at `-O' and higher.
4416 `-ftree-loop-linear'
4417 Perform linear loop transformations on tree. This flag can
4418 improve cache performance and allow further loop optimizations to
4422 Perform loop invariant motion on trees. This pass moves only
4423 invariants that would be hard to handle at RTL level (function
4424 calls, operations that expand to nontrivial sequences of insns).
4425 With `-funswitch-loops' it also moves operands of conditions that
4426 are invariant out of the loop, so that we can use just trivial
4427 invariantness analysis in loop unswitching. The pass also includes
4430 `-ftree-loop-ivcanon'
4431 Create a canonical counter for number of iterations in the loop
4432 for that determining number of iterations requires complicated
4433 analysis. Later optimizations then may determine the number
4434 easily. Useful especially in connection with unrolling.
4437 Perform induction variable optimizations (strength reduction,
4438 induction variable merging and induction variable elimination) on
4442 Perform scalar replacement of aggregates. This pass replaces
4443 structure references with scalars to prevent committing structures
4444 to memory too early. This flag is enabled by default at `-O' and
4448 Perform copy renaming on trees. This pass attempts to rename
4449 compiler temporaries to other variables at copy locations, usually
4450 resulting in variable names which more closely resemble the
4451 original variables. This flag is enabled by default at `-O' and
4455 Perform temporary expression replacement during the SSA->normal
4456 phase. Single use/single def temporaries are replaced at their
4457 use location with their defining expression. This results in
4458 non-GIMPLE code, but gives the expanders much more complex trees
4459 to work on resulting in better RTL generation. This is enabled by
4460 default at `-O' and higher.
4463 Perform live range splitting during the SSA->normal phase.
4464 Distinct live ranges of a variable are split into unique
4465 variables, allowing for better optimization later. This is
4466 enabled by default at `-O' and higher.
4469 Perform loop vectorization on trees.
4472 Perform tail duplication to enlarge superblock size. This
4473 transformation simplifies the control flow of the function
4474 allowing other optimizations to do better job.
4477 Unroll loops whose number of iterations can be determined at
4478 compile time or upon entry to the loop. `-funroll-loops' implies
4479 both `-fstrength-reduce' and `-frerun-cse-after-loop'. This
4480 option makes code larger, and may or may not make it run faster.
4482 `-funroll-all-loops'
4483 Unroll all loops, even if their number of iterations is uncertain
4484 when the loop is entered. This usually makes programs run more
4485 slowly. `-funroll-all-loops' implies the same options as
4488 `-fsplit-ivs-in-unroller'
4489 Enables expressing of values of induction variables in later
4490 iterations of the unrolled loop using the value in the first
4491 iteration. This breaks long dependency chains, thus improving
4492 efficiency of the scheduling passes (for best results, `-fweb'
4493 should be used as well).
4495 Combination of `-fweb' and CSE is often sufficient to obtain the
4496 same effect. However in cases the loop body is more complicated
4497 than a single basic block, this is not reliable. It also does not
4498 work at all on some of the architectures due to restrictions in
4501 This optimization is enabled by default.
4503 `-fvariable-expansion-in-unroller'
4504 With this option, the compiler will create multiple copies of some
4505 local variables when unrolling a loop which can result in superior
4508 `-fprefetch-loop-arrays'
4509 If supported by the target machine, generate instructions to
4510 prefetch memory to improve the performance of loops that access
4513 These options may generate better or worse code; results are highly
4514 dependent on the structure of loops within the source code.
4518 Disable any machine-specific peephole optimizations. The
4519 difference between `-fno-peephole' and `-fno-peephole2' is in how
4520 they are implemented in the compiler; some targets use one, some
4521 use the other, a few use both.
4523 `-fpeephole' is enabled by default. `-fpeephole2' enabled at
4524 levels `-O2', `-O3', `-Os'.
4526 `-fno-guess-branch-probability'
4527 Do not guess branch probabilities using heuristics.
4529 GCC will use heuristics to guess branch probabilities if they are
4530 not provided by profiling feedback (`-fprofile-arcs'). These
4531 heuristics are based on the control flow graph. If some branch
4532 probabilities are specified by `__builtin_expect', then the
4533 heuristics will be used to guess branch probabilities for the rest
4534 of the control flow graph, taking the `__builtin_expect' info into
4535 account. The interactions between the heuristics and
4536 `__builtin_expect' can be complex, and in some cases, it may be
4537 useful to disable the heuristics so that the effects of
4538 `__builtin_expect' are easier to understand.
4540 The default is `-fguess-branch-probability' at levels `-O', `-O2',
4544 Reorder basic blocks in the compiled function in order to reduce
4545 number of taken branches and improve code locality.
4547 Enabled at levels `-O2', `-O3'.
4549 `-freorder-blocks-and-partition'
4550 In addition to reordering basic blocks in the compiled function,
4551 in order to reduce number of taken branches, partitions hot and
4552 cold basic blocks into separate sections of the assembly and .o
4553 files, to improve paging and cache locality performance.
4555 This optimization is automatically turned off in the presence of
4556 exception handling, for linkonce sections, for functions with a
4557 user-defined section attribute and on any architecture that does
4558 not support named sections.
4560 `-freorder-functions'
4561 Reorder functions in the object file in order to improve code
4562 locality. This is implemented by using special subsections
4563 `.text.hot' for most frequently executed functions and
4564 `.text.unlikely' for unlikely executed functions. Reordering is
4565 done by the linker so object file format must support named
4566 sections and linker must place them in a reasonable way.
4568 Also profile feedback must be available in to make this option
4569 effective. See `-fprofile-arcs' for details.
4571 Enabled at levels `-O2', `-O3', `-Os'.
4574 Allows the compiler to assume the strictest aliasing rules
4575 applicable to the language being compiled. For C (and C++), this
4576 activates optimizations based on the type of expressions. In
4577 particular, an object of one type is assumed never to reside at
4578 the same address as an object of a different type, unless the
4579 types are almost the same. For example, an `unsigned int' can
4580 alias an `int', but not a `void*' or a `double'. A character type
4581 may alias any other type.
4583 Pay special attention to code like this:
4594 The practice of reading from a different union member than the one
4595 most recently written to (called "type-punning") is common. Even
4596 with `-fstrict-aliasing', type-punning is allowed, provided the
4597 memory is accessed through the union type. So, the code above
4598 will work as expected. However, this code might not:
4607 Every language that wishes to perform language-specific alias
4608 analysis should define a function that computes, given an `tree'
4609 node, an alias set for the node. Nodes in different alias sets
4610 are not allowed to alias. For an example, see the C front-end
4611 function `c_get_alias_set'.
4613 Enabled at levels `-O2', `-O3', `-Os'.
4616 `-falign-functions=N'
4617 Align the start of functions to the next power-of-two greater than
4618 N, skipping up to N bytes. For instance, `-falign-functions=32'
4619 aligns functions to the next 32-byte boundary, but
4620 `-falign-functions=24' would align to the next 32-byte boundary
4621 only if this can be done by skipping 23 bytes or less.
4623 `-fno-align-functions' and `-falign-functions=1' are equivalent
4624 and mean that functions will not be aligned.
4626 Some assemblers only support this flag when N is a power of two;
4627 in that case, it is rounded up.
4629 If N is not specified or is zero, use a machine-dependent default.
4631 Enabled at levels `-O2', `-O3'.
4635 Align all branch targets to a power-of-two boundary, skipping up to
4636 N bytes like `-falign-functions'. This option can easily make
4637 code slower, because it must insert dummy operations for when the
4638 branch target is reached in the usual flow of the code.
4640 `-fno-align-labels' and `-falign-labels=1' are equivalent and mean
4641 that labels will not be aligned.
4643 If `-falign-loops' or `-falign-jumps' are applicable and are
4644 greater than this value, then their values are used instead.
4646 If N is not specified or is zero, use a machine-dependent default
4647 which is very likely to be `1', meaning no alignment.
4649 Enabled at levels `-O2', `-O3'.
4653 Align loops to a power-of-two boundary, skipping up to N bytes
4654 like `-falign-functions'. The hope is that the loop will be
4655 executed many times, which will make up for any execution of the
4658 `-fno-align-loops' and `-falign-loops=1' are equivalent and mean
4659 that loops will not be aligned.
4661 If N is not specified or is zero, use a machine-dependent default.
4663 Enabled at levels `-O2', `-O3'.
4667 Align branch targets to a power-of-two boundary, for branch targets
4668 where the targets can only be reached by jumping, skipping up to N
4669 bytes like `-falign-functions'. In this case, no dummy operations
4672 `-fno-align-jumps' and `-falign-jumps=1' are equivalent and mean
4673 that loops will not be aligned.
4675 If N is not specified or is zero, use a machine-dependent default.
4677 Enabled at levels `-O2', `-O3'.
4680 Parse the whole compilation unit before starting to produce code.
4681 This allows some extra optimizations to take place but consumes
4682 more memory (in general). There are some compatibility issues
4683 with _unit-at-at-time_ mode:
4684 * enabling _unit-at-a-time_ mode may change the order in which
4685 functions, variables, and top-level `asm' statements are
4686 emitted, and will likely break code relying on some particular
4687 ordering. The majority of such top-level `asm' statements,
4688 though, can be replaced by `section' attributes.
4690 * _unit-at-a-time_ mode removes unreferenced static variables
4691 and functions are removed. This may result in undefined
4692 references when an `asm' statement refers directly to
4693 variables or functions that are otherwise unused. In that
4694 case either the variable/function shall be listed as an
4695 operand of the `asm' statement operand or, in the case of
4696 top-level `asm' statements the attribute `used' shall be used
4699 * Static functions now can use non-standard passing conventions
4700 that may break `asm' statements calling functions directly.
4701 Again, attribute `used' will prevent this behavior.
4703 As a temporary workaround, `-fno-unit-at-a-time' can be used, but
4704 this scheme may not be supported by future releases of GCC.
4706 Enabled at levels `-O2', `-O3'.
4709 Constructs webs as commonly used for register allocation purposes
4710 and assign each web individual pseudo register. This allows the
4711 register allocation pass to operate on pseudos directly, but also
4712 strengthens several other optimization passes, such as CSE, loop
4713 optimizer and trivial dead code remover. It can, however, make
4714 debugging impossible, since variables will no longer stay in a
4717 Enabled at levels `-O2', `-O3', `-Os', on targets where the
4718 default format for debugging information supports variable
4721 `-fno-cprop-registers'
4722 After register allocation and post-register allocation instruction
4723 splitting, we perform a copy-propagation pass to try to reduce
4724 scheduling dependencies and occasionally eliminate the copy.
4726 Disabled at levels `-O', `-O2', `-O3', `-Os'.
4728 `-fprofile-generate'
4729 Enable options usually used for instrumenting application to
4730 produce profile useful for later recompilation with profile
4731 feedback based optimization. You must use `-fprofile-generate'
4732 both when compiling and when linking your program.
4734 The following options are enabled: `-fprofile-arcs',
4735 `-fprofile-values', `-fvpt'.
4738 Enable profile feedback directed optimizations, and optimizations
4739 generally profitable only with profile feedback available.
4741 The following options are enabled: `-fbranch-probabilities',
4742 `-fvpt', `-funroll-loops', `-fpeel-loops', `-ftracer'.
4745 The following options control compiler behavior regarding floating
4746 point arithmetic. These options trade off between speed and
4747 correctness. All must be specifically enabled.
4750 Do not store floating point variables in registers, and inhibit
4751 other options that might change whether a floating point value is
4752 taken from a register or memory.
4754 This option prevents undesirable excess precision on machines such
4755 as the 68000 where the floating registers (of the 68881) keep more
4756 precision than a `double' is supposed to have. Similarly for the
4757 x86 architecture. For most programs, the excess precision does
4758 only good, but a few programs rely on the precise definition of
4759 IEEE floating point. Use `-ffloat-store' for such programs, after
4760 modifying them to store all pertinent intermediate computations
4764 Sets `-fno-math-errno', `-funsafe-math-optimizations',
4765 `-fno-trapping-math', `-ffinite-math-only', `-fno-rounding-math',
4766 `-fno-signaling-nans' and `fcx-limited-range'.
4768 This option causes the preprocessor macro `__FAST_MATH__' to be
4771 This option should never be turned on by any `-O' option since it
4772 can result in incorrect output for programs which depend on an
4773 exact implementation of IEEE or ISO rules/specifications for math
4777 Do not set ERRNO after calling math functions that are executed
4778 with a single instruction, e.g., sqrt. A program that relies on
4779 IEEE exceptions for math error handling may want to use this flag
4780 for speed while maintaining IEEE arithmetic compatibility.
4782 This option should never be turned on by any `-O' option since it
4783 can result in incorrect output for programs which depend on an
4784 exact implementation of IEEE or ISO rules/specifications for math
4787 The default is `-fmath-errno'.
4789 `-funsafe-math-optimizations'
4790 Allow optimizations for floating-point arithmetic that (a) assume
4791 that arguments and results are valid and (b) may violate IEEE or
4792 ANSI standards. When used at link-time, it may include libraries
4793 or startup files that change the default FPU control word or other
4794 similar optimizations.
4796 This option should never be turned on by any `-O' option since it
4797 can result in incorrect output for programs which depend on an
4798 exact implementation of IEEE or ISO rules/specifications for math
4801 The default is `-fno-unsafe-math-optimizations'.
4803 `-ffinite-math-only'
4804 Allow optimizations for floating-point arithmetic that assume that
4805 arguments and results are not NaNs or +-Infs.
4807 This option should never be turned on by any `-O' option since it
4808 can result in incorrect output for programs which depend on an
4809 exact implementation of IEEE or ISO rules/specifications.
4811 The default is `-fno-finite-math-only'.
4813 `-fno-trapping-math'
4814 Compile code assuming that floating-point operations cannot
4815 generate user-visible traps. These traps include division by
4816 zero, overflow, underflow, inexact result and invalid operation.
4817 This option implies `-fno-signaling-nans'. Setting this option
4818 may allow faster code if one relies on "non-stop" IEEE arithmetic,
4821 This option should never be turned on by any `-O' option since it
4822 can result in incorrect output for programs which depend on an
4823 exact implementation of IEEE or ISO rules/specifications for math
4826 The default is `-ftrapping-math'.
4829 Disable transformations and optimizations that assume default
4830 floating point rounding behavior. This is round-to-zero for all
4831 floating point to integer conversions, and round-to-nearest for
4832 all other arithmetic truncations. This option should be specified
4833 for programs that change the FP rounding mode dynamically, or that
4834 may be executed with a non-default rounding mode. This option
4835 disables constant folding of floating point expressions at
4836 compile-time (which may be affected by rounding mode) and
4837 arithmetic transformations that are unsafe in the presence of
4838 sign-dependent rounding modes.
4840 The default is `-fno-rounding-math'.
4842 This option is experimental and does not currently guarantee to
4843 disable all GCC optimizations that are affected by rounding mode.
4844 Future versions of GCC may provide finer control of this setting
4845 using C99's `FENV_ACCESS' pragma. This command line option will
4846 be used to specify the default state for `FENV_ACCESS'.
4849 Compile code assuming that IEEE signaling NaNs may generate
4850 user-visible traps during floating-point operations. Setting this
4851 option disables optimizations that may change the number of
4852 exceptions visible with signaling NaNs. This option implies
4855 This option causes the preprocessor macro `__SUPPORT_SNAN__' to be
4858 The default is `-fno-signaling-nans'.
4860 This option is experimental and does not currently guarantee to
4861 disable all GCC optimizations that affect signaling NaN behavior.
4863 `-fsingle-precision-constant'
4864 Treat floating point constant as single precision constant instead
4865 of implicitly converting it to double precision constant.
4867 `-fcx-limited-range'
4868 `-fno-cx-limited-range'
4869 When enabled, this option states that a range reduction step is not
4870 needed when performing complex division. The default is
4871 `-fno-cx-limited-range', but is enabled by `-ffast-math'.
4873 This option controls the default setting of the ISO C99
4874 `CX_LIMITED_RANGE' pragma. Nevertheless, the option applies to
4878 The following options control optimizations that may improve
4879 performance, but are not enabled by any `-O' options. This section
4880 includes experimental options that may produce broken code.
4882 `-fbranch-probabilities'
4883 After running a program compiled with `-fprofile-arcs' (*note
4884 Options for Debugging Your Program or `gcc': Debugging Options.),
4885 you can compile it a second time using `-fbranch-probabilities',
4886 to improve optimizations based on the number of times each branch
4887 was taken. When the program compiled with `-fprofile-arcs' exits
4888 it saves arc execution counts to a file called `SOURCENAME.gcda'
4889 for each source file The information in this data file is very
4890 dependent on the structure of the generated code, so you must use
4891 the same source code and the same optimization options for both
4894 With `-fbranch-probabilities', GCC puts a `REG_BR_PROB' note on
4895 each `JUMP_INSN' and `CALL_INSN'. These can be used to improve
4896 optimization. Currently, they are only used in one place: in
4897 `reorg.c', instead of guessing which path a branch is mostly to
4898 take, the `REG_BR_PROB' values are used to exactly determine which
4899 path is taken more often.
4902 If combined with `-fprofile-arcs', it adds code so that some data
4903 about values of expressions in the program is gathered.
4905 With `-fbranch-probabilities', it reads back the data gathered
4906 from profiling values of expressions and adds `REG_VALUE_PROFILE'
4907 notes to instructions for their later usage in optimizations.
4909 Enabled with `-fprofile-generate' and `-fprofile-use'.
4912 If combined with `-fprofile-arcs', it instructs the compiler to add
4913 a code to gather information about values of expressions.
4915 With `-fbranch-probabilities', it reads back the data gathered and
4916 actually performs the optimizations based on them. Currently the
4917 optimizations include specialization of division operation using
4918 the knowledge about the value of the denominator.
4920 `-fspeculative-prefetching'
4921 If combined with `-fprofile-arcs', it instructs the compiler to add
4922 a code to gather information about addresses of memory references
4925 With `-fbranch-probabilities', it reads back the data gathered and
4926 issues prefetch instructions according to them. In addition to
4927 the opportunities noticed by `-fprefetch-loop-arrays', it also
4928 notices more complicated memory access patterns--for example
4929 accesses to the data stored in linked list whose elements are
4930 usually allocated sequentially.
4932 In order to prevent issuing double prefetches, usage of
4933 `-fspeculative-prefetching' implies `-fno-prefetch-loop-arrays'.
4935 Enabled with `-fprofile-generate' and `-fprofile-use'.
4937 `-frename-registers'
4938 Attempt to avoid false dependencies in scheduled code by making use
4939 of registers left over after register allocation. This
4940 optimization will most benefit processors with lots of registers.
4941 Depending on the debug information format adopted by the target,
4942 however, it can make debugging impossible, since variables will no
4943 longer stay in a "home register".
4945 Not enabled by default at any level because it has known bugs.
4948 Perform tail duplication to enlarge superblock size. This
4949 transformation simplifies the control flow of the function
4950 allowing other optimizations to do better job.
4952 Enabled with `-fprofile-use'.
4955 Unroll loops whose number of iterations can be determined at
4956 compile time or upon entry to the loop. `-funroll-loops' implies
4957 `-frerun-cse-after-loop'. It also turns on complete loop peeling
4958 (i.e. complete removal of loops with small constant number of
4959 iterations). This option makes code larger, and may or may not
4962 Enabled with `-fprofile-use'.
4964 `-funroll-all-loops'
4965 Unroll all loops, even if their number of iterations is uncertain
4966 when the loop is entered. This usually makes programs run more
4967 slowly. `-funroll-all-loops' implies the same options as
4971 Peels the loops for that there is enough information that they do
4972 not roll much (from profile feedback). It also turns on complete
4973 loop peeling (i.e. complete removal of loops with small constant
4974 number of iterations).
4976 Enabled with `-fprofile-use'.
4978 `-fmove-loop-invariants'
4979 Enables the loop invariant motion pass in the new loop optimizer.
4980 Enabled at level `-O1'
4983 Move branches with loop invariant conditions out of the loop, with
4984 duplicates of the loop on both branches (modified according to
4985 result of the condition).
4987 `-fprefetch-loop-arrays'
4988 If supported by the target machine, generate instructions to
4989 prefetch memory to improve the performance of loops that access
4992 Disabled at level `-Os'.
4994 `-ffunction-sections'
4996 Place each function or data item into its own section in the output
4997 file if the target supports arbitrary sections. The name of the
4998 function or the name of the data item determines the section's name
5001 Use these options on systems where the linker can perform
5002 optimizations to improve locality of reference in the instruction
5003 space. Most systems using the ELF object format and SPARC
5004 processors running Solaris 2 have linkers with such optimizations.
5005 AIX may have these optimizations in the future.
5007 Only use these options when there are significant benefits from
5008 doing so. When you specify these options, the assembler and
5009 linker will create larger object and executable files and will
5010 also be slower. You will not be able to use `gprof' on all
5011 systems if you specify this option and you may have problems with
5012 debugging if you specify both this option and `-g'.
5014 `-fbranch-target-load-optimize'
5015 Perform branch target register load optimization before prologue /
5016 epilogue threading. The use of target registers can typically be
5017 exposed only during reload, thus hoisting loads out of loops and
5018 doing inter-block scheduling needs a separate optimization pass.
5020 `-fbranch-target-load-optimize2'
5021 Perform branch target register load optimization after prologue /
5024 `-fbtr-bb-exclusive'
5025 When performing branch target register load optimization, don't
5026 reuse branch target registers in within any basic block.
5028 `--param NAME=VALUE'
5029 In some places, GCC uses various constants to control the amount of
5030 optimization that is done. For example, GCC will not inline
5031 functions that contain more that a certain number of instructions.
5032 You can control some of these constants on the command-line using
5033 the `--param' option.
5035 The names of specific parameters, and the meaning of the values,
5036 are tied to the internals of the compiler, and are subject to
5037 change without notice in future releases.
5039 In each case, the VALUE is an integer. The allowable choices for
5040 NAME are given in the following table:
5042 `sra-max-structure-size'
5043 The maximum structure size, in bytes, at which the scalar
5044 replacement of aggregates (SRA) optimization will perform
5045 block copies. The default value, 0, implies that GCC will
5046 select the most appropriate size itself.
5048 `sra-field-structure-ratio'
5049 The threshold ratio (as a percentage) between instantiated
5050 fields and the complete structure size. We say that if the
5051 ratio of the number of bytes in instantiated fields to the
5052 number of bytes in the complete structure exceeds this
5053 parameter, then block copies are not used. The default is 75.
5055 `max-crossjump-edges'
5056 The maximum number of incoming edges to consider for
5057 crossjumping. The algorithm used by `-fcrossjumping' is
5058 O(N^2) in the number of edges incoming to each block.
5059 Increasing values mean more aggressive optimization, making
5060 the compile time increase with probably small improvement in
5063 `min-crossjump-insns'
5064 The minimum number of instructions which must be matched at
5065 the end of two blocks before crossjumping will be performed
5066 on them. This value is ignored in the case where all
5067 instructions in the block being crossjumped from are matched.
5068 The default value is 5.
5070 `max-goto-duplication-insns'
5071 The maximum number of instructions to duplicate to a block
5072 that jumps to a computed goto. To avoid O(N^2) behavior in a
5073 number of passes, GCC factors computed gotos early in the
5074 compilation process, and unfactors them as late as possible.
5075 Only computed jumps at the end of a basic blocks with no more
5076 than max-goto-duplication-insns are unfactored. The default
5079 `max-delay-slot-insn-search'
5080 The maximum number of instructions to consider when looking
5081 for an instruction to fill a delay slot. If more than this
5082 arbitrary number of instructions is searched, the time
5083 savings from filling the delay slot will be minimal so stop
5084 searching. Increasing values mean more aggressive
5085 optimization, making the compile time increase with probably
5086 small improvement in executable run time.
5088 `max-delay-slot-live-search'
5089 When trying to fill delay slots, the maximum number of
5090 instructions to consider when searching for a block with
5091 valid live register information. Increasing this arbitrarily
5092 chosen value means more aggressive optimization, increasing
5093 the compile time. This parameter should be removed when the
5094 delay slot code is rewritten to maintain the control-flow
5098 The approximate maximum amount of memory that will be
5099 allocated in order to perform the global common subexpression
5100 elimination optimization. If more memory than specified is
5101 required, the optimization will not be done.
5104 The maximum number of passes of GCSE to run. The default is
5107 `max-pending-list-length'
5108 The maximum number of pending dependencies scheduling will
5109 allow before flushing the current state and starting over.
5110 Large functions with few branches or calls can create
5111 excessively large lists which needlessly consume memory and
5114 `max-inline-insns-single'
5115 Several parameters control the tree inliner used in gcc.
5116 This number sets the maximum number of instructions (counted
5117 in GCC's internal representation) in a single function that
5118 the tree inliner will consider for inlining. This only
5119 affects functions declared inline and methods implemented in
5120 a class declaration (C++). The default value is 450.
5122 `max-inline-insns-auto'
5123 When you use `-finline-functions' (included in `-O3'), a lot
5124 of functions that would otherwise not be considered for
5125 inlining by the compiler will be investigated. To those
5126 functions, a different (more restrictive) limit compared to
5127 functions declared inline can be applied. The default value
5130 `large-function-insns'
5131 The limit specifying really large functions. For functions
5132 larger than this limit after inlining inlining is constrained
5133 by `--param large-function-growth'. This parameter is useful
5134 primarily to avoid extreme compilation time caused by
5135 non-linear algorithms used by the backend. This parameter is
5136 ignored when `-funit-at-a-time' is not used. The default
5139 `large-function-growth'
5140 Specifies maximal growth of large function caused by inlining
5141 in percents. This parameter is ignored when
5142 `-funit-at-a-time' is not used. The default value is 100
5143 which limits large function growth to 2.0 times the original
5146 `inline-unit-growth'
5147 Specifies maximal overall growth of the compilation unit
5148 caused by inlining. This parameter is ignored when
5149 `-funit-at-a-time' is not used. The default value is 50
5150 which limits unit growth to 1.5 times the original size.
5152 `max-inline-insns-recursive'
5153 `max-inline-insns-recursive-auto'
5154 Specifies maximum number of instructions out-of-line copy of
5155 self recursive inline function can grow into by performing
5158 For functions declared inline `--param
5159 max-inline-insns-recursive' is taken into acount. For
5160 function not declared inline, recursive inlining happens only
5161 when `-finline-functions' (included in `-O3') is enabled and
5162 `--param max-inline-insns-recursive-auto' is used. The
5163 default value is 450.
5165 `max-inline-recursive-depth'
5166 `max-inline-recursive-depth-auto'
5167 Specifies maximum recursion depth used by the recursive
5170 For functions declared inline `--param
5171 max-inline-recursive-depth' is taken into acount. For
5172 function not declared inline, recursive inlining happens only
5173 when `-finline-functions' (included in `-O3') is enabled and
5174 `--param max-inline-recursive-depth-auto' is used. The
5175 default value is 450.
5178 Specify cost of call instruction relative to simple
5179 arithmetics operations (having cost of 1). Increasing this
5180 cost disqualify inlinining of non-leaf functions and at same
5181 time increase size of leaf function that is believed to
5182 reduce function size by being inlined. In effect it increase
5183 amount of inlining for code having large abstraction penalty
5184 (many functions that just pass the argumetns to other
5185 functions) and decrease inlining for code with low
5186 abstraction penalty. Default value is 16.
5188 `max-unrolled-insns'
5189 The maximum number of instructions that a loop should have if
5190 that loop is unrolled, and if the loop is unrolled, it
5191 determines how many times the loop code is unrolled.
5193 `max-average-unrolled-insns'
5194 The maximum number of instructions biased by probabilities of
5195 their execution that a loop should have if that loop is
5196 unrolled, and if the loop is unrolled, it determines how many
5197 times the loop code is unrolled.
5200 The maximum number of unrollings of a single loop.
5203 The maximum number of instructions that a loop should have if
5204 that loop is peeled, and if the loop is peeled, it determines
5205 how many times the loop code is peeled.
5208 The maximum number of peelings of a single loop.
5210 `max-completely-peeled-insns'
5211 The maximum number of insns of a completely peeled loop.
5213 `max-completely-peel-times'
5214 The maximum number of iterations of a loop to be suitable for
5217 `max-unswitch-insns'
5218 The maximum number of insns of an unswitched loop.
5220 `max-unswitch-level'
5221 The maximum number of branches unswitched in a single loop.
5224 The minimum cost of an expensive expression in the loop
5227 `iv-consider-all-candidates-bound'
5228 Bound on number of candidates for induction variables below
5229 that all candidates are considered for each use in induction
5230 variable optimizations. Only the most relevant candidates
5231 are considered if there are more candidates, to avoid
5232 quadratic time complexity.
5234 `iv-max-considered-uses'
5235 The induction variable optimizations give up on loops that
5236 contain more induction variable uses.
5238 `iv-always-prune-cand-set-bound'
5239 If number of candidates in the set is smaller than this value,
5240 we always try to remove unnecessary ivs from the set during
5241 its optimization when a new iv is added to the set.
5243 `max-iterations-to-track'
5244 The maximum number of iterations of a loop the brute force
5245 algorithm for analysis of # of iterations of the loop tries
5248 `hot-bb-count-fraction'
5249 Select fraction of the maximal count of repetitions of basic
5250 block in program given basic block needs to have to be
5253 `hot-bb-frequency-fraction'
5254 Select fraction of the maximal frequency of executions of
5255 basic block in function given basic block needs to have to be
5258 `tracer-dynamic-coverage'
5259 `tracer-dynamic-coverage-feedback'
5260 This value is used to limit superblock formation once the
5261 given percentage of executed instructions is covered. This
5262 limits unnecessary code size expansion.
5264 The `tracer-dynamic-coverage-feedback' is used only when
5265 profile feedback is available. The real profiles (as opposed
5266 to statically estimated ones) are much less balanced allowing
5267 the threshold to be larger value.
5269 `tracer-max-code-growth'
5270 Stop tail duplication once code growth has reached given
5271 percentage. This is rather hokey argument, as most of the
5272 duplicates will be eliminated later in cross jumping, so it
5273 may be set to much higher values than is the desired code
5276 `tracer-min-branch-ratio'
5277 Stop reverse growth when the reverse probability of best edge
5278 is less than this threshold (in percent).
5280 `tracer-min-branch-ratio'
5281 `tracer-min-branch-ratio-feedback'
5282 Stop forward growth if the best edge do have probability
5283 lower than this threshold.
5285 Similarly to `tracer-dynamic-coverage' two values are
5286 present, one for compilation for profile feedback and one for
5287 compilation without. The value for compilation with profile
5288 feedback needs to be more conservative (higher) in order to
5289 make tracer effective.
5291 `max-cse-path-length'
5292 Maximum number of basic blocks on path that cse considers.
5295 `global-var-threshold'
5296 Counts the number of function calls (N) and the number of
5297 call-clobbered variables (V). If NxV is larger than this
5298 limit, a single artificial variable will be created to
5299 represent all the call-clobbered variables at function call
5300 sites. This artificial variable will then be made to alias
5301 every call-clobbered variable. (done as `int * size_t' on
5302 the host machine; beware overflow).
5305 Maximum number of virtual operands allowed to represent
5306 aliases before triggering the alias grouping heuristic.
5307 Alias grouping reduces compile times and memory consumption
5308 needed for aliasing at the expense of precision loss in alias
5312 GCC uses a garbage collector to manage its own memory
5313 allocation. This parameter specifies the minimum percentage
5314 by which the garbage collector's heap should be allowed to
5315 expand between collections. Tuning this may improve
5316 compilation speed; it has no effect on code generation.
5318 The default is 30% + 70% * (RAM/1GB) with an upper bound of
5319 100% when RAM >= 1GB. If `getrlimit' is available, the
5320 notion of "RAM" is the smallest of actual RAM and
5321 `RLIMIT_DATA' or `RLIMIT_AS'. If GCC is not able to
5322 calculate RAM on a particular platform, the lower bound of
5323 30% is used. Setting this parameter and `ggc-min-heapsize'
5324 to zero causes a full collection to occur at every
5325 opportunity. This is extremely slow, but can be useful for
5329 Minimum size of the garbage collector's heap before it begins
5330 bothering to collect garbage. The first collection occurs
5331 after the heap expands by `ggc-min-expand'% beyond
5332 `ggc-min-heapsize'. Again, tuning this may improve
5333 compilation speed, and has no effect on code generation.
5335 The default is the smaller of RAM/8, RLIMIT_RSS, or a limit
5336 which tries to ensure that RLIMIT_DATA or RLIMIT_AS are not
5337 exceeded, but with a lower bound of 4096 (four megabytes) and
5338 an upper bound of 131072 (128 megabytes). If GCC is not able
5339 to calculate RAM on a particular platform, the lower bound is
5340 used. Setting this parameter very large effectively disables
5341 garbage collection. Setting this parameter and
5342 `ggc-min-expand' to zero causes a full collection to occur at
5345 `max-reload-search-insns'
5346 The maximum number of instruction reload should look backward
5347 for equivalent register. Increasing values mean more
5348 aggressive optimization, making the compile time increase
5349 with probably slightly better performance. The default value
5352 `max-cselib-memory-location'
5353 The maximum number of memory locations cselib should take
5354 into acount. Increasing values mean more aggressive
5355 optimization, making the compile time increase with probably
5356 slightly better performance. The default value is 500.
5358 `reorder-blocks-duplicate'
5359 `reorder-blocks-duplicate-feedback'
5360 Used by basic block reordering pass to decide whether to use
5361 unconditional branch or duplicate the code on its
5362 destination. Code is duplicated when its estimated size is
5363 smaller than this value multiplied by the estimated size of
5364 unconditional jump in the hot spots of the program.
5366 The `reorder-block-duplicate-feedback' is used only when
5367 profile feedback is available and may be set to higher values
5368 than `reorder-block-duplicate' since information about the
5369 hot spots is more accurate.
5371 `max-sched-region-blocks'
5372 The maximum number of blocks in a region to be considered for
5373 interblock scheduling. The default value is 10.
5375 `max-sched-region-insns'
5376 The maximum number of insns in a region to be considered for
5377 interblock scheduling. The default value is 100.
5379 `max-last-value-rtl'
5380 The maximum size measured as number of RTLs that can be
5381 recorded in an expression in combiner for a pseudo register
5382 as last known value of that register. The default is 10000.
5384 `integer-share-limit'
5385 Small integer constants can use a shared data structure,
5386 reducing the compiler's memory usage and increasing its
5387 speed. This sets the maximum value of a shared integer
5388 constant's. The default value is 256.
5392 File: gcc.info, Node: Preprocessor Options, Next: Assembler Options, Prev: Optimize Options, Up: Invoking GCC
5394 3.11 Options Controlling the Preprocessor
5395 =========================================
5397 These options control the C preprocessor, which is run on each C source
5398 file before actual compilation.
5400 If you use the `-E' option, nothing is done except preprocessing.
5401 Some of these options make sense only together with `-E' because they
5402 cause the preprocessor output to be unsuitable for actual compilation.
5404 You can use `-Wp,OPTION' to bypass the compiler driver and pass
5405 OPTION directly through to the preprocessor. If OPTION contains
5406 commas, it is split into multiple options at the commas. However,
5407 many options are modified, translated or interpreted by the
5408 compiler driver before being passed to the preprocessor, and `-Wp'
5409 forcibly bypasses this phase. The preprocessor's direct interface
5410 is undocumented and subject to change, so whenever possible you
5411 should avoid using `-Wp' and let the driver handle the options
5414 `-Xpreprocessor OPTION'
5415 Pass OPTION as an option to the preprocessor. You can use this to
5416 supply system-specific preprocessor options which GCC does not
5417 know how to recognize.
5419 If you want to pass an option that takes an argument, you must use
5420 `-Xpreprocessor' twice, once for the option and once for the
5424 Predefine NAME as a macro, with definition `1'.
5426 `-D NAME=DEFINITION'
5427 The contents of DEFINITION are tokenized and processed as if they
5428 appeared during translation phase three in a `#define' directive.
5429 In particular, the definition will be truncated by embedded
5432 If you are invoking the preprocessor from a shell or shell-like
5433 program you may need to use the shell's quoting syntax to protect
5434 characters such as spaces that have a meaning in the shell syntax.
5436 If you wish to define a function-like macro on the command line,
5437 write its argument list with surrounding parentheses before the
5438 equals sign (if any). Parentheses are meaningful to most shells,
5439 so you will need to quote the option. With `sh' and `csh',
5440 `-D'NAME(ARGS...)=DEFINITION'' works.
5442 `-D' and `-U' options are processed in the order they are given on
5443 the command line. All `-imacros FILE' and `-include FILE' options
5444 are processed after all `-D' and `-U' options.
5447 Cancel any previous definition of NAME, either built in or
5448 provided with a `-D' option.
5451 Do not predefine any system-specific or GCC-specific macros. The
5452 standard predefined macros remain defined.
5455 Add the directory DIR to the list of directories to be searched
5456 for header files. Directories named by `-I' are searched before
5457 the standard system include directories. If the directory DIR is
5458 a standard system include directory, the option is ignored to
5459 ensure that the default search order for system directories and
5460 the special treatment of system headers are not defeated .
5463 Write output to FILE. This is the same as specifying FILE as the
5464 second non-option argument to `cpp'. `gcc' has a different
5465 interpretation of a second non-option argument, so you must use
5466 `-o' to specify the output file.
5469 Turns on all optional warnings which are desirable for normal code.
5470 At present this is `-Wcomment', `-Wtrigraphs', `-Wmultichar' and a
5471 warning about integer promotion causing a change of sign in `#if'
5472 expressions. Note that many of the preprocessor's warnings are on
5473 by default and have no options to control them.
5477 Warn whenever a comment-start sequence `/*' appears in a `/*'
5478 comment, or whenever a backslash-newline appears in a `//' comment.
5479 (Both forms have the same effect.)
5482 Most trigraphs in comments cannot affect the meaning of the
5483 program. However, a trigraph that would form an escaped newline
5484 (`??/' at the end of a line) can, by changing where the comment
5485 begins or ends. Therefore, only trigraphs that would form escaped
5486 newlines produce warnings inside a comment.
5488 This option is implied by `-Wall'. If `-Wall' is not given, this
5489 option is still enabled unless trigraphs are enabled. To get
5490 trigraph conversion without warnings, but get the other `-Wall'
5491 warnings, use `-trigraphs -Wall -Wno-trigraphs'.
5494 Warn about certain constructs that behave differently in
5495 traditional and ISO C. Also warn about ISO C constructs that have
5496 no traditional C equivalent, and problematic constructs which
5500 Warn the first time `#import' is used.
5503 Warn whenever an identifier which is not a macro is encountered in
5504 an `#if' directive, outside of `defined'. Such identifiers are
5508 Warn about macros defined in the main file that are unused. A
5509 macro is "used" if it is expanded or tested for existence at least
5510 once. The preprocessor will also warn if the macro has not been
5511 used at the time it is redefined or undefined.
5513 Built-in macros, macros defined on the command line, and macros
5514 defined in include files are not warned about.
5516 _Note:_ If a macro is actually used, but only used in skipped
5517 conditional blocks, then CPP will report it as unused. To avoid
5518 the warning in such a case, you might improve the scope of the
5519 macro's definition by, for example, moving it into the first
5520 skipped block. Alternatively, you could provide a dummy use with
5523 #if defined the_macro_causing_the_warning
5527 Warn whenever an `#else' or an `#endif' are followed by text.
5528 This usually happens in code of the form
5536 The second and third `FOO' should be in comments, but often are not
5537 in older programs. This warning is on by default.
5540 Make all warnings into hard errors. Source code which triggers
5541 warnings will be rejected.
5544 Issue warnings for code in system headers. These are normally
5545 unhelpful in finding bugs in your own code, therefore suppressed.
5546 If you are responsible for the system library, you may want to see
5550 Suppress all warnings, including those which GNU CPP issues by
5554 Issue all the mandatory diagnostics listed in the C standard.
5555 Some of them are left out by default, since they trigger
5556 frequently on harmless code.
5559 Issue all the mandatory diagnostics, and make all mandatory
5560 diagnostics into errors. This includes mandatory diagnostics that
5561 GCC issues without `-pedantic' but treats as warnings.
5564 Instead of outputting the result of preprocessing, output a rule
5565 suitable for `make' describing the dependencies of the main source
5566 file. The preprocessor outputs one `make' rule containing the
5567 object file name for that source file, a colon, and the names of
5568 all the included files, including those coming from `-include' or
5569 `-imacros' command line options.
5571 Unless specified explicitly (with `-MT' or `-MQ'), the object file
5572 name consists of the basename of the source file with any suffix
5573 replaced with object file suffix. If there are many included
5574 files then the rule is split into several lines using `\'-newline.
5575 The rule has no commands.
5577 This option does not suppress the preprocessor's debug output,
5578 such as `-dM'. To avoid mixing such debug output with the
5579 dependency rules you should explicitly specify the dependency
5580 output file with `-MF', or use an environment variable like
5581 `DEPENDENCIES_OUTPUT' (*note Environment Variables::). Debug
5582 output will still be sent to the regular output stream as normal.
5584 Passing `-M' to the driver implies `-E', and suppresses warnings
5585 with an implicit `-w'.
5588 Like `-M' but do not mention header files that are found in system
5589 header directories, nor header files that are included, directly
5590 or indirectly, from such a header.
5592 This implies that the choice of angle brackets or double quotes in
5593 an `#include' directive does not in itself determine whether that
5594 header will appear in `-MM' dependency output. This is a slight
5595 change in semantics from GCC versions 3.0 and earlier.
5598 When used with `-M' or `-MM', specifies a file to write the
5599 dependencies to. If no `-MF' switch is given the preprocessor
5600 sends the rules to the same place it would have sent preprocessed
5603 When used with the driver options `-MD' or `-MMD', `-MF' overrides
5604 the default dependency output file.
5607 In conjunction with an option such as `-M' requesting dependency
5608 generation, `-MG' assumes missing header files are generated files
5609 and adds them to the dependency list without raising an error.
5610 The dependency filename is taken directly from the `#include'
5611 directive without prepending any path. `-MG' also suppresses
5612 preprocessed output, as a missing header file renders this useless.
5614 This feature is used in automatic updating of makefiles.
5617 This option instructs CPP to add a phony target for each dependency
5618 other than the main file, causing each to depend on nothing. These
5619 dummy rules work around errors `make' gives if you remove header
5620 files without updating the `Makefile' to match.
5622 This is typical output:
5624 test.o: test.c test.h
5629 Change the target of the rule emitted by dependency generation. By
5630 default CPP takes the name of the main input file, including any
5631 path, deletes any file suffix such as `.c', and appends the
5632 platform's usual object suffix. The result is the target.
5634 An `-MT' option will set the target to be exactly the string you
5635 specify. If you want multiple targets, you can specify them as a
5636 single argument to `-MT', or use multiple `-MT' options.
5638 For example, `-MT '$(objpfx)foo.o'' might give
5640 $(objpfx)foo.o: foo.c
5643 Same as `-MT', but it quotes any characters which are special to
5644 Make. `-MQ '$(objpfx)foo.o'' gives
5646 $$(objpfx)foo.o: foo.c
5648 The default target is automatically quoted, as if it were given
5652 `-MD' is equivalent to `-M -MF FILE', except that `-E' is not
5653 implied. The driver determines FILE based on whether an `-o'
5654 option is given. If it is, the driver uses its argument but with
5655 a suffix of `.d', otherwise it take the basename of the input file
5656 and applies a `.d' suffix.
5658 If `-MD' is used in conjunction with `-E', any `-o' switch is
5659 understood to specify the dependency output file (but *note -MF:
5660 dashMF.), but if used without `-E', each `-o' is understood to
5661 specify a target object file.
5663 Since `-E' is not implied, `-MD' can be used to generate a
5664 dependency output file as a side-effect of the compilation process.
5667 Like `-MD' except mention only user header files, not system
5671 When using precompiled headers (*note Precompiled Headers::), this
5672 flag will cause the dependency-output flags to also list the files
5673 from the precompiled header's dependencies. If not specified only
5674 the precompiled header would be listed and not the files that were
5675 used to create it because those files are not consulted when a
5676 precompiled header is used.
5679 This option allows use of a precompiled header (*note Precompiled
5680 Headers::) together with `-E'. It inserts a special `#pragma',
5681 `#pragma GCC pch_preprocess "<filename>"' in the output to mark
5682 the place where the precompiled header was found, and its
5683 filename. When `-fpreprocessed' is in use, GCC recognizes this
5684 `#pragma' and loads the PCH.
5686 This option is off by default, because the resulting preprocessed
5687 output is only really suitable as input to GCC. It is switched on
5690 You should not write this `#pragma' in your own code, but it is
5691 safe to edit the filename if the PCH file is available in a
5692 different location. The filename may be absolute or it may be
5693 relative to GCC's current directory.
5698 `-x assembler-with-cpp'
5699 Specify the source language: C, C++, Objective-C, or assembly.
5700 This has nothing to do with standards conformance or extensions;
5701 it merely selects which base syntax to expect. If you give none
5702 of these options, cpp will deduce the language from the extension
5703 of the source file: `.c', `.cc', `.m', or `.S'. Some other common
5704 extensions for C++ and assembly are also recognized. If cpp does
5705 not recognize the extension, it will treat the file as C; this is
5706 the most generic mode.
5708 _Note:_ Previous versions of cpp accepted a `-lang' option which
5709 selected both the language and the standards conformance level.
5710 This option has been removed, because it conflicts with the `-l'
5715 Specify the standard to which the code should conform. Currently
5716 CPP knows about C and C++ standards; others may be added in the
5719 STANDARD may be one of:
5722 The ISO C standard from 1990. `c89' is the customary
5723 shorthand for this version of the standard.
5725 The `-ansi' option is equivalent to `-std=c89'.
5728 The 1990 C standard, as amended in 1994.
5734 The revised ISO C standard, published in December 1999.
5735 Before publication, this was known as C9X.
5738 The 1990 C standard plus GNU extensions. This is the default.
5742 The 1999 C standard plus GNU extensions.
5745 The 1998 ISO C++ standard plus amendments.
5748 The same as `-std=c++98' plus GNU extensions. This is the
5749 default for C++ code.
5752 Split the include path. Any directories specified with `-I'
5753 options before `-I-' are searched only for headers requested with
5754 `#include "FILE"'; they are not searched for `#include <FILE>'.
5755 If additional directories are specified with `-I' options after
5756 the `-I-', those directories are searched for all `#include'
5759 In addition, `-I-' inhibits the use of the directory of the current
5760 file directory as the first search directory for `#include "FILE"'.
5761 This option has been deprecated.
5764 Do not search the standard system directories for header files.
5765 Only the directories you have specified with `-I' options (and the
5766 directory of the current file, if appropriate) are searched.
5769 Do not search for header files in the C++-specific standard
5770 directories, but do still search the other standard directories.
5771 (This option is used when building the C++ library.)
5774 Process FILE as if `#include "file"' appeared as the first line of
5775 the primary source file. However, the first directory searched
5776 for FILE is the preprocessor's working directory _instead of_ the
5777 directory containing the main source file. If not found there, it
5778 is searched for in the remainder of the `#include "..."' search
5781 If multiple `-include' options are given, the files are included
5782 in the order they appear on the command line.
5785 Exactly like `-include', except that any output produced by
5786 scanning FILE is thrown away. Macros it defines remain defined.
5787 This allows you to acquire all the macros from a header without
5788 also processing its declarations.
5790 All files specified by `-imacros' are processed before all files
5791 specified by `-include'.
5794 Search DIR for header files, but do it _after_ all directories
5795 specified with `-I' and the standard system directories have been
5796 exhausted. DIR is treated as a system include directory.
5799 Specify PREFIX as the prefix for subsequent `-iwithprefix'
5800 options. If the prefix represents a directory, you should include
5804 `-iwithprefixbefore DIR'
5805 Append DIR to the prefix specified previously with `-iprefix', and
5806 add the resulting directory to the include search path.
5807 `-iwithprefixbefore' puts it in the same place `-I' would;
5808 `-iwithprefix' puts it where `-idirafter' would.
5811 Search DIR for header files, after all directories specified by
5812 `-I' but before the standard system directories. Mark it as a
5813 system directory, so that it gets the same special treatment as is
5814 applied to the standard system directories.
5817 Search DIR only for header files requested with `#include "FILE"';
5818 they are not searched for `#include <FILE>', before all
5819 directories specified by `-I' and before the standard system
5822 `-fdollars-in-identifiers'
5823 Accept `$' in identifiers.
5826 Indicate to the preprocessor that the input file has already been
5827 preprocessed. This suppresses things like macro expansion,
5828 trigraph conversion, escaped newline splicing, and processing of
5829 most directives. The preprocessor still recognizes and removes
5830 comments, so that you can pass a file preprocessed with `-C' to
5831 the compiler without problems. In this mode the integrated
5832 preprocessor is little more than a tokenizer for the front ends.
5834 `-fpreprocessed' is implicit if the input file has one of the
5835 extensions `.i', `.ii' or `.mi'. These are the extensions that
5836 GCC uses for preprocessed files created by `-save-temps'.
5839 Set the distance between tab stops. This helps the preprocessor
5840 report correct column numbers in warnings or errors, even if tabs
5841 appear on the line. If the value is less than 1 or greater than
5842 100, the option is ignored. The default is 8.
5844 `-fexec-charset=CHARSET'
5845 Set the execution character set, used for string and character
5846 constants. The default is UTF-8. CHARSET can be any encoding
5847 supported by the system's `iconv' library routine.
5849 `-fwide-exec-charset=CHARSET'
5850 Set the wide execution character set, used for wide string and
5851 character constants. The default is UTF-32 or UTF-16, whichever
5852 corresponds to the width of `wchar_t'. As with `-fexec-charset',
5853 CHARSET can be any encoding supported by the system's `iconv'
5854 library routine; however, you will have problems with encodings
5855 that do not fit exactly in `wchar_t'.
5857 `-finput-charset=CHARSET'
5858 Set the input character set, used for translation from the
5859 character set of the input file to the source character set used
5860 by GCC. If the locale does not specify, or GCC cannot get this
5861 information from the locale, the default is UTF-8. This can be
5862 overridden by either the locale or this command line option.
5863 Currently the command line option takes precedence if there's a
5864 conflict. CHARSET can be any encoding supported by the system's
5865 `iconv' library routine.
5867 `-fworking-directory'
5868 Enable generation of linemarkers in the preprocessor output that
5869 will let the compiler know the current working directory at the
5870 time of preprocessing. When this option is enabled, the
5871 preprocessor will emit, after the initial linemarker, a second
5872 linemarker with the current working directory followed by two
5873 slashes. GCC will use this directory, when it's present in the
5874 preprocessed input, as the directory emitted as the current
5875 working directory in some debugging information formats. This
5876 option is implicitly enabled if debugging information is enabled,
5877 but this can be inhibited with the negated form
5878 `-fno-working-directory'. If the `-P' flag is present in the
5879 command line, this option has no effect, since no `#line'
5880 directives are emitted whatsoever.
5883 Do not print column numbers in diagnostics. This may be necessary
5884 if diagnostics are being scanned by a program that does not
5885 understand the column numbers, such as `dejagnu'.
5887 `-A PREDICATE=ANSWER'
5888 Make an assertion with the predicate PREDICATE and answer ANSWER.
5889 This form is preferred to the older form `-A PREDICATE(ANSWER)',
5890 which is still supported, because it does not use shell special
5893 `-A -PREDICATE=ANSWER'
5894 Cancel an assertion with the predicate PREDICATE and answer ANSWER.
5897 CHARS is a sequence of one or more of the following characters,
5898 and must not be preceded by a space. Other characters are
5899 interpreted by the compiler proper, or reserved for future
5900 versions of GCC, and so are silently ignored. If you specify
5901 characters whose behavior conflicts, the result is undefined.
5904 Instead of the normal output, generate a list of `#define'
5905 directives for all the macros defined during the execution of
5906 the preprocessor, including predefined macros. This gives
5907 you a way of finding out what is predefined in your version
5908 of the preprocessor. Assuming you have no file `foo.h', the
5911 touch foo.h; cpp -dM foo.h
5913 will show all the predefined macros.
5916 Like `M' except in two respects: it does _not_ include the
5917 predefined macros, and it outputs _both_ the `#define'
5918 directives and the result of preprocessing. Both kinds of
5919 output go to the standard output file.
5922 Like `D', but emit only the macro names, not their expansions.
5925 Output `#include' directives in addition to the result of
5929 Inhibit generation of linemarkers in the output from the
5930 preprocessor. This might be useful when running the preprocessor
5931 on something that is not C code, and will be sent to a program
5932 which might be confused by the linemarkers.
5935 Do not discard comments. All comments are passed through to the
5936 output file, except for comments in processed directives, which
5937 are deleted along with the directive.
5939 You should be prepared for side effects when using `-C'; it causes
5940 the preprocessor to treat comments as tokens in their own right.
5941 For example, comments appearing at the start of what would be a
5942 directive line have the effect of turning that line into an
5943 ordinary source line, since the first token on the line is no
5947 Do not discard comments, including during macro expansion. This is
5948 like `-C', except that comments contained within macros are also
5949 passed through to the output file where the macro is expanded.
5951 In addition to the side-effects of the `-C' option, the `-CC'
5952 option causes all C++-style comments inside a macro to be
5953 converted to C-style comments. This is to prevent later use of
5954 that macro from inadvertently commenting out the remainder of the
5957 The `-CC' option is generally used to support lint comments.
5960 Try to imitate the behavior of old-fashioned C preprocessors, as
5961 opposed to ISO C preprocessors.
5964 Process trigraph sequences. These are three-character sequences,
5965 all starting with `??', that are defined by ISO C to stand for
5966 single characters. For example, `??/' stands for `\', so `'??/n''
5967 is a character constant for a newline. By default, GCC ignores
5968 trigraphs, but in standard-conforming modes it converts them. See
5969 the `-std' and `-ansi' options.
5971 The nine trigraphs and their replacements are
5973 Trigraph: ??( ??) ??< ??> ??= ??/ ??' ??! ??-
5974 Replacement: [ ] { } # \ ^ | ~
5977 Enable special code to work around file systems which only permit
5978 very short file names, such as MS-DOS.
5982 Print text describing all the command line options instead of
5983 preprocessing anything.
5986 Verbose mode. Print out GNU CPP's version number at the beginning
5987 of execution, and report the final form of the include path.
5990 Print the name of each header file used, in addition to other
5991 normal activities. Each name is indented to show how deep in the
5992 `#include' stack it is. Precompiled header files are also
5993 printed, even if they are found to be invalid; an invalid
5994 precompiled header file is printed with `...x' and a valid one
5999 Print out GNU CPP's version number. With one dash, proceed to
6000 preprocess as normal. With two dashes, exit immediately.
6003 File: gcc.info, Node: Assembler Options, Next: Link Options, Prev: Preprocessor Options, Up: Invoking GCC
6005 3.12 Passing Options to the Assembler
6006 =====================================
6008 You can pass options to the assembler.
6011 Pass OPTION as an option to the assembler. If OPTION contains
6012 commas, it is split into multiple options at the commas.
6014 `-Xassembler OPTION'
6015 Pass OPTION as an option to the assembler. You can use this to
6016 supply system-specific assembler options which GCC does not know
6019 If you want to pass an option that takes an argument, you must use
6020 `-Xassembler' twice, once for the option and once for the argument.
6024 File: gcc.info, Node: Link Options, Next: Directory Options, Prev: Assembler Options, Up: Invoking GCC
6026 3.13 Options for Linking
6027 ========================
6029 These options come into play when the compiler links object files into
6030 an executable output file. They are meaningless if the compiler is not
6034 A file name that does not end in a special recognized suffix is
6035 considered to name an object file or library. (Object files are
6036 distinguished from libraries by the linker according to the file
6037 contents.) If linking is done, these object files are used as
6038 input to the linker.
6043 If any of these options is used, then the linker is not run, and
6044 object file names should not be used as arguments. *Note Overall
6049 Search the library named LIBRARY when linking. (The second
6050 alternative with the library as a separate argument is only for
6051 POSIX compliance and is not recommended.)
6053 It makes a difference where in the command you write this option;
6054 the linker searches and processes libraries and object files in
6055 the order they are specified. Thus, `foo.o -lz bar.o' searches
6056 library `z' after file `foo.o' but before `bar.o'. If `bar.o'
6057 refers to functions in `z', those functions may not be loaded.
6059 The linker searches a standard list of directories for the library,
6060 which is actually a file named `libLIBRARY.a'. The linker then
6061 uses this file as if it had been specified precisely by name.
6063 The directories searched include several standard system
6064 directories plus any that you specify with `-L'.
6066 Normally the files found this way are library files--archive files
6067 whose members are object files. The linker handles an archive
6068 file by scanning through it for members which define symbols that
6069 have so far been referenced but not defined. But if the file that
6070 is found is an ordinary object file, it is linked in the usual
6071 fashion. The only difference between using an `-l' option and
6072 specifying a file name is that `-l' surrounds LIBRARY with `lib'
6073 and `.a' and searches several directories.
6076 You need this special case of the `-l' option in order to link an
6077 Objective-C or Objective-C++ program.
6080 Do not use the standard system startup files when linking. The
6081 standard system libraries are used normally, unless `-nostdlib' or
6082 `-nodefaultlibs' is used.
6085 Do not use the standard system libraries when linking. Only the
6086 libraries you specify will be passed to the linker. The standard
6087 startup files are used normally, unless `-nostartfiles' is used.
6088 The compiler may generate calls to `memcmp', `memset', `memcpy'
6089 and `memmove'. These entries are usually resolved by entries in
6090 libc. These entry points should be supplied through some other
6091 mechanism when this option is specified.
6094 Do not use the standard system startup files or libraries when
6095 linking. No startup files and only the libraries you specify will
6096 be passed to the linker. The compiler may generate calls to
6097 `memcmp', `memset', `memcpy' and `memmove'. These entries are
6098 usually resolved by entries in libc. These entry points should be
6099 supplied through some other mechanism when this option is
6102 One of the standard libraries bypassed by `-nostdlib' and
6103 `-nodefaultlibs' is `libgcc.a', a library of internal subroutines
6104 that GCC uses to overcome shortcomings of particular machines, or
6105 special needs for some languages. (*Note Interfacing to GCC
6106 Output: (gccint)Interface, for more discussion of `libgcc.a'.) In
6107 most cases, you need `libgcc.a' even when you want to avoid other
6108 standard libraries. In other words, when you specify `-nostdlib'
6109 or `-nodefaultlibs' you should usually specify `-lgcc' as well.
6110 This ensures that you have no unresolved references to internal GCC
6111 library subroutines. (For example, `__main', used to ensure C++
6112 constructors will be called; *note `collect2': (gccint)Collect2.)
6115 Produce a position independent executable on targets which support
6116 it. For predictable results, you must also specify the same set
6117 of options that were used to generate code (`-fpie', `-fPIE', or
6118 model suboptions) when you specify this option.
6121 Remove all symbol table and relocation information from the
6125 On systems that support dynamic linking, this prevents linking
6126 with the shared libraries. On other systems, this option has no
6130 Produce a shared object which can then be linked with other
6131 objects to form an executable. Not all systems support this
6132 option. For predictable results, you must also specify the same
6133 set of options that were used to generate code (`-fpic', `-fPIC',
6134 or model suboptions) when you specify this option.(1)
6138 On systems that provide `libgcc' as a shared library, these options
6139 force the use of either the shared or static version respectively.
6140 If no shared version of `libgcc' was built when the compiler was
6141 configured, these options have no effect.
6143 There are several situations in which an application should use the
6144 shared `libgcc' instead of the static version. The most common of
6145 these is when the application wishes to throw and catch exceptions
6146 across different shared libraries. In that case, each of the
6147 libraries as well as the application itself should use the shared
6150 Therefore, the G++ and GCJ drivers automatically add
6151 `-shared-libgcc' whenever you build a shared library or a main
6152 executable, because C++ and Java programs typically use
6153 exceptions, so this is the right thing to do.
6155 If, instead, you use the GCC driver to create shared libraries,
6156 you may find that they will not always be linked with the shared
6157 `libgcc'. If GCC finds, at its configuration time, that you have
6158 a non-GNU linker or a GNU linker that does not support option
6159 `--eh-frame-hdr', it will link the shared version of `libgcc' into
6160 shared libraries by default. Otherwise, it will take advantage of
6161 the linker and optimize away the linking with the shared version
6162 of `libgcc', linking with the static version of libgcc by default.
6163 This allows exceptions to propagate through such shared
6164 libraries, without incurring relocation costs at library load time.
6166 However, if a library or main executable is supposed to throw or
6167 catch exceptions, you must link it using the G++ or GCJ driver, as
6168 appropriate for the languages used in the program, or using the
6169 option `-shared-libgcc', such that it is linked with the shared
6173 Bind references to global symbols when building a shared object.
6174 Warn about any unresolved references (unless overridden by the
6175 link editor option `-Xlinker -z -Xlinker defs'). Only a few
6176 systems support this option.
6179 Pass OPTION as an option to the linker. You can use this to
6180 supply system-specific linker options which GCC does not know how
6183 If you want to pass an option that takes an argument, you must use
6184 `-Xlinker' twice, once for the option and once for the argument.
6185 For example, to pass `-assert definitions', you must write
6186 `-Xlinker -assert -Xlinker definitions'. It does not work to write
6187 `-Xlinker "-assert definitions"', because this passes the entire
6188 string as a single argument, which is not what the linker expects.
6191 Pass OPTION as an option to the linker. If OPTION contains
6192 commas, it is split into multiple options at the commas.
6195 Pretend the symbol SYMBOL is undefined, to force linking of
6196 library modules to define it. You can use `-u' multiple times with
6197 different symbols to force loading of additional library modules.
6199 ---------- Footnotes ----------
6201 (1) On some systems, `gcc -shared' needs to build supplementary stub
6202 code for constructors to work. On multi-libbed systems, `gcc -shared'
6203 must select the correct support libraries to link against. Failing to
6204 supply the correct flags may lead to subtle defects. Supplying them in
6205 cases where they are not necessary is innocuous.
6208 File: gcc.info, Node: Directory Options, Next: Spec Files, Prev: Link Options, Up: Invoking GCC
6210 3.14 Options for Directory Search
6211 =================================
6213 These options specify directories to search for header files, for
6214 libraries and for parts of the compiler:
6217 Add the directory DIR to the head of the list of directories to be
6218 searched for header files. This can be used to override a system
6219 header file, substituting your own version, since these
6220 directories are searched before the system header file
6221 directories. However, you should not use this option to add
6222 directories that contain vendor-supplied system header files (use
6223 `-isystem' for that). If you use more than one `-I' option, the
6224 directories are scanned in left-to-right order; the standard
6225 system directories come after.
6227 If a standard system include directory, or a directory specified
6228 with `-isystem', is also specified with `-I', the `-I' option will
6229 be ignored. The directory will still be searched but as a system
6230 directory at its normal position in the system include chain.
6231 This is to ensure that GCC's procedure to fix buggy system headers
6232 and the ordering for the include_next directive are not
6233 inadvertently changed. If you really need to change the search
6234 order for system directories, use the `-nostdinc' and/or
6238 Add the directory DIR to the head of the list of directories to be
6239 searched for header files only for the case of `#include "FILE"';
6240 they are not searched for `#include <FILE>', otherwise just like
6244 Add directory DIR to the list of directories to be searched for
6248 This option specifies where to find the executables, libraries,
6249 include files, and data files of the compiler itself.
6251 The compiler driver program runs one or more of the subprograms
6252 `cpp', `cc1', `as' and `ld'. It tries PREFIX as a prefix for each
6253 program it tries to run, both with and without `MACHINE/VERSION/'
6254 (*note Target Options::).
6256 For each subprogram to be run, the compiler driver first tries the
6257 `-B' prefix, if any. If that name is not found, or if `-B' was
6258 not specified, the driver tries two standard prefixes, which are
6259 `/usr/lib/gcc/' and `/usr/local/lib/gcc/'. If neither of those
6260 results in a file name that is found, the unmodified program name
6261 is searched for using the directories specified in your `PATH'
6262 environment variable.
6264 The compiler will check to see if the path provided by the `-B'
6265 refers to a directory, and if necessary it will add a directory
6266 separator character at the end of the path.
6268 `-B' prefixes that effectively specify directory names also apply
6269 to libraries in the linker, because the compiler translates these
6270 options into `-L' options for the linker. They also apply to
6271 includes files in the preprocessor, because the compiler
6272 translates these options into `-isystem' options for the
6273 preprocessor. In this case, the compiler appends `include' to the
6276 The run-time support file `libgcc.a' can also be searched for using
6277 the `-B' prefix, if needed. If it is not found there, the two
6278 standard prefixes above are tried, and that is all. The file is
6279 left out of the link if it is not found by those means.
6281 Another way to specify a prefix much like the `-B' prefix is to use
6282 the environment variable `GCC_EXEC_PREFIX'. *Note Environment
6285 As a special kludge, if the path provided by `-B' is
6286 `[dir/]stageN/', where N is a number in the range 0 to 9, then it
6287 will be replaced by `[dir/]include'. This is to help with
6288 boot-strapping the compiler.
6291 Process FILE after the compiler reads in the standard `specs'
6292 file, in order to override the defaults that the `gcc' driver
6293 program uses when determining what switches to pass to `cc1',
6294 `cc1plus', `as', `ld', etc. More than one `-specs=FILE' can be
6295 specified on the command line, and they are processed in order,
6299 This option has been deprecated. Please use `-iquote' instead for
6300 `-I' directories before the `-I-' and remove the `-I-'. Any
6301 directories you specify with `-I' options before the `-I-' option
6302 are searched only for the case of `#include "FILE"'; they are not
6303 searched for `#include <FILE>'.
6305 If additional directories are specified with `-I' options after
6306 the `-I-', these directories are searched for all `#include'
6307 directives. (Ordinarily _all_ `-I' directories are used this way.)
6309 In addition, the `-I-' option inhibits the use of the current
6310 directory (where the current input file came from) as the first
6311 search directory for `#include "FILE"'. There is no way to
6312 override this effect of `-I-'. With `-I.' you can specify
6313 searching the directory which was current when the compiler was
6314 invoked. That is not exactly the same as what the preprocessor
6315 does by default, but it is often satisfactory.
6317 `-I-' does not inhibit the use of the standard system directories
6318 for header files. Thus, `-I-' and `-nostdinc' are independent.
6321 File: gcc.info, Node: Spec Files, Next: Target Options, Prev: Directory Options, Up: Invoking GCC
6323 3.15 Specifying subprocesses and the switches to pass to them
6324 =============================================================
6326 `gcc' is a driver program. It performs its job by invoking a sequence
6327 of other programs to do the work of compiling, assembling and linking.
6328 GCC interprets its command-line parameters and uses these to deduce
6329 which programs it should invoke, and which command-line options it
6330 ought to place on their command lines. This behavior is controlled by
6331 "spec strings". In most cases there is one spec string for each
6332 program that GCC can invoke, but a few programs have multiple spec
6333 strings to control their behavior. The spec strings built into GCC can
6334 be overridden by using the `-specs=' command-line switch to specify a
6337 "Spec files" are plaintext files that are used to construct spec
6338 strings. They consist of a sequence of directives separated by blank
6339 lines. The type of directive is determined by the first non-whitespace
6340 character on the line and it can be one of the following:
6343 Issues a COMMAND to the spec file processor. The commands that can
6347 Search for FILE and insert its text at the current point in
6350 `%include_noerr <FILE>'
6351 Just like `%include', but do not generate an error message if
6352 the include file cannot be found.
6354 `%rename OLD_NAME NEW_NAME'
6355 Rename the spec string OLD_NAME to NEW_NAME.
6359 This tells the compiler to create, override or delete the named
6360 spec string. All lines after this directive up to the next
6361 directive or blank line are considered to be the text for the spec
6362 string. If this results in an empty string then the spec will be
6363 deleted. (Or, if the spec did not exist, then nothing will
6364 happened.) Otherwise, if the spec does not currently exist a new
6365 spec will be created. If the spec does exist then its contents
6366 will be overridden by the text of this directive, unless the first
6367 character of that text is the `+' character, in which case the
6368 text will be appended to the spec.
6371 Creates a new `[SUFFIX] spec' pair. All lines after this directive
6372 and up to the next directive or blank line are considered to make
6373 up the spec string for the indicated suffix. When the compiler
6374 encounters an input file with the named suffix, it will processes
6375 the spec string in order to work out how to compile that file.
6381 This says that any input file whose name ends in `.ZZ' should be
6382 passed to the program `z-compile', which should be invoked with the
6383 command-line switch `-input' and with the result of performing the
6384 `%i' substitution. (See below.)
6386 As an alternative to providing a spec string, the text that
6387 follows a suffix directive can be one of the following:
6390 This says that the suffix is an alias for a known LANGUAGE.
6391 This is similar to using the `-x' command-line switch to GCC
6392 to specify a language explicitly. For example:
6397 Says that .ZZ files are, in fact, C++ source files.
6400 This causes an error messages saying:
6402 NAME compiler not installed on this system.
6404 GCC already has an extensive list of suffixes built into it. This
6405 directive will add an entry to the end of the list of suffixes, but
6406 since the list is searched from the end backwards, it is
6407 effectively possible to override earlier entries using this
6411 GCC has the following spec strings built into it. Spec files can
6412 override these strings or create their own. Note that individual
6413 targets can also add their own spec strings to this list.
6415 asm Options to pass to the assembler
6416 asm_final Options to pass to the assembler post-processor
6417 cpp Options to pass to the C preprocessor
6418 cc1 Options to pass to the C compiler
6419 cc1plus Options to pass to the C++ compiler
6420 endfile Object files to include at the end of the link
6421 link Options to pass to the linker
6422 lib Libraries to include on the command line to the linker
6423 libgcc Decides which GCC support library to pass to the linker
6424 linker Sets the name of the linker
6425 predefines Defines to be passed to the C preprocessor
6426 signed_char Defines to pass to CPP to say whether `char' is signed
6428 startfile Object files to include at the start of the link
6430 Here is a small example of a spec file:
6435 --start-group -lgcc -lc -leval1 --end-group %(old_lib)
6437 This example renames the spec called `lib' to `old_lib' and then
6438 overrides the previous definition of `lib' with a new one. The new
6439 definition adds in some extra command-line options before including the
6440 text of the old definition.
6442 "Spec strings" are a list of command-line options to be passed to their
6443 corresponding program. In addition, the spec strings can contain
6444 `%'-prefixed sequences to substitute variable text or to conditionally
6445 insert text into the command line. Using these constructs it is
6446 possible to generate quite complex command lines.
6448 Here is a table of all defined `%'-sequences for spec strings. Note
6449 that spaces are not generated automatically around the results of
6450 expanding these sequences. Therefore you can concatenate them together
6451 or combine them with constant text in a single argument.
6454 Substitute one `%' into the program name or argument.
6457 Substitute the name of the input file being processed.
6460 Substitute the basename of the input file being processed. This
6461 is the substring up to (and not including) the last period and not
6462 including the directory.
6465 This is the same as `%b', but include the file suffix (text after
6469 Marks the argument containing or following the `%d' as a temporary
6470 file name, so that that file will be deleted if GCC exits
6471 successfully. Unlike `%g', this contributes no text to the
6475 Substitute a file name that has suffix SUFFIX and is chosen once
6476 per compilation, and mark the argument in the same way as `%d'.
6477 To reduce exposure to denial-of-service attacks, the file name is
6478 now chosen in a way that is hard to predict even when previously
6479 chosen file names are known. For example, `%g.s ... %g.o ... %g.s'
6480 might turn into `ccUVUUAU.s ccXYAXZ12.o ccUVUUAU.s'. SUFFIX
6481 matches the regexp `[.A-Za-z]*' or the special string `%O', which
6482 is treated exactly as if `%O' had been preprocessed. Previously,
6483 `%g' was simply substituted with a file name chosen once per
6484 compilation, without regard to any appended suffix (which was
6485 therefore treated just like ordinary text), making such attacks
6486 more likely to succeed.
6489 Like `%g', but generates a new temporary file name even if
6490 `%uSUFFIX' was already seen.
6493 Substitutes the last file name generated with `%uSUFFIX',
6494 generating a new one if there is no such last file name. In the
6495 absence of any `%uSUFFIX', this is just like `%gSUFFIX', except
6496 they don't share the same suffix _space_, so `%g.s ... %U.s ...
6497 %g.s ... %U.s' would involve the generation of two distinct file
6498 names, one for each `%g.s' and another for each `%U.s'.
6499 Previously, `%U' was simply substituted with a file name chosen
6500 for the previous `%u', without regard to any appended suffix.
6503 Substitutes the name of the `HOST_BIT_BUCKET', if any, and if it is
6504 writable, and if save-temps is off; otherwise, substitute the name
6505 of a temporary file, just like `%u'. This temporary file is not
6506 meant for communication between processes, but rather as a junk
6511 Like `%g', except if `-pipe' is in effect. In that case `%|'
6512 substitutes a single dash and `%m' substitutes nothing at all.
6513 These are the two most common ways to instruct a program that it
6514 should read from standard input or write to standard output. If
6515 you need something more elaborate you can use an `%{pipe:`X'}'
6516 construct: see for example `f/lang-specs.h'.
6519 Substitutes .SUFFIX for the suffixes of a matched switch's args
6520 when it is subsequently output with `%*'. SUFFIX is terminated by
6521 the next space or %.
6524 Marks the argument containing or following the `%w' as the
6525 designated output file of this compilation. This puts the argument
6526 into the sequence of arguments that `%o' will substitute later.
6529 Substitutes the names of all the output files, with spaces
6530 automatically placed around them. You should write spaces around
6531 the `%o' as well or the results are undefined. `%o' is for use in
6532 the specs for running the linker. Input files whose names have no
6533 recognized suffix are not compiled at all, but they are included
6534 among the output files, so they will be linked.
6537 Substitutes the suffix for object files. Note that this is
6538 handled specially when it immediately follows `%g, %u, or %U',
6539 because of the need for those to form complete file names. The
6540 handling is such that `%O' is treated exactly as if it had already
6541 been substituted, except that `%g, %u, and %U' do not currently
6542 support additional SUFFIX characters following `%O' as they would
6543 following, for example, `.o'.
6546 Substitutes the standard macro predefinitions for the current
6547 target machine. Use this when running `cpp'.
6550 Like `%p', but puts `__' before and after the name of each
6551 predefined macro, except for macros that start with `__' or with
6552 `_L', where L is an uppercase letter. This is for ISO C.
6555 Substitute any of `-iprefix' (made from `GCC_EXEC_PREFIX'),
6556 `-isysroot' (made from `TARGET_SYSTEM_ROOT'), and `-isystem' (made
6557 from `COMPILER_PATH' and `-B' options) as necessary.
6560 Current argument is the name of a library or startup file of some
6561 sort. Search for that file in a standard list of directories and
6562 substitute the full name found.
6565 Print STR as an error message. STR is terminated by a newline.
6566 Use this when inconsistent options are detected.
6569 Substitute the contents of spec string NAME at this point.
6572 Like `%(...)' but put `__' around `-D' arguments.
6575 Accumulate an option for `%X'.
6578 Output the accumulated linker options specified by `-Wl' or a `%x'
6582 Output the accumulated assembler options specified by `-Wa'.
6585 Output the accumulated preprocessor options specified by `-Wp'.
6588 Process the `asm' spec. This is used to compute the switches to
6589 be passed to the assembler.
6592 Process the `asm_final' spec. This is a spec string for passing
6593 switches to an assembler post-processor, if such a program is
6597 Process the `link' spec. This is the spec for computing the
6598 command line passed to the linker. Typically it will make use of
6599 the `%L %G %S %D and %E' sequences.
6602 Dump out a `-L' option for each directory that GCC believes might
6603 contain startup files. If the target supports multilibs then the
6604 current multilib directory will be prepended to each of these
6608 Process the `lib' spec. This is a spec string for deciding which
6609 libraries should be included on the command line to the linker.
6612 Process the `libgcc' spec. This is a spec string for deciding
6613 which GCC support library should be included on the command line
6617 Process the `startfile' spec. This is a spec for deciding which
6618 object files should be the first ones passed to the linker.
6619 Typically this might be a file named `crt0.o'.
6622 Process the `endfile' spec. This is a spec string that specifies
6623 the last object files that will be passed to the linker.
6626 Process the `cpp' spec. This is used to construct the arguments
6627 to be passed to the C preprocessor.
6630 Process the `cc1' spec. This is used to construct the options to
6631 be passed to the actual C compiler (`cc1').
6634 Process the `cc1plus' spec. This is used to construct the options
6635 to be passed to the actual C++ compiler (`cc1plus').
6638 Substitute the variable part of a matched option. See below.
6639 Note that each comma in the substituted string is replaced by a
6643 Remove all occurrences of `-S' from the command line. Note--this
6644 command is position dependent. `%' commands in the spec string
6645 before this one will see `-S', `%' commands in the spec string
6646 after this one will not.
6649 Call the named function FUNCTION, passing it ARGS. ARGS is first
6650 processed as a nested spec string, then split into an argument
6651 vector in the usual fashion. The function returns a string which
6652 is processed as if it had appeared literally as part of the
6655 The following built-in spec functions are provided:
6658 The `if-exists' spec function takes one argument, an absolute
6659 pathname to a file. If the file exists, `if-exists' returns
6660 the pathname. Here is a small example of its usage:
6663 crt0%O%s %:if-exists(crti%O%s) crtbegin%O%s
6666 The `if-exists-else' spec function is similar to the
6667 `if-exists' spec function, except that it takes two
6668 arguments. The first argument is an absolute pathname to a
6669 file. If the file exists, `if-exists-else' returns the
6670 pathname. If it does not exist, it returns the second
6671 argument. This way, `if-exists-else' can be used to select
6672 one file or another, based on the existence of the first.
6673 Here is a small example of its usage:
6676 crt0%O%s %:if-exists(crti%O%s) \
6677 %:if-exists-else(crtbeginT%O%s crtbegin%O%s)
6680 The `replace-outfile' spec function takes two arguments. It
6681 looks for the first argument in the outfiles array and
6682 replaces it with the second argument. Here is a small
6683 example of its usage:
6685 %{fgnu-runtime:%:replace-outfile(-lobjc -lobjc-gnu)}
6689 Substitutes the `-S' switch, if that switch was given to GCC. If
6690 that switch was not specified, this substitutes nothing. Note that
6691 the leading dash is omitted when specifying this option, and it is
6692 automatically inserted if the substitution is performed. Thus the
6693 spec string `%{foo}' would match the command-line option `-foo'
6694 and would output the command line option `-foo'.
6697 Like %{`S'} but mark last argument supplied within as a file to be
6701 Substitutes all the switches specified to GCC whose names start
6702 with `-S', but which also take an argument. This is used for
6703 switches like `-o', `-D', `-I', etc. GCC considers `-o foo' as
6704 being one switch whose names starts with `o'. %{o*} would
6705 substitute this text, including the space. Thus two arguments
6709 Like %{`S'*}, but preserve order of `S' and `T' options (the order
6710 of `S' and `T' in the spec is not significant). There can be any
6711 number of ampersand-separated variables; for each the wild card is
6712 optional. Useful for CPP as `%{D*&U*&A*}'.
6715 Substitutes `X', if the `-S' switch was given to GCC.
6718 Substitutes `X', if the `-S' switch was _not_ given to GCC.
6721 Substitutes `X' if one or more switches whose names start with
6722 `-S' are specified to GCC. Normally `X' is substituted only once,
6723 no matter how many such switches appeared. However, if `%*'
6724 appears somewhere in `X', then `X' will be substituted once for
6725 each matching switch, with the `%*' replaced by the part of that
6726 switch that matched the `*'.
6729 Substitutes `X', if processing a file with suffix `S'.
6732 Substitutes `X', if _not_ processing a file with suffix `S'.
6735 Substitutes `X' if either `-S' or `-P' was given to GCC. This may
6736 be combined with `!', `.', and `*' sequences as well, although
6737 they have a stronger binding than the `|'. If `%*' appears in
6738 `X', all of the alternatives must be starred, and only the first
6739 matching alternative is substituted.
6741 For example, a spec string like this:
6743 %{.c:-foo} %{!.c:-bar} %{.c|d:-baz} %{!.c|d:-boggle}
6745 will output the following command-line options from the following
6746 input command-line options:
6750 -d fred.c -foo -baz -boggle
6751 -d jim.d -bar -baz -boggle
6754 If `S' was given to GCC, substitutes `X'; else if `T' was given to
6755 GCC, substitutes `Y'; else substitutes `D'. There can be as many
6756 clauses as you need. This may be combined with `.', `!', `|', and
6760 The conditional text `X' in a %{`S':`X'} or similar construct may
6761 contain other nested `%' constructs or spaces, or even newlines. They
6762 are processed as usual, as described above. Trailing white space in
6763 `X' is ignored. White space may also appear anywhere on the left side
6764 of the colon in these constructs, except between `.' or `*' and the
6767 The `-O', `-f', `-m', and `-W' switches are handled specifically in
6768 these constructs. If another value of `-O' or the negated form of a
6769 `-f', `-m', or `-W' switch is found later in the command line, the
6770 earlier switch value is ignored, except with {`S'*} where `S' is just
6771 one letter, which passes all matching options.
6773 The character `|' at the beginning of the predicate text is used to
6774 indicate that a command should be piped to the following command, but
6775 only if `-pipe' is specified.
6777 It is built into GCC which switches take arguments and which do not.
6778 (You might think it would be useful to generalize this to allow each
6779 compiler's spec to say which switches take arguments. But this cannot
6780 be done in a consistent fashion. GCC cannot even decide which input
6781 files have been specified without knowing which switches take arguments,
6782 and it must know which input files to compile in order to tell which
6785 GCC also knows implicitly that arguments starting in `-l' are to be
6786 treated as compiler output files, and passed to the linker in their
6787 proper position among the other output files.
6790 File: gcc.info, Node: Target Options, Next: Submodel Options, Prev: Spec Files, Up: Invoking GCC
6792 3.16 Specifying Target Machine and Compiler Version
6793 ===================================================
6795 The usual way to run GCC is to run the executable called `gcc', or
6796 `<machine>-gcc' when cross-compiling, or `<machine>-gcc-<version>' to
6797 run a version other than the one that was installed last. Sometimes
6798 this is inconvenient, so GCC provides options that will switch to
6799 another cross-compiler or version.
6802 The argument MACHINE specifies the target machine for compilation.
6804 The value to use for MACHINE is the same as was specified as the
6805 machine type when configuring GCC as a cross-compiler. For
6806 example, if a cross-compiler was configured with `configure
6807 i386v', meaning to compile for an 80386 running System V, then you
6808 would specify `-b i386v' to run that cross compiler.
6811 The argument VERSION specifies which version of GCC to run. This
6812 is useful when multiple versions are installed. For example,
6813 VERSION might be `2.0', meaning to run GCC version 2.0.
6815 The `-V' and `-b' options work by running the
6816 `<machine>-gcc-<version>' executable, so there's no real reason to use
6817 them if you can just run that directly.
6820 File: gcc.info, Node: Submodel Options, Next: Code Gen Options, Prev: Target Options, Up: Invoking GCC
6822 3.17 Hardware Models and Configurations
6823 =======================================
6825 Earlier we discussed the standard option `-b' which chooses among
6826 different installed compilers for completely different target machines,
6827 such as VAX vs. 68000 vs. 80386.
6829 In addition, each of these target machine types can have its own
6830 special options, starting with `-m', to choose among various hardware
6831 models or configurations--for example, 68010 vs 68020, floating
6832 coprocessor or none. A single installed version of the compiler can
6833 compile for any model or configuration, according to the options
6836 Some configurations of the compiler also support additional special
6837 options, usually for compatibility with other compilers on the same
6840 These options are defined by the macro `TARGET_SWITCHES' in the
6841 machine description. The default for the options is also defined by
6842 that macro, which enables you to change the defaults.
6851 * DEC Alpha Options::
6852 * DEC Alpha/VMS Options::
6856 * i386 and x86-64 Options::
6868 * RS/6000 and PowerPC Options::
6869 * S/390 and zSeries Options::
6872 * System V Options::
6873 * TMS320C3x/C4x Options::
6877 * Xstormy16 Options::
6882 File: gcc.info, Node: ARC Options, Next: ARM Options, Up: Submodel Options
6887 These options are defined for ARC implementations:
6890 Compile code for little endian mode. This is the default.
6893 Compile code for big endian mode.
6896 Prepend the name of the cpu to all public symbol names. In
6897 multiple-processor systems, there are many ARC variants with
6898 different instruction and register set characteristics. This flag
6899 prevents code compiled for one cpu to be linked with code compiled
6900 for another. No facility exists for handling variants that are
6901 "almost identical". This is an all or nothing option.
6904 Compile code for ARC variant CPU. Which variants are supported
6905 depend on the configuration. All variants support `-mcpu=base',
6906 this is the default.
6908 `-mtext=TEXT-SECTION'
6909 `-mdata=DATA-SECTION'
6910 `-mrodata=READONLY-DATA-SECTION'
6911 Put functions, data, and readonly data in TEXT-SECTION,
6912 DATA-SECTION, and READONLY-DATA-SECTION respectively by default.
6913 This can be overridden with the `section' attribute. *Note
6914 Variable Attributes::.
6918 File: gcc.info, Node: ARM Options, Next: AVR Options, Prev: ARC Options, Up: Submodel Options
6923 These `-m' options are defined for Advanced RISC Machines (ARM)
6927 Generate code for the specified ABI. Permissible values are:
6928 `apcs-gnu', `atpcs', `aapcs' and `iwmmxt'.
6931 Generate a stack frame that is compliant with the ARM Procedure
6932 Call Standard for all functions, even if this is not strictly
6933 necessary for correct execution of the code. Specifying
6934 `-fomit-frame-pointer' with this option will cause the stack
6935 frames not to be generated for leaf functions. The default is
6939 This is a synonym for `-mapcs-frame'.
6942 Generate code which supports calling between the ARM and Thumb
6943 instruction sets. Without this option the two instruction sets
6944 cannot be reliably used inside one program. The default is
6945 `-mno-thumb-interwork', since slightly larger code is generated
6946 when `-mthumb-interwork' is specified.
6949 Prevent the reordering of instructions in the function prolog, or
6950 the merging of those instruction with the instructions in the
6951 function's body. This means that all functions will start with a
6952 recognizable set of instructions (or in fact one of a choice from
6953 a small set of different function prologues), and this information
6954 can be used to locate the start if functions inside an executable
6955 piece of code. The default is `-msched-prolog'.
6958 Generate output containing floating point instructions. This is
6962 Generate output containing library calls for floating point.
6963 *Warning:* the requisite libraries are not available for all ARM
6964 targets. Normally the facilities of the machine's usual C
6965 compiler are used, but this cannot be done directly in
6966 cross-compilation. You must make your own arrangements to provide
6967 suitable library functions for cross-compilation.
6969 `-msoft-float' changes the calling convention in the output file;
6970 therefore, it is only useful if you compile _all_ of a program with
6971 this option. In particular, you need to compile `libgcc.a', the
6972 library that comes with GCC, with `-msoft-float' in order for this
6976 Specifies which ABI to use for floating point values. Permissible
6977 values are: `soft', `softfp' and `hard'.
6979 `soft' and `hard' are equivalent to `-msoft-float' and
6980 `-mhard-float' respectively. `softfp' allows the generation of
6981 floating point instructions, but still uses the soft-float calling
6985 Generate code for a processor running in little-endian mode. This
6986 is the default for all standard configurations.
6989 Generate code for a processor running in big-endian mode; the
6990 default is to compile code for a little-endian processor.
6992 `-mwords-little-endian'
6993 This option only applies when generating code for big-endian
6994 processors. Generate code for a little-endian word order but a
6995 big-endian byte order. That is, a byte order of the form
6996 `32107654'. Note: this option should only be used if you require
6997 compatibility with code for big-endian ARM processors generated by
6998 versions of the compiler prior to 2.8.
7001 This specifies the name of the target ARM processor. GCC uses
7002 this name to determine what kind of instructions it can emit when
7003 generating assembly code. Permissible names are: `arm2', `arm250',
7004 `arm3', `arm6', `arm60', `arm600', `arm610', `arm620', `arm7',
7005 `arm7m', `arm7d', `arm7dm', `arm7di', `arm7dmi', `arm70', `arm700',
7006 `arm700i', `arm710', `arm710c', `arm7100', `arm7500', `arm7500fe',
7007 `arm7tdmi', `arm7tdmi-s', `arm8', `strongarm', `strongarm110',
7008 `strongarm1100', `arm8', `arm810', `arm9', `arm9e', `arm920',
7009 `arm920t', `arm922t', `arm946e-s', `arm966e-s', `arm968e-s',
7010 `arm926ej-s', `arm940t', `arm9tdmi', `arm10tdmi', `arm1020t',
7011 `arm1026ej-s', `arm10e', `arm1020e', `arm1022e', `arm1136j-s',
7012 `arm1136jf-s', `mpcore', `mpcorenovfp', `arm1176jz-s',
7013 `arm1176jzf-s', `xscale', `iwmmxt', `ep9312'.
7016 This option is very similar to the `-mcpu=' option, except that
7017 instead of specifying the actual target processor type, and hence
7018 restricting which instructions can be used, it specifies that GCC
7019 should tune the performance of the code as if the target were of
7020 the type specified in this option, but still choosing the
7021 instructions that it will generate based on the cpu specified by a
7022 `-mcpu=' option. For some ARM implementations better performance
7023 can be obtained by using this option.
7026 This specifies the name of the target ARM architecture. GCC uses
7027 this name to determine what kind of instructions it can emit when
7028 generating assembly code. This option can be used in conjunction
7029 with or instead of the `-mcpu=' option. Permissible names are:
7030 `armv2', `armv2a', `armv3', `armv3m', `armv4', `armv4t', `armv5',
7031 `armv5t', `armv5te', `armv6', `armv6j', `iwmmxt', `ep9312'.
7036 This specifies what floating point hardware (or hardware
7037 emulation) is available on the target. Permissible names are:
7038 `fpa', `fpe2', `fpe3', `maverick', `vfp'. `-mfp' and `-mfpe' are
7039 synonyms for `-mfpu'=`fpe'NUMBER, for compatibility with older
7042 If `-msoft-float' is specified this specifies the format of
7043 floating point values.
7045 `-mstructure-size-boundary=N'
7046 The size of all structures and unions will be rounded up to a
7047 multiple of the number of bits set by this option. Permissible
7048 values are 8, 32 and 64. The default value varies for different
7049 toolchains. For the COFF targeted toolchain the default value is
7050 8. A value of 64 is only allowed if the underlying ABI supports
7053 Specifying the larger number can produce faster, more efficient
7054 code, but can also increase the size of the program. Different
7055 values are potentially incompatible. Code compiled with one value
7056 cannot necessarily expect to work with code or libraries compiled
7057 with another value, if they exchange information using structures
7060 `-mabort-on-noreturn'
7061 Generate a call to the function `abort' at the end of a `noreturn'
7062 function. It will be executed if the function tries to return.
7066 Tells the compiler to perform function calls by first loading the
7067 address of the function into a register and then performing a
7068 subroutine call on this register. This switch is needed if the
7069 target function will lie outside of the 64 megabyte addressing
7070 range of the offset based version of subroutine call instruction.
7072 Even if this switch is enabled, not all function calls will be
7073 turned into long calls. The heuristic is that static functions,
7074 functions which have the `short-call' attribute, functions that
7075 are inside the scope of a `#pragma no_long_calls' directive and
7076 functions whose definitions have already been compiled within the
7077 current compilation unit, will not be turned into long calls. The
7078 exception to this rule is that weak function definitions,
7079 functions with the `long-call' attribute or the `section'
7080 attribute, and functions that are within the scope of a `#pragma
7081 long_calls' directive, will always be turned into long calls.
7083 This feature is not enabled by default. Specifying
7084 `-mno-long-calls' will restore the default behavior, as will
7085 placing the function calls within the scope of a `#pragma
7086 long_calls_off' directive. Note these switches have no effect on
7087 how the compiler generates code to handle function calls via
7090 `-mnop-fun-dllimport'
7091 Disable support for the `dllimport' attribute.
7094 Treat the register used for PIC addressing as read-only, rather
7095 than loading it in the prologue for each function. The run-time
7096 system is responsible for initializing this register with an
7097 appropriate value before execution begins.
7099 `-mpic-register=REG'
7100 Specify the register to be used for PIC addressing. The default
7101 is R10 unless stack-checking is enabled, when R9 is used.
7103 `-mcirrus-fix-invalid-insns'
7104 Insert NOPs into the instruction stream to in order to work around
7105 problems with invalid Maverick instruction combinations. This
7106 option is only valid if the `-mcpu=ep9312' option has been used to
7107 enable generation of instructions for the Cirrus Maverick floating
7108 point co-processor. This option is not enabled by default, since
7109 the problem is only present in older Maverick implementations.
7110 The default can be re-enabled by use of the
7111 `-mno-cirrus-fix-invalid-insns' switch.
7113 `-mpoke-function-name'
7114 Write the name of each function into the text section, directly
7115 preceding the function prologue. The generated code is similar to
7119 .ascii "arm_poke_function_name", 0
7122 .word 0xff000000 + (t1 - t0)
7123 arm_poke_function_name
7125 stmfd sp!, {fp, ip, lr, pc}
7128 When performing a stack backtrace, code can inspect the value of
7129 `pc' stored at `fp + 0'. If the trace function then looks at
7130 location `pc - 12' and the top 8 bits are set, then we know that
7131 there is a function name embedded immediately preceding this
7132 location and has length `((pc[-3]) & 0xff000000)'.
7135 Generate code for the 16-bit Thumb instruction set. The default
7136 is to use the 32-bit ARM instruction set.
7139 Generate a stack frame that is compliant with the Thumb Procedure
7140 Call Standard for all non-leaf functions. (A leaf function is one
7141 that does not call any other functions.) The default is
7145 Generate a stack frame that is compliant with the Thumb Procedure
7146 Call Standard for all leaf functions. (A leaf function is one
7147 that does not call any other functions.) The default is
7148 `-mno-apcs-leaf-frame'.
7150 `-mcallee-super-interworking'
7151 Gives all externally visible functions in the file being compiled
7152 an ARM instruction set header which switches to Thumb mode before
7153 executing the rest of the function. This allows these functions
7154 to be called from non-interworking code.
7156 `-mcaller-super-interworking'
7157 Allows calls via function pointers (including virtual functions) to
7158 execute correctly regardless of whether the target code has been
7159 compiled for interworking or not. There is a small overhead in
7160 the cost of executing a function pointer if this option is enabled.
7164 File: gcc.info, Node: AVR Options, Next: CRIS Options, Prev: ARM Options, Up: Submodel Options
7169 These options are defined for AVR implementations:
7172 Specify ATMEL AVR instruction set or MCU type.
7174 Instruction set avr1 is for the minimal AVR core, not supported by
7175 the C compiler, only for assembler programs (MCU types: at90s1200,
7176 attiny10, attiny11, attiny12, attiny15, attiny28).
7178 Instruction set avr2 (default) is for the classic AVR core with up
7179 to 8K program memory space (MCU types: at90s2313, at90s2323,
7180 attiny22, at90s2333, at90s2343, at90s4414, at90s4433, at90s4434,
7181 at90s8515, at90c8534, at90s8535).
7183 Instruction set avr3 is for the classic AVR core with up to 128K
7184 program memory space (MCU types: atmega103, atmega603, at43usb320,
7187 Instruction set avr4 is for the enhanced AVR core with up to 8K
7188 program memory space (MCU types: atmega8, atmega83, atmega85).
7190 Instruction set avr5 is for the enhanced AVR core with up to 128K
7191 program memory space (MCU types: atmega16, atmega161, atmega163,
7192 atmega32, atmega323, atmega64, atmega128, at43usb355, at94k).
7195 Output instruction sizes to the asm file.
7198 Specify the initial stack address, which may be a symbol or
7199 numeric value, `__stack' is the default.
7202 Generated code is not compatible with hardware interrupts. Code
7203 size will be smaller.
7206 Functions prologues/epilogues expanded as call to appropriate
7207 subroutines. Code size will be smaller.
7210 Do not generate tablejump insns which sometimes increase code size.
7213 Change only the low 8 bits of the stack pointer.
7216 Assume int to be 8 bit integer. This affects the sizes of all
7217 types: A char will be 1 byte, an int will be 1 byte, an long will
7218 be 2 bytes and long long will be 4 bytes. Please note that this
7219 option does not comply to the C standards, but it will provide you
7220 with smaller code size.
7223 File: gcc.info, Node: CRIS Options, Next: Darwin Options, Prev: AVR Options, Up: Submodel Options
7228 These options are defined specifically for the CRIS ports.
7230 `-march=ARCHITECTURE-TYPE'
7231 `-mcpu=ARCHITECTURE-TYPE'
7232 Generate code for the specified architecture. The choices for
7233 ARCHITECTURE-TYPE are `v3', `v8' and `v10' for respectively
7234 ETRAX 4, ETRAX 100, and ETRAX 100 LX. Default is `v0' except for
7235 cris-axis-linux-gnu, where the default is `v10'.
7237 `-mtune=ARCHITECTURE-TYPE'
7238 Tune to ARCHITECTURE-TYPE everything applicable about the generated
7239 code, except for the ABI and the set of available instructions.
7240 The choices for ARCHITECTURE-TYPE are the same as for
7241 `-march=ARCHITECTURE-TYPE'.
7243 `-mmax-stack-frame=N'
7244 Warn when the stack frame of a function exceeds N bytes.
7246 `-melinux-stacksize=N'
7247 Only available with the `cris-axis-aout' target. Arranges for
7248 indications in the program to the kernel loader that the stack of
7249 the program should be set to N bytes.
7253 The options `-metrax4' and `-metrax100' are synonyms for
7254 `-march=v3' and `-march=v8' respectively.
7256 `-mmul-bug-workaround'
7257 `-mno-mul-bug-workaround'
7258 Work around a bug in the `muls' and `mulu' instructions for CPU
7259 models where it applies. This option is active by default.
7262 Enable CRIS-specific verbose debug-related information in the
7263 assembly code. This option also has the effect to turn off the
7264 `#NO_APP' formatted-code indicator to the assembler at the
7265 beginning of the assembly file.
7268 Do not use condition-code results from previous instruction;
7269 always emit compare and test instructions before use of condition
7273 Do not emit instructions with side-effects in addressing modes
7274 other than post-increment.
7282 These options (no-options) arranges (eliminate arrangements) for
7283 the stack-frame, individual data and constants to be aligned for
7284 the maximum single data access size for the chosen CPU model. The
7285 default is to arrange for 32-bit alignment. ABI details such as
7286 structure layout are not affected by these options.
7291 Similar to the stack- data- and const-align options above, these
7292 options arrange for stack-frame, writable data and constants to
7293 all be 32-bit, 16-bit or 8-bit aligned. The default is 32-bit
7296 `-mno-prologue-epilogue'
7297 `-mprologue-epilogue'
7298 With `-mno-prologue-epilogue', the normal function prologue and
7299 epilogue that sets up the stack-frame are omitted and no return
7300 instructions or return sequences are generated in the code. Use
7301 this option only together with visual inspection of the compiled
7302 code: no warnings or errors are generated when call-saved
7303 registers must be saved, or storage for local variable needs to be
7308 With `-fpic' and `-fPIC', don't generate (do generate) instruction
7309 sequences that load addresses for functions from the PLT part of
7310 the GOT rather than (traditional on other architectures) calls to
7311 the PLT. The default is `-mgotplt'.
7314 Legacy no-op option only recognized with the cris-axis-aout target.
7317 Legacy no-op option only recognized with the cris-axis-elf and
7318 cris-axis-linux-gnu targets.
7321 Only recognized with the cris-axis-aout target, where it selects a
7322 GNU/linux-like multilib, include files and instruction set for
7326 Legacy no-op option only recognized with the cris-axis-linux-gnu
7330 This option, recognized for the cris-axis-aout and cris-axis-elf
7331 arranges to link with input-output functions from a simulator
7332 library. Code, initialized data and zero-initialized data are
7333 allocated consecutively.
7336 Like `-sim', but pass linker options to locate initialized data at
7337 0x40000000 and zero-initialized data at 0x80000000.
7340 File: gcc.info, Node: Darwin Options, Next: DEC Alpha Options, Prev: CRIS Options, Up: Submodel Options
7342 3.17.5 Darwin Options
7343 ---------------------
7345 These options are defined for all architectures running the Darwin
7348 FSF GCC on Darwin does not create "fat" object files; it will create
7349 an object file for the single architecture that it was built to target.
7350 Apple's GCC on Darwin does create "fat" files if multiple `-arch'
7351 options are used; it does so by running the compiler or linker multiple
7352 times and joining the results together with `lipo'.
7354 The subtype of the file created (like `ppc7400' or `ppc970' or `i686')
7355 is determined by the flags that specify the ISA that GCC is targetting,
7356 like `-mcpu' or `-march'. The `-force_cpusubtype_ALL' option can be
7357 used to override this.
7359 The Darwin tools vary in their behavior when presented with an ISA
7360 mismatch. The assembler, `as', will only permit instructions to be
7361 used that are valid for the subtype of the file it is generating, so
7362 you cannot put 64-bit instructions in an `ppc750' object file. The
7363 linker for shared libraries, `/usr/bin/libtool', will fail and print an
7364 error if asked to create a shared library with a less restrictive
7365 subtype than its input files (for instance, trying to put a `ppc970'
7366 object file in a `ppc7400' library). The linker for executables, `ld',
7367 will quietly give the executable the most restrictive subtype of any of
7371 Add the framework directory DIR to the head of the list of
7372 directories to be searched for header files. These directories are
7373 interleaved with those specified by `-I' options and are scanned
7374 in a left-to-right order.
7376 A framework directory is a directory with frameworks in it. A
7377 framework is a directory with a `"Headers"' and/or
7378 `"PrivateHeaders"' directory contained directly in it that ends in
7379 `".framework"'. The name of a framework is the name of this
7380 directory excluding the `".framework"'. Headers associated with
7381 the framework are found in one of those two directories, with
7382 `"Headers"' being searched first. A subframework is a framework
7383 directory that is in a framework's `"Frameworks"' directory.
7384 Includes of subframework headers can only appear in a header of a
7385 framework that contains the subframework, or in a sibling
7386 subframework header. Two subframeworks are siblings if they occur
7387 in the same framework. A subframework should not have the same
7388 name as a framework, a warning will be issued if this is violated.
7389 Currently a subframework cannot have subframeworks, in the
7390 future, the mechanism may be extended to support this. The
7391 standard frameworks can be found in `"/System/Library/Frameworks"'
7392 and `"/Library/Frameworks"'. An example include looks like
7393 `#include <Framework/header.h>', where `Framework' denotes the
7394 name of the framework and header.h is found in the
7395 `"PrivateHeaders"' or `"Headers"' directory.
7398 Emit debugging information for symbols that are used. For STABS
7399 debugging format, this enables `-feliminate-unused-debug-symbols'.
7400 This is by default ON.
7403 Emit debugging information for all symbols and types.
7406 Override the defaults for `bool' so that `sizeof(bool)==1'. By
7407 default `sizeof(bool)' is `4' when compiling for Darwin/PowerPC
7408 and `1' when compiling for Darwin/x86, so this option has no
7411 *Warning:* The `-mone-byte-bool' switch causes GCC to generate
7412 code that is not binary compatible with code generated without
7413 that switch. Using this switch may require recompiling all other
7414 modules in a program, including system libraries. Use this switch
7415 to conform to a non-default data model.
7417 `-mfix-and-continue'
7418 `-ffix-and-continue'
7420 Generate code suitable for fast turn around development. Needed to
7421 enable gdb to dynamically load `.o' files into already running
7422 programs. `-findirect-data' and `-ffix-and-continue' are provided
7423 for backwards compatibility.
7426 Loads all members of static archive libraries. See man ld(1) for
7429 `-arch_errors_fatal'
7430 Cause the errors having to do with files that have the wrong
7431 architecture to be fatal.
7434 Causes the output file to be marked such that the dynamic linker
7435 will bind all undefined references when the file is loaded or
7439 Produce a Mach-o bundle format file. See man ld(1) for more
7442 `-bundle_loader EXECUTABLE'
7443 This option specifies the EXECUTABLE that will be loading the build
7444 output file being linked. See man ld(1) for more information.
7447 When passed this option, GCC will produce a dynamic library
7448 instead of an executable when linking, using the Darwin `libtool'
7451 `-force_cpusubtype_ALL'
7452 This causes GCC's output file to have the ALL subtype, instead of
7453 one controlled by the `-mcpu' or `-march' option.
7455 `-allowable_client CLIENT_NAME'
7457 `-compatibility_version'
7462 `-dylinker_install_name'
7464 `-exported_symbols_list'
7467 `-force_flat_namespace'
7468 `-headerpad_max_install_names'
7472 `-keep_private_externs'
7475 `-multiply_defined_unused'
7477 `-no_dead_strip_inits_and_terms'
7484 `-prebind_all_twolevel_modules'
7488 `-sectobjectsymbols'
7492 `-sectobjectsymbols'
7495 `-segs_read_only_addr'
7496 `-segs_read_write_addr'
7498 `-seg_addr_table_filename'
7501 `-segs_read_only_addr'
7502 `-segs_read_write_addr'
7507 `-twolevel_namespace'
7510 `-unexported_symbols_list'
7511 `-weak_reference_mismatches'
7513 These options are passed to the Darwin linker. The Darwin linker
7514 man page describes them in detail.
7517 File: gcc.info, Node: DEC Alpha Options, Next: DEC Alpha/VMS Options, Prev: Darwin Options, Up: Submodel Options
7519 3.17.6 DEC Alpha Options
7520 ------------------------
7522 These `-m' options are defined for the DEC Alpha implementations:
7526 Use (do not use) the hardware floating-point instructions for
7527 floating-point operations. When `-msoft-float' is specified,
7528 functions in `libgcc.a' will be used to perform floating-point
7529 operations. Unless they are replaced by routines that emulate the
7530 floating-point operations, or compiled in such a way as to call
7531 such emulations routines, these routines will issue floating-point
7532 operations. If you are compiling for an Alpha without
7533 floating-point operations, you must ensure that the library is
7534 built so as not to call them.
7536 Note that Alpha implementations without floating-point operations
7537 are required to have floating-point registers.
7541 Generate code that uses (does not use) the floating-point register
7542 set. `-mno-fp-regs' implies `-msoft-float'. If the floating-point
7543 register set is not used, floating point operands are passed in
7544 integer registers as if they were integers and floating-point
7545 results are passed in `$0' instead of `$f0'. This is a
7546 non-standard calling sequence, so any function with a
7547 floating-point argument or return value called by code compiled
7548 with `-mno-fp-regs' must also be compiled with that option.
7550 A typical use of this option is building a kernel that does not
7551 use, and hence need not save and restore, any floating-point
7555 The Alpha architecture implements floating-point hardware
7556 optimized for maximum performance. It is mostly compliant with
7557 the IEEE floating point standard. However, for full compliance,
7558 software assistance is required. This option generates code fully
7559 IEEE compliant code _except_ that the INEXACT-FLAG is not
7560 maintained (see below). If this option is turned on, the
7561 preprocessor macro `_IEEE_FP' is defined during compilation. The
7562 resulting code is less efficient but is able to correctly support
7563 denormalized numbers and exceptional IEEE values such as
7564 not-a-number and plus/minus infinity. Other Alpha compilers call
7565 this option `-ieee_with_no_inexact'.
7567 `-mieee-with-inexact'
7568 This is like `-mieee' except the generated code also maintains the
7569 IEEE INEXACT-FLAG. Turning on this option causes the generated
7570 code to implement fully-compliant IEEE math. In addition to
7571 `_IEEE_FP', `_IEEE_FP_EXACT' is defined as a preprocessor macro.
7572 On some Alpha implementations the resulting code may execute
7573 significantly slower than the code generated by default. Since
7574 there is very little code that depends on the INEXACT-FLAG, you
7575 should normally not specify this option. Other Alpha compilers
7576 call this option `-ieee_with_inexact'.
7578 `-mfp-trap-mode=TRAP-MODE'
7579 This option controls what floating-point related traps are enabled.
7580 Other Alpha compilers call this option `-fptm TRAP-MODE'. The
7581 trap mode can be set to one of four values:
7584 This is the default (normal) setting. The only traps that
7585 are enabled are the ones that cannot be disabled in software
7586 (e.g., division by zero trap).
7589 In addition to the traps enabled by `n', underflow traps are
7593 Like `su', but the instructions are marked to be safe for
7594 software completion (see Alpha architecture manual for
7598 Like `su', but inexact traps are enabled as well.
7600 `-mfp-rounding-mode=ROUNDING-MODE'
7601 Selects the IEEE rounding mode. Other Alpha compilers call this
7602 option `-fprm ROUNDING-MODE'. The ROUNDING-MODE can be one of:
7605 Normal IEEE rounding mode. Floating point numbers are
7606 rounded towards the nearest machine number or towards the
7607 even machine number in case of a tie.
7610 Round towards minus infinity.
7613 Chopped rounding mode. Floating point numbers are rounded
7617 Dynamic rounding mode. A field in the floating point control
7618 register (FPCR, see Alpha architecture reference manual)
7619 controls the rounding mode in effect. The C library
7620 initializes this register for rounding towards plus infinity.
7621 Thus, unless your program modifies the FPCR, `d' corresponds
7622 to round towards plus infinity.
7624 `-mtrap-precision=TRAP-PRECISION'
7625 In the Alpha architecture, floating point traps are imprecise.
7626 This means without software assistance it is impossible to recover
7627 from a floating trap and program execution normally needs to be
7628 terminated. GCC can generate code that can assist operating
7629 system trap handlers in determining the exact location that caused
7630 a floating point trap. Depending on the requirements of an
7631 application, different levels of precisions can be selected:
7634 Program precision. This option is the default and means a
7635 trap handler can only identify which program caused a
7636 floating point exception.
7639 Function precision. The trap handler can determine the
7640 function that caused a floating point exception.
7643 Instruction precision. The trap handler can determine the
7644 exact instruction that caused a floating point exception.
7646 Other Alpha compilers provide the equivalent options called
7647 `-scope_safe' and `-resumption_safe'.
7650 This option marks the generated code as IEEE conformant. You must
7651 not use this option unless you also specify `-mtrap-precision=i'
7652 and either `-mfp-trap-mode=su' or `-mfp-trap-mode=sui'. Its only
7653 effect is to emit the line `.eflag 48' in the function prologue of
7654 the generated assembly file. Under DEC Unix, this has the effect
7655 that IEEE-conformant math library routines will be linked in.
7658 Normally GCC examines a 32- or 64-bit integer constant to see if
7659 it can construct it from smaller constants in two or three
7660 instructions. If it cannot, it will output the constant as a
7661 literal and generate code to load it from the data segment at
7664 Use this option to require GCC to construct _all_ integer constants
7665 using code, even if it takes more instructions (the maximum is
7668 You would typically use this option to build a shared library
7669 dynamic loader. Itself a shared library, it must relocate itself
7670 in memory before it can find the variables and constants in its
7675 Select whether to generate code to be assembled by the
7676 vendor-supplied assembler (`-malpha-as') or by the GNU assembler
7687 Indicate whether GCC should generate code to use the optional BWX,
7688 CIX, FIX and MAX instruction sets. The default is to use the
7689 instruction sets supported by the CPU type specified via `-mcpu='
7690 option or that of the CPU on which GCC was built if none was
7695 Generate code that uses (does not use) VAX F and G floating point
7696 arithmetic instead of IEEE single and double precision.
7699 `-mno-explicit-relocs'
7700 Older Alpha assemblers provided no way to generate symbol
7701 relocations except via assembler macros. Use of these macros does
7702 not allow optimal instruction scheduling. GNU binutils as of
7703 version 2.12 supports a new syntax that allows the compiler to
7704 explicitly mark which relocations should apply to which
7705 instructions. This option is mostly useful for debugging, as GCC
7706 detects the capabilities of the assembler when it is built and
7707 sets the default accordingly.
7711 When `-mexplicit-relocs' is in effect, static data is accessed via
7712 "gp-relative" relocations. When `-msmall-data' is used, objects 8
7713 bytes long or smaller are placed in a "small data area" (the
7714 `.sdata' and `.sbss' sections) and are accessed via 16-bit
7715 relocations off of the `$gp' register. This limits the size of
7716 the small data area to 64KB, but allows the variables to be
7717 directly accessed via a single instruction.
7719 The default is `-mlarge-data'. With this option the data area is
7720 limited to just below 2GB. Programs that require more than 2GB of
7721 data must use `malloc' or `mmap' to allocate the data in the heap
7722 instead of in the program's data segment.
7724 When generating code for shared libraries, `-fpic' implies
7725 `-msmall-data' and `-fPIC' implies `-mlarge-data'.
7729 When `-msmall-text' is used, the compiler assumes that the code of
7730 the entire program (or shared library) fits in 4MB, and is thus
7731 reachable with a branch instruction. When `-msmall-data' is used,
7732 the compiler can assume that all local symbols share the same
7733 `$gp' value, and thus reduce the number of instructions required
7734 for a function call from 4 to 1.
7736 The default is `-mlarge-text'.
7739 Set the instruction set and instruction scheduling parameters for
7740 machine type CPU_TYPE. You can specify either the `EV' style name
7741 or the corresponding chip number. GCC supports scheduling
7742 parameters for the EV4, EV5 and EV6 family of processors and will
7743 choose the default values for the instruction set from the
7744 processor you specify. If you do not specify a processor type,
7745 GCC will default to the processor on which the compiler was built.
7747 Supported values for CPU_TYPE are
7752 Schedules as an EV4 and has no instruction set extensions.
7756 Schedules as an EV5 and has no instruction set extensions.
7760 Schedules as an EV5 and supports the BWX extension.
7765 Schedules as an EV5 and supports the BWX and MAX extensions.
7769 Schedules as an EV6 and supports the BWX, FIX, and MAX
7774 Schedules as an EV6 and supports the BWX, CIX, FIX, and MAX
7778 Set only the instruction scheduling parameters for machine type
7779 CPU_TYPE. The instruction set is not changed.
7781 `-mmemory-latency=TIME'
7782 Sets the latency the scheduler should assume for typical memory
7783 references as seen by the application. This number is highly
7784 dependent on the memory access patterns used by the application
7785 and the size of the external cache on the machine.
7787 Valid options for TIME are
7790 A decimal number representing clock cycles.
7796 The compiler contains estimates of the number of clock cycles
7797 for "typical" EV4 & EV5 hardware for the Level 1, 2 & 3 caches
7798 (also called Dcache, Scache, and Bcache), as well as to main
7799 memory. Note that L3 is only valid for EV5.
7803 File: gcc.info, Node: DEC Alpha/VMS Options, Next: FRV Options, Prev: DEC Alpha Options, Up: Submodel Options
7805 3.17.7 DEC Alpha/VMS Options
7806 ----------------------------
7808 These `-m' options are defined for the DEC Alpha/VMS implementations:
7810 `-mvms-return-codes'
7811 Return VMS condition codes from main. The default is to return
7812 POSIX style condition (e.g. error) codes.
7815 File: gcc.info, Node: FRV Options, Next: H8/300 Options, Prev: DEC Alpha/VMS Options, Up: Submodel Options
7821 Only use the first 32 general purpose registers.
7824 Use all 64 general purpose registers.
7827 Use only the first 32 floating point registers.
7830 Use all 64 floating point registers
7833 Use hardware instructions for floating point operations.
7836 Use library routines for floating point operations.
7839 Dynamically allocate condition code registers.
7842 Do not try to dynamically allocate condition code registers, only
7843 use `icc0' and `fcc0'.
7846 Change ABI to use double word insns.
7849 Do not use double word instructions.
7852 Use floating point double instructions.
7855 Do not use floating point double instructions.
7858 Use media instructions.
7861 Do not use media instructions.
7864 Use multiply and add/subtract instructions.
7867 Do not use multiply and add/subtract instructions.
7870 Select the FDPIC ABI, that uses function descriptors to represent
7871 pointers to functions. Without any PIC/PIE-related options, it
7872 implies `-fPIE'. With `-fpic' or `-fpie', it assumes GOT entries
7873 and small data are within a 12-bit range from the GOT base
7874 address; with `-fPIC' or `-fPIE', GOT offsets are computed with 32
7878 Enable inlining of PLT entries in function calls to functions that
7879 are not known to bind locally. It has no effect without `-mfdpic'.
7880 It's enabled by default if optimizing for speed and compiling for
7881 shared libraries (i.e., `-fPIC' or `-fpic'), or when an
7882 optimization option such as `-O3' or above is present in the
7886 Assume a large TLS segment when generating thread-local code.
7889 Do not assume a large TLS segment when generating thread-local
7893 Enable the use of `GPREL' relocations in the FDPIC ABI for data
7894 that is known to be in read-only sections. It's enabled by
7895 default, except for `-fpic' or `-fpie': even though it may help
7896 make the global offset table smaller, it trades 1 instruction for
7897 4. With `-fPIC' or `-fPIE', it trades 3 instructions for 4, one
7898 of which may be shared by multiple symbols, and it avoids the need
7899 for a GOT entry for the referenced symbol, so it's more likely to
7900 be a win. If it is not, `-mno-gprel-ro' can be used to disable it.
7902 `-multilib-library-pic'
7903 Link with the (library, not FD) pic libraries. It's implied by
7904 `-mlibrary-pic', as well as by `-fPIC' and `-fpic' without
7905 `-mfdpic'. You should never have to use it explicitly.
7908 Follow the EABI requirement of always creating a frame pointer
7909 whenever a stack frame is allocated. This option is enabled by
7910 default and can be disabled with `-mno-linked-fp'.
7913 Use indirect addressing to call functions outside the current
7914 compilation unit. This allows the functions to be placed anywhere
7915 within the 32-bit address space.
7918 Try to align labels to an 8-byte boundary by inserting nops into
7919 the previous packet. This option only has an effect when VLIW
7920 packing is enabled. It doesn't create new packets; it merely adds
7921 nops to existing ones.
7924 Generate position-independent EABI code.
7927 Use only the first four media accumulator registers.
7930 Use all eight media accumulator registers.
7933 Pack VLIW instructions.
7936 Do not pack VLIW instructions.
7939 Do not mark ABI switches in e_flags.
7942 Enable the use of conditional-move instructions (default).
7944 This switch is mainly for debugging the compiler and will likely
7945 be removed in a future version.
7948 Disable the use of conditional-move instructions.
7950 This switch is mainly for debugging the compiler and will likely
7951 be removed in a future version.
7954 Enable the use of conditional set instructions (default).
7956 This switch is mainly for debugging the compiler and will likely
7957 be removed in a future version.
7960 Disable the use of conditional set instructions.
7962 This switch is mainly for debugging the compiler and will likely
7963 be removed in a future version.
7966 Enable the use of conditional execution (default).
7968 This switch is mainly for debugging the compiler and will likely
7969 be removed in a future version.
7972 Disable the use of conditional execution.
7974 This switch is mainly for debugging the compiler and will likely
7975 be removed in a future version.
7978 Run a pass to pack branches into VLIW instructions (default).
7980 This switch is mainly for debugging the compiler and will likely
7981 be removed in a future version.
7984 Do not run a pass to pack branches into VLIW instructions.
7986 This switch is mainly for debugging the compiler and will likely
7987 be removed in a future version.
7990 Enable optimization of `&&' and `||' in conditional execution
7993 This switch is mainly for debugging the compiler and will likely
7994 be removed in a future version.
7996 `-mno-multi-cond-exec'
7997 Disable optimization of `&&' and `||' in conditional execution.
7999 This switch is mainly for debugging the compiler and will likely
8000 be removed in a future version.
8002 `-mnested-cond-exec'
8003 Enable nested conditional execution optimizations (default).
8005 This switch is mainly for debugging the compiler and will likely
8006 be removed in a future version.
8008 `-mno-nested-cond-exec'
8009 Disable nested conditional execution optimizations.
8011 This switch is mainly for debugging the compiler and will likely
8012 be removed in a future version.
8015 Cause gas to print out tomcat statistics.
8018 Select the processor type for which to generate code. Possible
8019 values are `frv', `fr550', `tomcat', `fr500', `fr450', `fr405',
8020 `fr400', `fr300' and `simple'.
8024 File: gcc.info, Node: H8/300 Options, Next: HPPA Options, Prev: FRV Options, Up: Submodel Options
8026 3.17.9 H8/300 Options
8027 ---------------------
8029 These `-m' options are defined for the H8/300 implementations:
8032 Shorten some address references at link time, when possible; uses
8033 the linker option `-relax'. *Note `ld' and the H8/300:
8034 (ld)H8/300, for a fuller description.
8037 Generate code for the H8/300H.
8040 Generate code for the H8S.
8043 Generate code for the H8S and H8/300H in the normal mode. This
8044 switch must be used either with `-mh' or `-ms'.
8047 Generate code for the H8S/2600. This switch must be used with
8051 Make `int' data 32 bits by default.
8054 On the H8/300H and H8S, use the same alignment rules as for the
8055 H8/300. The default for the H8/300H and H8S is to align longs and
8056 floats on 4 byte boundaries. `-malign-300' causes them to be
8057 aligned on 2 byte boundaries. This option has no effect on the
8061 File: gcc.info, Node: HPPA Options, Next: i386 and x86-64 Options, Prev: H8/300 Options, Up: Submodel Options
8063 3.17.10 HPPA Options
8064 --------------------
8066 These `-m' options are defined for the HPPA family of computers:
8068 `-march=ARCHITECTURE-TYPE'
8069 Generate code for the specified architecture. The choices for
8070 ARCHITECTURE-TYPE are `1.0' for PA 1.0, `1.1' for PA 1.1, and
8071 `2.0' for PA 2.0 processors. Refer to `/usr/lib/sched.models' on
8072 an HP-UX system to determine the proper architecture option for
8073 your machine. Code compiled for lower numbered architectures will
8074 run on higher numbered architectures, but not the other way around.
8079 Synonyms for `-march=1.0', `-march=1.1', and `-march=2.0'
8083 Generate code suitable for big switch tables. Use this option
8084 only if the assembler/linker complain about out of range branches
8085 within a switch table.
8088 Fill delay slots of function calls with unconditional jump
8089 instructions by modifying the return pointer for the function call
8090 to be the target of the conditional jump.
8093 Prevent floating point registers from being used in any manner.
8094 This is necessary for compiling kernels which perform lazy context
8095 switching of floating point registers. If you use this option and
8096 attempt to perform floating point operations, the compiler will
8099 `-mdisable-indexing'
8100 Prevent the compiler from using indexing address modes. This
8101 avoids some rather obscure problems when compiling MIG generated
8105 Generate code that assumes the target has no space registers.
8106 This allows GCC to generate faster indirect calls and use unscaled
8107 index address modes.
8109 Such code is suitable for level 0 PA systems and kernels.
8111 `-mfast-indirect-calls'
8112 Generate code that assumes calls never cross space boundaries.
8113 This allows GCC to emit code which performs faster indirect calls.
8115 This option will not work in the presence of shared libraries or
8118 `-mfixed-range=REGISTER-RANGE'
8119 Generate code treating the given register range as fixed registers.
8120 A fixed register is one that the register allocator can not use.
8121 This is useful when compiling kernel code. A register range is
8122 specified as two registers separated by a dash. Multiple register
8123 ranges can be specified separated by a comma.
8126 Generate 3-instruction load and store sequences as sometimes
8127 required by the HP-UX 10 linker. This is equivalent to the `+k'
8128 option to the HP compilers.
8130 `-mportable-runtime'
8131 Use the portable calling conventions proposed by HP for ELF
8135 Enable the use of assembler directives only GAS understands.
8137 `-mschedule=CPU-TYPE'
8138 Schedule code according to the constraints for the machine type
8139 CPU-TYPE. The choices for CPU-TYPE are `700' `7100', `7100LC',
8140 `7200', `7300' and `8000'. Refer to `/usr/lib/sched.models' on an
8141 HP-UX system to determine the proper scheduling option for your
8142 machine. The default scheduling is `8000'.
8145 Enable the optimization pass in the HP-UX linker. Note this makes
8146 symbolic debugging impossible. It also triggers a bug in the
8147 HP-UX 8 and HP-UX 9 linkers in which they give bogus error
8148 messages when linking some programs.
8151 Generate output containing library calls for floating point.
8152 *Warning:* the requisite libraries are not available for all HPPA
8153 targets. Normally the facilities of the machine's usual C
8154 compiler are used, but this cannot be done directly in
8155 cross-compilation. You must make your own arrangements to provide
8156 suitable library functions for cross-compilation. The embedded
8157 target `hppa1.1-*-pro' does provide software floating point
8160 `-msoft-float' changes the calling convention in the output file;
8161 therefore, it is only useful if you compile _all_ of a program with
8162 this option. In particular, you need to compile `libgcc.a', the
8163 library that comes with GCC, with `-msoft-float' in order for this
8167 Generate the predefine, `_SIO', for server IO. The default is
8168 `-mwsio'. This generates the predefines, `__hp9000s700',
8169 `__hp9000s700__' and `_WSIO', for workstation IO. These options
8170 are available under HP-UX and HI-UX.
8173 Use GNU ld specific options. This passes `-shared' to ld when
8174 building a shared library. It is the default when GCC is
8175 configured, explicitly or implicitly, with the GNU linker. This
8176 option does not have any affect on which ld is called, it only
8177 changes what parameters are passed to that ld. The ld that is
8178 called is determined by the `--with-ld' configure option, GCC's
8179 program search path, and finally by the user's `PATH'. The linker
8180 used by GCC can be printed using `which `gcc -print-prog-name=ld`'.
8183 Use HP ld specific options. This passes `-b' to ld when building
8184 a shared library and passes `+Accept TypeMismatch' to ld on all
8185 links. It is the default when GCC is configured, explicitly or
8186 implicitly, with the HP linker. This option does not have any
8187 affect on which ld is called, it only changes what parameters are
8188 passed to that ld. The ld that is called is determined by the
8189 `--with-ld' configure option, GCC's program search path, and
8190 finally by the user's `PATH'. The linker used by GCC can be
8191 printed using `which `gcc -print-prog-name=ld`'.
8194 Generate code that uses long call sequences. This ensures that a
8195 call is always able to reach linker generated stubs. The default
8196 is to generate long calls only when the distance from the call
8197 site to the beginning of the function or translation unit, as the
8198 case may be, exceeds a predefined limit set by the branch type
8199 being used. The limits for normal calls are 7,600,000 and 240,000
8200 bytes, respectively for the PA 2.0 and PA 1.X architectures.
8201 Sibcalls are always limited at 240,000 bytes.
8203 Distances are measured from the beginning of functions when using
8204 the `-ffunction-sections' option, or when using the `-mgas' and
8205 `-mno-portable-runtime' options together under HP-UX with the SOM
8208 It is normally not desirable to use this option as it will degrade
8209 performance. However, it may be useful in large applications,
8210 particularly when partial linking is used to build the application.
8212 The types of long calls used depends on the capabilities of the
8213 assembler and linker, and the type of code being generated. The
8214 impact on systems that support long absolute calls, and long pic
8215 symbol-difference or pc-relative calls should be relatively small.
8216 However, an indirect call is used on 32-bit ELF systems in pic code
8217 and it is quite long.
8220 Generate compiler predefines and select a startfile for the
8221 specified UNIX standard. The choices for UNIX-STD are `93', `95'
8222 and `98'. `93' is supported on all HP-UX versions. `95' is
8223 available on HP-UX 10.10 and later. `98' is available on HP-UX
8224 11.11 and later. The default values are `93' for HP-UX 10.00,
8225 `95' for HP-UX 10.10 though to 11.00, and `98' for HP-UX 11.11 and
8228 `-munix=93' provides the same predefines as GCC 3.3 and 3.4.
8229 `-munix=95' provides additional predefines for `XOPEN_UNIX' and
8230 `_XOPEN_SOURCE_EXTENDED', and the startfile `unix95.o'.
8231 `-munix=98' provides additional predefines for `_XOPEN_UNIX',
8232 `_XOPEN_SOURCE_EXTENDED', `_INCLUDE__STDC_A1_SOURCE' and
8233 `_INCLUDE_XOPEN_SOURCE_500', and the startfile `unix98.o'.
8235 It is _important_ to note that this option changes the interfaces
8236 for various library routines. It also affects the operational
8237 behavior of the C library. Thus, _extreme_ care is needed in
8240 Library code that is intended to operate with more than one UNIX
8241 standard must test, set and restore the variable
8242 __XPG4_EXTENDED_MASK as appropriate. Most GNU software doesn't
8243 provide this capability.
8246 Suppress the generation of link options to search libdld.sl when
8247 the `-static' option is specified on HP-UX 10 and later.
8250 The HP-UX implementation of setlocale in libc has a dependency on
8251 libdld.sl. There isn't an archive version of libdld.sl. Thus,
8252 when the `-static' option is specified, special link options are
8253 needed to resolve this dependency.
8255 On HP-UX 10 and later, the GCC driver adds the necessary options to
8256 link with libdld.sl when the `-static' option is specified. This
8257 causes the resulting binary to be dynamic. On the 64-bit port,
8258 the linkers generate dynamic binaries by default in any case. The
8259 `-nolibdld' option can be used to prevent the GCC driver from
8260 adding these link options.
8263 Add support for multithreading with the "dce thread" library under
8264 HP-UX. This option sets flags for both the preprocessor and
8268 File: gcc.info, Node: i386 and x86-64 Options, Next: IA-64 Options, Prev: HPPA Options, Up: Submodel Options
8270 3.17.11 Intel 386 and AMD x86-64 Options
8271 ----------------------------------------
8273 These `-m' options are defined for the i386 and x86-64 family of
8277 Tune to CPU-TYPE everything applicable about the generated code,
8278 except for the ABI and the set of available instructions. The
8279 choices for CPU-TYPE are:
8281 Original Intel's i386 CPU.
8284 Intel's i486 CPU. (No scheduling is implemented for this
8288 Intel Pentium CPU with no MMX support.
8291 Intel PentiumMMX CPU based on Pentium core with MMX
8292 instruction set support.
8295 Intel PentiumPro CPU.
8298 Intel Pentium2 CPU based on PentiumPro core with MMX
8299 instruction set support.
8301 _pentium3, pentium3m_
8302 Intel Pentium3 CPU based on PentiumPro core with MMX and SSE
8303 instruction set support.
8306 Low power version of Intel Pentium3 CPU with MMX, SSE and
8307 SSE2 instruction set support. Used by Centrino notebooks.
8309 _pentium4, pentium4m_
8310 Intel Pentium4 CPU with MMX, SSE and SSE2 instruction set
8314 Improved version of Intel Pentium4 CPU with MMX, SSE, SSE2
8315 and SSE3 instruction set support.
8318 Improved version of Intel Pentium4 CPU with 64-bit
8319 extensions, MMX, SSE, SSE2 and SSE3 instruction set support.
8322 AMD K6 CPU with MMX instruction set support.
8325 Improved versions of AMD K6 CPU with MMX and 3dNOW!
8326 instruction set support.
8328 _athlon, athlon-tbird_
8329 AMD Athlon CPU with MMX, 3dNOW!, enhanced 3dNOW! and SSE
8330 prefetch instructions support.
8332 _athlon-4, athlon-xp, athlon-mp_
8333 Improved AMD Athlon CPU with MMX, 3dNOW!, enhanced 3dNOW! and
8334 full SSE instruction set support.
8336 _k8, opteron, athlon64, athlon-fx_
8337 AMD K8 core based CPUs with x86-64 instruction set support.
8338 (This supersets MMX, SSE, SSE2, 3dNOW!, enhanced 3dNOW! and
8339 64-bit instruction set extensions.)
8342 IDT Winchip C6 CPU, dealt in same way as i486 with additional
8343 MMX instruction set support.
8346 IDT Winchip2 CPU, dealt in same way as i486 with additional
8347 MMX and 3dNOW! instruction set support.
8350 Via C3 CPU with MMX and 3dNOW! instruction set support. (No
8351 scheduling is implemented for this chip.)
8354 Via C3-2 CPU with MMX and SSE instruction set support. (No
8355 scheduling is implemented for this chip.)
8357 While picking a specific CPU-TYPE will schedule things
8358 appropriately for that particular chip, the compiler will not
8359 generate any code that does not run on the i386 without the
8360 `-march=CPU-TYPE' option being used.
8363 Generate instructions for the machine type CPU-TYPE. The choices
8364 for CPU-TYPE are the same as for `-mtune'. Moreover, specifying
8365 `-march=CPU-TYPE' implies `-mtune=CPU-TYPE'.
8368 A deprecated synonym for `-mtune'.
8374 These options are synonyms for `-mtune=i386', `-mtune=i486',
8375 `-mtune=pentium', and `-mtune=pentiumpro' respectively. These
8376 synonyms are deprecated.
8379 Generate floating point arithmetics for selected unit UNIT. The
8380 choices for UNIT are:
8383 Use the standard 387 floating point coprocessor present
8384 majority of chips and emulated otherwise. Code compiled with
8385 this option will run almost everywhere. The temporary
8386 results are computed in 80bit precision instead of precision
8387 specified by the type resulting in slightly different results
8388 compared to most of other chips. See `-ffloat-store' for
8389 more detailed description.
8391 This is the default choice for i386 compiler.
8394 Use scalar floating point instructions present in the SSE
8395 instruction set. This instruction set is supported by
8396 Pentium3 and newer chips, in the AMD line by Athlon-4,
8397 Athlon-xp and Athlon-mp chips. The earlier version of SSE
8398 instruction set supports only single precision arithmetics,
8399 thus the double and extended precision arithmetics is still
8400 done using 387. Later version, present only in Pentium4 and
8401 the future AMD x86-64 chips supports double precision
8404 For the i386 compiler, you need to use `-march=CPU-TYPE',
8405 `-msse' or `-msse2' switches to enable SSE extensions and
8406 make this option effective. For the x86-64 compiler, these
8407 extensions are enabled by default.
8409 The resulting code should be considerably faster in the
8410 majority of cases and avoid the numerical instability
8411 problems of 387 code, but may break some existing code that
8412 expects temporaries to be 80bit.
8414 This is the default choice for the x86-64 compiler.
8417 Attempt to utilize both instruction sets at once. This
8418 effectively double the amount of available registers and on
8419 chips with separate execution units for 387 and SSE the
8420 execution resources too. Use this option with care, as it is
8421 still experimental, because the GCC register allocator does
8422 not model separate functional units well resulting in
8423 instable performance.
8426 Output asm instructions using selected DIALECT. Supported choices
8427 are `intel' or `att' (the default one).
8431 Control whether or not the compiler uses IEEE floating point
8432 comparisons. These handle correctly the case where the result of a
8433 comparison is unordered.
8436 Generate output containing library calls for floating point.
8437 *Warning:* the requisite libraries are not part of GCC. Normally
8438 the facilities of the machine's usual C compiler are used, but
8439 this can't be done directly in cross-compilation. You must make
8440 your own arrangements to provide suitable library functions for
8443 On machines where a function returns floating point results in the
8444 80387 register stack, some floating point opcodes may be emitted
8445 even if `-msoft-float' is used.
8447 `-mno-fp-ret-in-387'
8448 Do not use the FPU registers for return values of functions.
8450 The usual calling convention has functions return values of types
8451 `float' and `double' in an FPU register, even if there is no FPU.
8452 The idea is that the operating system should emulate an FPU.
8454 The option `-mno-fp-ret-in-387' causes such values to be returned
8455 in ordinary CPU registers instead.
8457 `-mno-fancy-math-387'
8458 Some 387 emulators do not support the `sin', `cos' and `sqrt'
8459 instructions for the 387. Specify this option to avoid generating
8460 those instructions. This option is the default on FreeBSD,
8461 OpenBSD and NetBSD. This option is overridden when `-march'
8462 indicates that the target cpu will always have an FPU and so the
8463 instruction will not need emulation. As of revision 2.6.1, these
8464 instructions are not generated unless you also use the
8465 `-funsafe-math-optimizations' switch.
8469 Control whether GCC aligns `double', `long double', and `long
8470 long' variables on a two word boundary or a one word boundary.
8471 Aligning `double' variables on a two word boundary will produce
8472 code that runs somewhat faster on a `Pentium' at the expense of
8475 *Warning:* if you use the `-malign-double' switch, structures
8476 containing the above types will be aligned differently than the
8477 published application binary interface specifications for the 386
8478 and will not be binary compatible with structures in code compiled
8479 without that switch.
8481 `-m96bit-long-double'
8482 `-m128bit-long-double'
8483 These switches control the size of `long double' type. The i386
8484 application binary interface specifies the size to be 96 bits, so
8485 `-m96bit-long-double' is the default in 32 bit mode.
8487 Modern architectures (Pentium and newer) would prefer `long double'
8488 to be aligned to an 8 or 16 byte boundary. In arrays or structures
8489 conforming to the ABI, this would not be possible. So specifying a
8490 `-m128bit-long-double' will align `long double' to a 16 byte
8491 boundary by padding the `long double' with an additional 32 bit
8494 In the x86-64 compiler, `-m128bit-long-double' is the default
8495 choice as its ABI specifies that `long double' is to be aligned on
8498 Notice that neither of these options enable any extra precision
8499 over the x87 standard of 80 bits for a `long double'.
8501 *Warning:* if you override the default value for your target ABI,
8502 the structures and arrays containing `long double' variables will
8503 change their size as well as function calling convention for
8504 function taking `long double' will be modified. Hence they will
8505 not be binary compatible with arrays or structures in code
8506 compiled without that switch.
8510 Control whether GCC places uninitialized local variables into the
8511 `bss' or `data' segments. `-msvr3-shlib' places them into `bss'.
8512 These options are meaningful only on System V Release 3.
8515 Use a different function-calling convention, in which functions
8516 that take a fixed number of arguments return with the `ret' NUM
8517 instruction, which pops their arguments while returning. This
8518 saves one instruction in the caller since there is no need to pop
8519 the arguments there.
8521 You can specify that an individual function is called with this
8522 calling sequence with the function attribute `stdcall'. You can
8523 also override the `-mrtd' option by using the function attribute
8524 `cdecl'. *Note Function Attributes::.
8526 *Warning:* this calling convention is incompatible with the one
8527 normally used on Unix, so you cannot use it if you need to call
8528 libraries compiled with the Unix compiler.
8530 Also, you must provide function prototypes for all functions that
8531 take variable numbers of arguments (including `printf'); otherwise
8532 incorrect code will be generated for calls to those functions.
8534 In addition, seriously incorrect code will result if you call a
8535 function with too many arguments. (Normally, extra arguments are
8536 harmlessly ignored.)
8539 Control how many registers are used to pass integer arguments. By
8540 default, no registers are used to pass arguments, and at most 3
8541 registers can be used. You can control this behavior for a
8542 specific function by using the function attribute `regparm'.
8543 *Note Function Attributes::.
8545 *Warning:* if you use this switch, and NUM is nonzero, then you
8546 must build all modules with the same value, including any
8547 libraries. This includes the system libraries and startup modules.
8549 `-mpreferred-stack-boundary=NUM'
8550 Attempt to keep the stack boundary aligned to a 2 raised to NUM
8551 byte boundary. If `-mpreferred-stack-boundary' is not specified,
8552 the default is 4 (16 bytes or 128 bits), except when optimizing
8553 for code size (`-Os'), in which case the default is the minimum
8554 correct alignment (4 bytes for x86, and 8 bytes for x86-64).
8556 On Pentium and PentiumPro, `double' and `long double' values
8557 should be aligned to an 8 byte boundary (see `-malign-double') or
8558 suffer significant run time performance penalties. On Pentium
8559 III, the Streaming SIMD Extension (SSE) data type `__m128' suffers
8560 similar penalties if it is not 16 byte aligned.
8562 To ensure proper alignment of this values on the stack, the stack
8563 boundary must be as aligned as that required by any value stored
8564 on the stack. Further, every function must be generated such that
8565 it keeps the stack aligned. Thus calling a function compiled with
8566 a higher preferred stack boundary from a function compiled with a
8567 lower preferred stack boundary will most likely misalign the
8568 stack. It is recommended that libraries that use callbacks always
8569 use the default setting.
8571 This extra alignment does consume extra stack space, and generally
8572 increases code size. Code that is sensitive to stack space usage,
8573 such as embedded systems and operating system kernels, may want to
8574 reduce the preferred alignment to `-mpreferred-stack-boundary=2'.
8590 These switches enable or disable the use of built-in functions
8591 that allow direct access to the MMX, SSE, SSE2, SSE3 and 3Dnow
8592 extensions of the instruction set.
8594 *Note X86 Built-in Functions::, for details of the functions
8595 enabled and disabled by these switches.
8597 To have SSE/SSE2 instructions generated automatically from
8598 floating-point code, see `-mfpmath=sse'.
8602 Use PUSH operations to store outgoing parameters. This method is
8603 shorter and usually equally fast as method using SUB/MOV
8604 operations and is enabled by default. In some cases disabling it
8605 may improve performance because of improved scheduling and reduced
8608 `-maccumulate-outgoing-args'
8609 If enabled, the maximum amount of space required for outgoing
8610 arguments will be computed in the function prologue. This is
8611 faster on most modern CPUs because of reduced dependencies,
8612 improved scheduling and reduced stack usage when preferred stack
8613 boundary is not equal to 2. The drawback is a notable increase in
8614 code size. This switch implies `-mno-push-args'.
8617 Support thread-safe exception handling on `Mingw32'. Code that
8618 relies on thread-safe exception handling must compile and link all
8619 code with the `-mthreads' option. When compiling, `-mthreads'
8620 defines `-D_MT'; when linking, it links in a special thread helper
8621 library `-lmingwthrd' which cleans up per thread exception
8624 `-mno-align-stringops'
8625 Do not align destination of inlined string operations. This
8626 switch reduces code size and improves performance in case the
8627 destination is already aligned, but GCC doesn't know about it.
8629 `-minline-all-stringops'
8630 By default GCC inlines string operations only when destination is
8631 known to be aligned at least to 4 byte boundary. This enables
8632 more inlining, increase code size, but may improve performance of
8633 code that depends on fast memcpy, strlen and memset for short
8636 `-momit-leaf-frame-pointer'
8637 Don't keep the frame pointer in a register for leaf functions.
8638 This avoids the instructions to save, set up and restore frame
8639 pointers and makes an extra register available in leaf functions.
8640 The option `-fomit-frame-pointer' removes the frame pointer for
8641 all functions which might make debugging harder.
8643 `-mtls-direct-seg-refs'
8644 `-mno-tls-direct-seg-refs'
8645 Controls whether TLS variables may be accessed with offsets from
8646 the TLS segment register (`%gs' for 32-bit, `%fs' for 64-bit), or
8647 whether the thread base pointer must be added. Whether or not this
8648 is legal depends on the operating system, and whether it maps the
8649 segment to cover the entire TLS area.
8651 For systems that use GNU libc, the default is on.
8653 These `-m' switches are supported in addition to the above on AMD
8654 x86-64 processors in 64-bit environments.
8658 Generate code for a 32-bit or 64-bit environment. The 32-bit
8659 environment sets int, long and pointer to 32 bits and generates
8660 code that runs on any i386 system. The 64-bit environment sets
8661 int to 32 bits and long and pointer to 64 bits and generates code
8662 for AMD's x86-64 architecture.
8665 Do not use a so called red zone for x86-64 code. The red zone is
8666 mandated by the x86-64 ABI, it is a 128-byte area beyond the
8667 location of the stack pointer that will not be modified by signal
8668 or interrupt handlers and therefore can be used for temporary data
8669 without adjusting the stack pointer. The flag `-mno-red-zone'
8670 disables this red zone.
8673 Generate code for the small code model: the program and its
8674 symbols must be linked in the lower 2 GB of the address space.
8675 Pointers are 64 bits. Programs can be statically or dynamically
8676 linked. This is the default code model.
8679 Generate code for the kernel code model. The kernel runs in the
8680 negative 2 GB of the address space. This model has to be used for
8684 Generate code for the medium model: The program is linked in the
8685 lower 2 GB of the address space but symbols can be located
8686 anywhere in the address space. Programs can be statically or
8687 dynamically linked, but building of shared libraries are not
8688 supported with the medium model.
8691 Generate code for the large model: This model makes no assumptions
8692 about addresses and sizes of sections. Currently GCC does not
8693 implement this model.
8696 File: gcc.info, Node: IA-64 Options, Next: M32R/D Options, Prev: i386 and x86-64 Options, Up: Submodel Options
8698 3.17.12 IA-64 Options
8699 ---------------------
8701 These are the `-m' options defined for the Intel IA-64 architecture.
8704 Generate code for a big endian target. This is the default for
8708 Generate code for a little endian target. This is the default for
8713 Generate (or don't) code for the GNU assembler. This is the
8718 Generate (or don't) code for the GNU linker. This is the default.
8721 Generate code that does not use a global pointer register. The
8722 result is not position independent code, and violates the IA-64
8725 `-mvolatile-asm-stop'
8726 `-mno-volatile-asm-stop'
8727 Generate (or don't) a stop bit immediately before and after
8728 volatile asm statements.
8731 `-mno-register-names'
8732 Generate (or don't) `in', `loc', and `out' register names for the
8733 stacked registers. This may make assembler output more readable.
8737 Disable (or enable) optimizations that use the small data section.
8738 This may be useful for working around optimizer bugs.
8741 Generate code that uses a single constant global pointer value.
8742 This is useful when compiling kernel code.
8745 Generate code that is self-relocatable. This implies
8746 `-mconstant-gp'. This is useful when compiling firmware code.
8748 `-minline-float-divide-min-latency'
8749 Generate code for inline divides of floating point values using
8750 the minimum latency algorithm.
8752 `-minline-float-divide-max-throughput'
8753 Generate code for inline divides of floating point values using
8754 the maximum throughput algorithm.
8756 `-minline-int-divide-min-latency'
8757 Generate code for inline divides of integer values using the
8758 minimum latency algorithm.
8760 `-minline-int-divide-max-throughput'
8761 Generate code for inline divides of integer values using the
8762 maximum throughput algorithm.
8764 `-minline-sqrt-min-latency'
8765 Generate code for inline square roots using the minimum latency
8768 `-minline-sqrt-max-throughput'
8769 Generate code for inline square roots using the maximum throughput
8774 Don't (or do) generate assembler code for the DWARF2 line number
8775 debugging info. This may be useful when not using the GNU
8779 `-mno-early-stop-bits'
8780 Allow stop bits to be placed earlier than immediately preceding the
8781 instruction that triggered the stop bit. This can improve
8782 instruction scheduling, but does not always do so.
8784 `-mfixed-range=REGISTER-RANGE'
8785 Generate code treating the given register range as fixed registers.
8786 A fixed register is one that the register allocator can not use.
8787 This is useful when compiling kernel code. A register range is
8788 specified as two registers separated by a dash. Multiple register
8789 ranges can be specified separated by a comma.
8791 `-mtls-size=TLS-SIZE'
8792 Specify bit size of immediate TLS offsets. Valid values are 14,
8795 `-mtune-arch=CPU-TYPE'
8796 Tune the instruction scheduling for a particular CPU, Valid values
8797 are itanium, itanium1, merced, itanium2, and mckinley.
8801 Add support for multithreading using the POSIX threads library.
8802 This option sets flags for both the preprocessor and linker. It
8803 does not affect the thread safety of object code produced by the
8804 compiler or that of libraries supplied with it. These are HP-UX
8809 Generate code for a 32-bit or 64-bit environment. The 32-bit
8810 environment sets int, long and pointer to 32 bits. The 64-bit
8811 environment sets int to 32 bits and long and pointer to 64 bits.
8812 These are HP-UX specific flags.
8816 File: gcc.info, Node: M32R/D Options, Next: M680x0 Options, Prev: IA-64 Options, Up: Submodel Options
8818 3.17.13 M32R/D Options
8819 ----------------------
8821 These `-m' options are defined for Renesas M32R/D architectures:
8824 Generate code for the M32R/2.
8827 Generate code for the M32R/X.
8830 Generate code for the M32R. This is the default.
8833 Assume all objects live in the lower 16MB of memory (so that their
8834 addresses can be loaded with the `ld24' instruction), and assume
8835 all subroutines are reachable with the `bl' instruction. This is
8838 The addressability of a particular object can be set with the
8842 Assume objects may be anywhere in the 32-bit address space (the
8843 compiler will generate `seth/add3' instructions to load their
8844 addresses), and assume all subroutines are reachable with the `bl'
8848 Assume objects may be anywhere in the 32-bit address space (the
8849 compiler will generate `seth/add3' instructions to load their
8850 addresses), and assume subroutines may not be reachable with the
8851 `bl' instruction (the compiler will generate the much slower
8852 `seth/add3/jl' instruction sequence).
8855 Disable use of the small data area. Variables will be put into
8856 one of `.data', `bss', or `.rodata' (unless the `section'
8857 attribute has been specified). This is the default.
8859 The small data area consists of sections `.sdata' and `.sbss'.
8860 Objects may be explicitly put in the small data area with the
8861 `section' attribute using one of these sections.
8864 Put small global and static data in the small data area, but do not
8865 generate special code to reference them.
8868 Put small global and static data in the small data area, and
8869 generate special instructions to reference them.
8872 Put global and static objects less than or equal to NUM bytes into
8873 the small data or bss sections instead of the normal data or bss
8874 sections. The default value of NUM is 8. The `-msdata' option
8875 must be set to one of `sdata' or `use' for this option to have any
8878 All modules should be compiled with the same `-G NUM' value.
8879 Compiling with different values of NUM may or may not work; if it
8880 doesn't the linker will give an error message--incorrect code will
8884 Makes the M32R specific code in the compiler display some
8885 statistics that might help in debugging programs.
8888 Align all loops to a 32-byte boundary.
8891 Do not enforce a 32-byte alignment for loops. This is the default.
8893 `-missue-rate=NUMBER'
8894 Issue NUMBER instructions per cycle. NUMBER can only be 1 or 2.
8896 `-mbranch-cost=NUMBER'
8897 NUMBER can only be 1 or 2. If it is 1 then branches will be
8898 preferred over conditional code, if it is 2, then the opposite will
8901 `-mflush-trap=NUMBER'
8902 Specifies the trap number to use to flush the cache. The default
8903 is 12. Valid numbers are between 0 and 15 inclusive.
8906 Specifies that the cache cannot be flushed by using a trap.
8909 Specifies the name of the operating system function to call to
8910 flush the cache. The default is __flush_cache_, but a function
8911 call will only be used if a trap is not available.
8914 Indicates that there is no OS function for flushing the cache.
8918 File: gcc.info, Node: M680x0 Options, Next: M68hc1x Options, Prev: M32R/D Options, Up: Submodel Options
8920 3.17.14 M680x0 Options
8921 ----------------------
8923 These are the `-m' options defined for the 68000 series. The default
8924 values for these options depends on which style of 68000 was selected
8925 when the compiler was configured; the defaults for the most common
8926 choices are given below.
8930 Generate output for a 68000. This is the default when the
8931 compiler is configured for 68000-based systems.
8933 Use this option for microcontrollers with a 68000 or EC000 core,
8934 including the 68008, 68302, 68306, 68307, 68322, 68328 and 68356.
8938 Generate output for a 68020. This is the default when the
8939 compiler is configured for 68020-based systems.
8942 Generate output containing 68881 instructions for floating point.
8943 This is the default for most 68020 systems unless `--nfp' was
8944 specified when the compiler was configured.
8947 Generate output for a 68030. This is the default when the
8948 compiler is configured for 68030-based systems.
8951 Generate output for a 68040. This is the default when the
8952 compiler is configured for 68040-based systems.
8954 This option inhibits the use of 68881/68882 instructions that have
8955 to be emulated by software on the 68040. Use this option if your
8956 68040 does not have code to emulate those instructions.
8959 Generate output for a 68060. This is the default when the
8960 compiler is configured for 68060-based systems.
8962 This option inhibits the use of 68020 and 68881/68882 instructions
8963 that have to be emulated by software on the 68060. Use this
8964 option if your 68060 does not have code to emulate those
8968 Generate output for a CPU32. This is the default when the
8969 compiler is configured for CPU32-based systems.
8971 Use this option for microcontrollers with a CPU32 or CPU32+ core,
8972 including the 68330, 68331, 68332, 68333, 68334, 68336, 68340,
8973 68341, 68349 and 68360.
8976 Generate output for a 520X "coldfire" family cpu. This is the
8977 default when the compiler is configured for 520X-based systems.
8979 Use this option for microcontroller with a 5200 core, including
8980 the MCF5202, MCF5203, MCF5204 and MCF5202.
8983 Generate output for a 68040, without using any of the new
8984 instructions. This results in code which can run relatively
8985 efficiently on either a 68020/68881 or a 68030 or a 68040. The
8986 generated code does use the 68881 instructions that are emulated
8990 Generate output for a 68060, without using any of the new
8991 instructions. This results in code which can run relatively
8992 efficiently on either a 68020/68881 or a 68030 or a 68040. The
8993 generated code does use the 68881 instructions that are emulated
8997 Generate output containing library calls for floating point.
8998 *Warning:* the requisite libraries are not available for all m68k
8999 targets. Normally the facilities of the machine's usual C
9000 compiler are used, but this can't be done directly in
9001 cross-compilation. You must make your own arrangements to provide
9002 suitable library functions for cross-compilation. The embedded
9003 targets `m68k-*-aout' and `m68k-*-coff' do provide software
9004 floating point support.
9007 Consider type `int' to be 16 bits wide, like `short int'.
9008 Additionally, parameters passed on the stack are also aligned to a
9009 16-bit boundary even on targets whose API mandates promotion to
9013 Do not use the bit-field instructions. The `-m68000', `-mcpu32'
9014 and `-m5200' options imply `-mnobitfield'.
9017 Do use the bit-field instructions. The `-m68020' option implies
9018 `-mbitfield'. This is the default if you use a configuration
9019 designed for a 68020.
9022 Use a different function-calling convention, in which functions
9023 that take a fixed number of arguments return with the `rtd'
9024 instruction, which pops their arguments while returning. This
9025 saves one instruction in the caller since there is no need to pop
9026 the arguments there.
9028 This calling convention is incompatible with the one normally used
9029 on Unix, so you cannot use it if you need to call libraries
9030 compiled with the Unix compiler.
9032 Also, you must provide function prototypes for all functions that
9033 take variable numbers of arguments (including `printf'); otherwise
9034 incorrect code will be generated for calls to those functions.
9036 In addition, seriously incorrect code will result if you call a
9037 function with too many arguments. (Normally, extra arguments are
9038 harmlessly ignored.)
9040 The `rtd' instruction is supported by the 68010, 68020, 68030,
9041 68040, 68060 and CPU32 processors, but not by the 68000 or 5200.
9045 Control whether GCC aligns `int', `long', `long long', `float',
9046 `double', and `long double' variables on a 32-bit boundary
9047 (`-malign-int') or a 16-bit boundary (`-mno-align-int'). Aligning
9048 variables on 32-bit boundaries produces code that runs somewhat
9049 faster on processors with 32-bit busses at the expense of more
9052 *Warning:* if you use the `-malign-int' switch, GCC will align
9053 structures containing the above types differently than most
9054 published application binary interface specifications for the m68k.
9057 Use the pc-relative addressing mode of the 68000 directly, instead
9058 of using a global offset table. At present, this option implies
9059 `-fpic', allowing at most a 16-bit offset for pc-relative
9060 addressing. `-fPIC' is not presently supported with `-mpcrel',
9061 though this could be supported for 68020 and higher processors.
9065 Do not (do) assume that unaligned memory references will be
9066 handled by the system.
9069 Generate code that allows the data segment to be located in a
9070 different area of memory from the text segment. This allows for
9071 execute in place in an environment without virtual memory
9072 management. This option implies `-fPIC'.
9075 Generate code that assumes that the data segment follows the text
9076 segment. This is the default.
9078 `-mid-shared-library'
9079 Generate code that supports shared libraries via the library ID
9080 method. This allows for execute in place and shared libraries in
9081 an environment without virtual memory management. This option
9084 `-mno-id-shared-library'
9085 Generate code that doesn't assume ID based shared libraries are
9086 being used. This is the default.
9088 `-mshared-library-id=n'
9089 Specified the identification number of the ID based shared library
9090 being compiled. Specifying a value of 0 will generate more
9091 compact code, specifying other values will force the allocation of
9092 that number to the current library but is no more space or time
9093 efficient than omitting this option.
9097 File: gcc.info, Node: M68hc1x Options, Next: MCore Options, Prev: M680x0 Options, Up: Submodel Options
9099 3.17.15 M68hc1x Options
9100 -----------------------
9102 These are the `-m' options defined for the 68hc11 and 68hc12
9103 microcontrollers. The default values for these options depends on
9104 which style of microcontroller was selected when the compiler was
9105 configured; the defaults for the most common choices are given below.
9109 Generate output for a 68HC11. This is the default when the
9110 compiler is configured for 68HC11-based systems.
9114 Generate output for a 68HC12. This is the default when the
9115 compiler is configured for 68HC12-based systems.
9119 Generate output for a 68HCS12.
9122 Enable the use of 68HC12 pre and post auto-increment and
9123 auto-decrement addressing modes.
9127 Enable the use of 68HC12 min and max instructions.
9131 Treat all calls as being far away (near). If calls are assumed to
9132 be far away, the compiler will use the `call' instruction to call
9133 a function and the `rtc' instruction for returning.
9136 Consider type `int' to be 16 bits wide, like `short int'.
9138 `-msoft-reg-count=COUNT'
9139 Specify the number of pseudo-soft registers which are used for the
9140 code generation. The maximum number is 32. Using more pseudo-soft
9141 register may or may not result in better code depending on the
9142 program. The default is 4 for 68HC11 and 2 for 68HC12.
9146 File: gcc.info, Node: MCore Options, Next: MIPS Options, Prev: M68hc1x Options, Up: Submodel Options
9148 3.17.16 MCore Options
9149 ---------------------
9151 These are the `-m' options defined for the Motorola M*Core processors.
9155 Inline constants into the code stream if it can be done in two
9156 instructions or less.
9160 Use the divide instruction. (Enabled by default).
9163 `-mno-relax-immediate'
9164 Allow arbitrary sized immediates in bit operations.
9167 `-mno-wide-bitfields'
9168 Always treat bit-fields as int-sized.
9171 `-mno-4byte-functions'
9172 Force all functions to be aligned to a four byte boundary.
9175 `-mno-callgraph-data'
9176 Emit callgraph information.
9180 Prefer word access when reading byte quantities.
9184 Generate code for a little endian target.
9188 Generate code for the 210 processor.
9191 File: gcc.info, Node: MIPS Options, Next: MMIX Options, Prev: MCore Options, Up: Submodel Options
9193 3.17.17 MIPS Options
9194 --------------------
9197 Generate big-endian code.
9200 Generate little-endian code. This is the default for `mips*el-*-*'
9204 Generate code that will run on ARCH, which can be the name of a
9205 generic MIPS ISA, or the name of a particular processor. The ISA
9206 names are: `mips1', `mips2', `mips3', `mips4', `mips32',
9207 `mips32r2', and `mips64'. The processor names are: `4kc', `4kp',
9208 `5kc', `20kc', `m4k', `r2000', `r3000', `r3900', `r4000', `r4400',
9209 `r4600', `r4650', `r6000', `r8000', `rm7000', `rm9000', `orion',
9210 `sb1', `vr4100', `vr4111', `vr4120', `vr4130', `vr4300', `vr5000',
9211 `vr5400' and `vr5500'. The special value `from-abi' selects the
9212 most compatible architecture for the selected ABI (that is,
9213 `mips1' for 32-bit ABIs and `mips3' for 64-bit ABIs).
9215 In processor names, a final `000' can be abbreviated as `k' (for
9216 example, `-march=r2k'). Prefixes are optional, and `vr' may be
9219 GCC defines two macros based on the value of this option. The
9220 first is `_MIPS_ARCH', which gives the name of target
9221 architecture, as a string. The second has the form
9222 `_MIPS_ARCH_FOO', where FOO is the capitalized value of
9223 `_MIPS_ARCH'. For example, `-march=r2000' will set `_MIPS_ARCH'
9224 to `"r2000"' and define the macro `_MIPS_ARCH_R2000'.
9226 Note that the `_MIPS_ARCH' macro uses the processor names given
9227 above. In other words, it will have the full prefix and will not
9228 abbreviate `000' as `k'. In the case of `from-abi', the macro
9229 names the resolved architecture (either `"mips1"' or `"mips3"').
9230 It names the default architecture when no `-march' option is given.
9233 Optimize for ARCH. Among other things, this option controls the
9234 way instructions are scheduled, and the perceived cost of
9235 arithmetic operations. The list of ARCH values is the same as for
9238 When this option is not used, GCC will optimize for the processor
9239 specified by `-march'. By using `-march' and `-mtune' together,
9240 it is possible to generate code that will run on a family of
9241 processors, but optimize the code for one particular member of
9244 `-mtune' defines the macros `_MIPS_TUNE' and `_MIPS_TUNE_FOO',
9245 which work in the same way as the `-march' ones described above.
9248 Equivalent to `-march=mips1'.
9251 Equivalent to `-march=mips2'.
9254 Equivalent to `-march=mips3'.
9257 Equivalent to `-march=mips4'.
9260 Equivalent to `-march=mips32'.
9263 Equivalent to `-march=mips32r2'.
9266 Equivalent to `-march=mips64'.
9270 Use (do not use) the MIPS16 ISA.
9277 Generate code for the given ABI.
9279 Note that the EABI has a 32-bit and a 64-bit variant. GCC normally
9280 generates 64-bit code when you select a 64-bit architecture, but
9281 you can use `-mgp32' to get 32-bit code instead.
9283 For information about the O64 ABI, see
9284 `http://gcc.gnu.org/projects/mipso64-abi.html'.
9288 Generate (do not generate) SVR4-style position-independent code.
9289 `-mabicalls' is the default for SVR4-based systems.
9293 Lift (do not lift) the usual restrictions on the size of the global
9296 GCC normally uses a single instruction to load values from the GOT.
9297 While this is relatively efficient, it will only work if the GOT
9298 is smaller than about 64k. Anything larger will cause the linker
9299 to report an error such as:
9301 relocation truncated to fit: R_MIPS_GOT16 foobar
9303 If this happens, you should recompile your code with `-mxgot'. It
9304 should then work with very large GOTs, although it will also be
9305 less efficient, since it will take three instructions to fetch the
9306 value of a global symbol.
9308 Note that some linkers can create multiple GOTs. If you have such
9309 a linker, you should only need to use `-mxgot' when a single object
9310 file accesses more than 64k's worth of GOT entries. Very few do.
9312 These options have no effect unless GCC is generating position
9316 Assume that general-purpose registers are 32 bits wide.
9319 Assume that general-purpose registers are 64 bits wide.
9322 Assume that floating-point registers are 32 bits wide.
9325 Assume that floating-point registers are 64 bits wide.
9328 Use floating-point coprocessor instructions.
9331 Do not use floating-point coprocessor instructions. Implement
9332 floating-point calculations using library calls instead.
9335 Assume that the floating-point coprocessor only supports
9336 single-precision operations.
9339 Assume that the floating-point coprocessor supports
9340 double-precision operations. This is the default.
9343 `-mno-paired-single'
9344 Use (do not use) paired-single floating-point instructions. *Note
9345 MIPS Paired-Single Support::. This option can only be used when
9346 generating 64-bit code and requires hardware floating-point
9347 support to be enabled.
9351 Use (do not use) the MIPS-3D ASE. *Note MIPS-3D Built-in
9352 Functions::. The option `-mips3d' implies `-mpaired-single'.
9355 Force `int' and `long' types to be 64 bits wide. See `-mlong32'
9356 for an explanation of the default and the way that the pointer
9359 This option has been deprecated and will be removed in a future
9363 Force `long' types to be 64 bits wide. See `-mlong32' for an
9364 explanation of the default and the way that the pointer size is
9368 Force `long', `int', and pointer types to be 32 bits wide.
9370 The default size of `int's, `long's and pointers depends on the
9371 ABI. All the supported ABIs use 32-bit `int's. The n64 ABI uses
9372 64-bit `long's, as does the 64-bit EABI; the others use 32-bit
9373 `long's. Pointers are the same size as `long's, or the same size
9374 as integer registers, whichever is smaller.
9378 Assume (do not assume) that all symbols have 32-bit values,
9379 regardless of the selected ABI. This option is useful in
9380 combination with `-mabi=64' and `-mno-abicalls' because it allows
9381 GCC to generate shorter and faster references to symbolic
9385 Put global and static items less than or equal to NUM bytes into
9386 the small data or bss section instead of the normal data or bss
9387 section. This allows the data to be accessed using a single
9390 All modules should be compiled with the same `-G NUM' value.
9393 `-mno-embedded-data'
9394 Allocate variables to the read-only data section first if
9395 possible, then next in the small data section if possible,
9396 otherwise in data. This gives slightly slower code than the
9397 default, but reduces the amount of RAM required when executing,
9398 and thus may be preferred for some embedded systems.
9400 `-muninit-const-in-rodata'
9401 `-mno-uninit-const-in-rodata'
9402 Put uninitialized `const' variables in the read-only data section.
9403 This option is only meaningful in conjunction with
9407 `-mno-split-addresses'
9408 Enable (disable) use of the `%hi()' and `%lo()' assembler
9409 relocation operators. This option has been superseded by
9410 `-mexplicit-relocs' but is retained for backwards compatibility.
9413 `-mno-explicit-relocs'
9414 Use (do not use) assembler relocation operators when dealing with
9415 symbolic addresses. The alternative, selected by
9416 `-mno-explicit-relocs', is to use assembler macros instead.
9418 `-mexplicit-relocs' is the default if GCC was configured to use an
9419 assembler that supports relocation operators.
9421 `-mcheck-zero-division'
9422 `-mno-check-zero-division'
9423 Trap (do not trap) on integer division by zero. The default is
9424 `-mcheck-zero-division'.
9428 MIPS systems check for division by zero by generating either a
9429 conditional trap or a break instruction. Using traps results in
9430 smaller code, but is only supported on MIPS II and later. Also,
9431 some versions of the Linux kernel have a bug that prevents trap
9432 from generating the proper signal (`SIGFPE'). Use
9433 `-mdivide-traps' to allow conditional traps on architectures that
9434 support them and `-mdivide-breaks' to force the use of breaks.
9436 The default is usually `-mdivide-traps', but this can be
9437 overridden at configure time using `--with-divide=breaks'.
9438 Divide-by-zero checks can be completely disabled using
9439 `-mno-check-zero-division'.
9443 Force (do not force) the use of `memcpy()' for non-trivial block
9444 moves. The default is `-mno-memcpy', which allows GCC to inline
9445 most constant-sized copies.
9449 Disable (do not disable) use of the `jal' instruction. Calling
9450 functions using `jal' is more efficient but requires the caller
9451 and callee to be in the same 256 megabyte segment.
9453 This option has no effect on abicalls code. The default is
9458 Enable (disable) use of the `mad', `madu' and `mul' instructions,
9459 as provided by the R4650 ISA.
9463 Enable (disable) use of the floating point multiply-accumulate
9464 instructions, when they are available. The default is
9467 When multiply-accumulate instructions are used, the intermediate
9468 product is calculated to infinite precision and is not subject to
9469 the FCSR Flush to Zero bit. This may be undesirable in some
9473 Tell the MIPS assembler to not run its preprocessor over user
9474 assembler files (with a `.s' suffix) when assembling them.
9478 Work around certain R4000 CPU errata:
9479 - A double-word or a variable shift may give an incorrect
9480 result if executed immediately after starting an integer
9483 - A double-word or a variable shift may give an incorrect
9484 result if executed while an integer multiplication is in
9487 - An integer division may give an incorrect result if started
9488 in a delay slot of a taken branch or a jump.
9492 Work around certain R4400 CPU errata:
9493 - A double-word or a variable shift may give an incorrect
9494 result if executed immediately after starting an integer
9499 Work around certain VR4120 errata:
9500 - `dmultu' does not always produce the correct result.
9502 - `div' and `ddiv' do not always produce the correct result if
9503 one of the operands is negative.
9504 The workarounds for the division errata rely on special functions
9505 in `libgcc.a'. At present, these functions are only provided by
9506 the `mips64vr*-elf' configurations.
9508 Other VR4120 errata require a nop to be inserted between certain
9509 pairs of instructions. These errata are handled by the assembler,
9513 Work around the VR4130 `mflo'/`mfhi' errata. The workarounds are
9514 implemented by the assembler rather than by GCC, although GCC will
9515 avoid using `mflo' and `mfhi' if the VR4130 `macc', `macchi',
9516 `dmacc' and `dmacchi' instructions are available instead.
9520 Work around certain SB-1 CPU core errata. (This flag currently
9521 works around the SB-1 revision 2 "F1" and "F2" floating point
9526 Specifies the function to call to flush the I and D caches, or to
9527 not call any such function. If called, the function must take the
9528 same arguments as the common `_flush_func()', that is, the address
9529 of the memory range for which the cache is being flushed, the size
9530 of the memory range, and the number 3 (to flush both caches). The
9531 default depends on the target GCC was configured for, but commonly
9532 is either `_flush_func' or `__cpu_flush'.
9535 `-mno-branch-likely'
9536 Enable or disable use of Branch Likely instructions, regardless of
9537 the default for the selected architecture. By default, Branch
9538 Likely instructions may be generated if they are supported by the
9539 selected architecture. An exception is for the MIPS32 and MIPS64
9540 architectures and processors which implement those architectures;
9541 for those, Branch Likely instructions will not be generated by
9542 default because the MIPS32 and MIPS64 architectures specifically
9543 deprecate their use.
9546 `-mno-fp-exceptions'
9547 Specifies whether FP exceptions are enabled. This affects how we
9548 schedule FP instructions for some processors. The default is that
9549 FP exceptions are enabled.
9551 For instance, on the SB-1, if FP exceptions are disabled, and we
9552 are emitting 64-bit code, then we can use both FP pipes.
9553 Otherwise, we can only use one FP pipe.
9557 The VR4130 pipeline is two-way superscalar, but can only issue two
9558 instructions together if the first one is 8-byte aligned. When
9559 this option is enabled, GCC will align pairs of instructions that
9560 it thinks should execute in parallel.
9562 This option only has an effect when optimizing for the VR4130. It
9563 normally makes code faster, but at the expense of making it bigger.
9564 It is enabled by default at optimization level `-O3'.
9567 File: gcc.info, Node: MMIX Options, Next: MN10300 Options, Prev: MIPS Options, Up: Submodel Options
9569 3.17.18 MMIX Options
9570 --------------------
9572 These options are defined for the MMIX:
9576 Specify that intrinsic library functions are being compiled,
9577 passing all values in registers, no matter the size.
9581 Generate floating-point comparison instructions that compare with
9582 respect to the `rE' epsilon register.
9586 Generate code that passes function parameters and return values
9587 that (in the called function) are seen as registers `$0' and up,
9588 as opposed to the GNU ABI which uses global registers `$231' and
9593 When reading data from memory in sizes shorter than 64 bits, use
9594 (do not use) zero-extending load instructions by default, rather
9595 than sign-extending ones.
9599 Make the result of a division yielding a remainder have the same
9600 sign as the divisor. With the default, `-mno-knuthdiv', the sign
9601 of the remainder follows the sign of the dividend. Both methods
9602 are arithmetically valid, the latter being almost exclusively used.
9604 `-mtoplevel-symbols'
9605 `-mno-toplevel-symbols'
9606 Prepend (do not prepend) a `:' to all global symbols, so the
9607 assembly code can be used with the `PREFIX' assembly directive.
9610 Generate an executable in the ELF format, rather than the default
9611 `mmo' format used by the `mmix' simulator.
9614 `-mno-branch-predict'
9615 Use (do not use) the probable-branch instructions, when static
9616 branch prediction indicates a probable branch.
9619 `-mno-base-addresses'
9620 Generate (do not generate) code that uses _base addresses_. Using
9621 a base address automatically generates a request (handled by the
9622 assembler and the linker) for a constant to be set up in a global
9623 register. The register is used for one or more base address
9624 requests within the range 0 to 255 from the value held in the
9625 register. The generally leads to short and fast code, but the
9626 number of different data items that can be addressed is limited.
9627 This means that a program that uses lots of static data may
9628 require `-mno-base-addresses'.
9632 Force (do not force) generated code to have a single exit point in
9636 File: gcc.info, Node: MN10300 Options, Next: NS32K Options, Prev: MMIX Options, Up: Submodel Options
9638 3.17.19 MN10300 Options
9639 -----------------------
9641 These `-m' options are defined for Matsushita MN10300 architectures:
9644 Generate code to avoid bugs in the multiply instructions for the
9645 MN10300 processors. This is the default.
9648 Do not generate code to avoid bugs in the multiply instructions
9649 for the MN10300 processors.
9652 Generate code which uses features specific to the AM33 processor.
9655 Do not generate code which uses features specific to the AM33
9656 processor. This is the default.
9659 Do not link in the C run-time initialization object file.
9662 Indicate to the linker that it should perform a relaxation
9663 optimization pass to shorten branches, calls and absolute memory
9664 addresses. This option only has an effect when used on the
9665 command line for the final link step.
9667 This option makes symbolic debugging impossible.
9670 File: gcc.info, Node: NS32K Options, Next: PDP-11 Options, Prev: MN10300 Options, Up: Submodel Options
9672 3.17.20 NS32K Options
9673 ---------------------
9675 These are the `-m' options defined for the 32000 series. The default
9676 values for these options depends on which style of 32000 was selected
9677 when the compiler was configured; the defaults for the most common
9678 choices are given below.
9682 Generate output for a 32032. This is the default when the
9683 compiler is configured for 32032 and 32016 based systems.
9687 Generate output for a 32332. This is the default when the
9688 compiler is configured for 32332-based systems.
9692 Generate output for a 32532. This is the default when the
9693 compiler is configured for 32532-based systems.
9696 Generate output containing 32081 instructions for floating point.
9697 This is the default for all systems.
9700 Generate output containing 32381 instructions for floating point.
9701 This also implies `-m32081'. The 32381 is only compatible with
9702 the 32332 and 32532 cpus. This is the default for the
9703 pc532-netbsd configuration.
9706 Try and generate multiply-add floating point instructions `polyF'
9707 and `dotF'. This option is only available if the `-m32381' option
9708 is in effect. Using these instructions requires changes to
9709 register allocation which generally has a negative impact on
9710 performance. This option should only be enabled when compiling
9711 code particularly likely to make heavy use of multiply-add
9715 Do not try and generate multiply-add floating point instructions
9716 `polyF' and `dotF'. This is the default on all platforms.
9719 Generate output containing library calls for floating point.
9720 *Warning:* the requisite libraries may not be available.
9724 Control whether or not the compiler uses IEEE floating point
9725 comparisons. These handle correctly the case where the result of a
9726 comparison is unordered. *Warning:* the requisite kernel support
9727 may not be available.
9730 Do not use the bit-field instructions. On some machines it is
9731 faster to use shifting and masking operations. This is the
9732 default for the pc532.
9735 Do use the bit-field instructions. This is the default for all
9736 platforms except the pc532.
9739 Use a different function-calling convention, in which functions
9740 that take a fixed number of arguments return pop their arguments
9741 on return with the `ret' instruction.
9743 This calling convention is incompatible with the one normally used
9744 on Unix, so you cannot use it if you need to call libraries
9745 compiled with the Unix compiler.
9747 Also, you must provide function prototypes for all functions that
9748 take variable numbers of arguments (including `printf'); otherwise
9749 incorrect code will be generated for calls to those functions.
9751 In addition, seriously incorrect code will result if you call a
9752 function with too many arguments. (Normally, extra arguments are
9753 harmlessly ignored.)
9755 This option takes its name from the 680x0 `rtd' instruction.
9758 Use a different function-calling convention where the first two
9759 arguments are passed in registers.
9761 This calling convention is incompatible with the one normally used
9762 on Unix, so you cannot use it if you need to call libraries
9763 compiled with the Unix compiler.
9766 Do not pass any arguments in registers. This is the default for
9770 It is OK to use the sb as an index register which is always loaded
9771 with zero. This is the default for the pc532-netbsd target.
9774 The sb register is not available for use or has not been
9775 initialized to zero by the run time system. This is the default
9776 for all targets except the pc532-netbsd. It is also implied
9777 whenever `-mhimem' or `-fpic' is set.
9780 Many ns32000 series addressing modes use displacements of up to
9781 512MB. If an address is above 512MB then displacements from zero
9782 can not be used. This option causes code to be generated which
9783 can be loaded above 512MB. This may be useful for operating
9784 systems or ROM code.
9787 Assume code will be loaded in the first 512MB of virtual address
9788 space. This is the default for all platforms.
9792 File: gcc.info, Node: PDP-11 Options, Next: PowerPC Options, Prev: NS32K Options, Up: Submodel Options
9794 3.17.21 PDP-11 Options
9795 ----------------------
9797 These options are defined for the PDP-11:
9800 Use hardware FPP floating point. This is the default. (FIS
9801 floating point on the PDP-11/40 is not supported.)
9804 Do not use hardware floating point.
9807 Return floating-point results in ac0 (fr0 in Unix assembler
9811 Return floating-point results in memory. This is the default.
9814 Generate code for a PDP-11/40.
9817 Generate code for a PDP-11/45. This is the default.
9820 Generate code for a PDP-11/10.
9823 Use inline `movmemhi' patterns for copying memory. This is the
9827 Do not use inline `movmemhi' patterns for copying memory.
9831 Use 16-bit `int'. This is the default.
9839 Use 64-bit `float'. This is the default.
9846 Use `abshi2' pattern. This is the default.
9849 Do not use `abshi2' pattern.
9851 `-mbranch-expensive'
9852 Pretend that branches are expensive. This is for experimenting
9853 with code generation only.
9856 Do not pretend that branches are expensive. This is the default.
9859 Generate code for a system with split I&D.
9862 Generate code for a system without split I&D. This is the default.
9865 Use Unix assembler syntax. This is the default when configured for
9869 Use DEC assembler syntax. This is the default when configured for
9870 any PDP-11 target other than `pdp11-*-bsd'.
9873 File: gcc.info, Node: PowerPC Options, Next: RS/6000 and PowerPC Options, Prev: PDP-11 Options, Up: Submodel Options
9875 3.17.22 PowerPC Options
9876 -----------------------
9878 These are listed under *Note RS/6000 and PowerPC Options::.
9881 File: gcc.info, Node: RS/6000 and PowerPC Options, Next: S/390 and zSeries Options, Prev: PowerPC Options, Up: Submodel Options
9883 3.17.23 IBM RS/6000 and PowerPC Options
9884 ---------------------------------------
9886 These `-m' options are defined for the IBM RS/6000 and PowerPC:
9894 `-mno-powerpc-gpopt'
9896 `-mno-powerpc-gfxopt'
9899 GCC supports two related instruction set architectures for the
9900 RS/6000 and PowerPC. The "POWER" instruction set are those
9901 instructions supported by the `rios' chip set used in the original
9902 RS/6000 systems and the "PowerPC" instruction set is the
9903 architecture of the Motorola MPC5xx, MPC6xx, MPC8xx
9904 microprocessors, and the IBM 4xx microprocessors.
9906 Neither architecture is a subset of the other. However there is a
9907 large common subset of instructions supported by both. An MQ
9908 register is included in processors supporting the POWER
9911 You use these options to specify which instructions are available
9912 on the processor you are using. The default value of these
9913 options is determined when configuring GCC. Specifying the
9914 `-mcpu=CPU_TYPE' overrides the specification of these options. We
9915 recommend you use the `-mcpu=CPU_TYPE' option rather than the
9916 options listed above.
9918 The `-mpower' option allows GCC to generate instructions that are
9919 found only in the POWER architecture and to use the MQ register.
9920 Specifying `-mpower2' implies `-power' and also allows GCC to
9921 generate instructions that are present in the POWER2 architecture
9922 but not the original POWER architecture.
9924 The `-mpowerpc' option allows GCC to generate instructions that
9925 are found only in the 32-bit subset of the PowerPC architecture.
9926 Specifying `-mpowerpc-gpopt' implies `-mpowerpc' and also allows
9927 GCC to use the optional PowerPC architecture instructions in the
9928 General Purpose group, including floating-point square root.
9929 Specifying `-mpowerpc-gfxopt' implies `-mpowerpc' and also allows
9930 GCC to use the optional PowerPC architecture instructions in the
9931 Graphics group, including floating-point select.
9933 The `-mpowerpc64' option allows GCC to generate the additional
9934 64-bit instructions that are found in the full PowerPC64
9935 architecture and to treat GPRs as 64-bit, doubleword quantities.
9936 GCC defaults to `-mno-powerpc64'.
9938 If you specify both `-mno-power' and `-mno-powerpc', GCC will use
9939 only the instructions in the common subset of both architectures
9940 plus some special AIX common-mode calls, and will not use the MQ
9941 register. Specifying both `-mpower' and `-mpowerpc' permits GCC
9942 to use any instruction from either architecture and to allow use
9943 of the MQ register; specify this for the Motorola MPC601.
9947 Select which mnemonics to use in the generated assembler code.
9948 With `-mnew-mnemonics', GCC uses the assembler mnemonics defined
9949 for the PowerPC architecture. With `-mold-mnemonics' it uses the
9950 assembler mnemonics defined for the POWER architecture.
9951 Instructions defined in only one architecture have only one
9952 mnemonic; GCC uses that mnemonic irrespective of which of these
9953 options is specified.
9955 GCC defaults to the mnemonics appropriate for the architecture in
9956 use. Specifying `-mcpu=CPU_TYPE' sometimes overrides the value of
9957 these option. Unless you are building a cross-compiler, you
9958 should normally not specify either `-mnew-mnemonics' or
9959 `-mold-mnemonics', but should instead accept the default.
9962 Set architecture type, register usage, choice of mnemonics, and
9963 instruction scheduling parameters for machine type CPU_TYPE.
9964 Supported values for CPU_TYPE are `401', `403', `405', `405fp',
9965 `440', `440fp', `505', `601', `602', `603', `603e', `604', `604e',
9966 `620', `630', `740', `7400', `7450', `750', `801', `821', `823',
9967 `860', `970', `8540', `common', `ec603e', `G3', `G4', `G5',
9968 `power', `power2', `power3', `power4', `power5', `powerpc',
9969 `powerpc64', `rios', `rios1', `rios2', `rsc', and `rs64a'.
9971 `-mcpu=common' selects a completely generic processor. Code
9972 generated under this option will run on any POWER or PowerPC
9973 processor. GCC will use only the instructions in the common
9974 subset of both architectures, and will not use the MQ register.
9975 GCC assumes a generic processor model for scheduling purposes.
9977 `-mcpu=power', `-mcpu=power2', `-mcpu=powerpc', and
9978 `-mcpu=powerpc64' specify generic POWER, POWER2, pure 32-bit
9979 PowerPC (i.e., not MPC601), and 64-bit PowerPC architecture machine
9980 types, with an appropriate, generic processor model assumed for
9981 scheduling purposes.
9983 The other options specify a specific processor. Code generated
9984 under those options will run best on that processor, and may not
9985 run at all on others.
9987 The `-mcpu' options automatically enable or disable the following
9988 options: `-maltivec', `-mhard-float', `-mmfcrf', `-mmultiple',
9989 `-mnew-mnemonics', `-mpower', `-mpower2', `-mpowerpc64',
9990 `-mpowerpc-gpopt', `-mpowerpc-gfxopt', `-mstring'. The particular
9991 options set for any particular CPU will vary between compiler
9992 versions, depending on what setting seems to produce optimal code
9993 for that CPU; it doesn't necessarily reflect the actual hardware's
9994 capabilities. If you wish to set an individual option to a
9995 particular value, you may specify it after the `-mcpu' option,
9996 like `-mcpu=970 -mno-altivec'.
9998 On AIX, the `-maltivec' and `-mpowerpc64' options are not enabled
9999 or disabled by the `-mcpu' option at present, since AIX does not
10000 have full support for these options. You may still enable or
10001 disable them individually if you're sure it'll work in your
10005 Set the instruction scheduling parameters for machine type
10006 CPU_TYPE, but do not set the architecture type, register usage, or
10007 choice of mnemonics, as `-mcpu=CPU_TYPE' would. The same values
10008 for CPU_TYPE are used for `-mtune' as for `-mcpu'. If both are
10009 specified, the code generated will use the architecture,
10010 registers, and mnemonics set by `-mcpu', but the scheduling
10011 parameters set by `-mtune'.
10015 Generate code that uses (does not use) AltiVec instructions, and
10016 also enable the use of built-in functions that allow more direct
10017 access to the AltiVec instruction set. You may also need to set
10018 `-mabi=altivec' to adjust the current ABI with AltiVec ABI
10022 Extend the current ABI with SPE ABI extensions. This does not
10023 change the default ABI, instead it adds the SPE ABI extensions to
10027 Disable Booke SPE ABI extensions for the current ABI.
10031 This switch enables or disables the generation of ISEL
10036 This switch enables or disables the generation of SPE simd
10039 `-mfloat-gprs=YES/SINGLE/DOUBLE/NO'
10041 This switch enables or disables the generation of floating point
10042 operations on the general purpose registers for architectures that
10045 The argument YES or SINGLE enables the use of single-precision
10046 floating point operations.
10048 The argument DOUBLE enables the use of single and double-precision
10049 floating point operations.
10051 The argument NO disables floating point operations on the general
10054 This option is currently only available on the MPC854x.
10058 Generate code for 32-bit or 64-bit environments of Darwin and SVR4
10059 targets (including GNU/Linux). The 32-bit environment sets int,
10060 long and pointer to 32 bits and generates code that runs on any
10061 PowerPC variant. The 64-bit environment sets int to 32 bits and
10062 long and pointer to 64 bits, and generates code for PowerPC64, as
10069 Modify generation of the TOC (Table Of Contents), which is created
10070 for every executable file. The `-mfull-toc' option is selected by
10071 default. In that case, GCC will allocate at least one TOC entry
10072 for each unique non-automatic variable reference in your program.
10073 GCC will also place floating-point constants in the TOC. However,
10074 only 16,384 entries are available in the TOC.
10076 If you receive a linker error message that saying you have
10077 overflowed the available TOC space, you can reduce the amount of
10078 TOC space used with the `-mno-fp-in-toc' and `-mno-sum-in-toc'
10079 options. `-mno-fp-in-toc' prevents GCC from putting floating-point
10080 constants in the TOC and `-mno-sum-in-toc' forces GCC to generate
10081 code to calculate the sum of an address and a constant at run-time
10082 instead of putting that sum into the TOC. You may specify one or
10083 both of these options. Each causes GCC to produce very slightly
10084 slower and larger code at the expense of conserving TOC space.
10086 If you still run out of space in the TOC even when you specify
10087 both of these options, specify `-mminimal-toc' instead. This
10088 option causes GCC to make only one TOC entry for every file. When
10089 you specify this option, GCC will produce code that is slower and
10090 larger but which uses extremely little TOC space. You may wish to
10091 use this option only on files that contain less frequently
10096 Enable 64-bit AIX ABI and calling convention: 64-bit pointers,
10097 64-bit `long' type, and the infrastructure needed to support them.
10098 Specifying `-maix64' implies `-mpowerpc64' and `-mpowerpc', while
10099 `-maix32' disables the 64-bit ABI and implies `-mno-powerpc64'.
10100 GCC defaults to `-maix32'.
10104 Produce code that conforms more closely to IBM XLC semantics when
10105 using AIX-compatible ABI. Pass floating-point arguments to
10106 prototyped functions beyond the register save area (RSA) on the
10107 stack in addition to argument FPRs. Do not assume that most
10108 significant double in 128 bit long double value is properly
10109 rounded when comparing values.
10111 The AIX calling convention was extended but not initially
10112 documented to handle an obscure K&R C case of calling a function
10113 that takes the address of its arguments with fewer arguments than
10114 declared. AIX XL compilers access floating point arguments which
10115 do not fit in the RSA from the stack when a subroutine is compiled
10116 without optimization. Because always storing floating-point
10117 arguments on the stack is inefficient and rarely needed, this
10118 option is not enabled by default and only is necessary when
10119 calling subroutines compiled by AIX XL compilers without
10123 Support "IBM RS/6000 SP" "Parallel Environment" (PE). Link an
10124 application written to use message passing with special startup
10125 code to enable the application to run. The system must have PE
10126 installed in the standard location (`/usr/lpp/ppe.poe/'), or the
10127 `specs' file must be overridden with the `-specs=' option to
10128 specify the appropriate directory location. The Parallel
10129 Environment does not support threads, so the `-mpe' option and the
10130 `-pthread' option are incompatible.
10134 On AIX, 32-bit Darwin, and 64-bit PowerPC GNU/Linux, the option
10135 `-malign-natural' overrides the ABI-defined alignment of larger
10136 types, such as floating-point doubles, on their natural size-based
10137 boundary. The option `-malign-power' instructs GCC to follow the
10138 ABI-specified alignment rules. GCC defaults to the standard
10139 alignment defined in the ABI.
10141 On 64-bit Darwin, natural alignment is the default, and
10142 `-malign-power' is not supported.
10146 Generate code that does not use (uses) the floating-point register
10147 set. Software floating point emulation is provided if you use the
10148 `-msoft-float' option, and pass the option to GCC when linking.
10152 Generate code that uses (does not use) the load multiple word
10153 instructions and the store multiple word instructions. These
10154 instructions are generated by default on POWER systems, and not
10155 generated on PowerPC systems. Do not use `-mmultiple' on little
10156 endian PowerPC systems, since those instructions do not work when
10157 the processor is in little endian mode. The exceptions are PPC740
10158 and PPC750 which permit the instructions usage in little endian
10163 Generate code that uses (does not use) the load string instructions
10164 and the store string word instructions to save multiple registers
10165 and do small block moves. These instructions are generated by
10166 default on POWER systems, and not generated on PowerPC systems.
10167 Do not use `-mstring' on little endian PowerPC systems, since those
10168 instructions do not work when the processor is in little endian
10169 mode. The exceptions are PPC740 and PPC750 which permit the
10170 instructions usage in little endian mode.
10174 Generate code that uses (does not use) the load or store
10175 instructions that update the base register to the address of the
10176 calculated memory location. These instructions are generated by
10177 default. If you use `-mno-update', there is a small window
10178 between the time that the stack pointer is updated and the address
10179 of the previous frame is stored, which means code that walks the
10180 stack frame across interrupts or signals may get corrupted data.
10184 Generate code that uses (does not use) the floating point multiply
10185 and accumulate instructions. These instructions are generated by
10186 default if hardware floating is used.
10190 On System V.4 and embedded PowerPC systems do not (do) force
10191 structures and unions that contain bit-fields to be aligned to the
10192 base type of the bit-field.
10194 For example, by default a structure containing nothing but 8
10195 `unsigned' bit-fields of length 1 would be aligned to a 4 byte
10196 boundary and have a size of 4 bytes. By using `-mno-bit-align',
10197 the structure would be aligned to a 1 byte boundary and be one
10200 `-mno-strict-align'
10202 On System V.4 and embedded PowerPC systems do not (do) assume that
10203 unaligned memory references will be handled by the system.
10207 On embedded PowerPC systems generate code that allows (does not
10208 allow) the program to be relocated to a different address at
10209 runtime. If you use `-mrelocatable' on any module, all objects
10210 linked together must be compiled with `-mrelocatable' or
10211 `-mrelocatable-lib'.
10213 `-mrelocatable-lib'
10214 `-mno-relocatable-lib'
10215 On embedded PowerPC systems generate code that allows (does not
10216 allow) the program to be relocated to a different address at
10217 runtime. Modules compiled with `-mrelocatable-lib' can be linked
10218 with either modules compiled without `-mrelocatable' and
10219 `-mrelocatable-lib' or with modules compiled with the
10220 `-mrelocatable' options.
10224 On System V.4 and embedded PowerPC systems do not (do) assume that
10225 register 2 contains a pointer to a global area pointing to the
10226 addresses used in the program.
10230 On System V.4 and embedded PowerPC systems compile code for the
10231 processor in little endian mode. The `-mlittle-endian' option is
10232 the same as `-mlittle'.
10236 On System V.4 and embedded PowerPC systems compile code for the
10237 processor in big endian mode. The `-mbig-endian' option is the
10241 On Darwin and Mac OS X systems, compile code so that it is not
10242 relocatable, but that its external references are relocatable. The
10243 resulting code is suitable for applications, but not shared
10246 `-mprioritize-restricted-insns=PRIORITY'
10247 This option controls the priority that is assigned to
10248 dispatch-slot restricted instructions during the second scheduling
10249 pass. The argument PRIORITY takes the value 0/1/2 to assign
10250 NO/HIGHEST/SECOND-HIGHEST priority to dispatch slot restricted
10253 `-msched-costly-dep=DEPENDENCE_TYPE'
10254 This option controls which dependences are considered costly by
10255 the target during instruction scheduling. The argument
10256 DEPENDENCE_TYPE takes one of the following values: NO: no
10257 dependence is costly, ALL: all dependences are costly,
10258 TRUE_STORE_TO_LOAD: a true dependence from store to load is costly,
10259 STORE_TO_LOAD: any dependence from store to load is costly,
10260 NUMBER: any dependence which latency >= NUMBER is costly.
10262 `-minsert-sched-nops=SCHEME'
10263 This option controls which nop insertion scheme will be used during
10264 the second scheduling pass. The argument SCHEME takes one of the
10265 following values: NO: Don't insert nops. PAD: Pad with nops any
10266 dispatch group which has vacant issue slots, according to the
10267 scheduler's grouping. REGROUP_EXACT: Insert nops to force costly
10268 dependent insns into separate groups. Insert exactly as many nops
10269 as needed to force an insn to a new group, according to the
10270 estimated processor grouping. NUMBER: Insert nops to force costly
10271 dependent insns into separate groups. Insert NUMBER nops to force
10272 an insn to a new group.
10275 On System V.4 and embedded PowerPC systems compile code using
10276 calling conventions that adheres to the March 1995 draft of the
10277 System V Application Binary Interface, PowerPC processor
10278 supplement. This is the default unless you configured GCC using
10279 `powerpc-*-eabiaix'.
10282 Specify both `-mcall-sysv' and `-meabi' options.
10284 `-mcall-sysv-noeabi'
10285 Specify both `-mcall-sysv' and `-mno-eabi' options.
10288 On System V.4 and embedded PowerPC systems compile code for the
10289 Solaris operating system.
10292 On System V.4 and embedded PowerPC systems compile code for the
10293 Linux-based GNU system.
10296 On System V.4 and embedded PowerPC systems compile code for the
10297 Hurd-based GNU system.
10300 On System V.4 and embedded PowerPC systems compile code for the
10301 NetBSD operating system.
10303 `-maix-struct-return'
10304 Return all structures in memory (as specified by the AIX ABI).
10306 `-msvr4-struct-return'
10307 Return structures smaller than 8 bytes in registers (as specified
10311 Extend the current ABI with AltiVec ABI extensions. This does not
10312 change the default ABI, instead it adds the AltiVec ABI extensions
10313 to the current ABI.
10316 Disable AltiVec ABI extensions for the current ABI.
10320 On System V.4 and embedded PowerPC systems assume that all calls to
10321 variable argument functions are properly prototyped. Otherwise,
10322 the compiler must insert an instruction before every non
10323 prototyped call to set or clear bit 6 of the condition code
10324 register (CR) to indicate whether floating point values were
10325 passed in the floating point registers in case the function takes
10326 a variable arguments. With `-mprototype', only calls to
10327 prototyped variable argument functions will set or clear the bit.
10330 On embedded PowerPC systems, assume that the startup module is
10331 called `sim-crt0.o' and that the standard C libraries are
10332 `libsim.a' and `libc.a'. This is the default for
10333 `powerpc-*-eabisim'. configurations.
10336 On embedded PowerPC systems, assume that the startup module is
10337 called `crt0.o' and the standard C libraries are `libmvme.a' and
10341 On embedded PowerPC systems, assume that the startup module is
10342 called `crt0.o' and the standard C libraries are `libads.a' and
10346 On embedded PowerPC systems, assume that the startup module is
10347 called `crt0.o' and the standard C libraries are `libyk.a' and
10351 On System V.4 and embedded PowerPC systems, specify that you are
10352 compiling for a VxWorks system.
10355 Specify that you are compiling for the WindISS simulation
10359 On embedded PowerPC systems, set the PPC_EMB bit in the ELF flags
10360 header to indicate that `eabi' extended relocations are used.
10364 On System V.4 and embedded PowerPC systems do (do not) adhere to
10365 the Embedded Applications Binary Interface (eabi) which is a set of
10366 modifications to the System V.4 specifications. Selecting `-meabi'
10367 means that the stack is aligned to an 8 byte boundary, a function
10368 `__eabi' is called to from `main' to set up the eabi environment,
10369 and the `-msdata' option can use both `r2' and `r13' to point to
10370 two separate small data areas. Selecting `-mno-eabi' means that
10371 the stack is aligned to a 16 byte boundary, do not call an
10372 initialization function from `main', and the `-msdata' option will
10373 only use `r13' to point to a single small data area. The `-meabi'
10374 option is on by default if you configured GCC using one of the
10375 `powerpc*-*-eabi*' options.
10378 On System V.4 and embedded PowerPC systems, put small initialized
10379 `const' global and static data in the `.sdata2' section, which is
10380 pointed to by register `r2'. Put small initialized non-`const'
10381 global and static data in the `.sdata' section, which is pointed
10382 to by register `r13'. Put small uninitialized global and static
10383 data in the `.sbss' section, which is adjacent to the `.sdata'
10384 section. The `-msdata=eabi' option is incompatible with the
10385 `-mrelocatable' option. The `-msdata=eabi' option also sets the
10389 On System V.4 and embedded PowerPC systems, put small global and
10390 static data in the `.sdata' section, which is pointed to by
10391 register `r13'. Put small uninitialized global and static data in
10392 the `.sbss' section, which is adjacent to the `.sdata' section.
10393 The `-msdata=sysv' option is incompatible with the `-mrelocatable'
10398 On System V.4 and embedded PowerPC systems, if `-meabi' is used,
10399 compile code the same as `-msdata=eabi', otherwise compile code the
10400 same as `-msdata=sysv'.
10403 On System V.4 and embedded PowerPC systems, put small global and
10404 static data in the `.sdata' section. Put small uninitialized
10405 global and static data in the `.sbss' section. Do not use
10406 register `r13' to address small data however. This is the default
10407 behavior unless other `-msdata' options are used.
10411 On embedded PowerPC systems, put all initialized global and static
10412 data in the `.data' section, and all uninitialized data in the
10416 On embedded PowerPC systems, put global and static items less than
10417 or equal to NUM bytes into the small data or bss sections instead
10418 of the normal data or bss section. By default, NUM is 8. The `-G
10419 NUM' switch is also passed to the linker. All modules should be
10420 compiled with the same `-G NUM' value.
10424 On System V.4 and embedded PowerPC systems do (do not) emit
10425 register names in the assembly language output using symbolic
10430 Default to making all function calls indirectly, using a register,
10431 so that functions which reside further than 32 megabytes
10432 (33,554,432 bytes) from the current location can be called. This
10433 setting can be overridden by the `shortcall' function attribute,
10434 or by `#pragma longcall(0)'.
10436 Some linkers are capable of detecting out-of-range calls and
10437 generating glue code on the fly. On these systems, long calls are
10438 unnecessary and generate slower code. As of this writing, the AIX
10439 linker can do this, as can the GNU linker for PowerPC/64. It is
10440 planned to add this feature to the GNU linker for 32-bit PowerPC
10443 On Darwin/PPC systems, `#pragma longcall' will generate "jbsr
10444 callee, L42", plus a "branch island" (glue code). The two target
10445 addresses represent the callee and the "branch island". The
10446 Darwin/PPC linker will prefer the first address and generate a "bl
10447 callee" if the PPC "bl" instruction will reach the callee directly;
10448 otherwise, the linker will generate "bl L42" to call the "branch
10449 island". The "branch island" is appended to the body of the
10450 calling function; it computes the full 32-bit address of the callee
10453 On Mach-O (Darwin) systems, this option directs the compiler emit
10454 to the glue for every direct call, and the Darwin linker decides
10455 whether to use or discard it.
10457 In the future, we may cause GCC to ignore all longcall
10458 specifications when the linker is known to generate glue.
10461 Adds support for multithreading with the "pthreads" library. This
10462 option sets flags for both the preprocessor and linker.
10466 File: gcc.info, Node: S/390 and zSeries Options, Next: SH Options, Prev: RS/6000 and PowerPC Options, Up: Submodel Options
10468 3.17.24 S/390 and zSeries Options
10469 ---------------------------------
10471 These are the `-m' options defined for the S/390 and zSeries
10476 Use (do not use) the hardware floating-point instructions and
10477 registers for floating-point operations. When `-msoft-float' is
10478 specified, functions in `libgcc.a' will be used to perform
10479 floating-point operations. When `-mhard-float' is specified, the
10480 compiler generates IEEE floating-point instructions. This is the
10485 Store (do not store) the address of the caller's frame as
10486 backchain pointer into the callee's stack frame. A backchain may
10487 be needed to allow debugging using tools that do not understand
10488 DWARF-2 call frame information. When `-mno-packed-stack' is in
10489 effect, the backchain pointer is stored at the bottom of the stack
10490 frame; when `-mpacked-stack' is in effect, the backchain is placed
10491 into the topmost word of the 96/160 byte register save area.
10493 In general, code compiled with `-mbackchain' is call-compatible
10494 with code compiled with `-mmo-backchain'; however, use of the
10495 backchain for debugging purposes usually requires that the whole
10496 binary is built with `-mbackchain'. Note that the combination of
10497 `-mbackchain', `-mpacked-stack' and `-mhard-float' is not
10498 supported. In order to build a linux kernel use `-msoft-float'.
10500 The default is to not maintain the backchain.
10504 `-mno-packed-stack'
10505 Use (do not use) the packed stack layout. When
10506 `-mno-packed-stack' is specified, the compiler uses the all fields
10507 of the 96/160 byte register save area only for their default
10508 purpose; unused fields still take up stack space. When
10509 `-mpacked-stack' is specified, register save slots are densely
10510 packed at the top of the register save area; unused space is
10511 reused for other purposes, allowing for more efficient use of the
10512 available stack space. However, when `-mbackchain' is also in
10513 effect, the topmost word of the save area is always used to store
10514 the backchain, and the return address register is always saved two
10515 words below the backchain.
10517 As long as the stack frame backchain is not used, code generated
10518 with `-mpacked-stack' is call-compatible with code generated with
10519 `-mno-packed-stack'. Note that some non-FSF releases of GCC 2.95
10520 for S/390 or zSeries generated code that uses the stack frame
10521 backchain at run time, not just for debugging purposes. Such code
10522 is not call-compatible with code compiled with `-mpacked-stack'.
10523 Also, note that the combination of `-mbackchain', `-mpacked-stack'
10524 and `-mhard-float' is not supported. In order to build a linux
10525 kernel use `-msoft-float'.
10527 The default is to not use the packed stack layout.
10531 Generate (or do not generate) code using the `bras' instruction to
10532 do subroutine calls. This only works reliably if the total
10533 executable size does not exceed 64k. The default is to use the
10534 `basr' instruction instead, which does not have this limitation.
10538 When `-m31' is specified, generate code compliant to the GNU/Linux
10539 for S/390 ABI. When `-m64' is specified, generate code compliant
10540 to the GNU/Linux for zSeries ABI. This allows GCC in particular
10541 to generate 64-bit instructions. For the `s390' targets, the
10542 default is `-m31', while the `s390x' targets default to `-m64'.
10546 When `-mzarch' is specified, generate code using the instructions
10547 available on z/Architecture. When `-mesa' is specified, generate
10548 code using the instructions available on ESA/390. Note that
10549 `-mesa' is not possible with `-m64'. When generating code
10550 compliant to the GNU/Linux for S/390 ABI, the default is `-mesa'.
10551 When generating code compliant to the GNU/Linux for zSeries ABI,
10552 the default is `-mzarch'.
10556 Generate (or do not generate) code using the `mvcle' instruction
10557 to perform block moves. When `-mno-mvcle' is specified, use a
10558 `mvc' loop instead. This is the default.
10562 Print (or do not print) additional debug information when
10563 compiling. The default is to not print debug information.
10566 Generate code that will run on CPU-TYPE, which is the name of a
10567 system representing a certain processor type. Possible values for
10568 CPU-TYPE are `g5', `g6', `z900', and `z990'. When generating code
10569 using the instructions available on z/Architecture, the default is
10570 `-march=z900'. Otherwise, the default is `-march=g5'.
10573 Tune to CPU-TYPE everything applicable about the generated code,
10574 except for the ABI and the set of available instructions. The
10575 list of CPU-TYPE values is the same as for `-march'. The default
10576 is the value used for `-march'.
10580 Generate code that adds (does not add) in TPF OS specific branches
10581 to trace routines in the operating system. This option is off by
10582 default, even when compiling for the TPF OS.
10586 Generate code that uses (does not use) the floating point multiply
10587 and accumulate instructions. These instructions are generated by
10588 default if hardware floating point is used.
10590 `-mwarn-framesize=FRAMESIZE'
10591 Emit a warning if the current function exceeds the given frame
10592 size. Because this is a compile time check it doesn't need to be
10593 a real problem when the program runs. It is intended to identify
10594 functions which most probably cause a stack overflow. It is
10595 useful to be used in an environment with limited stack size e.g.
10598 `-mwarn-dynamicstack'
10599 Emit a warning if the function calls alloca or uses dynamically
10600 sized arrays. This is generally a bad idea with a limited stack
10603 `-mstack-guard=STACK-GUARD'
10605 `-mstack-size=STACK-SIZE'
10606 These arguments always have to be used in conjunction. If they
10607 are present the s390 back end emits additional instructions in the
10608 function prologue which trigger a trap if the stack size is
10609 STACK-GUARD bytes above the STACK-SIZE (remember that the stack on
10610 s390 grows downward). These options are intended to be used to
10611 help debugging stack overflow problems. The additionally emitted
10612 code cause only little overhead and hence can also be used in
10613 production like systems without greater performance degradation.
10614 The given values have to be exact powers of 2 and STACK-SIZE has
10615 to be greater than STACK-GUARD. In order to be efficient the
10616 extra code makes the assumption that the stack starts at an
10617 address aligned to the value given by STACK-SIZE.
10620 File: gcc.info, Node: SH Options, Next: SPARC Options, Prev: S/390 and zSeries Options, Up: Submodel Options
10625 These `-m' options are defined for the SH implementations:
10628 Generate code for the SH1.
10631 Generate code for the SH2.
10634 Generate code for the SH2e.
10637 Generate code for the SH3.
10640 Generate code for the SH3e.
10643 Generate code for the SH4 without a floating-point unit.
10646 Generate code for the SH4 with a floating-point unit that only
10647 supports single-precision arithmetic.
10650 Generate code for the SH4 assuming the floating-point unit is in
10651 single-precision mode by default.
10654 Generate code for the SH4.
10657 Generate code for the SH4al-dsp, or for a SH4a in such a way that
10658 the floating-point unit is not used.
10661 Generate code for the SH4a, in such a way that no double-precision
10662 floating point operations are used.
10665 Generate code for the SH4a assuming the floating-point unit is in
10666 single-precision mode by default.
10669 Generate code for the SH4a.
10672 Same as `-m4a-nofpu', except that it implicitly passes `-dsp' to
10673 the assembler. GCC doesn't generate any DSP instructions at the
10677 Compile code for the processor in big endian mode.
10680 Compile code for the processor in little endian mode.
10683 Align doubles at 64-bit boundaries. Note that this changes the
10684 calling conventions, and thus some functions from the standard C
10685 library will not work unless you recompile it first with
10689 Shorten some address references at link time, when possible; uses
10690 the linker option `-relax'.
10693 Use 32-bit offsets in `switch' tables. The default is to use
10697 Enable the use of the instruction `fmovd'.
10700 Comply with the calling conventions defined by Renesas.
10703 Comply with the calling conventions defined by Renesas.
10706 Comply with the calling conventions defined for GCC before the
10707 Renesas conventions were available. This option is the default
10708 for all targets of the SH toolchain except for `sh-symbianelf'.
10711 Mark the `MAC' register as call-clobbered, even if `-mhitachi' is
10715 Increase IEEE-compliance of floating-point code.
10718 Dump instruction size and location in the assembly code.
10721 This option is deprecated. It pads structures to multiple of 4
10722 bytes, which is incompatible with the SH ABI.
10725 Optimize for space instead of speed. Implied by `-Os'.
10728 When generating position-independent code, emit function calls
10729 using the Global Offset Table instead of the Procedure Linkage
10733 Generate a library function call to invalidate instruction cache
10734 entries, after fixing up a trampoline. This library function call
10735 doesn't assume it can write to the whole memory address space.
10736 This is the default when the target is `sh-*-linux*'.
10739 File: gcc.info, Node: SPARC Options, Next: System V Options, Prev: SH Options, Up: Submodel Options
10741 3.17.26 SPARC Options
10742 ---------------------
10744 These `-m' options are supported on the SPARC:
10748 Specify `-mapp-regs' to generate output using the global registers
10749 2 through 4, which the SPARC SVR4 ABI reserves for applications.
10750 This is the default.
10752 To be fully SVR4 ABI compliant at the cost of some performance
10753 loss, specify `-mno-app-regs'. You should compile libraries and
10754 system software with this option.
10758 Generate output containing floating point instructions. This is
10763 Generate output containing library calls for floating point.
10764 *Warning:* the requisite libraries are not available for all SPARC
10765 targets. Normally the facilities of the machine's usual C
10766 compiler are used, but this cannot be done directly in
10767 cross-compilation. You must make your own arrangements to provide
10768 suitable library functions for cross-compilation. The embedded
10769 targets `sparc-*-aout' and `sparclite-*-*' do provide software
10770 floating point support.
10772 `-msoft-float' changes the calling convention in the output file;
10773 therefore, it is only useful if you compile _all_ of a program with
10774 this option. In particular, you need to compile `libgcc.a', the
10775 library that comes with GCC, with `-msoft-float' in order for this
10778 `-mhard-quad-float'
10779 Generate output containing quad-word (long double) floating point
10782 `-msoft-quad-float'
10783 Generate output containing library calls for quad-word (long
10784 double) floating point instructions. The functions called are
10785 those specified in the SPARC ABI. This is the default.
10787 As of this writing, there are no SPARC implementations that have
10788 hardware support for the quad-word floating point instructions.
10789 They all invoke a trap handler for one of these instructions, and
10790 then the trap handler emulates the effect of the instruction.
10791 Because of the trap handler overhead, this is much slower than
10792 calling the ABI library routines. Thus the `-msoft-quad-float'
10793 option is the default.
10795 `-mno-unaligned-doubles'
10796 `-munaligned-doubles'
10797 Assume that doubles have 8 byte alignment. This is the default.
10799 With `-munaligned-doubles', GCC assumes that doubles have 8 byte
10800 alignment only if they are contained in another type, or if they
10801 have an absolute address. Otherwise, it assumes they have 4 byte
10802 alignment. Specifying this option avoids some rare compatibility
10803 problems with code generated by other compilers. It is not the
10804 default because it results in a performance loss, especially for
10805 floating point code.
10807 `-mno-faster-structs'
10809 With `-mfaster-structs', the compiler assumes that structures
10810 should have 8 byte alignment. This enables the use of pairs of
10811 `ldd' and `std' instructions for copies in structure assignment,
10812 in place of twice as many `ld' and `st' pairs. However, the use
10813 of this changed alignment directly violates the SPARC ABI. Thus,
10814 it's intended only for use on targets where the developer
10815 acknowledges that their resulting code will not be directly in
10816 line with the rules of the ABI.
10819 `-mimpure-text', used in addition to `-shared', tells the compiler
10820 to not pass `-z text' to the linker when linking a shared object.
10821 Using this option, you can link position-dependent code into a
10824 `-mimpure-text' suppresses the "relocations remain against
10825 allocatable but non-writable sections" linker error message.
10826 However, the necessary relocations will trigger copy-on-write, and
10827 the shared object is not actually shared across processes.
10828 Instead of using `-mimpure-text', you should compile all source
10829 code with `-fpic' or `-fPIC'.
10831 This option is only available on SunOS and Solaris.
10834 Set the instruction set, register set, and instruction scheduling
10835 parameters for machine type CPU_TYPE. Supported values for
10836 CPU_TYPE are `v7', `cypress', `v8', `supersparc', `sparclite',
10837 `f930', `f934', `hypersparc', `sparclite86x', `sparclet',
10838 `tsc701', `v9', `ultrasparc', and `ultrasparc3'.
10840 Default instruction scheduling parameters are used for values that
10841 select an architecture and not an implementation. These are `v7',
10842 `v8', `sparclite', `sparclet', `v9'.
10844 Here is a list of each supported architecture and their supported
10848 v8: supersparc, hypersparc
10849 sparclite: f930, f934, sparclite86x
10851 v9: ultrasparc, ultrasparc3
10853 By default (unless configured otherwise), GCC generates code for
10854 the V7 variant of the SPARC architecture. With `-mcpu=cypress',
10855 the compiler additionally optimizes it for the Cypress CY7C602
10856 chip, as used in the SPARCStation/SPARCServer 3xx series. This is
10857 also appropriate for the older SPARCStation 1, 2, IPX etc.
10859 With `-mcpu=v8', GCC generates code for the V8 variant of the SPARC
10860 architecture. The only difference from V7 code is that the
10861 compiler emits the integer multiply and integer divide
10862 instructions which exist in SPARC-V8 but not in SPARC-V7. With
10863 `-mcpu=supersparc', the compiler additionally optimizes it for the
10864 SuperSPARC chip, as used in the SPARCStation 10, 1000 and 2000
10867 With `-mcpu=sparclite', GCC generates code for the SPARClite
10868 variant of the SPARC architecture. This adds the integer
10869 multiply, integer divide step and scan (`ffs') instructions which
10870 exist in SPARClite but not in SPARC-V7. With `-mcpu=f930', the
10871 compiler additionally optimizes it for the Fujitsu MB86930 chip,
10872 which is the original SPARClite, with no FPU. With `-mcpu=f934',
10873 the compiler additionally optimizes it for the Fujitsu MB86934
10874 chip, which is the more recent SPARClite with FPU.
10876 With `-mcpu=sparclet', GCC generates code for the SPARClet variant
10877 of the SPARC architecture. This adds the integer multiply,
10878 multiply/accumulate, integer divide step and scan (`ffs')
10879 instructions which exist in SPARClet but not in SPARC-V7. With
10880 `-mcpu=tsc701', the compiler additionally optimizes it for the
10881 TEMIC SPARClet chip.
10883 With `-mcpu=v9', GCC generates code for the V9 variant of the SPARC
10884 architecture. This adds 64-bit integer and floating-point move
10885 instructions, 3 additional floating-point condition code registers
10886 and conditional move instructions. With `-mcpu=ultrasparc', the
10887 compiler additionally optimizes it for the Sun UltraSPARC I/II
10888 chips. With `-mcpu=ultrasparc3', the compiler additionally
10889 optimizes it for the Sun UltraSPARC III chip.
10892 Set the instruction scheduling parameters for machine type
10893 CPU_TYPE, but do not set the instruction set or register set that
10894 the option `-mcpu=CPU_TYPE' would.
10896 The same values for `-mcpu=CPU_TYPE' can be used for
10897 `-mtune=CPU_TYPE', but the only useful values are those that
10898 select a particular cpu implementation. Those are `cypress',
10899 `supersparc', `hypersparc', `f930', `f934', `sparclite86x',
10900 `tsc701', `ultrasparc', and `ultrasparc3'.
10904 With `-mv8plus', GCC generates code for the SPARC-V8+ ABI. The
10905 difference from the V8 ABI is that the global and out registers are
10906 considered 64-bit wide. This is enabled by default on Solaris in
10907 32-bit mode for all SPARC-V9 processors.
10911 With `-mvis', GCC generates code that takes advantage of the
10912 UltraSPARC Visual Instruction Set extensions. The default is
10915 These `-m' options are supported in addition to the above on SPARC-V9
10916 processors in 64-bit environments:
10919 Generate code for a processor running in little-endian mode. It
10920 is only available for a few configurations and most notably not on
10925 Generate code for a 32-bit or 64-bit environment. The 32-bit
10926 environment sets int, long and pointer to 32 bits. The 64-bit
10927 environment sets int to 32 bits and long and pointer to 64 bits.
10930 Generate code for the Medium/Low code model: 64-bit addresses,
10931 programs must be linked in the low 32 bits of memory. Programs
10932 can be statically or dynamically linked.
10935 Generate code for the Medium/Middle code model: 64-bit addresses,
10936 programs must be linked in the low 44 bits of memory, the text and
10937 data segments must be less than 2GB in size and the data segment
10938 must be located within 2GB of the text segment.
10941 Generate code for the Medium/Anywhere code model: 64-bit
10942 addresses, programs may be linked anywhere in memory, the text and
10943 data segments must be less than 2GB in size and the data segment
10944 must be located within 2GB of the text segment.
10946 `-mcmodel=embmedany'
10947 Generate code for the Medium/Anywhere code model for embedded
10948 systems: 64-bit addresses, the text and data segments must be less
10949 than 2GB in size, both starting anywhere in memory (determined at
10950 link time). The global register %g4 points to the base of the
10951 data segment. Programs are statically linked and PIC is not
10956 With `-mstack-bias', GCC assumes that the stack pointer, and frame
10957 pointer if present, are offset by -2047 which must be added back
10958 when making stack frame references. This is the default in 64-bit
10959 mode. Otherwise, assume no such offset is present.
10961 These switches are supported in addition to the above on Solaris:
10964 Add support for multithreading using the Solaris threads library.
10965 This option sets flags for both the preprocessor and linker. This
10966 option does not affect the thread safety of object code produced
10967 by the compiler or that of libraries supplied with it.
10970 Add support for multithreading using the POSIX threads library.
10971 This option sets flags for both the preprocessor and linker. This
10972 option does not affect the thread safety of object code produced
10973 by the compiler or that of libraries supplied with it.
10976 File: gcc.info, Node: System V Options, Next: TMS320C3x/C4x Options, Prev: SPARC Options, Up: Submodel Options
10978 3.17.27 Options for System V
10979 ----------------------------
10981 These additional options are available on System V Release 4 for
10982 compatibility with other compilers on those systems:
10985 Create a shared object. It is recommended that `-symbolic' or
10986 `-shared' be used instead.
10989 Identify the versions of each tool used by the compiler, in a
10990 `.ident' assembler directive in the output.
10993 Refrain from adding `.ident' directives to the output file (this is
10997 Search the directories DIRS, and no others, for libraries
10998 specified with `-l'.
11001 Look in the directory DIR to find the M4 preprocessor. The
11002 assembler uses this option.
11005 File: gcc.info, Node: TMS320C3x/C4x Options, Next: V850 Options, Prev: System V Options, Up: Submodel Options
11007 3.17.28 TMS320C3x/C4x Options
11008 -----------------------------
11010 These `-m' options are defined for TMS320C3x/C4x implementations:
11013 Set the instruction set, register set, and instruction scheduling
11014 parameters for machine type CPU_TYPE. Supported values for
11015 CPU_TYPE are `c30', `c31', `c32', `c40', and `c44'. The default
11016 is `c40' to generate code for the TMS320C40.
11022 Generates code for the big or small memory model. The small memory
11023 model assumed that all data fits into one 64K word page. At
11024 run-time the data page (DP) register must be set to point to the
11025 64K page containing the .bss and .data program sections. The big
11026 memory model is the default and requires reloading of the DP
11027 register for every direct memory access.
11031 Allow (disallow) allocation of general integer operands into the
11032 block count register BK.
11036 Enable (disable) generation of code using decrement and branch,
11037 DBcond(D), instructions. This is enabled by default for the C4x.
11038 To be on the safe side, this is disabled for the C3x, since the
11039 maximum iteration count on the C3x is 2^23 + 1 (but who iterates
11040 loops more than 2^23 times on the C3x?). Note that GCC will try
11041 to reverse a loop so that it can utilize the decrement and branch
11042 instruction, but will give up if there is more than one memory
11043 reference in the loop. Thus a loop where the loop counter is
11044 decremented can generate slightly more efficient code, in cases
11045 where the RPTB instruction cannot be utilized.
11049 Force the DP register to be saved on entry to an interrupt service
11050 routine (ISR), reloaded to point to the data section, and restored
11051 on exit from the ISR. This should not be required unless someone
11052 has violated the small memory model by modifying the DP register,
11053 say within an object library.
11057 For the C3x use the 24-bit MPYI instruction for integer multiplies
11058 instead of a library call to guarantee 32-bit results. Note that
11059 if one of the operands is a constant, then the multiplication will
11060 be performed using shifts and adds. If the `-mmpyi' option is not
11061 specified for the C3x, then squaring operations are performed
11062 inline instead of a library call.
11066 The C3x/C4x FIX instruction to convert a floating point value to an
11067 integer value chooses the nearest integer less than or equal to the
11068 floating point value rather than to the nearest integer. Thus if
11069 the floating point number is negative, the result will be
11070 incorrectly truncated an additional code is necessary to detect
11071 and correct this case. This option can be used to disable
11072 generation of the additional code required to correct the result.
11076 Enable (disable) generation of repeat block sequences using the
11077 RPTB instruction for zero overhead looping. The RPTB construct is
11078 only used for innermost loops that do not call functions or jump
11079 across the loop boundaries. There is no advantage having nested
11080 RPTB loops due to the overhead required to save and restore the
11081 RC, RS, and RE registers. This is enabled by default with `-O2'.
11085 Enable (disable) the use of the single instruction repeat
11086 instruction RPTS. If a repeat block contains a single
11087 instruction, and the loop count can be guaranteed to be less than
11088 the value COUNT, GCC will emit a RPTS instruction instead of a
11089 RPTB. If no value is specified, then a RPTS will be emitted even
11090 if the loop count cannot be determined at compile time. Note that
11091 the repeated instruction following RPTS does not have to be
11092 reloaded from memory each iteration, thus freeing up the CPU buses
11093 for operands. However, since interrupts are blocked by this
11094 instruction, it is disabled by default.
11097 `-mno-loop-unsigned'
11098 The maximum iteration count when using RPTS and RPTB (and DB on
11099 the C40) is 2^31 + 1 since these instructions test if the
11100 iteration count is negative to terminate the loop. If the
11101 iteration count is unsigned there is a possibility than the 2^31 +
11102 1 maximum iteration count may be exceeded. This switch allows an
11103 unsigned iteration count.
11106 Try to emit an assembler syntax that the TI assembler (asm30) is
11107 happy with. This also enforces compatibility with the API
11108 employed by the TI C3x C compiler. For example, long doubles are
11109 passed as structures rather than in floating point registers.
11113 Generate code that uses registers (stack) for passing arguments to
11114 functions. By default, arguments are passed in registers where
11115 possible rather than by pushing arguments on to the stack.
11118 `-mno-parallel-insns'
11119 Allow the generation of parallel instructions. This is enabled by
11120 default with `-O2'.
11123 `-mno-parallel-mpy'
11124 Allow the generation of MPY||ADD and MPY||SUB parallel
11125 instructions, provided `-mparallel-insns' is also specified.
11126 These instructions have tight register constraints which can
11127 pessimize the code generation of large functions.
11131 File: gcc.info, Node: V850 Options, Next: VAX Options, Prev: TMS320C3x/C4x Options, Up: Submodel Options
11133 3.17.29 V850 Options
11134 --------------------
11136 These `-m' options are defined for V850 implementations:
11140 Treat all calls as being far away (near). If calls are assumed to
11141 be far away, the compiler will always load the functions address
11142 up into a register, and call indirect through the pointer.
11146 Do not optimize (do optimize) basic blocks that use the same index
11147 pointer 4 or more times to copy pointer into the `ep' register, and
11148 use the shorter `sld' and `sst' instructions. The `-mep' option
11149 is on by default if you optimize.
11151 `-mno-prolog-function'
11152 `-mprolog-function'
11153 Do not use (do use) external functions to save and restore
11154 registers at the prologue and epilogue of a function. The
11155 external functions are slower, but use less code space if more
11156 than one function saves the same number of registers. The
11157 `-mprolog-function' option is on by default if you optimize.
11160 Try to make the code as small as possible. At present, this just
11161 turns on the `-mep' and `-mprolog-function' options.
11164 Put static or global variables whose size is N bytes or less into
11165 the tiny data area that register `ep' points to. The tiny data
11166 area can hold up to 256 bytes in total (128 bytes for byte
11170 Put static or global variables whose size is N bytes or less into
11171 the small data area that register `gp' points to. The small data
11172 area can hold up to 64 kilobytes.
11175 Put static or global variables whose size is N bytes or less into
11176 the first 32 kilobytes of memory.
11179 Specify that the target processor is the V850.
11182 Generate code suitable for big switch tables. Use this option
11183 only if the assembler/linker complain about out of range branches
11184 within a switch table.
11187 This option will cause r2 and r5 to be used in the code generated
11188 by the compiler. This setting is the default.
11191 This option will cause r2 and r5 to be treated as fixed registers.
11194 Specify that the target processor is the V850E1. The preprocessor
11195 constants `__v850e1__' and `__v850e__' will be defined if this
11199 Specify that the target processor is the V850E. The preprocessor
11200 constant `__v850e__' will be defined if this option is used.
11202 If neither `-mv850' nor `-mv850e' nor `-mv850e1' are defined then
11203 a default target processor will be chosen and the relevant
11204 `__v850*__' preprocessor constant will be defined.
11206 The preprocessor constants `__v850' and `__v851__' are always
11207 defined, regardless of which processor variant is the target.
11210 This option will suppress generation of the CALLT instruction for
11211 the v850e and v850e1 flavors of the v850 architecture. The
11212 default is `-mno-disable-callt' which allows the CALLT instruction
11217 File: gcc.info, Node: VAX Options, Next: x86-64 Options, Prev: V850 Options, Up: Submodel Options
11219 3.17.30 VAX Options
11220 -------------------
11222 These `-m' options are defined for the VAX:
11225 Do not output certain jump instructions (`aobleq' and so on) that
11226 the Unix assembler for the VAX cannot handle across long ranges.
11229 Do output those jump instructions, on the assumption that you will
11230 assemble with the GNU assembler.
11233 Output code for g-format floating point numbers instead of
11237 File: gcc.info, Node: x86-64 Options, Next: Xstormy16 Options, Prev: VAX Options, Up: Submodel Options
11239 3.17.31 x86-64 Options
11240 ----------------------
11242 These are listed under *Note i386 and x86-64 Options::.
11245 File: gcc.info, Node: Xstormy16 Options, Next: Xtensa Options, Prev: x86-64 Options, Up: Submodel Options
11247 3.17.32 Xstormy16 Options
11248 -------------------------
11250 These options are defined for Xstormy16:
11253 Choose startup files and linker script suitable for the simulator.
11256 File: gcc.info, Node: Xtensa Options, Next: zSeries Options, Prev: Xstormy16 Options, Up: Submodel Options
11258 3.17.33 Xtensa Options
11259 ----------------------
11261 These options are supported for Xtensa targets:
11265 Enable or disable use of `CONST16' instructions for loading
11266 constant values. The `CONST16' instruction is currently not a
11267 standard option from Tensilica. When enabled, `CONST16'
11268 instructions are always used in place of the standard `L32R'
11269 instructions. The use of `CONST16' is enabled by default only if
11270 the `L32R' instruction is not available.
11274 Enable or disable use of fused multiply/add and multiply/subtract
11275 instructions in the floating-point option. This has no effect if
11276 the floating-point option is not also enabled. Disabling fused
11277 multiply/add and multiply/subtract instructions forces the
11278 compiler to use separate instructions for the multiply and
11279 add/subtract operations. This may be desirable in some cases
11280 where strict IEEE 754-compliant results are required: the fused
11281 multiply add/subtract instructions do not round the intermediate
11282 result, thereby producing results with _more_ bits of precision
11283 than specified by the IEEE standard. Disabling fused multiply
11284 add/subtract instructions also ensures that the program output is
11285 not sensitive to the compiler's ability to combine multiply and
11286 add/subtract operations.
11288 `-mtext-section-literals'
11289 `-mno-text-section-literals'
11290 Control the treatment of literal pools. The default is
11291 `-mno-text-section-literals', which places literals in a separate
11292 section in the output file. This allows the literal pool to be
11293 placed in a data RAM/ROM, and it also allows the linker to combine
11294 literal pools from separate object files to remove redundant
11295 literals and improve code size. With `-mtext-section-literals',
11296 the literals are interspersed in the text section in order to keep
11297 them as close as possible to their references. This may be
11298 necessary for large assembly files.
11301 `-mno-target-align'
11302 When this option is enabled, GCC instructs the assembler to
11303 automatically align instructions to reduce branch penalties at the
11304 expense of some code density. The assembler attempts to widen
11305 density instructions to align branch targets and the instructions
11306 following call instructions. If there are not enough preceding
11307 safe density instructions to align a target, no widening will be
11308 performed. The default is `-mtarget-align'. These options do not
11309 affect the treatment of auto-aligned instructions like `LOOP',
11310 which the assembler will always align, either by widening density
11311 instructions or by inserting no-op instructions.
11315 When this option is enabled, GCC instructs the assembler to
11316 translate direct calls to indirect calls unless it can determine
11317 that the target of a direct call is in the range allowed by the
11318 call instruction. This translation typically occurs for calls to
11319 functions in other source files. Specifically, the assembler
11320 translates a direct `CALL' instruction into an `L32R' followed by
11321 a `CALLX' instruction. The default is `-mno-longcalls'. This
11322 option should be used in programs where the call target can
11323 potentially be out of range. This option is implemented in the
11324 assembler, not the compiler, so the assembly code generated by GCC
11325 will still show direct call instructions--look at the disassembled
11326 object code to see the actual instructions. Note that the
11327 assembler will use an indirect call for every cross-file call, not
11328 just those that really will be out of range.
11331 File: gcc.info, Node: zSeries Options, Prev: Xtensa Options, Up: Submodel Options
11333 3.17.34 zSeries Options
11334 -----------------------
11336 These are listed under *Note S/390 and zSeries Options::.
11339 File: gcc.info, Node: Code Gen Options, Next: Environment Variables, Prev: Submodel Options, Up: Invoking GCC
11341 3.18 Options for Code Generation Conventions
11342 ============================================
11344 These machine-independent options control the interface conventions
11345 used in code generation.
11347 Most of them have both positive and negative forms; the negative form
11348 of `-ffoo' would be `-fno-foo'. In the table below, only one of the
11349 forms is listed--the one which is not the default. You can figure out
11350 the other form by either removing `no-' or adding it.
11353 For front-ends that support it, generate additional code to check
11354 that indices used to access arrays are within the declared range.
11355 This is currently only supported by the Java and Fortran 77
11356 front-ends, where this option defaults to true and false
11360 This option generates traps for signed overflow on addition,
11361 subtraction, multiplication operations.
11364 This option instructs the compiler to assume that signed arithmetic
11365 overflow of addition, subtraction and multiplication wraps around
11366 using twos-complement representation. This flag enables some
11367 optimizations and disables other. This option is enabled by
11368 default for the Java front-end, as required by the Java language
11372 Enable exception handling. Generates extra code needed to
11373 propagate exceptions. For some targets, this implies GCC will
11374 generate frame unwind information for all functions, which can
11375 produce significant data size overhead, although it does not
11376 affect execution. If you do not specify this option, GCC will
11377 enable it by default for languages like C++ which normally require
11378 exception handling, and disable it for languages like C that do
11379 not normally require it. However, you may need to enable this
11380 option when compiling C code that needs to interoperate properly
11381 with exception handlers written in C++. You may also wish to
11382 disable this option if you are compiling older C++ programs that
11383 don't use exception handling.
11385 `-fnon-call-exceptions'
11386 Generate code that allows trapping instructions to throw
11387 exceptions. Note that this requires platform-specific runtime
11388 support that does not exist everywhere. Moreover, it only allows
11389 _trapping_ instructions to throw exceptions, i.e. memory
11390 references or floating point instructions. It does not allow
11391 exceptions to be thrown from arbitrary signal handlers such as
11395 Similar to `-fexceptions', except that it will just generate any
11396 needed static data, but will not affect the generated code in any
11397 other way. You will normally not enable this option; instead, a
11398 language processor that needs this handling would enable it on
11401 `-fasynchronous-unwind-tables'
11402 Generate unwind table in dwarf2 format, if supported by target
11403 machine. The table is exact at each instruction boundary, so it
11404 can be used for stack unwinding from asynchronous events (such as
11405 debugger or garbage collector).
11407 `-fpcc-struct-return'
11408 Return "short" `struct' and `union' values in memory like longer
11409 ones, rather than in registers. This convention is less
11410 efficient, but it has the advantage of allowing intercallability
11411 between GCC-compiled files and files compiled with other
11412 compilers, particularly the Portable C Compiler (pcc).
11414 The precise convention for returning structures in memory depends
11415 on the target configuration macros.
11417 Short structures and unions are those whose size and alignment
11418 match that of some integer type.
11420 *Warning:* code compiled with the `-fpcc-struct-return' switch is
11421 not binary compatible with code compiled with the
11422 `-freg-struct-return' switch. Use it to conform to a non-default
11423 application binary interface.
11425 `-freg-struct-return'
11426 Return `struct' and `union' values in registers when possible.
11427 This is more efficient for small structures than
11428 `-fpcc-struct-return'.
11430 If you specify neither `-fpcc-struct-return' nor
11431 `-freg-struct-return', GCC defaults to whichever convention is
11432 standard for the target. If there is no standard convention, GCC
11433 defaults to `-fpcc-struct-return', except on targets where GCC is
11434 the principal compiler. In those cases, we can choose the
11435 standard, and we chose the more efficient register return
11438 *Warning:* code compiled with the `-freg-struct-return' switch is
11439 not binary compatible with code compiled with the
11440 `-fpcc-struct-return' switch. Use it to conform to a non-default
11441 application binary interface.
11444 Allocate to an `enum' type only as many bytes as it needs for the
11445 declared range of possible values. Specifically, the `enum' type
11446 will be equivalent to the smallest integer type which has enough
11449 *Warning:* the `-fshort-enums' switch causes GCC to generate code
11450 that is not binary compatible with code generated without that
11451 switch. Use it to conform to a non-default application binary
11455 Use the same size for `double' as for `float'.
11457 *Warning:* the `-fshort-double' switch causes GCC to generate code
11458 that is not binary compatible with code generated without that
11459 switch. Use it to conform to a non-default application binary
11463 Override the underlying type for `wchar_t' to be `short unsigned
11464 int' instead of the default for the target. This option is useful
11465 for building programs to run under WINE.
11467 *Warning:* the `-fshort-wchar' switch causes GCC to generate code
11468 that is not binary compatible with code generated without that
11469 switch. Use it to conform to a non-default application binary
11473 Requests that the data and non-`const' variables of this
11474 compilation be shared data rather than private data. The
11475 distinction makes sense only on certain operating systems, where
11476 shared data is shared between processes running the same program,
11477 while private data exists in one copy per process.
11480 In C, allocate even uninitialized global variables in the data
11481 section of the object file, rather than generating them as common
11482 blocks. This has the effect that if the same variable is declared
11483 (without `extern') in two different compilations, you will get an
11484 error when you link them. The only reason this might be useful is
11485 if you wish to verify that the program will work on other systems
11486 which always work this way.
11489 Ignore the `#ident' directive.
11491 `-finhibit-size-directive'
11492 Don't output a `.size' assembler directive, or anything else that
11493 would cause trouble if the function is split in the middle, and the
11494 two halves are placed at locations far apart in memory. This
11495 option is used when compiling `crtstuff.c'; you should not need to
11496 use it for anything else.
11499 Put extra commentary information in the generated assembly code to
11500 make it more readable. This option is generally only of use to
11501 those who actually need to read the generated assembly code
11502 (perhaps while debugging the compiler itself).
11504 `-fno-verbose-asm', the default, causes the extra information to
11505 be omitted and is useful when comparing two assembler files.
11508 Generate position-independent code (PIC) suitable for use in a
11509 shared library, if supported for the target machine. Such code
11510 accesses all constant addresses through a global offset table
11511 (GOT). The dynamic loader resolves the GOT entries when the
11512 program starts (the dynamic loader is not part of GCC; it is part
11513 of the operating system). If the GOT size for the linked
11514 executable exceeds a machine-specific maximum size, you get an
11515 error message from the linker indicating that `-fpic' does not
11516 work; in that case, recompile with `-fPIC' instead. (These
11517 maximums are 8k on the SPARC and 32k on the m68k and RS/6000. The
11518 386 has no such limit.)
11520 Position-independent code requires special support, and therefore
11521 works only on certain machines. For the 386, GCC supports PIC for
11522 System V but not for the Sun 386i. Code generated for the IBM
11523 RS/6000 is always position-independent.
11526 If supported for the target machine, emit position-independent
11527 code, suitable for dynamic linking and avoiding any limit on the
11528 size of the global offset table. This option makes a difference
11529 on the m68k, PowerPC and SPARC.
11531 Position-independent code requires special support, and therefore
11532 works only on certain machines.
11536 These options are similar to `-fpic' and `-fPIC', but generated
11537 position independent code can be only linked into executables.
11538 Usually these options are used when `-pie' GCC option will be used
11542 Treat the register named REG as a fixed register; generated code
11543 should never refer to it (except perhaps as a stack pointer, frame
11544 pointer or in some other fixed role).
11546 REG must be the name of a register. The register names accepted
11547 are machine-specific and are defined in the `REGISTER_NAMES' macro
11548 in the machine description macro file.
11550 This flag does not have a negative form, because it specifies a
11554 Treat the register named REG as an allocable register that is
11555 clobbered by function calls. It may be allocated for temporaries
11556 or variables that do not live across a call. Functions compiled
11557 this way will not save and restore the register REG.
11559 It is an error to used this flag with the frame pointer or stack
11560 pointer. Use of this flag for other registers that have fixed
11561 pervasive roles in the machine's execution model will produce
11562 disastrous results.
11564 This flag does not have a negative form, because it specifies a
11568 Treat the register named REG as an allocable register saved by
11569 functions. It may be allocated even for temporaries or variables
11570 that live across a call. Functions compiled this way will save
11571 and restore the register REG if they use it.
11573 It is an error to used this flag with the frame pointer or stack
11574 pointer. Use of this flag for other registers that have fixed
11575 pervasive roles in the machine's execution model will produce
11576 disastrous results.
11578 A different sort of disaster will result from the use of this flag
11579 for a register in which function values may be returned.
11581 This flag does not have a negative form, because it specifies a
11584 `-fpack-struct[=N]'
11585 Without a value specified, pack all structure members together
11586 without holes. When a value is specified (which must be a small
11587 power of two), pack structure members according to this value,
11588 representing the maximum alignment (that is, objects with default
11589 alignment requirements larger than this will be output potentially
11590 unaligned at the next fitting location.
11592 *Warning:* the `-fpack-struct' switch causes GCC to generate code
11593 that is not binary compatible with code generated without that
11594 switch. Additionally, it makes the code suboptimal. Use it to
11595 conform to a non-default application binary interface.
11597 `-finstrument-functions'
11598 Generate instrumentation calls for entry and exit to functions.
11599 Just after function entry and just before function exit, the
11600 following profiling functions will be called with the address of
11601 the current function and its call site. (On some platforms,
11602 `__builtin_return_address' does not work beyond the current
11603 function, so the call site information may not be available to the
11604 profiling functions otherwise.)
11606 void __cyg_profile_func_enter (void *this_fn,
11608 void __cyg_profile_func_exit (void *this_fn,
11611 The first argument is the address of the start of the current
11612 function, which may be looked up exactly in the symbol table.
11614 This instrumentation is also done for functions expanded inline in
11615 other functions. The profiling calls will indicate where,
11616 conceptually, the inline function is entered and exited. This
11617 means that addressable versions of such functions must be
11618 available. If all your uses of a function are expanded inline,
11619 this may mean an additional expansion of code size. If you use
11620 `extern inline' in your C code, an addressable version of such
11621 functions must be provided. (This is normally the case anyways,
11622 but if you get lucky and the optimizer always expands the
11623 functions inline, you might have gotten away without providing
11626 A function may be given the attribute `no_instrument_function', in
11627 which case this instrumentation will not be done. This can be
11628 used, for example, for the profiling functions listed above,
11629 high-priority interrupt routines, and any functions from which the
11630 profiling functions cannot safely be called (perhaps signal
11631 handlers, if the profiling routines generate output or allocate
11635 Generate code to verify that you do not go beyond the boundary of
11636 the stack. You should specify this flag if you are running in an
11637 environment with multiple threads, but only rarely need to specify
11638 it in a single-threaded environment since stack overflow is
11639 automatically detected on nearly all systems if there is only one
11642 Note that this switch does not actually cause checking to be done;
11643 the operating system must do that. The switch causes generation
11644 of code to ensure that the operating system sees the stack being
11647 `-fstack-limit-register=REG'
11648 `-fstack-limit-symbol=SYM'
11650 Generate code to ensure that the stack does not grow beyond a
11651 certain value, either the value of a register or the address of a
11652 symbol. If the stack would grow beyond the value, a signal is
11653 raised. For most targets, the signal is raised before the stack
11654 overruns the boundary, so it is possible to catch the signal
11655 without taking special precautions.
11657 For instance, if the stack starts at absolute address `0x80000000'
11658 and grows downwards, you can use the flags
11659 `-fstack-limit-symbol=__stack_limit' and
11660 `-Wl,--defsym,__stack_limit=0x7ffe0000' to enforce a stack limit
11661 of 128KB. Note that this may only work with the GNU linker.
11664 `-fargument-noalias'
11665 `-fargument-noalias-global'
11666 Specify the possible relationships among parameters and between
11667 parameters and global data.
11669 `-fargument-alias' specifies that arguments (parameters) may alias
11670 each other and may alias global storage.
11671 `-fargument-noalias' specifies that arguments do not alias each
11672 other, but may alias global storage.
11673 `-fargument-noalias-global' specifies that arguments do not alias
11674 each other and do not alias global storage.
11676 Each language will automatically use whatever option is required by
11677 the language standard. You should not need to use these options
11680 `-fleading-underscore'
11681 This option and its counterpart, `-fno-leading-underscore',
11682 forcibly change the way C symbols are represented in the object
11683 file. One use is to help link with legacy assembly code.
11685 *Warning:* the `-fleading-underscore' switch causes GCC to
11686 generate code that is not binary compatible with code generated
11687 without that switch. Use it to conform to a non-default
11688 application binary interface. Not all targets provide complete
11689 support for this switch.
11691 `-ftls-model=MODEL'
11692 Alter the thread-local storage model to be used (*note
11693 Thread-Local::). The MODEL argument should be one of
11694 `global-dynamic', `local-dynamic', `initial-exec' or `local-exec'.
11696 The default without `-fpic' is `initial-exec'; with `-fpic' the
11697 default is `global-dynamic'.
11699 `-fvisibility=DEFAULT|INTERNAL|HIDDEN|PROTECTED'
11700 Set the default ELF image symbol visibility to the specified
11701 option--all symbols will be marked with this unless overridden
11702 within the code. Using this feature can very substantially
11703 improve linking and load times of shared object libraries, produce
11704 more optimized code, provide near-perfect API export and prevent
11705 symbol clashes. It is *strongly* recommended that you use this in
11706 any shared objects you distribute.
11708 Despite the nomenclature, `default' always means public ie;
11709 available to be linked against from outside the shared object.
11710 `protected' and `internal' are pretty useless in real-world usage
11711 so the only other commonly used option will be `hidden'. The
11712 default if `-fvisibility' isn't specified is `default', i.e., make
11713 every symbol public--this causes the same behavior as previous
11716 A good explanation of the benefits offered by ensuring ELF symbols
11717 have the correct visibility is given by "How To Write Shared
11718 Libraries" by Ulrich Drepper (which can be found at
11719 `http://people.redhat.com/~drepper/')--however a superior solution
11720 made possible by this option to marking things hidden when the
11721 default is public is to make the default hidden and mark things
11722 public. This is the norm with DLL's on Windows and with
11723 `-fvisibility=hidden' and `__attribute__
11724 ((visibility("default")))' instead of `__declspec(dllexport)' you
11725 get almost identical semantics with identical syntax. This is a
11726 great boon to those working with cross-platform projects.
11728 For those adding visibility support to existing code, you may find
11729 `#pragma GCC visibility' of use. This works by you enclosing the
11730 declarations you wish to set visibility for with (for example)
11731 `#pragma GCC visibility push(hidden)' and `#pragma GCC visibility
11732 pop'. These can be nested up to sixteen times. Bear in mind that
11733 symbol visibility should be viewed *as part of the API interface
11734 contract* and thus all new code should always specify visibility
11735 when it is not the default ie; declarations only for use within
11736 the local DSO should *always* be marked explicitly as hidden as so
11737 to avoid PLT indirection overheads--making this abundantly clear
11738 also aids readability and self-documentation of the code. Note
11739 that due to ISO C++ specification requirements, operator new and
11740 operator delete must always be of default visibility.
11742 An overview of these techniques, their benefits and how to use them
11743 is at `http://www.nedprod.com/programs/gccvisibility.html'.
11747 File: gcc.info, Node: Environment Variables, Next: Precompiled Headers, Prev: Code Gen Options, Up: Invoking GCC
11749 3.19 Environment Variables Affecting GCC
11750 ========================================
11752 This section describes several environment variables that affect how GCC
11753 operates. Some of them work by specifying directories or prefixes to
11754 use when searching for various kinds of files. Some are used to
11755 specify other aspects of the compilation environment.
11757 Note that you can also specify places to search using options such as
11758 `-B', `-I' and `-L' (*note Directory Options::). These take precedence
11759 over places specified using environment variables, which in turn take
11760 precedence over those specified by the configuration of GCC. *Note
11761 Controlling the Compilation Driver `gcc': (gccint)Driver.
11767 These environment variables control the way that GCC uses
11768 localization information that allow GCC to work with different
11769 national conventions. GCC inspects the locale categories
11770 `LC_CTYPE' and `LC_MESSAGES' if it has been configured to do so.
11771 These locale categories can be set to any value supported by your
11772 installation. A typical value is `en_GB.UTF-8' for English in the
11773 United Kingdom encoded in UTF-8.
11775 The `LC_CTYPE' environment variable specifies character
11776 classification. GCC uses it to determine the character boundaries
11777 in a string; this is needed for some multibyte encodings that
11778 contain quote and escape characters that would otherwise be
11779 interpreted as a string end or escape.
11781 The `LC_MESSAGES' environment variable specifies the language to
11782 use in diagnostic messages.
11784 If the `LC_ALL' environment variable is set, it overrides the value
11785 of `LC_CTYPE' and `LC_MESSAGES'; otherwise, `LC_CTYPE' and
11786 `LC_MESSAGES' default to the value of the `LANG' environment
11787 variable. If none of these variables are set, GCC defaults to
11788 traditional C English behavior.
11791 If `TMPDIR' is set, it specifies the directory to use for temporary
11792 files. GCC uses temporary files to hold the output of one stage of
11793 compilation which is to be used as input to the next stage: for
11794 example, the output of the preprocessor, which is the input to the
11798 If `GCC_EXEC_PREFIX' is set, it specifies a prefix to use in the
11799 names of the subprograms executed by the compiler. No slash is
11800 added when this prefix is combined with the name of a subprogram,
11801 but you can specify a prefix that ends with a slash if you wish.
11803 If `GCC_EXEC_PREFIX' is not set, GCC will attempt to figure out an
11804 appropriate prefix to use based on the pathname it was invoked
11807 If GCC cannot find the subprogram using the specified prefix, it
11808 tries looking in the usual places for the subprogram.
11810 The default value of `GCC_EXEC_PREFIX' is `PREFIX/lib/gcc/' where
11811 PREFIX is the value of `prefix' when you ran the `configure'
11814 Other prefixes specified with `-B' take precedence over this
11817 This prefix is also used for finding files such as `crt0.o' that
11818 are used for linking.
11820 In addition, the prefix is used in an unusual way in finding the
11821 directories to search for header files. For each of the standard
11822 directories whose name normally begins with `/usr/local/lib/gcc'
11823 (more precisely, with the value of `GCC_INCLUDE_DIR'), GCC tries
11824 replacing that beginning with the specified prefix to produce an
11825 alternate directory name. Thus, with `-Bfoo/', GCC will search
11826 `foo/bar' where it would normally search `/usr/local/lib/bar'.
11827 These alternate directories are searched first; the standard
11828 directories come next.
11831 The value of `COMPILER_PATH' is a colon-separated list of
11832 directories, much like `PATH'. GCC tries the directories thus
11833 specified when searching for subprograms, if it can't find the
11834 subprograms using `GCC_EXEC_PREFIX'.
11837 The value of `LIBRARY_PATH' is a colon-separated list of
11838 directories, much like `PATH'. When configured as a native
11839 compiler, GCC tries the directories thus specified when searching
11840 for special linker files, if it can't find them using
11841 `GCC_EXEC_PREFIX'. Linking using GCC also uses these directories
11842 when searching for ordinary libraries for the `-l' option (but
11843 directories specified with `-L' come first).
11846 This variable is used to pass locale information to the compiler.
11847 One way in which this information is used is to determine the
11848 character set to be used when character literals, string literals
11849 and comments are parsed in C and C++. When the compiler is
11850 configured to allow multibyte characters, the following values for
11851 `LANG' are recognized:
11854 Recognize JIS characters.
11857 Recognize SJIS characters.
11860 Recognize EUCJP characters.
11862 If `LANG' is not defined, or if it has some other value, then the
11863 compiler will use mblen and mbtowc as defined by the default
11864 locale to recognize and translate multibyte characters.
11866 Some additional environments variables affect the behavior of the
11871 `CPLUS_INCLUDE_PATH'
11872 `OBJC_INCLUDE_PATH'
11873 Each variable's value is a list of directories separated by a
11874 special character, much like `PATH', in which to look for header
11875 files. The special character, `PATH_SEPARATOR', is
11876 target-dependent and determined at GCC build time. For Microsoft
11877 Windows-based targets it is a semicolon, and for almost all other
11878 targets it is a colon.
11880 `CPATH' specifies a list of directories to be searched as if
11881 specified with `-I', but after any paths given with `-I' options
11882 on the command line. This environment variable is used regardless
11883 of which language is being preprocessed.
11885 The remaining environment variables apply only when preprocessing
11886 the particular language indicated. Each specifies a list of
11887 directories to be searched as if specified with `-isystem', but
11888 after any paths given with `-isystem' options on the command line.
11890 In all these variables, an empty element instructs the compiler to
11891 search its current working directory. Empty elements can appear
11892 at the beginning or end of a path. For instance, if the value of
11893 `CPATH' is `:/special/include', that has the same effect as
11894 `-I. -I/special/include'.
11896 `DEPENDENCIES_OUTPUT'
11897 If this variable is set, its value specifies how to output
11898 dependencies for Make based on the non-system header files
11899 processed by the compiler. System header files are ignored in the
11902 The value of `DEPENDENCIES_OUTPUT' can be just a file name, in
11903 which case the Make rules are written to that file, guessing the
11904 target name from the source file name. Or the value can have the
11905 form `FILE TARGET', in which case the rules are written to file
11906 FILE using TARGET as the target name.
11908 In other words, this environment variable is equivalent to
11909 combining the options `-MM' and `-MF' (*note Preprocessor
11910 Options::), with an optional `-MT' switch too.
11912 `SUNPRO_DEPENDENCIES'
11913 This variable is the same as `DEPENDENCIES_OUTPUT' (see above),
11914 except that system header files are not ignored, so it implies
11915 `-M' rather than `-MM'. However, the dependence on the main input
11916 file is omitted. *Note Preprocessor Options::.
11919 File: gcc.info, Node: Precompiled Headers, Next: Running Protoize, Prev: Environment Variables, Up: Invoking GCC
11921 3.20 Using Precompiled Headers
11922 ==============================
11924 Often large projects have many header files that are included in every
11925 source file. The time the compiler takes to process these header files
11926 over and over again can account for nearly all of the time required to
11927 build the project. To make builds faster, GCC allows users to
11928 `precompile' a header file; then, if builds can use the precompiled
11929 header file they will be much faster.
11931 *Caution:* There are a few known situations where GCC will crash when
11932 trying to use a precompiled header. If you have trouble with a
11933 precompiled header, you should remove the precompiled header and
11934 compile without it. In addition, please use GCC's on-line
11935 defect-tracking system to report any problems you encounter with
11936 precompiled headers. *Note Bugs::.
11938 To create a precompiled header file, simply compile it as you would any
11939 other file, if necessary using the `-x' option to make the driver treat
11940 it as a C or C++ header file. You will probably want to use a tool
11941 like `make' to keep the precompiled header up-to-date when the headers
11942 it contains change.
11944 A precompiled header file will be searched for when `#include' is seen
11945 in the compilation. As it searches for the included file (*note Search
11946 Path: (cpp)Search Path.) the compiler looks for a precompiled header in
11947 each directory just before it looks for the include file in that
11948 directory. The name searched for is the name specified in the
11949 `#include' with `.gch' appended. If the precompiled header file can't
11950 be used, it is ignored.
11952 For instance, if you have `#include "all.h"', and you have `all.h.gch'
11953 in the same directory as `all.h', then the precompiled header file will
11954 be used if possible, and the original header will be used otherwise.
11956 Alternatively, you might decide to put the precompiled header file in a
11957 directory and use `-I' to ensure that directory is searched before (or
11958 instead of) the directory containing the original header. Then, if you
11959 want to check that the precompiled header file is always used, you can
11960 put a file of the same name as the original header in this directory
11961 containing an `#error' command.
11963 This also works with `-include'. So yet another way to use
11964 precompiled headers, good for projects not designed with precompiled
11965 header files in mind, is to simply take most of the header files used by
11966 a project, include them from another header file, precompile that header
11967 file, and `-include' the precompiled header. If the header files have
11968 guards against multiple inclusion, they will be skipped because they've
11969 already been included (in the precompiled header).
11971 If you need to precompile the same header file for different
11972 languages, targets, or compiler options, you can instead make a
11973 _directory_ named like `all.h.gch', and put each precompiled header in
11974 the directory, perhaps using `-o'. It doesn't matter what you call the
11975 files in the directory, every precompiled header in the directory will
11976 be considered. The first precompiled header encountered in the
11977 directory that is valid for this compilation will be used; they're
11978 searched in no particular order.
11980 There are many other possibilities, limited only by your imagination,
11981 good sense, and the constraints of your build system.
11983 A precompiled header file can be used only when these conditions apply:
11985 * Only one precompiled header can be used in a particular
11988 * A precompiled header can't be used once the first C token is seen.
11989 You can have preprocessor directives before a precompiled header;
11990 you can even include a precompiled header from inside another
11991 header, so long as there are no C tokens before the `#include'.
11993 * The precompiled header file must be produced for the same language
11994 as the current compilation. You can't use a C precompiled header
11995 for a C++ compilation.
11997 * The precompiled header file must be produced by the same compiler
11998 version and configuration as the current compilation is using.
11999 The easiest way to guarantee this is to use the same compiler
12000 binary for creating and using precompiled headers.
12002 * Any macros defined before the precompiled header is included must
12003 either be defined in the same way as when the precompiled header
12004 was generated, or must not affect the precompiled header, which
12005 usually means that they don't appear in the precompiled header at
12008 The `-D' option is one way to define a macro before a precompiled
12009 header is included; using a `#define' can also do it. There are
12010 also some options that define macros implicitly, like `-O' and
12011 `-Wdeprecated'; the same rule applies to macros defined this way.
12013 * If debugging information is output when using the precompiled
12014 header, using `-g' or similar, the same kind of debugging
12015 information must have been output when building the precompiled
12016 header. However, a precompiled header built using `-g' can be
12017 used in a compilation when no debugging information is being
12020 * The same `-m' options must generally be used when building and
12021 using the precompiled header. *Note Submodel Options::, for any
12022 cases where this rule is relaxed.
12024 * Each of the following options must be the same when building and
12025 using the precompiled header:
12027 -fexceptions -funit-at-a-time
12029 * Some other command-line options starting with `-f', `-p', or `-O'
12030 must be defined in the same way as when the precompiled header was
12031 generated. At present, it's not clear which options are safe to
12032 change and which are not; the safest choice is to use exactly the
12033 same options when generating and using the precompiled header.
12034 The following are known to be safe:
12036 -fpreprocessed -pedantic-errors
12039 For all of these except the last, the compiler will automatically
12040 ignore the precompiled header if the conditions aren't met. If you
12041 find an option combination that doesn't work and doesn't cause the
12042 precompiled header to be ignored, please consider filing a bug report,
12045 If you do use differing options when generating and using the
12046 precompiled header, the actual behavior will be a mixture of the
12047 behavior for the options. For instance, if you use `-g' to generate
12048 the precompiled header but not when using it, you may or may not get
12049 debugging information for routines in the precompiled header.
12052 File: gcc.info, Node: Running Protoize, Prev: Precompiled Headers, Up: Invoking GCC
12054 3.21 Running Protoize
12055 =====================
12057 The program `protoize' is an optional part of GCC. You can use it to
12058 add prototypes to a program, thus converting the program to ISO C in
12059 one respect. The companion program `unprotoize' does the reverse: it
12060 removes argument types from any prototypes that are found.
12062 When you run these programs, you must specify a set of source files as
12063 command line arguments. The conversion programs start out by compiling
12064 these files to see what functions they define. The information gathered
12065 about a file FOO is saved in a file named `FOO.X'.
12067 After scanning comes actual conversion. The specified files are all
12068 eligible to be converted; any files they include (whether sources or
12069 just headers) are eligible as well.
12071 But not all the eligible files are converted. By default, `protoize'
12072 and `unprotoize' convert only source and header files in the current
12073 directory. You can specify additional directories whose files should
12074 be converted with the `-d DIRECTORY' option. You can also specify
12075 particular files to exclude with the `-x FILE' option. A file is
12076 converted if it is eligible, its directory name matches one of the
12077 specified directory names, and its name within the directory has not
12080 Basic conversion with `protoize' consists of rewriting most function
12081 definitions and function declarations to specify the types of the
12082 arguments. The only ones not rewritten are those for varargs functions.
12084 `protoize' optionally inserts prototype declarations at the beginning
12085 of the source file, to make them available for any calls that precede
12086 the function's definition. Or it can insert prototype declarations
12087 with block scope in the blocks where undeclared functions are called.
12089 Basic conversion with `unprotoize' consists of rewriting most function
12090 declarations to remove any argument types, and rewriting function
12091 definitions to the old-style pre-ISO form.
12093 Both conversion programs print a warning for any function declaration
12094 or definition that they can't convert. You can suppress these warnings
12097 The output from `protoize' or `unprotoize' replaces the original
12098 source file. The original file is renamed to a name ending with
12099 `.save' (for DOS, the saved filename ends in `.sav' without the
12100 original `.c' suffix). If the `.save' (`.sav' for DOS) file already
12101 exists, then the source file is simply discarded.
12103 `protoize' and `unprotoize' both depend on GCC itself to scan the
12104 program and collect information about the functions it uses. So
12105 neither of these programs will work until GCC is installed.
12107 Here is a table of the options you can use with `protoize' and
12108 `unprotoize'. Each option works with both programs unless otherwise
12112 Look for the file `SYSCALLS.c.X' in DIRECTORY, instead of the
12113 usual directory (normally `/usr/local/lib'). This file contains
12114 prototype information about standard system functions. This option
12115 applies only to `protoize'.
12117 `-c COMPILATION-OPTIONS'
12118 Use COMPILATION-OPTIONS as the options when running `gcc' to
12119 produce the `.X' files. The special option `-aux-info' is always
12120 passed in addition, to tell `gcc' to write a `.X' file.
12122 Note that the compilation options must be given as a single
12123 argument to `protoize' or `unprotoize'. If you want to specify
12124 several `gcc' options, you must quote the entire set of
12125 compilation options to make them a single word in the shell.
12127 There are certain `gcc' arguments that you cannot use, because they
12128 would produce the wrong kind of output. These include `-g', `-O',
12129 `-c', `-S', and `-o' If you include these in the
12130 COMPILATION-OPTIONS, they are ignored.
12133 Rename files to end in `.C' (`.cc' for DOS-based file systems)
12134 instead of `.c'. This is convenient if you are converting a C
12135 program to C++. This option applies only to `protoize'.
12138 Add explicit global declarations. This means inserting explicit
12139 declarations at the beginning of each source file for each function
12140 that is called in the file and was not declared. These
12141 declarations precede the first function definition that contains a
12142 call to an undeclared function. This option applies only to
12146 Indent old-style parameter declarations with the string STRING.
12147 This option applies only to `protoize'.
12149 `unprotoize' converts prototyped function definitions to old-style
12150 function definitions, where the arguments are declared between the
12151 argument list and the initial `{'. By default, `unprotoize' uses
12152 five spaces as the indentation. If you want to indent with just
12153 one space instead, use `-i " "'.
12156 Keep the `.X' files. Normally, they are deleted after conversion
12160 Add explicit local declarations. `protoize' with `-l' inserts a
12161 prototype declaration for each function in each block which calls
12162 the function without any declaration. This option applies only to
12166 Make no real changes. This mode just prints information about the
12167 conversions that would have been done without `-n'.
12170 Make no `.save' files. The original files are simply deleted.
12171 Use this option with caution.
12174 Use the program PROGRAM as the compiler. Normally, the name `gcc'
12178 Work quietly. Most warnings are suppressed.
12181 Print the version number, just like `-v' for `gcc'.
12183 If you need special compiler options to compile one of your program's
12184 source files, then you should generate that file's `.X' file specially,
12185 by running `gcc' on that source file with the appropriate options and
12186 the option `-aux-info'. Then run `protoize' on the entire set of
12187 files. `protoize' will use the existing `.X' file because it is newer
12188 than the source file. For example:
12190 gcc -Dfoo=bar file1.c -aux-info file1.X
12193 You need to include the special files along with the rest in the
12194 `protoize' command, even though their `.X' files already exist, because
12195 otherwise they won't get converted.
12197 *Note Protoize Caveats::, for more information on how to use
12198 `protoize' successfully.
12201 File: gcc.info, Node: C Implementation, Next: C Extensions, Prev: Invoking GCC, Up: Top
12203 4 C Implementation-defined behavior
12204 ***********************************
12206 A conforming implementation of ISO C is required to document its choice
12207 of behavior in each of the areas that are designated "implementation
12208 defined". The following lists all such areas, along with the section
12209 numbers from the ISO/IEC 9899:1990 and ISO/IEC 9899:1999 standards.
12210 Some areas are only implementation-defined in one version of the
12213 Some choices depend on the externally determined ABI for the platform
12214 (including standard character encodings) which GCC follows; these are
12215 listed as "determined by ABI" below. *Note Binary Compatibility:
12216 Compatibility, and `http://gcc.gnu.org/readings.html'. Some choices
12217 are documented in the preprocessor manual. *Note
12218 Implementation-defined behavior: (cpp)Implementation-defined behavior.
12219 Some choices are made by the library and operating system (or other
12220 environment when compiling for a freestanding environment); refer to
12221 their documentation for details.
12225 * Translation implementation::
12226 * Environment implementation::
12227 * Identifiers implementation::
12228 * Characters implementation::
12229 * Integers implementation::
12230 * Floating point implementation::
12231 * Arrays and pointers implementation::
12232 * Hints implementation::
12233 * Structures unions enumerations and bit-fields implementation::
12234 * Qualifiers implementation::
12235 * Declarators implementation::
12236 * Statements implementation::
12237 * Preprocessing directives implementation::
12238 * Library functions implementation::
12239 * Architecture implementation::
12240 * Locale-specific behavior implementation::
12243 File: gcc.info, Node: Translation implementation, Next: Environment implementation, Up: C Implementation
12248 * `How a diagnostic is identified (C90 3.7, C99 3.10, C90 and C99
12251 Diagnostics consist of all the output sent to stderr by GCC.
12253 * `Whether each nonempty sequence of white-space characters other
12254 than new-line is retained or replaced by one space character in
12255 translation phase 3 (C90 and C99 5.1.1.2).'
12257 *Note Implementation-defined behavior: (cpp)Implementation-defined
12262 File: gcc.info, Node: Environment implementation, Next: Identifiers implementation, Prev: Translation implementation, Up: C Implementation
12267 The behavior of most of these points are dependent on the implementation
12268 of the C library, and are not defined by GCC itself.
12270 * `The mapping between physical source file multibyte characters and
12271 the source character set in translation phase 1 (C90 and C99
12274 *Note Implementation-defined behavior: (cpp)Implementation-defined
12279 File: gcc.info, Node: Identifiers implementation, Next: Characters implementation, Prev: Environment implementation, Up: C Implementation
12284 * `Which additional multibyte characters may appear in identifiers
12285 and their correspondence to universal character names (C99 6.4.2).'
12287 *Note Implementation-defined behavior: (cpp)Implementation-defined
12290 * `The number of significant initial characters in an identifier
12291 (C90 6.1.2, C90 and C99 5.2.4.1, C99 6.4.2).'
12293 For internal names, all characters are significant. For external
12294 names, the number of significant characters are defined by the
12295 linker; for almost all targets, all characters are significant.
12297 * `Whether case distinctions are significant in an identifier with
12298 external linkage (C90 6.1.2).'
12300 This is a property of the linker. C99 requires that case
12301 distinctions are always significant in identifiers with external
12302 linkage and systems without this property are not supported by GCC.
12306 File: gcc.info, Node: Characters implementation, Next: Integers implementation, Prev: Identifiers implementation, Up: C Implementation
12311 * `The number of bits in a byte (C90 3.4, C99 3.6).'
12315 * `The values of the members of the execution character set (C90 and
12320 * `The unique value of the member of the execution character set
12321 produced for each of the standard alphabetic escape sequences (C90
12326 * `The value of a `char' object into which has been stored any
12327 character other than a member of the basic execution character set
12328 (C90 6.1.2.5, C99 6.2.5).'
12332 * `Which of `signed char' or `unsigned char' has the same range,
12333 representation, and behavior as "plain" `char' (C90 6.1.2.5, C90
12334 6.2.1.1, C99 6.2.5, C99 6.3.1.1).'
12336 Determined by ABI. The options `-funsigned-char' and
12337 `-fsigned-char' change the default. *Note Options Controlling C
12338 Dialect: C Dialect Options.
12340 * `The mapping of members of the source character set (in character
12341 constants and string literals) to members of the execution
12342 character set (C90 6.1.3.4, C99 6.4.4.4, C90 and C99 5.1.1.2).'
12346 * `The value of an integer character constant containing more than
12347 one character or containing a character or escape sequence that
12348 does not map to a single-byte execution character (C90 6.1.3.4,
12351 *Note Implementation-defined behavior: (cpp)Implementation-defined
12354 * `The value of a wide character constant containing more than one
12355 multibyte character, or containing a multibyte character or escape
12356 sequence not represented in the extended execution character set
12357 (C90 6.1.3.4, C99 6.4.4.4).'
12359 *Note Implementation-defined behavior: (cpp)Implementation-defined
12362 * `The current locale used to convert a wide character constant
12363 consisting of a single multibyte character that maps to a member
12364 of the extended execution character set into a corresponding wide
12365 character code (C90 6.1.3.4, C99 6.4.4.4).'
12367 *Note Implementation-defined behavior: (cpp)Implementation-defined
12370 * `The current locale used to convert a wide string literal into
12371 corresponding wide character codes (C90 6.1.4, C99 6.4.5).'
12373 *Note Implementation-defined behavior: (cpp)Implementation-defined
12376 * `The value of a string literal containing a multibyte character or
12377 escape sequence not represented in the execution character set
12378 (C90 6.1.4, C99 6.4.5).'
12380 *Note Implementation-defined behavior: (cpp)Implementation-defined
12384 File: gcc.info, Node: Integers implementation, Next: Floating point implementation, Prev: Characters implementation, Up: C Implementation
12389 * `Any extended integer types that exist in the implementation (C99
12392 GCC does not support any extended integer types.
12394 * `Whether signed integer types are represented using sign and
12395 magnitude, two's complement, or one's complement, and whether the
12396 extraordinary value is a trap representation or an ordinary value
12399 GCC supports only two's complement integer types, and all bit
12400 patterns are ordinary values.
12402 * `The rank of any extended integer type relative to another extended
12403 integer type with the same precision (C99 6.3.1.1).'
12405 GCC does not support any extended integer types.
12407 * `The result of, or the signal raised by, converting an integer to a
12408 signed integer type when the value cannot be represented in an
12409 object of that type (C90 6.2.1.2, C99 6.3.1.3).'
12411 For conversion to a type of width N, the value is reduced modulo
12412 2^N to be within range of the type; no signal is raised.
12414 * `The results of some bitwise operations on signed integers (C90
12417 Bitwise operators act on the representation of the value including
12418 both the sign and value bits, where the sign bit is considered
12419 immediately above the highest-value value bit. Signed `>>' acts
12420 on negative numbers by sign extension.
12422 GCC does not use the latitude given in C99 only to treat certain
12423 aspects of signed `<<' as undefined, but this is subject to change.
12425 * `The sign of the remainder on integer division (C90 6.3.5).'
12427 GCC always follows the C99 requirement that the result of division
12428 is truncated towards zero.
12432 File: gcc.info, Node: Floating point implementation, Next: Arrays and pointers implementation, Prev: Integers implementation, Up: C Implementation
12437 * `The accuracy of the floating-point operations and of the library
12438 functions in `<math.h>' and `<complex.h>' that return
12439 floating-point results (C90 and C99 5.2.4.2.2).'
12441 The accuracy is unknown.
12443 * `The rounding behaviors characterized by non-standard values of
12444 `FLT_ROUNDS' (C90 and C99 5.2.4.2.2).'
12446 GCC does not use such values.
12448 * `The evaluation methods characterized by non-standard negative
12449 values of `FLT_EVAL_METHOD' (C99 5.2.4.2.2).'
12451 GCC does not use such values.
12453 * `The direction of rounding when an integer is converted to a
12454 floating-point number that cannot exactly represent the original
12455 value (C90 6.2.1.3, C99 6.3.1.4).'
12457 C99 Annex F is followed.
12459 * `The direction of rounding when a floating-point number is
12460 converted to a narrower floating-point number (C90 6.2.1.4, C99
12463 C99 Annex F is followed.
12465 * `How the nearest representable value or the larger or smaller
12466 representable value immediately adjacent to the nearest
12467 representable value is chosen for certain floating constants (C90
12468 6.1.3.1, C99 6.4.4.2).'
12470 C99 Annex F is followed.
12472 * `Whether and how floating expressions are contracted when not
12473 disallowed by the `FP_CONTRACT' pragma (C99 6.5).'
12475 Expressions are currently only contracted if
12476 `-funsafe-math-optimizations' or `-ffast-math' are used. This is
12479 * `The default state for the `FENV_ACCESS' pragma (C99 7.6.1).'
12481 This pragma is not implemented, but the default is to "off" unless
12482 `-frounding-math' is used in which case it is "on".
12484 * `Additional floating-point exceptions, rounding modes,
12485 environments, and classifications, and their macro names (C99 7.6,
12488 This is dependent on the implementation of the C library, and is
12489 not defined by GCC itself.
12491 * `The default state for the `FP_CONTRACT' pragma (C99 7.12.2).'
12493 This pragma is not implemented. Expressions are currently only
12494 contracted if `-funsafe-math-optimizations' or `-ffast-math' are
12495 used. This is subject to change.
12497 * `Whether the "inexact" floating-point exception can be raised when
12498 the rounded result actually does equal the mathematical result in
12499 an IEC 60559 conformant implementation (C99 F.9).'
12501 This is dependent on the implementation of the C library, and is
12502 not defined by GCC itself.
12504 * `Whether the "underflow" (and "inexact") floating-point exception
12505 can be raised when a result is tiny but not inexact in an IEC
12506 60559 conformant implementation (C99 F.9).'
12508 This is dependent on the implementation of the C library, and is
12509 not defined by GCC itself.
12513 File: gcc.info, Node: Arrays and pointers implementation, Next: Hints implementation, Prev: Floating point implementation, Up: C Implementation
12515 4.7 Arrays and pointers
12516 =======================
12518 * `The result of converting a pointer to an integer or vice versa
12519 (C90 6.3.4, C99 6.3.2.3).'
12521 A cast from pointer to integer discards most-significant bits if
12522 the pointer representation is larger than the integer type,
12523 sign-extends(1) if the pointer representation is smaller than the
12524 integer type, otherwise the bits are unchanged.
12526 A cast from integer to pointer discards most-significant bits if
12527 the pointer representation is smaller than the integer type,
12528 extends according to the signedness of the integer type if the
12529 pointer representation is larger than the integer type, otherwise
12530 the bits are unchanged.
12532 When casting from pointer to integer and back again, the resulting
12533 pointer must reference the same object as the original pointer,
12534 otherwise the behavior is undefined. That is, one may not use
12535 integer arithmetic to avoid the undefined behavior of pointer
12536 arithmetic as proscribed in C99 6.5.6/8.
12538 * `The size of the result of subtracting two pointers to elements of
12539 the same array (C90 6.3.6, C99 6.5.6).'
12541 The value is as specified in the standard and the type is
12542 determined by the ABI.
12545 ---------- Footnotes ----------
12547 (1) Future versions of GCC may zero-extend, or use a target-defined
12548 `ptr_extend' pattern. Do not rely on sign extension.
12551 File: gcc.info, Node: Hints implementation, Next: Structures unions enumerations and bit-fields implementation, Prev: Arrays and pointers implementation, Up: C Implementation
12556 * `The extent to which suggestions made by using the `register'
12557 storage-class specifier are effective (C90 6.5.1, C99 6.7.1).'
12559 The `register' specifier affects code generation only in these
12562 * When used as part of the register variable extension, see
12563 *Note Explicit Reg Vars::.
12565 * When `-O0' is in use, the compiler allocates distinct stack
12566 memory for all variables that do not have the `register'
12567 storage-class specifier; if `register' is specified, the
12568 variable may have a shorter lifespan than the code would
12569 indicate and may never be placed in memory.
12571 * On some rare x86 targets, `setjmp' doesn't save the registers
12572 in all circumstances. In those cases, GCC doesn't allocate
12573 any variables in registers unless they are marked `register'.
12576 * `The extent to which suggestions made by using the inline function
12577 specifier are effective (C99 6.7.4).'
12579 GCC will not inline any functions if the `-fno-inline' option is
12580 used or if `-O0' is used. Otherwise, GCC may still be unable to
12581 inline a function for many reasons; the `-Winline' option may be
12582 used to determine if a function has not been inlined and why not.
12586 File: gcc.info, Node: Structures unions enumerations and bit-fields implementation, Next: Qualifiers implementation, Prev: Hints implementation, Up: C Implementation
12588 4.9 Structures, unions, enumerations, and bit-fields
12589 ====================================================
12591 * `A member of a union object is accessed using a member of a
12592 different type (C90 6.3.2.3).'
12594 The relevant bytes of the representation of the object are treated
12595 as an object of the type used for the access. This may be a trap
12598 * `Whether a "plain" `int' bit-field is treated as a `signed int'
12599 bit-field or as an `unsigned int' bit-field (C90 6.5.2, C90
12600 6.5.2.1, C99 6.7.2, C99 6.7.2.1).'
12602 By default it is treated as `signed int' but this may be changed
12603 by the `-funsigned-bitfields' option.
12605 * `Allowable bit-field types other than `_Bool', `signed int', and
12606 `unsigned int' (C99 6.7.2.1).'
12608 No other types are permitted in strictly conforming mode.
12610 * `Whether a bit-field can straddle a storage-unit boundary (C90
12611 6.5.2.1, C99 6.7.2.1).'
12615 * `The order of allocation of bit-fields within a unit (C90 6.5.2.1,
12620 * `The alignment of non-bit-field members of structures (C90
12621 6.5.2.1, C99 6.7.2.1).'
12625 * `The integer type compatible with each enumerated type (C90
12626 6.5.2.2, C99 6.7.2.2).'
12628 Normally, the type is `unsigned int' if there are no negative
12629 values in the enumeration, otherwise `int'. If `-fshort-enums' is
12630 specified, then if there are negative values it is the first of
12631 `signed char', `short' and `int' that can represent all the
12632 values, otherwise it is the first of `unsigned char', `unsigned
12633 short' and `unsigned int' that can represent all the values.
12635 On some targets, `-fshort-enums' is the default; this is
12636 determined by the ABI.
12640 File: gcc.info, Node: Qualifiers implementation, Next: Declarators implementation, Prev: Structures unions enumerations and bit-fields implementation, Up: C Implementation
12645 * `What constitutes an access to an object that has
12646 volatile-qualified type (C90 6.5.3, C99 6.7.3).'
12648 *Note When is a Volatile Object Accessed?: Volatiles.
12652 File: gcc.info, Node: Declarators implementation, Next: Statements implementation, Prev: Qualifiers implementation, Up: C Implementation
12657 * `The maximum number of declarators that may modify an arithmetic,
12658 structure or union type (C90 6.5.4).'
12660 GCC is only limited by available memory.
12664 File: gcc.info, Node: Statements implementation, Next: Preprocessing directives implementation, Prev: Declarators implementation, Up: C Implementation
12669 * `The maximum number of `case' values in a `switch' statement (C90
12672 GCC is only limited by available memory.
12676 File: gcc.info, Node: Preprocessing directives implementation, Next: Library functions implementation, Prev: Statements implementation, Up: C Implementation
12678 4.13 Preprocessing directives
12679 =============================
12681 *Note Implementation-defined behavior: (cpp)Implementation-defined
12682 behavior, for details of these aspects of implementation-defined
12685 * `How sequences in both forms of header names are mapped to headers
12686 or external source file names (C90 6.1.7, C99 6.4.7).'
12688 * `Whether the value of a character constant in a constant expression
12689 that controls conditional inclusion matches the value of the same
12690 character constant in the execution character set (C90 6.8.1, C99
12693 * `Whether the value of a single-character character constant in a
12694 constant expression that controls conditional inclusion may have a
12695 negative value (C90 6.8.1, C99 6.10.1).'
12697 * `The places that are searched for an included `<>' delimited
12698 header, and how the places are specified or the header is
12699 identified (C90 6.8.2, C99 6.10.2).'
12701 * `How the named source file is searched for in an included `""'
12702 delimited header (C90 6.8.2, C99 6.10.2).'
12704 * `The method by which preprocessing tokens (possibly resulting from
12705 macro expansion) in a `#include' directive are combined into a
12706 header name (C90 6.8.2, C99 6.10.2).'
12708 * `The nesting limit for `#include' processing (C90 6.8.2, C99
12711 * `Whether the `#' operator inserts a `\' character before the `\'
12712 character that begins a universal character name in a character
12713 constant or string literal (C99 6.10.3.2).'
12715 * `The behavior on each recognized non-`STDC #pragma' directive (C90
12716 6.8.6, C99 6.10.6).'
12718 *Note Pragmas: (cpp)Pragmas, for details of pragmas accepted by
12719 GCC on all targets. *Note Pragmas Accepted by GCC: Pragmas, for
12720 details of target-specific pragmas.
12722 * `The definitions for `__DATE__' and `__TIME__' when respectively,
12723 the date and time of translation are not available (C90 6.8.8, C99
12728 File: gcc.info, Node: Library functions implementation, Next: Architecture implementation, Prev: Preprocessing directives implementation, Up: C Implementation
12730 4.14 Library functions
12731 ======================
12733 The behavior of most of these points are dependent on the implementation
12734 of the C library, and are not defined by GCC itself.
12736 * `The null pointer constant to which the macro `NULL' expands (C90
12739 In `<stddef.h>', `NULL' expands to `((void *)0)'. GCC does not
12740 provide the other headers which define `NULL' and some library
12741 implementations may use other definitions in those headers.
12745 File: gcc.info, Node: Architecture implementation, Next: Locale-specific behavior implementation, Prev: Library functions implementation, Up: C Implementation
12750 * `The values or expressions assigned to the macros specified in the
12751 headers `<float.h>', `<limits.h>', and `<stdint.h>' (C90 and C99
12752 5.2.4.2, C99 7.18.2, C99 7.18.3).'
12756 * `The number, order, and encoding of bytes in any object (when not
12757 explicitly specified in this International Standard) (C99
12762 * `The value of the result of the `sizeof' operator (C90 6.3.3.4,
12769 File: gcc.info, Node: Locale-specific behavior implementation, Prev: Architecture implementation, Up: C Implementation
12771 4.16 Locale-specific behavior
12772 =============================
12774 The behavior of these points are dependent on the implementation of the
12775 C library, and are not defined by GCC itself.
12778 File: gcc.info, Node: C Extensions, Next: C++ Extensions, Prev: C Implementation, Up: Top
12780 5 Extensions to the C Language Family
12781 *************************************
12783 GNU C provides several language features not found in ISO standard C.
12784 (The `-pedantic' option directs GCC to print a warning message if any
12785 of these features is used.) To test for the availability of these
12786 features in conditional compilation, check for a predefined macro
12787 `__GNUC__', which is always defined under GCC.
12789 These extensions are available in C and Objective-C. Most of them are
12790 also available in C++. *Note Extensions to the C++ Language: C++
12791 Extensions, for extensions that apply _only_ to C++.
12793 Some features that are in ISO C99 but not C89 or C++ are also, as
12794 extensions, accepted by GCC in C89 mode and in C++.
12798 * Statement Exprs:: Putting statements and declarations inside expressions.
12799 * Local Labels:: Labels local to a block.
12800 * Labels as Values:: Getting pointers to labels, and computed gotos.
12801 * Nested Functions:: As in Algol and Pascal, lexical scoping of functions.
12802 * Constructing Calls:: Dispatching a call to another function.
12803 * Typeof:: `typeof': referring to the type of an expression.
12804 * Conditionals:: Omitting the middle operand of a `?:' expression.
12805 * Long Long:: Double-word integers---`long long int'.
12806 * Complex:: Data types for complex numbers.
12807 * Hex Floats:: Hexadecimal floating-point constants.
12808 * Zero Length:: Zero-length arrays.
12809 * Variable Length:: Arrays whose length is computed at run time.
12810 * Empty Structures:: Structures with no members.
12811 * Variadic Macros:: Macros with a variable number of arguments.
12812 * Escaped Newlines:: Slightly looser rules for escaped newlines.
12813 * Subscripting:: Any array can be subscripted, even if not an lvalue.
12814 * Pointer Arith:: Arithmetic on `void'-pointers and function pointers.
12815 * Initializers:: Non-constant initializers.
12816 * Compound Literals:: Compound literals give structures, unions
12817 or arrays as values.
12818 * Designated Inits:: Labeling elements of initializers.
12819 * Cast to Union:: Casting to union type from any member of the union.
12820 * Case Ranges:: `case 1 ... 9' and such.
12821 * Mixed Declarations:: Mixing declarations and code.
12822 * Function Attributes:: Declaring that functions have no side effects,
12823 or that they can never return.
12824 * Attribute Syntax:: Formal syntax for attributes.
12825 * Function Prototypes:: Prototype declarations and old-style definitions.
12826 * C++ Comments:: C++ comments are recognized.
12827 * Dollar Signs:: Dollar sign is allowed in identifiers.
12828 * Character Escapes:: `\e' stands for the character <ESC>.
12829 * Variable Attributes:: Specifying attributes of variables.
12830 * Type Attributes:: Specifying attributes of types.
12831 * Alignment:: Inquiring about the alignment of a type or variable.
12832 * Inline:: Defining inline functions (as fast as macros).
12833 * Extended Asm:: Assembler instructions with C expressions as operands.
12834 (With them you can define ``built-in'' functions.)
12835 * Constraints:: Constraints for asm operands
12836 * Asm Labels:: Specifying the assembler name to use for a C symbol.
12837 * Explicit Reg Vars:: Defining variables residing in specified registers.
12838 * Alternate Keywords:: `__const__', `__asm__', etc., for header files.
12839 * Incomplete Enums:: `enum foo;', with details to follow.
12840 * Function Names:: Printable strings which are the name of the current
12842 * Return Address:: Getting the return or frame address of a function.
12843 * Vector Extensions:: Using vector instructions through built-in functions.
12844 * Offsetof:: Special syntax for implementing `offsetof'.
12845 * Other Builtins:: Other built-in functions.
12846 * Target Builtins:: Built-in functions specific to particular targets.
12847 * Target Format Checks:: Format checks specific to particular targets.
12848 * Pragmas:: Pragmas accepted by GCC.
12849 * Unnamed Fields:: Unnamed struct/union fields within structs/unions.
12850 * Thread-Local:: Per-thread variables.
12853 File: gcc.info, Node: Statement Exprs, Next: Local Labels, Up: C Extensions
12855 5.1 Statements and Declarations in Expressions
12856 ==============================================
12858 A compound statement enclosed in parentheses may appear as an expression
12859 in GNU C. This allows you to use loops, switches, and local variables
12860 within an expression.
12862 Recall that a compound statement is a sequence of statements surrounded
12863 by braces; in this construct, parentheses go around the braces. For
12866 ({ int y = foo (); int z;
12871 is a valid (though slightly more complex than necessary) expression for
12872 the absolute value of `foo ()'.
12874 The last thing in the compound statement should be an expression
12875 followed by a semicolon; the value of this subexpression serves as the
12876 value of the entire construct. (If you use some other kind of statement
12877 last within the braces, the construct has type `void', and thus
12878 effectively no value.)
12880 This feature is especially useful in making macro definitions "safe"
12881 (so that they evaluate each operand exactly once). For example, the
12882 "maximum" function is commonly defined as a macro in standard C as
12885 #define max(a,b) ((a) > (b) ? (a) : (b))
12887 But this definition computes either A or B twice, with bad results if
12888 the operand has side effects. In GNU C, if you know the type of the
12889 operands (here taken as `int'), you can define the macro safely as
12892 #define maxint(a,b) \
12893 ({int _a = (a), _b = (b); _a > _b ? _a : _b; })
12895 Embedded statements are not allowed in constant expressions, such as
12896 the value of an enumeration constant, the width of a bit-field, or the
12897 initial value of a static variable.
12899 If you don't know the type of the operand, you can still do this, but
12900 you must use `typeof' (*note Typeof::).
12902 In G++, the result value of a statement expression undergoes array and
12903 function pointer decay, and is returned by value to the enclosing
12904 expression. For instance, if `A' is a class, then
12910 will construct a temporary `A' object to hold the result of the
12911 statement expression, and that will be used to invoke `Foo'. Therefore
12912 the `this' pointer observed by `Foo' will not be the address of `a'.
12914 Any temporaries created within a statement within a statement
12915 expression will be destroyed at the statement's end. This makes
12916 statement expressions inside macros slightly different from function
12917 calls. In the latter case temporaries introduced during argument
12918 evaluation will be destroyed at the end of the statement that includes
12919 the function call. In the statement expression case they will be
12920 destroyed during the statement expression. For instance,
12922 #define macro(a) ({__typeof__(a) b = (a); b + 3; })
12923 template<typename T> T function(T a) { T b = a; return b + 3; }
12931 will have different places where temporaries are destroyed. For the
12932 `macro' case, the temporary `X' will be destroyed just after the
12933 initialization of `b'. In the `function' case that temporary will be
12934 destroyed when the function returns.
12936 These considerations mean that it is probably a bad idea to use
12937 statement-expressions of this form in header files that are designed to
12938 work with C++. (Note that some versions of the GNU C Library contained
12939 header files using statement-expression that lead to precisely this
12942 Jumping into a statement expression with `goto' or using a `switch'
12943 statement outside the statement expression with a `case' or `default'
12944 label inside the statement expression is not permitted. Jumping into a
12945 statement expression with a computed `goto' (*note Labels as Values::)
12946 yields undefined behavior. Jumping out of a statement expression is
12947 permitted, but if the statement expression is part of a larger
12948 expression then it is unspecified which other subexpressions of that
12949 expression have been evaluated except where the language definition
12950 requires certain subexpressions to be evaluated before or after the
12951 statement expression. In any case, as with a function call the
12952 evaluation of a statement expression is not interleaved with the
12953 evaluation of other parts of the containing expression. For example,
12955 foo (), (({ bar1 (); goto a; 0; }) + bar2 ()), baz();
12957 will call `foo' and `bar1' and will not call `baz' but may or may not
12958 call `bar2'. If `bar2' is called, it will be called after `foo' and
12962 File: gcc.info, Node: Local Labels, Next: Labels as Values, Prev: Statement Exprs, Up: C Extensions
12964 5.2 Locally Declared Labels
12965 ===========================
12967 GCC allows you to declare "local labels" in any nested block scope. A
12968 local label is just like an ordinary label, but you can only reference
12969 it (with a `goto' statement, or by taking its address) within the block
12970 in which it was declared.
12972 A local label declaration looks like this:
12978 __label__ LABEL1, LABEL2, /* ... */;
12980 Local label declarations must come at the beginning of the block,
12981 before any ordinary declarations or statements.
12983 The label declaration defines the label _name_, but does not define
12984 the label itself. You must do this in the usual way, with `LABEL:',
12985 within the statements of the statement expression.
12987 The local label feature is useful for complex macros. If a macro
12988 contains nested loops, a `goto' can be useful for breaking out of them.
12989 However, an ordinary label whose scope is the whole function cannot be
12990 used: if the macro can be expanded several times in one function, the
12991 label will be multiply defined in that function. A local label avoids
12992 this problem. For example:
12994 #define SEARCH(value, array, target) \
12997 typeof (target) _SEARCH_target = (target); \
12998 typeof (*(array)) *_SEARCH_array = (array); \
13001 for (i = 0; i < max; i++) \
13002 for (j = 0; j < max; j++) \
13003 if (_SEARCH_array[i][j] == _SEARCH_target) \
13004 { (value) = i; goto found; } \
13009 This could also be written using a statement-expression:
13011 #define SEARCH(array, target) \
13014 typeof (target) _SEARCH_target = (target); \
13015 typeof (*(array)) *_SEARCH_array = (array); \
13018 for (i = 0; i < max; i++) \
13019 for (j = 0; j < max; j++) \
13020 if (_SEARCH_array[i][j] == _SEARCH_target) \
13021 { value = i; goto found; } \
13027 Local label declarations also make the labels they declare visible to
13028 nested functions, if there are any. *Note Nested Functions::, for
13032 File: gcc.info, Node: Labels as Values, Next: Nested Functions, Prev: Local Labels, Up: C Extensions
13034 5.3 Labels as Values
13035 ====================
13037 You can get the address of a label defined in the current function (or
13038 a containing function) with the unary operator `&&'. The value has
13039 type `void *'. This value is a constant and can be used wherever a
13040 constant of that type is valid. For example:
13046 To use these values, you need to be able to jump to one. This is done
13047 with the computed goto statement(1), `goto *EXP;'. For example,
13051 Any expression of type `void *' is allowed.
13053 One way of using these constants is in initializing a static array that
13054 will serve as a jump table:
13056 static void *array[] = { &&foo, &&bar, &&hack };
13058 Then you can select a label with indexing, like this:
13062 Note that this does not check whether the subscript is in bounds--array
13063 indexing in C never does that.
13065 Such an array of label values serves a purpose much like that of the
13066 `switch' statement. The `switch' statement is cleaner, so use that
13067 rather than an array unless the problem does not fit a `switch'
13068 statement very well.
13070 Another use of label values is in an interpreter for threaded code.
13071 The labels within the interpreter function can be stored in the
13072 threaded code for super-fast dispatching.
13074 You may not use this mechanism to jump to code in a different function.
13075 If you do that, totally unpredictable things will happen. The best way
13076 to avoid this is to store the label address only in automatic variables
13077 and never pass it as an argument.
13079 An alternate way to write the above example is
13081 static const int array[] = { &&foo - &&foo, &&bar - &&foo,
13083 goto *(&&foo + array[i]);
13085 This is more friendly to code living in shared libraries, as it reduces
13086 the number of dynamic relocations that are needed, and by consequence,
13087 allows the data to be read-only.
13089 ---------- Footnotes ----------
13091 (1) The analogous feature in Fortran is called an assigned goto, but
13092 that name seems inappropriate in C, where one can do more than simply
13093 store label addresses in label variables.
13096 File: gcc.info, Node: Nested Functions, Next: Constructing Calls, Prev: Labels as Values, Up: C Extensions
13098 5.4 Nested Functions
13099 ====================
13101 A "nested function" is a function defined inside another function.
13102 (Nested functions are not supported for GNU C++.) The nested function's
13103 name is local to the block where it is defined. For example, here we
13104 define a nested function named `square', and call it twice:
13106 foo (double a, double b)
13108 double square (double z) { return z * z; }
13110 return square (a) + square (b);
13113 The nested function can access all the variables of the containing
13114 function that are visible at the point of its definition. This is
13115 called "lexical scoping". For example, here we show a nested function
13116 which uses an inherited variable named `offset':
13118 bar (int *array, int offset, int size)
13120 int access (int *array, int index)
13121 { return array[index + offset]; }
13124 for (i = 0; i < size; i++)
13125 /* ... */ access (array, i) /* ... */
13128 Nested function definitions are permitted within functions in the
13129 places where variable definitions are allowed; that is, in any block,
13130 mixed with the other declarations and statements in the block.
13132 It is possible to call the nested function from outside the scope of
13133 its name by storing its address or passing the address to another
13136 hack (int *array, int size)
13138 void store (int index, int value)
13139 { array[index] = value; }
13141 intermediate (store, size);
13144 Here, the function `intermediate' receives the address of `store' as
13145 an argument. If `intermediate' calls `store', the arguments given to
13146 `store' are used to store into `array'. But this technique works only
13147 so long as the containing function (`hack', in this example) does not
13150 If you try to call the nested function through its address after the
13151 containing function has exited, all hell will break loose. If you try
13152 to call it after a containing scope level has exited, and if it refers
13153 to some of the variables that are no longer in scope, you may be lucky,
13154 but it's not wise to take the risk. If, however, the nested function
13155 does not refer to anything that has gone out of scope, you should be
13158 GCC implements taking the address of a nested function using a
13159 technique called "trampolines". A paper describing them is available as
13161 `http://people.debian.org/~aaronl/Usenix88-lexic.pdf'.
13163 A nested function can jump to a label inherited from a containing
13164 function, provided the label was explicitly declared in the containing
13165 function (*note Local Labels::). Such a jump returns instantly to the
13166 containing function, exiting the nested function which did the `goto'
13167 and any intermediate functions as well. Here is an example:
13169 bar (int *array, int offset, int size)
13172 int access (int *array, int index)
13176 return array[index + offset];
13180 for (i = 0; i < size; i++)
13181 /* ... */ access (array, i) /* ... */
13185 /* Control comes here from `access'
13186 if it detects an error. */
13191 A nested function always has no linkage. Declaring one with `extern'
13192 or `static' is erroneous. If you need to declare the nested function
13193 before its definition, use `auto' (which is otherwise meaningless for
13194 function declarations).
13196 bar (int *array, int offset, int size)
13199 auto int access (int *, int);
13201 int access (int *array, int index)
13205 return array[index + offset];
13211 File: gcc.info, Node: Constructing Calls, Next: Typeof, Prev: Nested Functions, Up: C Extensions
13213 5.5 Constructing Function Calls
13214 ===============================
13216 Using the built-in functions described below, you can record the
13217 arguments a function received, and call another function with the same
13218 arguments, without knowing the number or types of the arguments.
13220 You can also record the return value of that function call, and later
13221 return that value, without knowing what data type the function tried to
13222 return (as long as your caller expects that data type).
13224 However, these built-in functions may interact badly with some
13225 sophisticated features or other extensions of the language. It is,
13226 therefore, not recommended to use them outside very simple functions
13227 acting as mere forwarders for their arguments.
13229 -- Built-in Function: void * __builtin_apply_args ()
13230 This built-in function returns a pointer to data describing how to
13231 perform a call with the same arguments as were passed to the
13234 The function saves the arg pointer register, structure value
13235 address, and all registers that might be used to pass arguments to
13236 a function into a block of memory allocated on the stack. Then it
13237 returns the address of that block.
13239 -- Built-in Function: void * __builtin_apply (void (*FUNCTION)(), void
13240 *ARGUMENTS, size_t SIZE)
13241 This built-in function invokes FUNCTION with a copy of the
13242 parameters described by ARGUMENTS and SIZE.
13244 The value of ARGUMENTS should be the value returned by
13245 `__builtin_apply_args'. The argument SIZE specifies the size of
13246 the stack argument data, in bytes.
13248 This function returns a pointer to data describing how to return
13249 whatever value was returned by FUNCTION. The data is saved in a
13250 block of memory allocated on the stack.
13252 It is not always simple to compute the proper value for SIZE. The
13253 value is used by `__builtin_apply' to compute the amount of data
13254 that should be pushed on the stack and copied from the incoming
13257 -- Built-in Function: void __builtin_return (void *RESULT)
13258 This built-in function returns the value described by RESULT from
13259 the containing function. You should specify, for RESULT, a value
13260 returned by `__builtin_apply'.
13263 File: gcc.info, Node: Typeof, Next: Conditionals, Prev: Constructing Calls, Up: C Extensions
13265 5.6 Referring to a Type with `typeof'
13266 =====================================
13268 Another way to refer to the type of an expression is with `typeof'.
13269 The syntax of using of this keyword looks like `sizeof', but the
13270 construct acts semantically like a type name defined with `typedef'.
13272 There are two ways of writing the argument to `typeof': with an
13273 expression or with a type. Here is an example with an expression:
13277 This assumes that `x' is an array of pointers to functions; the type
13278 described is that of the values of the functions.
13280 Here is an example with a typename as the argument:
13284 Here the type described is that of pointers to `int'.
13286 If you are writing a header file that must work when included in ISO C
13287 programs, write `__typeof__' instead of `typeof'. *Note Alternate
13290 A `typeof'-construct can be used anywhere a typedef name could be
13291 used. For example, you can use it in a declaration, in a cast, or
13292 inside of `sizeof' or `typeof'.
13294 `typeof' is often useful in conjunction with the
13295 statements-within-expressions feature. Here is how the two together can
13296 be used to define a safe "maximum" macro that operates on any
13297 arithmetic type and evaluates each of its arguments exactly once:
13300 ({ typeof (a) _a = (a); \
13301 typeof (b) _b = (b); \
13302 _a > _b ? _a : _b; })
13304 The reason for using names that start with underscores for the local
13305 variables is to avoid conflicts with variable names that occur within
13306 the expressions that are substituted for `a' and `b'. Eventually we
13307 hope to design a new form of declaration syntax that allows you to
13308 declare variables whose scopes start only after their initializers;
13309 this will be a more reliable way to prevent such conflicts.
13311 Some more examples of the use of `typeof':
13313 * This declares `y' with the type of what `x' points to.
13317 * This declares `y' as an array of such values.
13321 * This declares `y' as an array of pointers to characters:
13323 typeof (typeof (char *)[4]) y;
13325 It is equivalent to the following traditional C declaration:
13329 To see the meaning of the declaration using `typeof', and why it
13330 might be a useful way to write, rewrite it with these macros:
13332 #define pointer(T) typeof(T *)
13333 #define array(T, N) typeof(T [N])
13335 Now the declaration can be rewritten this way:
13337 array (pointer (char), 4) y;
13339 Thus, `array (pointer (char), 4)' is the type of arrays of 4
13340 pointers to `char'.
13342 _Compatibility Note:_ In addition to `typeof', GCC 2 supported a more
13343 limited extension which permitted one to write
13347 with the effect of declaring T to have the type of the expression EXPR.
13348 This extension does not work with GCC 3 (versions between 3.0 and 3.2
13349 will crash; 3.2.1 and later give an error). Code which relies on it
13350 should be rewritten to use `typeof':
13352 typedef typeof(EXPR) T;
13354 This will work with all versions of GCC.
13357 File: gcc.info, Node: Conditionals, Next: Long Long, Prev: Typeof, Up: C Extensions
13359 5.7 Conditionals with Omitted Operands
13360 ======================================
13362 The middle operand in a conditional expression may be omitted. Then if
13363 the first operand is nonzero, its value is the value of the conditional
13366 Therefore, the expression
13370 has the value of `x' if that is nonzero; otherwise, the value of `y'.
13372 This example is perfectly equivalent to
13376 In this simple case, the ability to omit the middle operand is not
13377 especially useful. When it becomes useful is when the first operand
13378 does, or may (if it is a macro argument), contain a side effect. Then
13379 repeating the operand in the middle would perform the side effect
13380 twice. Omitting the middle operand uses the value already computed
13381 without the undesirable effects of recomputing it.
13384 File: gcc.info, Node: Long Long, Next: Complex, Prev: Conditionals, Up: C Extensions
13386 5.8 Double-Word Integers
13387 ========================
13389 ISO C99 supports data types for integers that are at least 64 bits wide,
13390 and as an extension GCC supports them in C89 mode and in C++. Simply
13391 write `long long int' for a signed integer, or `unsigned long long int'
13392 for an unsigned integer. To make an integer constant of type `long
13393 long int', add the suffix `LL' to the integer. To make an integer
13394 constant of type `unsigned long long int', add the suffix `ULL' to the
13397 You can use these types in arithmetic like any other integer types.
13398 Addition, subtraction, and bitwise boolean operations on these types
13399 are open-coded on all types of machines. Multiplication is open-coded
13400 if the machine supports fullword-to-doubleword a widening multiply
13401 instruction. Division and shifts are open-coded only on machines that
13402 provide special support. The operations that are not open-coded use
13403 special library routines that come with GCC.
13405 There may be pitfalls when you use `long long' types for function
13406 arguments, unless you declare function prototypes. If a function
13407 expects type `int' for its argument, and you pass a value of type `long
13408 long int', confusion will result because the caller and the subroutine
13409 will disagree about the number of bytes for the argument. Likewise, if
13410 the function expects `long long int' and you pass `int'. The best way
13411 to avoid such problems is to use prototypes.
13414 File: gcc.info, Node: Complex, Next: Hex Floats, Prev: Long Long, Up: C Extensions
13416 5.9 Complex Numbers
13417 ===================
13419 ISO C99 supports complex floating data types, and as an extension GCC
13420 supports them in C89 mode and in C++, and supports complex integer data
13421 types which are not part of ISO C99. You can declare complex types
13422 using the keyword `_Complex'. As an extension, the older GNU keyword
13423 `__complex__' is also supported.
13425 For example, `_Complex double x;' declares `x' as a variable whose
13426 real part and imaginary part are both of type `double'. `_Complex
13427 short int y;' declares `y' to have real and imaginary parts of type
13428 `short int'; this is not likely to be useful, but it shows that the set
13429 of complex types is complete.
13431 To write a constant with a complex data type, use the suffix `i' or
13432 `j' (either one; they are equivalent). For example, `2.5fi' has type
13433 `_Complex float' and `3i' has type `_Complex int'. Such a constant
13434 always has a pure imaginary value, but you can form any complex value
13435 you like by adding one to a real constant. This is a GNU extension; if
13436 you have an ISO C99 conforming C library (such as GNU libc), and want
13437 to construct complex constants of floating type, you should include
13438 `<complex.h>' and use the macros `I' or `_Complex_I' instead.
13440 To extract the real part of a complex-valued expression EXP, write
13441 `__real__ EXP'. Likewise, use `__imag__' to extract the imaginary
13442 part. This is a GNU extension; for values of floating type, you should
13443 use the ISO C99 functions `crealf', `creal', `creall', `cimagf',
13444 `cimag' and `cimagl', declared in `<complex.h>' and also provided as
13445 built-in functions by GCC.
13447 The operator `~' performs complex conjugation when used on a value
13448 with a complex type. This is a GNU extension; for values of floating
13449 type, you should use the ISO C99 functions `conjf', `conj' and `conjl',
13450 declared in `<complex.h>' and also provided as built-in functions by
13453 GCC can allocate complex automatic variables in a noncontiguous
13454 fashion; it's even possible for the real part to be in a register while
13455 the imaginary part is on the stack (or vice-versa). Only the DWARF2
13456 debug info format can represent this, so use of DWARF2 is recommended.
13457 If you are using the stabs debug info format, GCC describes a
13458 noncontiguous complex variable as if it were two separate variables of
13459 noncomplex type. If the variable's actual name is `foo', the two
13460 fictitious variables are named `foo$real' and `foo$imag'. You can
13461 examine and set these two fictitious variables with your debugger.
13464 File: gcc.info, Node: Hex Floats, Next: Zero Length, Prev: Complex, Up: C Extensions
13469 ISO C99 supports floating-point numbers written not only in the usual
13470 decimal notation, such as `1.55e1', but also numbers such as `0x1.fp3'
13471 written in hexadecimal format. As a GNU extension, GCC supports this
13472 in C89 mode (except in some cases when strictly conforming) and in C++.
13473 In that format the `0x' hex introducer and the `p' or `P' exponent
13474 field are mandatory. The exponent is a decimal number that indicates
13475 the power of 2 by which the significant part will be multiplied. Thus
13476 `0x1.f' is 1 15/16, `p3' multiplies it by 8, and the value of `0x1.fp3'
13477 is the same as `1.55e1'.
13479 Unlike for floating-point numbers in the decimal notation the exponent
13480 is always required in the hexadecimal notation. Otherwise the compiler
13481 would not be able to resolve the ambiguity of, e.g., `0x1.f'. This
13482 could mean `1.0f' or `1.9375' since `f' is also the extension for
13483 floating-point constants of type `float'.
13486 File: gcc.info, Node: Zero Length, Next: Variable Length, Prev: Hex Floats, Up: C Extensions
13488 5.11 Arrays of Length Zero
13489 ==========================
13491 Zero-length arrays are allowed in GNU C. They are very useful as the
13492 last element of a structure which is really a header for a
13493 variable-length object:
13500 struct line *thisline = (struct line *)
13501 malloc (sizeof (struct line) + this_length);
13502 thisline->length = this_length;
13504 In ISO C90, you would have to give `contents' a length of 1, which
13505 means either you waste space or complicate the argument to `malloc'.
13507 In ISO C99, you would use a "flexible array member", which is slightly
13508 different in syntax and semantics:
13510 * Flexible array members are written as `contents[]' without the `0'.
13512 * Flexible array members have incomplete type, and so the `sizeof'
13513 operator may not be applied. As a quirk of the original
13514 implementation of zero-length arrays, `sizeof' evaluates to zero.
13516 * Flexible array members may only appear as the last member of a
13517 `struct' that is otherwise non-empty.
13519 * A structure containing a flexible array member, or a union
13520 containing such a structure (possibly recursively), may not be a
13521 member of a structure or an element of an array. (However, these
13522 uses are permitted by GCC as extensions.)
13524 GCC versions before 3.0 allowed zero-length arrays to be statically
13525 initialized, as if they were flexible arrays. In addition to those
13526 cases that were useful, it also allowed initializations in situations
13527 that would corrupt later data. Non-empty initialization of zero-length
13528 arrays is now treated like any case where there are more initializer
13529 elements than the array holds, in that a suitable warning about "excess
13530 elements in array" is given, and the excess elements (all of them, in
13531 this case) are ignored.
13533 Instead GCC allows static initialization of flexible array members.
13534 This is equivalent to defining a new structure containing the original
13535 structure followed by an array of sufficient size to contain the data.
13536 I.e. in the following, `f1' is constructed as if it were declared like
13541 } f1 = { 1, { 2, 3, 4 } };
13544 struct f1 f1; int data[3];
13545 } f2 = { { 1 }, { 2, 3, 4 } };
13547 The convenience of this extension is that `f1' has the desired type,
13548 eliminating the need to consistently refer to `f2.f1'.
13550 This has symmetry with normal static arrays, in that an array of
13551 unknown size is also written with `[]'.
13553 Of course, this extension only makes sense if the extra data comes at
13554 the end of a top-level object, as otherwise we would be overwriting
13555 data at subsequent offsets. To avoid undue complication and confusion
13556 with initialization of deeply nested arrays, we simply disallow any
13557 non-empty initialization except when the structure is the top-level
13558 object. For example:
13560 struct foo { int x; int y[]; };
13561 struct bar { struct foo z; };
13563 struct foo a = { 1, { 2, 3, 4 } }; // Valid.
13564 struct bar b = { { 1, { 2, 3, 4 } } }; // Invalid.
13565 struct bar c = { { 1, { } } }; // Valid.
13566 struct foo d[1] = { { 1 { 2, 3, 4 } } }; // Invalid.
13569 File: gcc.info, Node: Empty Structures, Next: Variadic Macros, Prev: Variable Length, Up: C Extensions
13571 5.12 Structures With No Members
13572 ===============================
13574 GCC permits a C structure to have no members:
13579 The structure will have size zero. In C++, empty structures are part
13580 of the language. G++ treats empty structures as if they had a single
13581 member of type `char'.
13584 File: gcc.info, Node: Variable Length, Next: Empty Structures, Prev: Zero Length, Up: C Extensions
13586 5.13 Arrays of Variable Length
13587 ==============================
13589 Variable-length automatic arrays are allowed in ISO C99, and as an
13590 extension GCC accepts them in C89 mode and in C++. (However, GCC's
13591 implementation of variable-length arrays does not yet conform in detail
13592 to the ISO C99 standard.) These arrays are declared like any other
13593 automatic arrays, but with a length that is not a constant expression.
13594 The storage is allocated at the point of declaration and deallocated
13595 when the brace-level is exited. For example:
13598 concat_fopen (char *s1, char *s2, char *mode)
13600 char str[strlen (s1) + strlen (s2) + 1];
13603 return fopen (str, mode);
13606 Jumping or breaking out of the scope of the array name deallocates the
13607 storage. Jumping into the scope is not allowed; you get an error
13610 You can use the function `alloca' to get an effect much like
13611 variable-length arrays. The function `alloca' is available in many
13612 other C implementations (but not in all). On the other hand,
13613 variable-length arrays are more elegant.
13615 There are other differences between these two methods. Space allocated
13616 with `alloca' exists until the containing _function_ returns. The
13617 space for a variable-length array is deallocated as soon as the array
13618 name's scope ends. (If you use both variable-length arrays and
13619 `alloca' in the same function, deallocation of a variable-length array
13620 will also deallocate anything more recently allocated with `alloca'.)
13622 You can also use variable-length arrays as arguments to functions:
13625 tester (int len, char data[len][len])
13630 The length of an array is computed once when the storage is allocated
13631 and is remembered for the scope of the array in case you access it with
13634 If you want to pass the array first and the length afterward, you can
13635 use a forward declaration in the parameter list--another GNU extension.
13638 tester (int len; char data[len][len], int len)
13643 The `int len' before the semicolon is a "parameter forward
13644 declaration", and it serves the purpose of making the name `len' known
13645 when the declaration of `data' is parsed.
13647 You can write any number of such parameter forward declarations in the
13648 parameter list. They can be separated by commas or semicolons, but the
13649 last one must end with a semicolon, which is followed by the "real"
13650 parameter declarations. Each forward declaration must match a "real"
13651 declaration in parameter name and data type. ISO C99 does not support
13652 parameter forward declarations.
13655 File: gcc.info, Node: Variadic Macros, Next: Escaped Newlines, Prev: Empty Structures, Up: C Extensions
13657 5.14 Macros with a Variable Number of Arguments.
13658 ================================================
13660 In the ISO C standard of 1999, a macro can be declared to accept a
13661 variable number of arguments much as a function can. The syntax for
13662 defining the macro is similar to that of a function. Here is an
13665 #define debug(format, ...) fprintf (stderr, format, __VA_ARGS__)
13667 Here `...' is a "variable argument". In the invocation of such a
13668 macro, it represents the zero or more tokens until the closing
13669 parenthesis that ends the invocation, including any commas. This set of
13670 tokens replaces the identifier `__VA_ARGS__' in the macro body wherever
13671 it appears. See the CPP manual for more information.
13673 GCC has long supported variadic macros, and used a different syntax
13674 that allowed you to give a name to the variable arguments just like any
13675 other argument. Here is an example:
13677 #define debug(format, args...) fprintf (stderr, format, args)
13679 This is in all ways equivalent to the ISO C example above, but arguably
13680 more readable and descriptive.
13682 GNU CPP has two further variadic macro extensions, and permits them to
13683 be used with either of the above forms of macro definition.
13685 In standard C, you are not allowed to leave the variable argument out
13686 entirely; but you are allowed to pass an empty argument. For example,
13687 this invocation is invalid in ISO C, because there is no comma after
13690 debug ("A message")
13692 GNU CPP permits you to completely omit the variable arguments in this
13693 way. In the above examples, the compiler would complain, though since
13694 the expansion of the macro still has the extra comma after the format
13697 To help solve this problem, CPP behaves specially for variable
13698 arguments used with the token paste operator, `##'. If instead you
13701 #define debug(format, ...) fprintf (stderr, format, ## __VA_ARGS__)
13703 and if the variable arguments are omitted or empty, the `##' operator
13704 causes the preprocessor to remove the comma before it. If you do
13705 provide some variable arguments in your macro invocation, GNU CPP does
13706 not complain about the paste operation and instead places the variable
13707 arguments after the comma. Just like any other pasted macro argument,
13708 these arguments are not macro expanded.
13711 File: gcc.info, Node: Escaped Newlines, Next: Subscripting, Prev: Variadic Macros, Up: C Extensions
13713 5.15 Slightly Looser Rules for Escaped Newlines
13714 ===============================================
13716 Recently, the preprocessor has relaxed its treatment of escaped
13717 newlines. Previously, the newline had to immediately follow a
13718 backslash. The current implementation allows whitespace in the form of
13719 spaces, horizontal and vertical tabs, and form feeds between the
13720 backslash and the subsequent newline. The preprocessor issues a
13721 warning, but treats it as a valid escaped newline and combines the two
13722 lines to form a single logical line. This works within comments and
13723 tokens, as well as between tokens. Comments are _not_ treated as
13724 whitespace for the purposes of this relaxation, since they have not yet
13725 been replaced with spaces.
13728 File: gcc.info, Node: Subscripting, Next: Pointer Arith, Prev: Escaped Newlines, Up: C Extensions
13730 5.16 Non-Lvalue Arrays May Have Subscripts
13731 ==========================================
13733 In ISO C99, arrays that are not lvalues still decay to pointers, and
13734 may be subscripted, although they may not be modified or used after the
13735 next sequence point and the unary `&' operator may not be applied to
13736 them. As an extension, GCC allows such arrays to be subscripted in C89
13737 mode, though otherwise they do not decay to pointers outside C99 mode.
13738 For example, this is valid in GNU C though not valid in C89:
13740 struct foo {int a[4];};
13746 return f().a[index];
13750 File: gcc.info, Node: Pointer Arith, Next: Initializers, Prev: Subscripting, Up: C Extensions
13752 5.17 Arithmetic on `void'- and Function-Pointers
13753 ================================================
13755 In GNU C, addition and subtraction operations are supported on pointers
13756 to `void' and on pointers to functions. This is done by treating the
13757 size of a `void' or of a function as 1.
13759 A consequence of this is that `sizeof' is also allowed on `void' and
13760 on function types, and returns 1.
13762 The option `-Wpointer-arith' requests a warning if these extensions
13766 File: gcc.info, Node: Initializers, Next: Compound Literals, Prev: Pointer Arith, Up: C Extensions
13768 5.18 Non-Constant Initializers
13769 ==============================
13771 As in standard C++ and ISO C99, the elements of an aggregate
13772 initializer for an automatic variable are not required to be constant
13773 expressions in GNU C. Here is an example of an initializer with
13774 run-time varying elements:
13776 foo (float f, float g)
13778 float beat_freqs[2] = { f-g, f+g };
13783 File: gcc.info, Node: Compound Literals, Next: Designated Inits, Prev: Initializers, Up: C Extensions
13785 5.19 Compound Literals
13786 ======================
13788 ISO C99 supports compound literals. A compound literal looks like a
13789 cast containing an initializer. Its value is an object of the type
13790 specified in the cast, containing the elements specified in the
13791 initializer; it is an lvalue. As an extension, GCC supports compound
13792 literals in C89 mode and in C++.
13794 Usually, the specified type is a structure. Assume that `struct foo'
13795 and `structure' are declared as shown:
13797 struct foo {int a; char b[2];} structure;
13799 Here is an example of constructing a `struct foo' with a compound
13802 structure = ((struct foo) {x + y, 'a', 0});
13804 This is equivalent to writing the following:
13807 struct foo temp = {x + y, 'a', 0};
13811 You can also construct an array. If all the elements of the compound
13812 literal are (made up of) simple constant expressions, suitable for use
13813 in initializers of objects of static storage duration, then the compound
13814 literal can be coerced to a pointer to its first element and used in
13815 such an initializer, as shown here:
13817 char **foo = (char *[]) { "x", "y", "z" };
13819 Compound literals for scalar types and union types are is also
13820 allowed, but then the compound literal is equivalent to a cast.
13822 As a GNU extension, GCC allows initialization of objects with static
13823 storage duration by compound literals (which is not possible in ISO
13824 C99, because the initializer is not a constant). It is handled as if
13825 the object was initialized only with the bracket enclosed list if
13826 compound literal's and object types match. The initializer list of the
13827 compound literal must be constant. If the object being initialized has
13828 array type of unknown size, the size is determined by compound literal
13831 static struct foo x = (struct foo) {1, 'a', 'b'};
13832 static int y[] = (int []) {1, 2, 3};
13833 static int z[] = (int [3]) {1};
13835 The above lines are equivalent to the following:
13836 static struct foo x = {1, 'a', 'b'};
13837 static int y[] = {1, 2, 3};
13838 static int z[] = {1, 0, 0};
13841 File: gcc.info, Node: Designated Inits, Next: Cast to Union, Prev: Compound Literals, Up: C Extensions
13843 5.20 Designated Initializers
13844 ============================
13846 Standard C89 requires the elements of an initializer to appear in a
13847 fixed order, the same as the order of the elements in the array or
13848 structure being initialized.
13850 In ISO C99 you can give the elements in any order, specifying the array
13851 indices or structure field names they apply to, and GNU C allows this as
13852 an extension in C89 mode as well. This extension is not implemented in
13855 To specify an array index, write `[INDEX] =' before the element value.
13858 int a[6] = { [4] = 29, [2] = 15 };
13862 int a[6] = { 0, 0, 15, 0, 29, 0 };
13864 The index values must be constant expressions, even if the array being
13865 initialized is automatic.
13867 An alternative syntax for this which has been obsolete since GCC 2.5
13868 but GCC still accepts is to write `[INDEX]' before the element value,
13871 To initialize a range of elements to the same value, write `[FIRST ...
13872 LAST] = VALUE'. This is a GNU extension. For example,
13874 int widths[] = { [0 ... 9] = 1, [10 ... 99] = 2, [100] = 3 };
13876 If the value in it has side-effects, the side-effects will happen only
13877 once, not for each initialized field by the range initializer.
13879 Note that the length of the array is the highest value specified plus
13882 In a structure initializer, specify the name of a field to initialize
13883 with `.FIELDNAME =' before the element value. For example, given the
13884 following structure,
13886 struct point { int x, y; };
13888 the following initialization
13890 struct point p = { .y = yvalue, .x = xvalue };
13894 struct point p = { xvalue, yvalue };
13896 Another syntax which has the same meaning, obsolete since GCC 2.5, is
13897 `FIELDNAME:', as shown here:
13899 struct point p = { y: yvalue, x: xvalue };
13901 The `[INDEX]' or `.FIELDNAME' is known as a "designator". You can
13902 also use a designator (or the obsolete colon syntax) when initializing
13903 a union, to specify which element of the union should be used. For
13906 union foo { int i; double d; };
13908 union foo f = { .d = 4 };
13910 will convert 4 to a `double' to store it in the union using the second
13911 element. By contrast, casting 4 to type `union foo' would store it
13912 into the union as the integer `i', since it is an integer. (*Note Cast
13915 You can combine this technique of naming elements with ordinary C
13916 initialization of successive elements. Each initializer element that
13917 does not have a designator applies to the next consecutive element of
13918 the array or structure. For example,
13920 int a[6] = { [1] = v1, v2, [4] = v4 };
13924 int a[6] = { 0, v1, v2, 0, v4, 0 };
13926 Labeling the elements of an array initializer is especially useful
13927 when the indices are characters or belong to an `enum' type. For
13930 int whitespace[256]
13931 = { [' '] = 1, ['\t'] = 1, ['\h'] = 1,
13932 ['\f'] = 1, ['\n'] = 1, ['\r'] = 1 };
13934 You can also write a series of `.FIELDNAME' and `[INDEX]' designators
13935 before an `=' to specify a nested subobject to initialize; the list is
13936 taken relative to the subobject corresponding to the closest
13937 surrounding brace pair. For example, with the `struct point'
13940 struct point ptarray[10] = { [2].y = yv2, [2].x = xv2, [0].x = xv0 };
13942 If the same field is initialized multiple times, it will have value from
13943 the last initialization. If any such overridden initialization has
13944 side-effect, it is unspecified whether the side-effect happens or not.
13945 Currently, GCC will discard them and issue a warning.
13948 File: gcc.info, Node: Case Ranges, Next: Mixed Declarations, Prev: Cast to Union, Up: C Extensions
13953 You can specify a range of consecutive values in a single `case' label,
13958 This has the same effect as the proper number of individual `case'
13959 labels, one for each integer value from LOW to HIGH, inclusive.
13961 This feature is especially useful for ranges of ASCII character codes:
13965 *Be careful:* Write spaces around the `...', for otherwise it may be
13966 parsed wrong when you use it with integer values. For example, write
13976 File: gcc.info, Node: Cast to Union, Next: Case Ranges, Prev: Designated Inits, Up: C Extensions
13978 5.22 Cast to a Union Type
13979 =========================
13981 A cast to union type is similar to other casts, except that the type
13982 specified is a union type. You can specify the type either with `union
13983 TAG' or with a typedef name. A cast to union is actually a constructor
13984 though, not a cast, and hence does not yield an lvalue like normal
13985 casts. (*Note Compound Literals::.)
13987 The types that may be cast to the union type are those of the members
13988 of the union. Thus, given the following union and variables:
13990 union foo { int i; double d; };
13994 both `x' and `y' can be cast to type `union foo'.
13996 Using the cast as the right-hand side of an assignment to a variable of
13997 union type is equivalent to storing in a member of the union:
14001 u = (union foo) x == u.i = x
14002 u = (union foo) y == u.d = y
14004 You can also use the union cast as a function argument:
14006 void hack (union foo);
14008 hack ((union foo) x);
14011 File: gcc.info, Node: Mixed Declarations, Next: Function Attributes, Prev: Case Ranges, Up: C Extensions
14013 5.23 Mixed Declarations and Code
14014 ================================
14016 ISO C99 and ISO C++ allow declarations and code to be freely mixed
14017 within compound statements. As an extension, GCC also allows this in
14018 C89 mode. For example, you could do:
14025 Each identifier is visible from where it is declared until the end of
14026 the enclosing block.
14029 File: gcc.info, Node: Function Attributes, Next: Attribute Syntax, Prev: Mixed Declarations, Up: C Extensions
14031 5.24 Declaring Attributes of Functions
14032 ======================================
14034 In GNU C, you declare certain things about functions called in your
14035 program which help the compiler optimize function calls and check your
14036 code more carefully.
14038 The keyword `__attribute__' allows you to specify special attributes
14039 when making a declaration. This keyword is followed by an attribute
14040 specification inside double parentheses. The following attributes are
14041 currently defined for functions on all targets: `noreturn', `noinline',
14042 `always_inline', `pure', `const', `nothrow', `sentinel', `format',
14043 `format_arg', `no_instrument_function', `section', `constructor',
14044 `destructor', `used', `unused', `deprecated', `weak', `malloc',
14045 `alias', `warn_unused_result' and `nonnull'. Several other attributes
14046 are defined for functions on particular target systems. Other
14047 attributes, including `section' are supported for variables declarations
14048 (*note Variable Attributes::) and for types (*note Type Attributes::).
14050 You may also specify attributes with `__' preceding and following each
14051 keyword. This allows you to use them in header files without being
14052 concerned about a possible macro of the same name. For example, you
14053 may use `__noreturn__' instead of `noreturn'.
14055 *Note Attribute Syntax::, for details of the exact syntax for using
14059 The `alias' attribute causes the declaration to be emitted as an
14060 alias for another symbol, which must be specified. For instance,
14062 void __f () { /* Do something. */; }
14063 void f () __attribute__ ((weak, alias ("__f")));
14065 declares `f' to be a weak alias for `__f'. In C++, the mangled
14066 name for the target must be used. It is an error if `__f' is not
14067 defined in the same translation unit.
14069 Not all target machines support this attribute.
14072 Generally, functions are not inlined unless optimization is
14073 specified. For functions declared inline, this attribute inlines
14074 the function even if no optimization level was specified.
14077 On the Intel 386, the `cdecl' attribute causes the compiler to
14078 assume that the calling function will pop off the stack space used
14079 to pass arguments. This is useful to override the effects of the
14083 Many functions do not examine any values except their arguments,
14084 and have no effects except the return value. Basically this is
14085 just slightly more strict class than the `pure' attribute below,
14086 since function is not allowed to read global memory.
14088 Note that a function that has pointer arguments and examines the
14089 data pointed to must _not_ be declared `const'. Likewise, a
14090 function that calls a non-`const' function usually must not be
14091 `const'. It does not make sense for a `const' function to return
14094 The attribute `const' is not implemented in GCC versions earlier
14095 than 2.5. An alternative way to declare that a function has no
14096 side effects, which works in the current version and in some older
14097 versions, is as follows:
14099 typedef int intfn ();
14101 extern const intfn square;
14103 This approach does not work in GNU C++ from 2.6.0 on, since the
14104 language specifies that the `const' must be attached to the return
14109 The `constructor' attribute causes the function to be called
14110 automatically before execution enters `main ()'. Similarly, the
14111 `destructor' attribute causes the function to be called
14112 automatically after `main ()' has completed or `exit ()' has been
14113 called. Functions with these attributes are useful for
14114 initializing data that will be used implicitly during the
14115 execution of the program.
14117 These attributes are not currently implemented for Objective-C.
14120 The `deprecated' attribute results in a warning if the function is
14121 used anywhere in the source file. This is useful when identifying
14122 functions that are expected to be removed in a future version of a
14123 program. The warning also includes the location of the declaration
14124 of the deprecated function, to enable users to easily find further
14125 information about why the function is deprecated, or what they
14126 should do instead. Note that the warnings only occurs for uses:
14128 int old_fn () __attribute__ ((deprecated));
14130 int (*fn_ptr)() = old_fn;
14132 results in a warning on line 3 but not line 2.
14134 The `deprecated' attribute can also be used for variables and
14135 types (*note Variable Attributes::, *note Type Attributes::.)
14138 On Microsoft Windows targets and Symbian OS targets the
14139 `dllexport' attribute causes the compiler to provide a global
14140 pointer to a pointer in a DLL, so that it can be referenced with
14141 the `dllimport' attribute. On Microsoft Windows targets, the
14142 pointer name is formed by combining `_imp__' and the function or
14145 You can use `__declspec(dllexport)' as a synonym for
14146 `__attribute__ ((dllexport))' for compatibility with other
14149 On systems that support the `visibility' attribute, this attribute
14150 also implies "default" visibility, unless a `visibility' attribute
14151 is explicitly specified. You should avoid the use of `dllexport'
14152 with "hidden" or "internal" visibility; in the future GCC may
14153 issue an error for those cases.
14155 Currently, the `dllexport' attribute is ignored for inlined
14156 functions, unless the `-fkeep-inline-functions' flag has been
14157 used. The attribute is also ignored for undefined symbols.
14159 When applied to C++ classes, the attribute marks defined
14160 non-inlined member functions and static data members as exports.
14161 Static consts initialized in-class are not marked unless they are
14162 also defined out-of-class.
14164 For Microsoft Windows targets there are alternative methods for
14165 including the symbol in the DLL's export table such as using a
14166 `.def' file with an `EXPORTS' section or, with GNU ld, using the
14167 `--export-all' linker flag.
14170 On Microsoft Windows and Symbian OS targets, the `dllimport'
14171 attribute causes the compiler to reference a function or variable
14172 via a global pointer to a pointer that is set up by the DLL
14173 exporting the symbol. The attribute implies `extern' storage. On
14174 Microsoft Windows targets, the pointer name is formed by combining
14175 `_imp__' and the function or variable name.
14177 You can use `__declspec(dllimport)' as a synonym for
14178 `__attribute__ ((dllimport))' for compatibility with other
14181 Currently, the attribute is ignored for inlined functions. If the
14182 attribute is applied to a symbol _definition_, an error is
14183 reported. If a symbol previously declared `dllimport' is later
14184 defined, the attribute is ignored in subsequent references, and a
14185 warning is emitted. The attribute is also overridden by a
14186 subsequent declaration as `dllexport'.
14188 When applied to C++ classes, the attribute marks non-inlined
14189 member functions and static data members as imports. However, the
14190 attribute is ignored for virtual methods to allow creation of
14191 vtables using thunks.
14193 On the SH Symbian OS target the `dllimport' attribute also has
14194 another affect--it can cause the vtable and run-time type
14195 information for a class to be exported. This happens when the
14196 class has a dllimport'ed constructor or a non-inline, non-pure
14197 virtual function and, for either of those two conditions, the
14198 class also has a inline constructor or destructor and has a key
14199 function that is defined in the current translation unit.
14201 For Microsoft Windows based targets the use of the `dllimport'
14202 attribute on functions is not necessary, but provides a small
14203 performance benefit by eliminating a thunk in the DLL. The use of
14204 the `dllimport' attribute on imported variables was required on
14205 older versions of the GNU linker, but can now be avoided by
14206 passing the `--enable-auto-import' switch to the GNU linker. As
14207 with functions, using the attribute for a variable eliminates a
14210 One drawback to using this attribute is that a pointer to a
14211 function or variable marked as `dllimport' cannot be used as a
14212 constant address. On Microsoft Windows targets, the attribute can
14213 be disabled for functions by setting the `-mnop-fun-dllimport'
14217 Use this attribute on the H8/300, H8/300H, and H8S to indicate
14218 that the specified variable should be placed into the eight bit
14219 data section. The compiler will generate more efficient code for
14220 certain operations on data in the eight bit data area. Note the
14221 eight bit data area is limited to 256 bytes of data.
14223 You must use GAS and GLD from GNU binutils version 2.7 or later for
14224 this attribute to work correctly.
14227 On 68HC11 and 68HC12 the `far' attribute causes the compiler to
14228 use a calling convention that takes care of switching memory banks
14229 when entering and leaving a function. This calling convention is
14230 also the default when using the `-mlong-calls' option.
14232 On 68HC12 the compiler will use the `call' and `rtc' instructions
14233 to call and return from a function.
14235 On 68HC11 the compiler will generate a sequence of instructions to
14236 invoke a board-specific routine to switch the memory bank and call
14237 the real function. The board-specific routine simulates a `call'.
14238 At the end of a function, it will jump to a board-specific routine
14239 instead of using `rts'. The board-specific return routine
14240 simulates the `rtc'.
14243 On the Intel 386, the `fastcall' attribute causes the compiler to
14244 pass the first two arguments in the registers ECX and EDX.
14245 Subsequent arguments are passed on the stack. The called function
14246 will pop the arguments off the stack. If the number of arguments
14247 is variable all arguments are pushed on the stack.
14249 `format (ARCHETYPE, STRING-INDEX, FIRST-TO-CHECK)'
14250 The `format' attribute specifies that a function takes `printf',
14251 `scanf', `strftime' or `strfmon' style arguments which should be
14252 type-checked against a format string. For example, the
14256 my_printf (void *my_object, const char *my_format, ...)
14257 __attribute__ ((format (printf, 2, 3)));
14259 causes the compiler to check the arguments in calls to `my_printf'
14260 for consistency with the `printf' style format string argument
14263 The parameter ARCHETYPE determines how the format string is
14264 interpreted, and should be `printf', `scanf', `strftime' or
14265 `strfmon'. (You can also use `__printf__', `__scanf__',
14266 `__strftime__' or `__strfmon__'.) The parameter STRING-INDEX
14267 specifies which argument is the format string argument (starting
14268 from 1), while FIRST-TO-CHECK is the number of the first argument
14269 to check against the format string. For functions where the
14270 arguments are not available to be checked (such as `vprintf'),
14271 specify the third parameter as zero. In this case the compiler
14272 only checks the format string for consistency. For `strftime'
14273 formats, the third parameter is required to be zero. Since
14274 non-static C++ methods have an implicit `this' argument, the
14275 arguments of such methods should be counted from two, not one, when
14276 giving values for STRING-INDEX and FIRST-TO-CHECK.
14278 In the example above, the format string (`my_format') is the second
14279 argument of the function `my_print', and the arguments to check
14280 start with the third argument, so the correct parameters for the
14281 format attribute are 2 and 3.
14283 The `format' attribute allows you to identify your own functions
14284 which take format strings as arguments, so that GCC can check the
14285 calls to these functions for errors. The compiler always (unless
14286 `-ffreestanding' or `-fno-builtin' is used) checks formats for the
14287 standard library functions `printf', `fprintf', `sprintf',
14288 `scanf', `fscanf', `sscanf', `strftime', `vprintf', `vfprintf' and
14289 `vsprintf' whenever such warnings are requested (using
14290 `-Wformat'), so there is no need to modify the header file
14291 `stdio.h'. In C99 mode, the functions `snprintf', `vsnprintf',
14292 `vscanf', `vfscanf' and `vsscanf' are also checked. Except in
14293 strictly conforming C standard modes, the X/Open function
14294 `strfmon' is also checked as are `printf_unlocked' and
14295 `fprintf_unlocked'. *Note Options Controlling C Dialect: C
14298 The target may provide additional types of format checks. *Note
14299 Format Checks Specific to Particular Target Machines: Target
14302 `format_arg (STRING-INDEX)'
14303 The `format_arg' attribute specifies that a function takes a format
14304 string for a `printf', `scanf', `strftime' or `strfmon' style
14305 function and modifies it (for example, to translate it into
14306 another language), so the result can be passed to a `printf',
14307 `scanf', `strftime' or `strfmon' style function (with the
14308 remaining arguments to the format function the same as they would
14309 have been for the unmodified string). For example, the
14313 my_dgettext (char *my_domain, const char *my_format)
14314 __attribute__ ((format_arg (2)));
14316 causes the compiler to check the arguments in calls to a `printf',
14317 `scanf', `strftime' or `strfmon' type function, whose format
14318 string argument is a call to the `my_dgettext' function, for
14319 consistency with the format string argument `my_format'. If the
14320 `format_arg' attribute had not been specified, all the compiler
14321 could tell in such calls to format functions would be that the
14322 format string argument is not constant; this would generate a
14323 warning when `-Wformat-nonliteral' is used, but the calls could
14324 not be checked without the attribute.
14326 The parameter STRING-INDEX specifies which argument is the format
14327 string argument (starting from one). Since non-static C++ methods
14328 have an implicit `this' argument, the arguments of such methods
14329 should be counted from two.
14331 The `format-arg' attribute allows you to identify your own
14332 functions which modify format strings, so that GCC can check the
14333 calls to `printf', `scanf', `strftime' or `strfmon' type function
14334 whose operands are a call to one of your own function. The
14335 compiler always treats `gettext', `dgettext', and `dcgettext' in
14336 this manner except when strict ISO C support is requested by
14337 `-ansi' or an appropriate `-std' option, or `-ffreestanding' or
14338 `-fno-builtin' is used. *Note Options Controlling C Dialect: C
14342 Use this attribute on the H8/300, H8/300H, and H8S to indicate
14343 that the specified function should be called through the function
14344 vector. Calling a function through the function vector will
14345 reduce code size, however; the function vector has a limited size
14346 (maximum 128 entries on the H8/300 and 64 entries on the H8/300H
14347 and H8S) and shares space with the interrupt vector.
14349 You must use GAS and GLD from GNU binutils version 2.7 or later for
14350 this attribute to work correctly.
14353 Use this attribute on the ARM, AVR, C4x, M32R/D and Xstormy16
14354 ports to indicate that the specified function is an interrupt
14355 handler. The compiler will generate function entry and exit
14356 sequences suitable for use in an interrupt handler when this
14357 attribute is present.
14359 Note, interrupt handlers for the m68k, H8/300, H8/300H, H8S, and
14360 SH processors can be specified via the `interrupt_handler'
14363 Note, on the AVR, interrupts will be enabled inside the function.
14365 Note, for the ARM, you can specify the kind of interrupt to be
14366 handled by adding an optional parameter to the interrupt attribute
14369 void f () __attribute__ ((interrupt ("IRQ")));
14371 Permissible values for this parameter are: IRQ, FIQ, SWI, ABORT
14374 `interrupt_handler'
14375 Use this attribute on the m68k, H8/300, H8/300H, H8S, and SH to
14376 indicate that the specified function is an interrupt handler. The
14377 compiler will generate function entry and exit sequences suitable
14378 for use in an interrupt handler when this attribute is present.
14380 `long_call/short_call'
14381 This attribute specifies how a particular function is called on
14382 ARM. Both attributes override the `-mlong-calls' (*note ARM
14383 Options::) command line switch and `#pragma long_calls' settings.
14384 The `long_call' attribute causes the compiler to always call the
14385 function by first loading its address into a register and then
14386 using the contents of that register. The `short_call' attribute
14387 always places the offset to the function from the call site into
14388 the `BL' instruction directly.
14390 `longcall/shortcall'
14391 On the RS/6000 and PowerPC, the `longcall' attribute causes the
14392 compiler to always call this function via a pointer, just as it
14393 would if the `-mlongcall' option had been specified. The
14394 `shortcall' attribute causes the compiler not to do this. These
14395 attributes override both the `-mlongcall' switch and the `#pragma
14398 *Note RS/6000 and PowerPC Options::, for more information on
14399 whether long calls are necessary.
14402 The `malloc' attribute is used to tell the compiler that a function
14403 may be treated as if any non-`NULL' pointer it returns cannot
14404 alias any other pointer valid when the function returns. This
14405 will often improve optimization. Standard functions with this
14406 property include `malloc' and `calloc'. `realloc'-like functions
14407 have this property as long as the old pointer is never referred to
14408 (including comparing it to the new pointer) after the function
14409 returns a non-`NULL' value.
14411 `model (MODEL-NAME)'
14412 On the M32R/D, use this attribute to set the addressability of an
14413 object, and of the code generated for a function. The identifier
14414 MODEL-NAME is one of `small', `medium', or `large', representing
14415 each of the code models.
14417 Small model objects live in the lower 16MB of memory (so that their
14418 addresses can be loaded with the `ld24' instruction), and are
14419 callable with the `bl' instruction.
14421 Medium model objects may live anywhere in the 32-bit address space
14422 (the compiler will generate `seth/add3' instructions to load their
14423 addresses), and are callable with the `bl' instruction.
14425 Large model objects may live anywhere in the 32-bit address space
14426 (the compiler will generate `seth/add3' instructions to load their
14427 addresses), and may not be reachable with the `bl' instruction
14428 (the compiler will generate the much slower `seth/add3/jl'
14429 instruction sequence).
14431 On IA-64, use this attribute to set the addressability of an
14432 object. At present, the only supported identifier for MODEL-NAME
14433 is `small', indicating addressability via "small" (22-bit)
14434 addresses (so that their addresses can be loaded with the `addl'
14435 instruction). Caveat: such addressing is by definition not
14436 position independent and hence this attribute must not be used for
14437 objects defined by shared libraries.
14440 Use this attribute on the ARM, AVR, C4x and IP2K ports to indicate
14441 that the specified function does not need prologue/epilogue
14442 sequences generated by the compiler. It is up to the programmer
14443 to provide these sequences.
14446 On 68HC11 and 68HC12 the `near' attribute causes the compiler to
14447 use the normal calling convention based on `jsr' and `rts'. This
14448 attribute can be used to cancel the effect of the `-mlong-calls'
14451 `no_instrument_function'
14452 If `-finstrument-functions' is given, profiling function calls will
14453 be generated at entry and exit of most user-compiled functions.
14454 Functions with this attribute will not be so instrumented.
14457 This function attribute prevents a function from being considered
14460 `nonnull (ARG-INDEX, ...)'
14461 The `nonnull' attribute specifies that some function parameters
14462 should be non-null pointers. For instance, the declaration:
14465 my_memcpy (void *dest, const void *src, size_t len)
14466 __attribute__((nonnull (1, 2)));
14468 causes the compiler to check that, in calls to `my_memcpy',
14469 arguments DEST and SRC are non-null. If the compiler determines
14470 that a null pointer is passed in an argument slot marked as
14471 non-null, and the `-Wnonnull' option is enabled, a warning is
14472 issued. The compiler may also choose to make optimizations based
14473 on the knowledge that certain function arguments will not be null.
14475 If no argument index list is given to the `nonnull' attribute, all
14476 pointer arguments are marked as non-null. To illustrate, the
14477 following declaration is equivalent to the previous example:
14480 my_memcpy (void *dest, const void *src, size_t len)
14481 __attribute__((nonnull));
14484 A few standard library functions, such as `abort' and `exit',
14485 cannot return. GCC knows this automatically. Some programs define
14486 their own functions that never return. You can declare them
14487 `noreturn' to tell the compiler this fact. For example,
14489 void fatal () __attribute__ ((noreturn));
14494 /* ... */ /* Print error message. */ /* ... */
14498 The `noreturn' keyword tells the compiler to assume that `fatal'
14499 cannot return. It can then optimize without regard to what would
14500 happen if `fatal' ever did return. This makes slightly better
14501 code. More importantly, it helps avoid spurious warnings of
14502 uninitialized variables.
14504 The `noreturn' keyword does not affect the exceptional path when
14505 that applies: a `noreturn'-marked function may still return to the
14506 caller by throwing an exception or calling `longjmp'.
14508 Do not assume that registers saved by the calling function are
14509 restored before calling the `noreturn' function.
14511 It does not make sense for a `noreturn' function to have a return
14512 type other than `void'.
14514 The attribute `noreturn' is not implemented in GCC versions
14515 earlier than 2.5. An alternative way to declare that a function
14516 does not return, which works in the current version and in some
14517 older versions, is as follows:
14519 typedef void voidfn ();
14521 volatile voidfn fatal;
14523 This approach does not work in GNU C++.
14526 The `nothrow' attribute is used to inform the compiler that a
14527 function cannot throw an exception. For example, most functions in
14528 the standard C library can be guaranteed not to throw an exception
14529 with the notable exceptions of `qsort' and `bsearch' that take
14530 function pointer arguments. The `nothrow' attribute is not
14531 implemented in GCC versions earlier than 3.3.
14534 Many functions have no effects except the return value and their
14535 return value depends only on the parameters and/or global
14536 variables. Such a function can be subject to common subexpression
14537 elimination and loop optimization just as an arithmetic operator
14538 would be. These functions should be declared with the attribute
14539 `pure'. For example,
14541 int square (int) __attribute__ ((pure));
14543 says that the hypothetical function `square' is safe to call fewer
14544 times than the program says.
14546 Some of common examples of pure functions are `strlen' or `memcmp'.
14547 Interesting non-pure functions are functions with infinite loops
14548 or those depending on volatile memory or other system resource,
14549 that may change between two consecutive calls (such as `feof' in a
14550 multithreading environment).
14552 The attribute `pure' is not implemented in GCC versions earlier
14556 On the Intel 386, the `regparm' attribute causes the compiler to
14557 pass up to NUMBER integer arguments in registers EAX, EDX, and ECX
14558 instead of on the stack. Functions that take a variable number of
14559 arguments will continue to be passed all of their arguments on the
14562 Beware that on some ELF systems this attribute is unsuitable for
14563 global functions in shared libraries with lazy binding (which is
14564 the default). Lazy binding will send the first call via resolving
14565 code in the loader, which might assume EAX, EDX and ECX can be
14566 clobbered, as per the standard calling conventions. Solaris 8 is
14567 affected by this. GNU systems with GLIBC 2.1 or higher, and
14568 FreeBSD, are believed to be safe since the loaders there save all
14569 registers. (Lazy binding can be disabled with the linker or the
14570 loader if desired, to avoid the problem.)
14573 Use this attribute on the H8/300, H8/300H, and H8S to indicate that
14574 all registers except the stack pointer should be saved in the
14575 prologue regardless of whether they are used or not.
14577 `section ("SECTION-NAME")'
14578 Normally, the compiler places the code it generates in the `text'
14579 section. Sometimes, however, you need additional sections, or you
14580 need certain particular functions to appear in special sections.
14581 The `section' attribute specifies that a function lives in a
14582 particular section. For example, the declaration:
14584 extern void foobar (void) __attribute__ ((section ("bar")));
14586 puts the function `foobar' in the `bar' section.
14588 Some file formats do not support arbitrary sections so the
14589 `section' attribute is not available on all platforms. If you
14590 need to map the entire contents of a module to a particular
14591 section, consider using the facilities of the linker instead.
14594 This function attribute ensures that a parameter in a function
14595 call is an explicit `NULL'. The attribute is only valid on
14596 variadic functions. By default, the sentinel is located at
14597 position zero, the last parameter of the function call. If an
14598 optional integer position argument P is supplied to the attribute,
14599 the sentinel must be located at position P counting backwards from
14600 the end of the argument list.
14602 __attribute__ ((sentinel))
14604 __attribute__ ((sentinel(0)))
14606 The attribute is automatically set with a position of 0 for the
14607 built-in functions `execl' and `execlp'. The built-in function
14608 `execle' has the attribute set with a position of 1.
14610 A valid `NULL' in this context is defined as zero with any pointer
14611 type. If your system defines the `NULL' macro with an integer type
14612 then you need to add an explicit cast. GCC replaces `stddef.h'
14613 with a copy that redefines NULL appropriately.
14615 The warnings for missing or incorrect sentinels are enabled with
14619 See long_call/short_call.
14622 See longcall/shortcall.
14625 Use this attribute on the AVR to indicate that the specified
14626 function is a signal handler. The compiler will generate function
14627 entry and exit sequences suitable for use in a signal handler when
14628 this attribute is present. Interrupts will be disabled inside the
14632 Use this attribute on the SH to indicate an `interrupt_handler'
14633 function should switch to an alternate stack. It expects a string
14634 argument that names a global variable holding the address of the
14638 void f () __attribute__ ((interrupt_handler,
14639 sp_switch ("alt_stack")));
14642 On the Intel 386, the `stdcall' attribute causes the compiler to
14643 assume that the called function will pop off the stack space used
14644 to pass arguments, unless it takes a variable number of arguments.
14647 Use this attribute on the H8/300H and H8S to indicate that the
14648 specified variable should be placed into the tiny data section.
14649 The compiler will generate more efficient code for loads and stores
14650 on data in the tiny data section. Note the tiny data area is
14651 limited to slightly under 32kbytes of data.
14654 Use this attribute on the SH for an `interrupt_handler' to return
14655 using `trapa' instead of `rte'. This attribute expects an integer
14656 argument specifying the trap number to be used.
14659 This attribute, attached to a function, means that the function is
14660 meant to be possibly unused. GCC will not produce a warning for
14664 This attribute, attached to a function, means that code must be
14665 emitted for the function even if it appears that the function is
14666 not referenced. This is useful, for example, when the function is
14667 referenced only in inline assembly.
14669 `visibility ("VISIBILITY_TYPE")'
14670 The `visibility' attribute on ELF targets causes the declaration
14671 to be emitted with default, hidden, protected or internal
14674 void __attribute__ ((visibility ("protected")))
14675 f () { /* Do something. */; }
14676 int i __attribute__ ((visibility ("hidden")));
14678 See the ELF gABI for complete details, but the short story is:
14681 Default visibility is the normal case for ELF. This value is
14682 available for the visibility attribute to override other
14683 options that may change the assumed visibility of symbols.
14686 Hidden visibility indicates that the symbol will not be
14687 placed into the dynamic symbol table, so no other "module"
14688 (executable or shared library) can reference it directly.
14691 Internal visibility is like hidden visibility, but with
14692 additional processor specific semantics. Unless otherwise
14693 specified by the psABI, GCC defines internal visibility to
14694 mean that the function is _never_ called from another module.
14695 Note that hidden symbols, while they cannot be referenced
14696 directly by other modules, can be referenced indirectly via
14697 function pointers. By indicating that a symbol cannot be
14698 called from outside the module, GCC may for instance omit the
14699 load of a PIC register since it is known that the calling
14700 function loaded the correct value.
14703 Protected visibility indicates that the symbol will be placed
14704 in the dynamic symbol table, but that references within the
14705 defining module will bind to the local symbol. That is, the
14706 symbol cannot be overridden by another module.
14709 Not all ELF targets support this attribute.
14711 `warn_unused_result'
14712 The `warn_unused_result' attribute causes a warning to be emitted
14713 if a caller of the function with this attribute does not use its
14714 return value. This is useful for functions where not checking the
14715 result is either a security problem or always a bug, such as
14718 int fn () __attribute__ ((warn_unused_result));
14721 if (fn () < 0) return -1;
14726 results in warning on line 5.
14729 The `weak' attribute causes the declaration to be emitted as a weak
14730 symbol rather than a global. This is primarily useful in defining
14731 library functions which can be overridden in user code, though it
14732 can also be used with non-function declarations. Weak symbols are
14733 supported for ELF targets, and also for a.out targets when using
14734 the GNU assembler and linker.
14737 You can specify multiple attributes in a declaration by separating them
14738 by commas within the double parentheses or by immediately following an
14739 attribute declaration with another attribute declaration.
14741 Some people object to the `__attribute__' feature, suggesting that ISO
14742 C's `#pragma' should be used instead. At the time `__attribute__' was
14743 designed, there were two reasons for not doing this.
14745 1. It is impossible to generate `#pragma' commands from a macro.
14747 2. There is no telling what the same `#pragma' might mean in another
14750 These two reasons applied to almost any application that might have
14751 been proposed for `#pragma'. It was basically a mistake to use
14752 `#pragma' for _anything_.
14754 The ISO C99 standard includes `_Pragma', which now allows pragmas to
14755 be generated from macros. In addition, a `#pragma GCC' namespace is
14756 now in use for GCC-specific pragmas. However, it has been found
14757 convenient to use `__attribute__' to achieve a natural attachment of
14758 attributes to their corresponding declarations, whereas `#pragma GCC'
14759 is of use for constructs that do not naturally form part of the
14760 grammar. *Note Miscellaneous Preprocessing Directives: (cpp)Other
14764 File: gcc.info, Node: Attribute Syntax, Next: Function Prototypes, Prev: Function Attributes, Up: C Extensions
14766 5.25 Attribute Syntax
14767 =====================
14769 This section describes the syntax with which `__attribute__' may be
14770 used, and the constructs to which attribute specifiers bind, for the C
14771 language. Some details may vary for C++ and Objective-C. Because of
14772 infelicities in the grammar for attributes, some forms described here
14773 may not be successfully parsed in all cases.
14775 There are some problems with the semantics of attributes in C++. For
14776 example, there are no manglings for attributes, although they may affect
14777 code generation, so problems may arise when attributed types are used in
14778 conjunction with templates or overloading. Similarly, `typeid' does
14779 not distinguish between types with different attributes. Support for
14780 attributes in C++ may be restricted in future to attributes on
14781 declarations only, but not on nested declarators.
14783 *Note Function Attributes::, for details of the semantics of attributes
14784 applying to functions. *Note Variable Attributes::, for details of the
14785 semantics of attributes applying to variables. *Note Type Attributes::,
14786 for details of the semantics of attributes applying to structure, union
14787 and enumerated types.
14789 An "attribute specifier" is of the form `__attribute__
14790 ((ATTRIBUTE-LIST))'. An "attribute list" is a possibly empty
14791 comma-separated sequence of "attributes", where each attribute is one
14794 * Empty. Empty attributes are ignored.
14796 * A word (which may be an identifier such as `unused', or a reserved
14797 word such as `const').
14799 * A word, followed by, in parentheses, parameters for the attribute.
14800 These parameters take one of the following forms:
14802 * An identifier. For example, `mode' attributes use this form.
14804 * An identifier followed by a comma and a non-empty
14805 comma-separated list of expressions. For example, `format'
14806 attributes use this form.
14808 * A possibly empty comma-separated list of expressions. For
14809 example, `format_arg' attributes use this form with the list
14810 being a single integer constant expression, and `alias'
14811 attributes use this form with the list being a single string
14814 An "attribute specifier list" is a sequence of one or more attribute
14815 specifiers, not separated by any other tokens.
14817 In GNU C, an attribute specifier list may appear after the colon
14818 following a label, other than a `case' or `default' label. The only
14819 attribute it makes sense to use after a label is `unused'. This
14820 feature is intended for code generated by programs which contains labels
14821 that may be unused but which is compiled with `-Wall'. It would not
14822 normally be appropriate to use in it human-written code, though it
14823 could be useful in cases where the code that jumps to the label is
14824 contained within an `#ifdef' conditional. GNU C++ does not permit such
14825 placement of attribute lists, as it is permissible for a declaration,
14826 which could begin with an attribute list, to be labelled in C++.
14827 Declarations cannot be labelled in C90 or C99, so the ambiguity does
14830 An attribute specifier list may appear as part of a `struct', `union'
14831 or `enum' specifier. It may go either immediately after the `struct',
14832 `union' or `enum' keyword, or after the closing brace. It is ignored
14833 if the content of the structure, union or enumerated type is not
14834 defined in the specifier in which the attribute specifier list is
14835 used--that is, in usages such as `struct __attribute__((foo)) bar' with
14836 no following opening brace. Where attribute specifiers follow the
14837 closing brace, they are considered to relate to the structure, union or
14838 enumerated type defined, not to any enclosing declaration the type
14839 specifier appears in, and the type defined is not complete until after
14840 the attribute specifiers.
14842 Otherwise, an attribute specifier appears as part of a declaration,
14843 counting declarations of unnamed parameters and type names, and relates
14844 to that declaration (which may be nested in another declaration, for
14845 example in the case of a parameter declaration), or to a particular
14846 declarator within a declaration. Where an attribute specifier is
14847 applied to a parameter declared as a function or an array, it should
14848 apply to the function or array rather than the pointer to which the
14849 parameter is implicitly converted, but this is not yet correctly
14852 Any list of specifiers and qualifiers at the start of a declaration may
14853 contain attribute specifiers, whether or not such a list may in that
14854 context contain storage class specifiers. (Some attributes, however,
14855 are essentially in the nature of storage class specifiers, and only make
14856 sense where storage class specifiers may be used; for example,
14857 `section'.) There is one necessary limitation to this syntax: the
14858 first old-style parameter declaration in a function definition cannot
14859 begin with an attribute specifier, because such an attribute applies to
14860 the function instead by syntax described below (which, however, is not
14861 yet implemented in this case). In some other cases, attribute
14862 specifiers are permitted by this grammar but not yet supported by the
14863 compiler. All attribute specifiers in this place relate to the
14864 declaration as a whole. In the obsolescent usage where a type of `int'
14865 is implied by the absence of type specifiers, such a list of specifiers
14866 and qualifiers may be an attribute specifier list with no other
14867 specifiers or qualifiers.
14869 At present, the first parameter in a function prototype must have some
14870 type specifier which is not an attribute specifier; this resolves an
14871 ambiguity in the interpretation of `void f(int (__attribute__((foo))
14872 x))', but is subject to change. At present, if the parentheses of a
14873 function declarator contain only attributes then those attributes are
14874 ignored, rather than yielding an error or warning or implying a single
14875 parameter of type int, but this is subject to change.
14877 An attribute specifier list may appear immediately before a declarator
14878 (other than the first) in a comma-separated list of declarators in a
14879 declaration of more than one identifier using a single list of
14880 specifiers and qualifiers. Such attribute specifiers apply only to the
14881 identifier before whose declarator they appear. For example, in
14883 __attribute__((noreturn)) void d0 (void),
14884 __attribute__((format(printf, 1, 2))) d1 (const char *, ...),
14887 the `noreturn' attribute applies to all the functions declared; the
14888 `format' attribute only applies to `d1'.
14890 An attribute specifier list may appear immediately before the comma,
14891 `=' or semicolon terminating the declaration of an identifier other
14892 than a function definition. At present, such attribute specifiers apply
14893 to the declared object or function, but in future they may attach to the
14894 outermost adjacent declarator. In simple cases there is no difference,
14895 but, for example, in
14897 void (****f)(void) __attribute__((noreturn));
14899 at present the `noreturn' attribute applies to `f', which causes a
14900 warning since `f' is not a function, but in future it may apply to the
14901 function `****f'. The precise semantics of what attributes in such
14902 cases will apply to are not yet specified. Where an assembler name for
14903 an object or function is specified (*note Asm Labels::), at present the
14904 attribute must follow the `asm' specification; in future, attributes
14905 before the `asm' specification may apply to the adjacent declarator,
14906 and those after it to the declared object or function.
14908 An attribute specifier list may, in future, be permitted to appear
14909 after the declarator in a function definition (before any old-style
14910 parameter declarations or the function body).
14912 Attribute specifiers may be mixed with type qualifiers appearing inside
14913 the `[]' of a parameter array declarator, in the C99 construct by which
14914 such qualifiers are applied to the pointer to which the array is
14915 implicitly converted. Such attribute specifiers apply to the pointer,
14916 not to the array, but at present this is not implemented and they are
14919 An attribute specifier list may appear at the start of a nested
14920 declarator. At present, there are some limitations in this usage: the
14921 attributes correctly apply to the declarator, but for most individual
14922 attributes the semantics this implies are not implemented. When
14923 attribute specifiers follow the `*' of a pointer declarator, they may
14924 be mixed with any type qualifiers present. The following describes the
14925 formal semantics of this syntax. It will make the most sense if you
14926 are familiar with the formal specification of declarators in the ISO C
14929 Consider (as in C99 subclause 6.7.5 paragraph 4) a declaration `T D1',
14930 where `T' contains declaration specifiers that specify a type TYPE
14931 (such as `int') and `D1' is a declarator that contains an identifier
14932 IDENT. The type specified for IDENT for derived declarators whose type
14933 does not include an attribute specifier is as in the ISO C standard.
14935 If `D1' has the form `( ATTRIBUTE-SPECIFIER-LIST D )', and the
14936 declaration `T D' specifies the type "DERIVED-DECLARATOR-TYPE-LIST
14937 TYPE" for IDENT, then `T D1' specifies the type
14938 "DERIVED-DECLARATOR-TYPE-LIST ATTRIBUTE-SPECIFIER-LIST TYPE" for IDENT.
14940 If `D1' has the form `* TYPE-QUALIFIER-AND-ATTRIBUTE-SPECIFIER-LIST
14941 D', and the declaration `T D' specifies the type
14942 "DERIVED-DECLARATOR-TYPE-LIST TYPE" for IDENT, then `T D1' specifies
14943 the type "DERIVED-DECLARATOR-TYPE-LIST
14944 TYPE-QUALIFIER-AND-ATTRIBUTE-SPECIFIER-LIST TYPE" for IDENT.
14948 void (__attribute__((noreturn)) ****f) (void);
14950 specifies the type "pointer to pointer to pointer to pointer to
14951 non-returning function returning `void'". As another example,
14953 char *__attribute__((aligned(8))) *f;
14955 specifies the type "pointer to 8-byte-aligned pointer to `char'". Note
14956 again that this does not work with most attributes; for example, the
14957 usage of `aligned' and `noreturn' attributes given above is not yet
14960 For compatibility with existing code written for compiler versions that
14961 did not implement attributes on nested declarators, some laxity is
14962 allowed in the placing of attributes. If an attribute that only applies
14963 to types is applied to a declaration, it will be treated as applying to
14964 the type of that declaration. If an attribute that only applies to
14965 declarations is applied to the type of a declaration, it will be treated
14966 as applying to that declaration; and, for compatibility with code
14967 placing the attributes immediately before the identifier declared, such
14968 an attribute applied to a function return type will be treated as
14969 applying to the function type, and such an attribute applied to an array
14970 element type will be treated as applying to the array type. If an
14971 attribute that only applies to function types is applied to a
14972 pointer-to-function type, it will be treated as applying to the pointer
14973 target type; if such an attribute is applied to a function return type
14974 that is not a pointer-to-function type, it will be treated as applying
14975 to the function type.
14978 File: gcc.info, Node: Function Prototypes, Next: C++ Comments, Prev: Attribute Syntax, Up: C Extensions
14980 5.26 Prototypes and Old-Style Function Definitions
14981 ==================================================
14983 GNU C extends ISO C to allow a function prototype to override a later
14984 old-style non-prototype definition. Consider the following example:
14986 /* Use prototypes unless the compiler is old-fashioned. */
14993 /* Prototype function declaration. */
14994 int isroot P((uid_t));
14996 /* Old-style function definition. */
14998 isroot (x) /* ??? lossage here ??? */
15004 Suppose the type `uid_t' happens to be `short'. ISO C does not allow
15005 this example, because subword arguments in old-style non-prototype
15006 definitions are promoted. Therefore in this example the function
15007 definition's argument is really an `int', which does not match the
15008 prototype argument type of `short'.
15010 This restriction of ISO C makes it hard to write code that is portable
15011 to traditional C compilers, because the programmer does not know
15012 whether the `uid_t' type is `short', `int', or `long'. Therefore, in
15013 cases like these GNU C allows a prototype to override a later old-style
15014 definition. More precisely, in GNU C, a function prototype argument
15015 type overrides the argument type specified by a later old-style
15016 definition if the former type is the same as the latter type before
15017 promotion. Thus in GNU C the above example is equivalent to the
15020 int isroot (uid_t);
15028 GNU C++ does not support old-style function definitions, so this
15029 extension is irrelevant.
15032 File: gcc.info, Node: C++ Comments, Next: Dollar Signs, Prev: Function Prototypes, Up: C Extensions
15034 5.27 C++ Style Comments
15035 =======================
15037 In GNU C, you may use C++ style comments, which start with `//' and
15038 continue until the end of the line. Many other C implementations allow
15039 such comments, and they are included in the 1999 C standard. However,
15040 C++ style comments are not recognized if you specify an `-std' option
15041 specifying a version of ISO C before C99, or `-ansi' (equivalent to
15045 File: gcc.info, Node: Dollar Signs, Next: Character Escapes, Prev: C++ Comments, Up: C Extensions
15047 5.28 Dollar Signs in Identifier Names
15048 =====================================
15050 In GNU C, you may normally use dollar signs in identifier names. This
15051 is because many traditional C implementations allow such identifiers.
15052 However, dollar signs in identifiers are not supported on a few target
15053 machines, typically because the target assembler does not allow them.
15056 File: gcc.info, Node: Character Escapes, Next: Variable Attributes, Prev: Dollar Signs, Up: C Extensions
15058 5.29 The Character <ESC> in Constants
15059 =====================================
15061 You can use the sequence `\e' in a string or character constant to
15062 stand for the ASCII character <ESC>.
15065 File: gcc.info, Node: Alignment, Next: Inline, Prev: Type Attributes, Up: C Extensions
15067 5.30 Inquiring on Alignment of Types or Variables
15068 =================================================
15070 The keyword `__alignof__' allows you to inquire about how an object is
15071 aligned, or the minimum alignment usually required by a type. Its
15072 syntax is just like `sizeof'.
15074 For example, if the target machine requires a `double' value to be
15075 aligned on an 8-byte boundary, then `__alignof__ (double)' is 8. This
15076 is true on many RISC machines. On more traditional machine designs,
15077 `__alignof__ (double)' is 4 or even 2.
15079 Some machines never actually require alignment; they allow reference
15080 to any data type even at an odd address. For these machines,
15081 `__alignof__' reports the _recommended_ alignment of a type.
15083 If the operand of `__alignof__' is an lvalue rather than a type, its
15084 value is the required alignment for its type, taking into account any
15085 minimum alignment specified with GCC's `__attribute__' extension (*note
15086 Variable Attributes::). For example, after this declaration:
15088 struct foo { int x; char y; } foo1;
15090 the value of `__alignof__ (foo1.y)' is 1, even though its actual
15091 alignment is probably 2 or 4, the same as `__alignof__ (int)'.
15093 It is an error to ask for the alignment of an incomplete type.
15096 File: gcc.info, Node: Variable Attributes, Next: Type Attributes, Prev: Character Escapes, Up: C Extensions
15098 5.31 Specifying Attributes of Variables
15099 =======================================
15101 The keyword `__attribute__' allows you to specify special attributes of
15102 variables or structure fields. This keyword is followed by an
15103 attribute specification inside double parentheses. Some attributes are
15104 currently defined generically for variables. Other attributes are
15105 defined for variables on particular target systems. Other attributes
15106 are available for functions (*note Function Attributes::) and for types
15107 (*note Type Attributes::). Other front ends might define more
15108 attributes (*note Extensions to the C++ Language: C++ Extensions.).
15110 You may also specify attributes with `__' preceding and following each
15111 keyword. This allows you to use them in header files without being
15112 concerned about a possible macro of the same name. For example, you
15113 may use `__aligned__' instead of `aligned'.
15115 *Note Attribute Syntax::, for details of the exact syntax for using
15118 `aligned (ALIGNMENT)'
15119 This attribute specifies a minimum alignment for the variable or
15120 structure field, measured in bytes. For example, the declaration:
15122 int x __attribute__ ((aligned (16))) = 0;
15124 causes the compiler to allocate the global variable `x' on a
15125 16-byte boundary. On a 68040, this could be used in conjunction
15126 with an `asm' expression to access the `move16' instruction which
15127 requires 16-byte aligned operands.
15129 You can also specify the alignment of structure fields. For
15130 example, to create a double-word aligned `int' pair, you could
15133 struct foo { int x[2] __attribute__ ((aligned (8))); };
15135 This is an alternative to creating a union with a `double' member
15136 that forces the union to be double-word aligned.
15138 As in the preceding examples, you can explicitly specify the
15139 alignment (in bytes) that you wish the compiler to use for a given
15140 variable or structure field. Alternatively, you can leave out the
15141 alignment factor and just ask the compiler to align a variable or
15142 field to the maximum useful alignment for the target machine you
15143 are compiling for. For example, you could write:
15145 short array[3] __attribute__ ((aligned));
15147 Whenever you leave out the alignment factor in an `aligned'
15148 attribute specification, the compiler automatically sets the
15149 alignment for the declared variable or field to the largest
15150 alignment which is ever used for any data type on the target
15151 machine you are compiling for. Doing this can often make copy
15152 operations more efficient, because the compiler can use whatever
15153 instructions copy the biggest chunks of memory when performing
15154 copies to or from the variables or fields that you have aligned
15157 The `aligned' attribute can only increase the alignment; but you
15158 can decrease it by specifying `packed' as well. See below.
15160 Note that the effectiveness of `aligned' attributes may be limited
15161 by inherent limitations in your linker. On many systems, the
15162 linker is only able to arrange for variables to be aligned up to a
15163 certain maximum alignment. (For some linkers, the maximum
15164 supported alignment may be very very small.) If your linker is
15165 only able to align variables up to a maximum of 8 byte alignment,
15166 then specifying `aligned(16)' in an `__attribute__' will still
15167 only provide you with 8 byte alignment. See your linker
15168 documentation for further information.
15170 `cleanup (CLEANUP_FUNCTION)'
15171 The `cleanup' attribute runs a function when the variable goes out
15172 of scope. This attribute can only be applied to auto function
15173 scope variables; it may not be applied to parameters or variables
15174 with static storage duration. The function must take one
15175 parameter, a pointer to a type compatible with the variable. The
15176 return value of the function (if any) is ignored.
15178 If `-fexceptions' is enabled, then CLEANUP_FUNCTION will be run
15179 during the stack unwinding that happens during the processing of
15180 the exception. Note that the `cleanup' attribute does not allow
15181 the exception to be caught, only to perform an action. It is
15182 undefined what happens if CLEANUP_FUNCTION does not return
15187 The `common' attribute requests GCC to place a variable in
15188 "common" storage. The `nocommon' attribute requests the
15189 opposite--to allocate space for it directly.
15191 These attributes override the default chosen by the `-fno-common'
15192 and `-fcommon' flags respectively.
15195 The `deprecated' attribute results in a warning if the variable is
15196 used anywhere in the source file. This is useful when identifying
15197 variables that are expected to be removed in a future version of a
15198 program. The warning also includes the location of the declaration
15199 of the deprecated variable, to enable users to easily find further
15200 information about why the variable is deprecated, or what they
15201 should do instead. Note that the warning only occurs for uses:
15203 extern int old_var __attribute__ ((deprecated));
15204 extern int old_var;
15205 int new_fn () { return old_var; }
15207 results in a warning on line 3 but not line 2.
15209 The `deprecated' attribute can also be used for functions and
15210 types (*note Function Attributes::, *note Type Attributes::.)
15213 This attribute specifies the data type for the
15214 declaration--whichever type corresponds to the mode MODE. This in
15215 effect lets you request an integer or floating point type
15216 according to its width.
15218 You may also specify a mode of `byte' or `__byte__' to indicate
15219 the mode corresponding to a one-byte integer, `word' or `__word__'
15220 for the mode of a one-word integer, and `pointer' or `__pointer__'
15221 for the mode used to represent pointers.
15224 The `packed' attribute specifies that a variable or structure field
15225 should have the smallest possible alignment--one byte for a
15226 variable, and one bit for a field, unless you specify a larger
15227 value with the `aligned' attribute.
15229 Here is a structure in which the field `x' is packed, so that it
15230 immediately follows `a':
15235 int x[2] __attribute__ ((packed));
15238 `section ("SECTION-NAME")'
15239 Normally, the compiler places the objects it generates in sections
15240 like `data' and `bss'. Sometimes, however, you need additional
15241 sections, or you need certain particular variables to appear in
15242 special sections, for example to map to special hardware. The
15243 `section' attribute specifies that a variable (or function) lives
15244 in a particular section. For example, this small program uses
15245 several specific section names:
15247 struct duart a __attribute__ ((section ("DUART_A"))) = { 0 };
15248 struct duart b __attribute__ ((section ("DUART_B"))) = { 0 };
15249 char stack[10000] __attribute__ ((section ("STACK"))) = { 0 };
15250 int init_data __attribute__ ((section ("INITDATA"))) = 0;
15254 /* Initialize stack pointer */
15255 init_sp (stack + sizeof (stack));
15257 /* Initialize initialized data */
15258 memcpy (&init_data, &data, &edata - &data);
15260 /* Turn on the serial ports */
15265 Use the `section' attribute with an _initialized_ definition of a
15266 _global_ variable, as shown in the example. GCC issues a warning
15267 and otherwise ignores the `section' attribute in uninitialized
15268 variable declarations.
15270 You may only use the `section' attribute with a fully initialized
15271 global definition because of the way linkers work. The linker
15272 requires each object be defined once, with the exception that
15273 uninitialized variables tentatively go in the `common' (or `bss')
15274 section and can be multiply "defined". You can force a variable
15275 to be initialized with the `-fno-common' flag or the `nocommon'
15278 Some file formats do not support arbitrary sections so the
15279 `section' attribute is not available on all platforms. If you
15280 need to map the entire contents of a module to a particular
15281 section, consider using the facilities of the linker instead.
15284 On Microsoft Windows, in addition to putting variable definitions
15285 in a named section, the section can also be shared among all
15286 running copies of an executable or DLL. For example, this small
15287 program defines shared data by putting it in a named section
15288 `shared' and marking the section shareable:
15290 int foo __attribute__((section ("shared"), shared)) = 0;
15295 /* Read and write foo. All running
15296 copies see the same value. */
15300 You may only use the `shared' attribute along with `section'
15301 attribute with a fully initialized global definition because of
15302 the way linkers work. See `section' attribute for more
15305 The `shared' attribute is only available on Microsoft Windows.
15307 `tls_model ("TLS_MODEL")'
15308 The `tls_model' attribute sets thread-local storage model (*note
15309 Thread-Local::) of a particular `__thread' variable, overriding
15310 `-ftls-model=' command line switch on a per-variable basis. The
15311 TLS_MODEL argument should be one of `global-dynamic',
15312 `local-dynamic', `initial-exec' or `local-exec'.
15314 Not all targets support this attribute.
15316 `transparent_union'
15317 This attribute, attached to a function parameter which is a union,
15318 means that the corresponding argument may have the type of any
15319 union member, but the argument is passed as if its type were that
15320 of the first union member. For more details see *Note Type
15321 Attributes::. You can also use this attribute on a `typedef' for
15322 a union data type; then it applies to all function parameters with
15326 This attribute, attached to a variable, means that the variable is
15327 meant to be possibly unused. GCC will not produce a warning for
15330 `vector_size (BYTES)'
15331 This attribute specifies the vector size for the variable,
15332 measured in bytes. For example, the declaration:
15334 int foo __attribute__ ((vector_size (16)));
15336 causes the compiler to set the mode for `foo', to be 16 bytes,
15337 divided into `int' sized units. Assuming a 32-bit int (a vector of
15338 4 units of 4 bytes), the corresponding mode of `foo' will be V4SI.
15340 This attribute is only applicable to integral and float scalars,
15341 although arrays, pointers, and function return values are allowed
15342 in conjunction with this construct.
15344 Aggregates with this attribute are invalid, even if they are of
15345 the same size as a corresponding scalar. For example, the
15348 struct S { int a; };
15349 struct S __attribute__ ((vector_size (16))) foo;
15351 is invalid even if the size of the structure is the same as the
15355 The `weak' attribute is described in *Note Function Attributes::.
15358 The `dllimport' attribute is described in *Note Function
15362 The `dllexport' attribute is described in *Note Function
15366 5.31.1 M32R/D Variable Attributes
15367 ---------------------------------
15369 One attribute is currently defined for the M32R/D.
15371 `model (MODEL-NAME)'
15372 Use this attribute on the M32R/D to set the addressability of an
15373 object. The identifier MODEL-NAME is one of `small', `medium', or
15374 `large', representing each of the code models.
15376 Small model objects live in the lower 16MB of memory (so that their
15377 addresses can be loaded with the `ld24' instruction).
15379 Medium and large model objects may live anywhere in the 32-bit
15380 address space (the compiler will generate `seth/add3' instructions
15381 to load their addresses).
15383 5.31.2 i386 Variable Attributes
15384 -------------------------------
15386 Two attributes are currently defined for i386 configurations:
15387 `ms_struct' and `gcc_struct'
15391 If `packed' is used on a structure, or if bit-fields are used it
15392 may be that the Microsoft ABI packs them differently than GCC
15393 would normally pack them. Particularly when moving packed data
15394 between functions compiled with GCC and the native Microsoft
15395 compiler (either via function call or as data in a file), it may
15396 be necessary to access either format.
15398 Currently `-m[no-]ms-bitfields' is provided for the Microsoft
15399 Windows X86 compilers to match the native Microsoft compiler.
15401 5.31.3 Xstormy16 Variable Attributes
15402 ------------------------------------
15404 One attribute is currently defined for xstormy16 configurations:
15408 If a variable has the `below100' attribute (`BELOW100' is allowed
15409 also), GCC will place the variable in the first 0x100 bytes of
15410 memory and use special opcodes to access it. Such variables will
15411 be placed in either the `.bss_below100' section or the
15412 `.data_below100' section.
15416 File: gcc.info, Node: Type Attributes, Next: Alignment, Prev: Variable Attributes, Up: C Extensions
15418 5.32 Specifying Attributes of Types
15419 ===================================
15421 The keyword `__attribute__' allows you to specify special attributes of
15422 `struct' and `union' types when you define such types. This keyword is
15423 followed by an attribute specification inside double parentheses. Six
15424 attributes are currently defined for types: `aligned', `packed',
15425 `transparent_union', `unused', `deprecated' and `may_alias'. Other
15426 attributes are defined for functions (*note Function Attributes::) and
15427 for variables (*note Variable Attributes::).
15429 You may also specify any one of these attributes with `__' preceding
15430 and following its keyword. This allows you to use these attributes in
15431 header files without being concerned about a possible macro of the same
15432 name. For example, you may use `__aligned__' instead of `aligned'.
15434 You may specify the `aligned' and `transparent_union' attributes
15435 either in a `typedef' declaration or just past the closing curly brace
15436 of a complete enum, struct or union type _definition_ and the `packed'
15437 attribute only past the closing brace of a definition.
15439 You may also specify attributes between the enum, struct or union tag
15440 and the name of the type rather than after the closing brace.
15442 *Note Attribute Syntax::, for details of the exact syntax for using
15445 `aligned (ALIGNMENT)'
15446 This attribute specifies a minimum alignment (in bytes) for
15447 variables of the specified type. For example, the declarations:
15449 struct S { short f[3]; } __attribute__ ((aligned (8)));
15450 typedef int more_aligned_int __attribute__ ((aligned (8)));
15452 force the compiler to insure (as far as it can) that each variable
15453 whose type is `struct S' or `more_aligned_int' will be allocated
15454 and aligned _at least_ on a 8-byte boundary. On a SPARC, having
15455 all variables of type `struct S' aligned to 8-byte boundaries
15456 allows the compiler to use the `ldd' and `std' (doubleword load and
15457 store) instructions when copying one variable of type `struct S' to
15458 another, thus improving run-time efficiency.
15460 Note that the alignment of any given `struct' or `union' type is
15461 required by the ISO C standard to be at least a perfect multiple of
15462 the lowest common multiple of the alignments of all of the members
15463 of the `struct' or `union' in question. This means that you _can_
15464 effectively adjust the alignment of a `struct' or `union' type by
15465 attaching an `aligned' attribute to any one of the members of such
15466 a type, but the notation illustrated in the example above is a
15467 more obvious, intuitive, and readable way to request the compiler
15468 to adjust the alignment of an entire `struct' or `union' type.
15470 As in the preceding example, you can explicitly specify the
15471 alignment (in bytes) that you wish the compiler to use for a given
15472 `struct' or `union' type. Alternatively, you can leave out the
15473 alignment factor and just ask the compiler to align a type to the
15474 maximum useful alignment for the target machine you are compiling
15475 for. For example, you could write:
15477 struct S { short f[3]; } __attribute__ ((aligned));
15479 Whenever you leave out the alignment factor in an `aligned'
15480 attribute specification, the compiler automatically sets the
15481 alignment for the type to the largest alignment which is ever used
15482 for any data type on the target machine you are compiling for.
15483 Doing this can often make copy operations more efficient, because
15484 the compiler can use whatever instructions copy the biggest chunks
15485 of memory when performing copies to or from the variables which
15486 have types that you have aligned this way.
15488 In the example above, if the size of each `short' is 2 bytes, then
15489 the size of the entire `struct S' type is 6 bytes. The smallest
15490 power of two which is greater than or equal to that is 8, so the
15491 compiler sets the alignment for the entire `struct S' type to 8
15494 Note that although you can ask the compiler to select a
15495 time-efficient alignment for a given type and then declare only
15496 individual stand-alone objects of that type, the compiler's
15497 ability to select a time-efficient alignment is primarily useful
15498 only when you plan to create arrays of variables having the
15499 relevant (efficiently aligned) type. If you declare or use arrays
15500 of variables of an efficiently-aligned type, then it is likely
15501 that your program will also be doing pointer arithmetic (or
15502 subscripting, which amounts to the same thing) on pointers to the
15503 relevant type, and the code that the compiler generates for these
15504 pointer arithmetic operations will often be more efficient for
15505 efficiently-aligned types than for other types.
15507 The `aligned' attribute can only increase the alignment; but you
15508 can decrease it by specifying `packed' as well. See below.
15510 Note that the effectiveness of `aligned' attributes may be limited
15511 by inherent limitations in your linker. On many systems, the
15512 linker is only able to arrange for variables to be aligned up to a
15513 certain maximum alignment. (For some linkers, the maximum
15514 supported alignment may be very very small.) If your linker is
15515 only able to align variables up to a maximum of 8 byte alignment,
15516 then specifying `aligned(16)' in an `__attribute__' will still
15517 only provide you with 8 byte alignment. See your linker
15518 documentation for further information.
15521 This attribute, attached to `struct' or `union' type definition,
15522 specifies that each member of the structure or union is placed to
15523 minimize the memory required. When attached to an `enum'
15524 definition, it indicates that the smallest integral type should be
15527 Specifying this attribute for `struct' and `union' types is
15528 equivalent to specifying the `packed' attribute on each of the
15529 structure or union members. Specifying the `-fshort-enums' flag
15530 on the line is equivalent to specifying the `packed' attribute on
15531 all `enum' definitions.
15533 In the following example `struct my_packed_struct''s members are
15534 packed closely together, but the internal layout of its `s' member
15535 is not packed--to do that, `struct my_unpacked_struct' would need
15538 struct my_unpacked_struct
15544 struct my_packed_struct __attribute__ ((__packed__))
15548 struct my_unpacked_struct s;
15551 You may only specify this attribute on the definition of a `enum',
15552 `struct' or `union', not on a `typedef' which does not also define
15553 the enumerated type, structure or union.
15555 `transparent_union'
15556 This attribute, attached to a `union' type definition, indicates
15557 that any function parameter having that union type causes calls to
15558 that function to be treated in a special way.
15560 First, the argument corresponding to a transparent union type can
15561 be of any type in the union; no cast is required. Also, if the
15562 union contains a pointer type, the corresponding argument can be a
15563 null pointer constant or a void pointer expression; and if the
15564 union contains a void pointer type, the corresponding argument can
15565 be any pointer expression. If the union member type is a pointer,
15566 qualifiers like `const' on the referenced type must be respected,
15567 just as with normal pointer conversions.
15569 Second, the argument is passed to the function using the calling
15570 conventions of the first member of the transparent union, not the
15571 calling conventions of the union itself. All members of the union
15572 must have the same machine representation; this is necessary for
15573 this argument passing to work properly.
15575 Transparent unions are designed for library functions that have
15576 multiple interfaces for compatibility reasons. For example,
15577 suppose the `wait' function must accept either a value of type
15578 `int *' to comply with Posix, or a value of type `union wait *' to
15579 comply with the 4.1BSD interface. If `wait''s parameter were
15580 `void *', `wait' would accept both kinds of arguments, but it
15581 would also accept any other pointer type and this would make
15582 argument type checking less useful. Instead, `<sys/wait.h>' might
15583 define the interface as follows:
15589 } wait_status_ptr_t __attribute__ ((__transparent_union__));
15591 pid_t wait (wait_status_ptr_t);
15593 This interface allows either `int *' or `union wait *' arguments
15594 to be passed, using the `int *' calling convention. The program
15595 can call `wait' with arguments of either type:
15597 int w1 () { int w; return wait (&w); }
15598 int w2 () { union wait w; return wait (&w); }
15600 With this interface, `wait''s implementation might look like this:
15602 pid_t wait (wait_status_ptr_t p)
15604 return waitpid (-1, p.__ip, 0);
15608 When attached to a type (including a `union' or a `struct'), this
15609 attribute means that variables of that type are meant to appear
15610 possibly unused. GCC will not produce a warning for any variables
15611 of that type, even if the variable appears to do nothing. This is
15612 often the case with lock or thread classes, which are usually
15613 defined and then not referenced, but contain constructors and
15614 destructors that have nontrivial bookkeeping functions.
15617 The `deprecated' attribute results in a warning if the type is
15618 used anywhere in the source file. This is useful when identifying
15619 types that are expected to be removed in a future version of a
15620 program. If possible, the warning also includes the location of
15621 the declaration of the deprecated type, to enable users to easily
15622 find further information about why the type is deprecated, or what
15623 they should do instead. Note that the warnings only occur for
15624 uses and then only if the type is being applied to an identifier
15625 that itself is not being declared as deprecated.
15627 typedef int T1 __attribute__ ((deprecated));
15631 typedef T1 T3 __attribute__ ((deprecated));
15632 T3 z __attribute__ ((deprecated));
15634 results in a warning on line 2 and 3 but not lines 4, 5, or 6. No
15635 warning is issued for line 4 because T2 is not explicitly
15636 deprecated. Line 5 has no warning because T3 is explicitly
15637 deprecated. Similarly for line 6.
15639 The `deprecated' attribute can also be used for functions and
15640 variables (*note Function Attributes::, *note Variable
15644 Accesses to objects with types with this attribute are not
15645 subjected to type-based alias analysis, but are instead assumed to
15646 be able to alias any other type of objects, just like the `char'
15647 type. See `-fstrict-aliasing' for more information on aliasing
15652 typedef short __attribute__((__may_alias__)) short_a;
15657 int a = 0x12345678;
15658 short_a *b = (short_a *) &a;
15662 if (a == 0x12345678)
15668 If you replaced `short_a' with `short' in the variable
15669 declaration, the above program would abort when compiled with
15670 `-fstrict-aliasing', which is on by default at `-O2' or above in
15671 recent GCC versions.
15673 5.32.1 ARM Type Attributes
15674 --------------------------
15676 On those ARM targets that support `dllimport' (such as Symbian
15677 OS), you can use the `notshared' attribute to indicate that the virtual
15678 table and other similar data for a class should not be exported from a
15681 class __declspec(notshared) C {
15683 __declspec(dllimport) C();
15687 __declspec(dllexport)
15690 In this code, `C::C' is exported from the current DLL, but the
15691 virtual table for `C' is not exported. (You can use `__attribute__'
15692 instead of `__declspec' if you prefer, but most Symbian OS code uses
15695 5.32.2 i386 Type Attributes
15696 ---------------------------
15698 Two attributes are currently defined for i386 configurations:
15699 `ms_struct' and `gcc_struct'
15703 If `packed' is used on a structure, or if bit-fields are used it
15704 may be that the Microsoft ABI packs them differently than GCC
15705 would normally pack them. Particularly when moving packed data
15706 between functions compiled with GCC and the native Microsoft
15707 compiler (either via function call or as data in a file), it may
15708 be necessary to access either format.
15710 Currently `-m[no-]ms-bitfields' is provided for the Microsoft
15711 Windows X86 compilers to match the native Microsoft compiler.
15713 To specify multiple attributes, separate them by commas within the
15714 double parentheses: for example, `__attribute__ ((aligned (16),
15718 File: gcc.info, Node: Inline, Next: Extended Asm, Prev: Alignment, Up: C Extensions
15720 5.33 An Inline Function is As Fast As a Macro
15721 =============================================
15723 By declaring a function `inline', you can direct GCC to integrate that
15724 function's code into the code for its callers. This makes execution
15725 faster by eliminating the function-call overhead; in addition, if any
15726 of the actual argument values are constant, their known values may
15727 permit simplifications at compile time so that not all of the inline
15728 function's code needs to be included. The effect on code size is less
15729 predictable; object code may be larger or smaller with function
15730 inlining, depending on the particular case. Inlining of functions is an
15731 optimization and it really "works" only in optimizing compilation. If
15732 you don't use `-O', no function is really inline.
15734 Inline functions are included in the ISO C99 standard, but there are
15735 currently substantial differences between what GCC implements and what
15736 the ISO C99 standard requires.
15738 To declare a function inline, use the `inline' keyword in its
15739 declaration, like this:
15747 (If you are writing a header file to be included in ISO C programs,
15748 write `__inline__' instead of `inline'. *Note Alternate Keywords::.)
15749 You can also make all "simple enough" functions inline with the option
15750 `-finline-functions'.
15752 Note that certain usages in a function definition can make it
15753 unsuitable for inline substitution. Among these usages are: use of
15754 varargs, use of alloca, use of variable sized data types (*note
15755 Variable Length::), use of computed goto (*note Labels as Values::),
15756 use of nonlocal goto, and nested functions (*note Nested Functions::).
15757 Using `-Winline' will warn when a function marked `inline' could not be
15758 substituted, and will give the reason for the failure.
15760 Note that in C and Objective-C, unlike C++, the `inline' keyword does
15761 not affect the linkage of the function.
15763 GCC automatically inlines member functions defined within the class
15764 body of C++ programs even if they are not explicitly declared `inline'.
15765 (You can override this with `-fno-default-inline'; *note Options
15766 Controlling C++ Dialect: C++ Dialect Options.)
15768 When a function is both inline and `static', if all calls to the
15769 function are integrated into the caller, and the function's address is
15770 never used, then the function's own assembler code is never referenced.
15771 In this case, GCC does not actually output assembler code for the
15772 function, unless you specify the option `-fkeep-inline-functions'.
15773 Some calls cannot be integrated for various reasons (in particular,
15774 calls that precede the function's definition cannot be integrated, and
15775 neither can recursive calls within the definition). If there is a
15776 nonintegrated call, then the function is compiled to assembler code as
15777 usual. The function must also be compiled as usual if the program
15778 refers to its address, because that can't be inlined.
15780 When an inline function is not `static', then the compiler must assume
15781 that there may be calls from other source files; since a global symbol
15782 can be defined only once in any program, the function must not be
15783 defined in the other source files, so the calls therein cannot be
15784 integrated. Therefore, a non-`static' inline function is always
15785 compiled on its own in the usual fashion.
15787 If you specify both `inline' and `extern' in the function definition,
15788 then the definition is used only for inlining. In no case is the
15789 function compiled on its own, not even if you refer to its address
15790 explicitly. Such an address becomes an external reference, as if you
15791 had only declared the function, and had not defined it.
15793 This combination of `inline' and `extern' has almost the effect of a
15794 macro. The way to use it is to put a function definition in a header
15795 file with these keywords, and put another copy of the definition
15796 (lacking `inline' and `extern') in a library file. The definition in
15797 the header file will cause most calls to the function to be inlined.
15798 If any uses of the function remain, they will refer to the single copy
15801 Since GCC eventually will implement ISO C99 semantics for inline
15802 functions, it is best to use `static inline' only to guarantee
15803 compatibility. (The existing semantics will remain available when
15804 `-std=gnu89' is specified, but eventually the default will be
15805 `-std=gnu99' and that will implement the C99 semantics, though it does
15808 GCC does not inline any functions when not optimizing unless you
15809 specify the `always_inline' attribute for the function, like this:
15812 inline void foo (const char) __attribute__((always_inline));
15815 File: gcc.info, Node: Extended Asm, Next: Constraints, Prev: Inline, Up: C Extensions
15817 5.34 Assembler Instructions with C Expression Operands
15818 ======================================================
15820 In an assembler instruction using `asm', you can specify the operands
15821 of the instruction using C expressions. This means you need not guess
15822 which registers or memory locations will contain the data you want to
15825 You must specify an assembler instruction template much like what
15826 appears in a machine description, plus an operand constraint string for
15829 For example, here is how to use the 68881's `fsinx' instruction:
15831 asm ("fsinx %1,%0" : "=f" (result) : "f" (angle));
15833 Here `angle' is the C expression for the input operand while `result'
15834 is that of the output operand. Each has `"f"' as its operand
15835 constraint, saying that a floating point register is required. The `='
15836 in `=f' indicates that the operand is an output; all output operands'
15837 constraints must use `='. The constraints use the same language used
15838 in the machine description (*note Constraints::).
15840 Each operand is described by an operand-constraint string followed by
15841 the C expression in parentheses. A colon separates the assembler
15842 template from the first output operand and another separates the last
15843 output operand from the first input, if any. Commas separate the
15844 operands within each group. The total number of operands is currently
15845 limited to 30; this limitation may be lifted in some future version of
15848 If there are no output operands but there are input operands, you must
15849 place two consecutive colons surrounding the place where the output
15852 As of GCC version 3.1, it is also possible to specify input and output
15853 operands using symbolic names which can be referenced within the
15854 assembler code. These names are specified inside square brackets
15855 preceding the constraint string, and can be referenced inside the
15856 assembler code using `%[NAME]' instead of a percentage sign followed by
15857 the operand number. Using named operands the above example could look
15860 asm ("fsinx %[angle],%[output]"
15861 : [output] "=f" (result)
15862 : [angle] "f" (angle));
15864 Note that the symbolic operand names have no relation whatsoever to
15865 other C identifiers. You may use any name you like, even those of
15866 existing C symbols, but you must ensure that no two operands within the
15867 same assembler construct use the same symbolic name.
15869 Output operand expressions must be lvalues; the compiler can check
15870 this. The input operands need not be lvalues. The compiler cannot
15871 check whether the operands have data types that are reasonable for the
15872 instruction being executed. It does not parse the assembler instruction
15873 template and does not know what it means or even whether it is valid
15874 assembler input. The extended `asm' feature is most often used for
15875 machine instructions the compiler itself does not know exist. If the
15876 output expression cannot be directly addressed (for example, it is a
15877 bit-field), your constraint must allow a register. In that case, GCC
15878 will use the register as the output of the `asm', and then store that
15879 register into the output.
15881 The ordinary output operands must be write-only; GCC will assume that
15882 the values in these operands before the instruction are dead and need
15883 not be generated. Extended asm supports input-output or read-write
15884 operands. Use the constraint character `+' to indicate such an operand
15885 and list it with the output operands. You should only use read-write
15886 operands when the constraints for the operand (or the operand in which
15887 only some of the bits are to be changed) allow a register.
15889 You may, as an alternative, logically split its function into two
15890 separate operands, one input operand and one write-only output operand.
15891 The connection between them is expressed by constraints which say they
15892 need to be in the same location when the instruction executes. You can
15893 use the same C expression for both operands, or different expressions.
15894 For example, here we write the (fictitious) `combine' instruction with
15895 `bar' as its read-only source operand and `foo' as its read-write
15898 asm ("combine %2,%0" : "=r" (foo) : "0" (foo), "g" (bar));
15900 The constraint `"0"' for operand 1 says that it must occupy the same
15901 location as operand 0. A number in constraint is allowed only in an
15902 input operand and it must refer to an output operand.
15904 Only a number in the constraint can guarantee that one operand will be
15905 in the same place as another. The mere fact that `foo' is the value of
15906 both operands is not enough to guarantee that they will be in the same
15907 place in the generated assembler code. The following would not work
15910 asm ("combine %2,%0" : "=r" (foo) : "r" (foo), "g" (bar));
15912 Various optimizations or reloading could cause operands 0 and 1 to be
15913 in different registers; GCC knows no reason not to do so. For example,
15914 the compiler might find a copy of the value of `foo' in one register and
15915 use it for operand 1, but generate the output operand 0 in a different
15916 register (copying it afterward to `foo''s own address). Of course,
15917 since the register for operand 1 is not even mentioned in the assembler
15918 code, the result will not work, but GCC can't tell that.
15920 As of GCC version 3.1, one may write `[NAME]' instead of the operand
15921 number for a matching constraint. For example:
15923 asm ("cmoveq %1,%2,%[result]"
15924 : [result] "=r"(result)
15925 : "r" (test), "r"(new), "[result]"(old));
15927 Sometimes you need to make an `asm' operand be a specific register,
15928 but there's no matching constraint letter for that register _by
15929 itself_. To force the operand into that register, use a local variable
15930 for the operand and specify the register in the variable declaration.
15931 *Note Explicit Reg Vars::. Then for the `asm' operand, use any
15932 register constraint letter that matches the register:
15934 register int *p1 asm ("r0") = ...;
15935 register int *p2 asm ("r1") = ...;
15936 register int *result asm ("r0");
15937 asm ("sysint" : "=r" (result) : "0" (p1), "r" (p2));
15939 In the above example, beware that a register that is call-clobbered by
15940 the target ABI will be overwritten by any function call in the
15941 assignment, including library calls for arithmetic operators. Assuming
15942 it is a call-clobbered register, this may happen to `r0' above by the
15943 assignment to `p2'. If you have to use such a register, use temporary
15944 variables for expressions between the register assignment and use:
15947 register int *p1 asm ("r0") = ...;
15948 register int *p2 asm ("r1") = t1;
15949 register int *result asm ("r0");
15950 asm ("sysint" : "=r" (result) : "0" (p1), "r" (p2));
15952 Some instructions clobber specific hard registers. To describe this,
15953 write a third colon after the input operands, followed by the names of
15954 the clobbered hard registers (given as strings). Here is a realistic
15955 example for the VAX:
15957 asm volatile ("movc3 %0,%1,%2"
15959 : "g" (from), "g" (to), "g" (count)
15960 : "r0", "r1", "r2", "r3", "r4", "r5");
15962 You may not write a clobber description in a way that overlaps with an
15963 input or output operand. For example, you may not have an operand
15964 describing a register class with one member if you mention that register
15965 in the clobber list. Variables declared to live in specific registers
15966 (*note Explicit Reg Vars::), and used as asm input or output operands
15967 must have no part mentioned in the clobber description. There is no
15968 way for you to specify that an input operand is modified without also
15969 specifying it as an output operand. Note that if all the output
15970 operands you specify are for this purpose (and hence unused), you will
15971 then also need to specify `volatile' for the `asm' construct, as
15972 described below, to prevent GCC from deleting the `asm' statement as
15975 If you refer to a particular hardware register from the assembler code,
15976 you will probably have to list the register after the third colon to
15977 tell the compiler the register's value is modified. In some assemblers,
15978 the register names begin with `%'; to produce one `%' in the assembler
15979 code, you must write `%%' in the input.
15981 If your assembler instruction can alter the condition code register,
15982 add `cc' to the list of clobbered registers. GCC on some machines
15983 represents the condition codes as a specific hardware register; `cc'
15984 serves to name this register. On other machines, the condition code is
15985 handled differently, and specifying `cc' has no effect. But it is
15986 valid no matter what the machine.
15988 If your assembler instructions access memory in an unpredictable
15989 fashion, add `memory' to the list of clobbered registers. This will
15990 cause GCC to not keep memory values cached in registers across the
15991 assembler instruction and not optimize stores or loads to that memory.
15992 You will also want to add the `volatile' keyword if the memory affected
15993 is not listed in the inputs or outputs of the `asm', as the `memory'
15994 clobber does not count as a side-effect of the `asm'. If you know how
15995 large the accessed memory is, you can add it as input or output but if
15996 this is not known, you should add `memory'. As an example, if you
15997 access ten bytes of a string, you can use a memory input like:
15999 {"m"( ({ struct { char x[10]; } *p = (void *)ptr ; *p; }) )}.
16001 Note that in the following example the memory input is necessary,
16002 otherwise GCC might optimize the store to `x' away:
16008 asm ("magic stuff accessing an 'int' pointed to by '%1'"
16009 "=&d" (r) : "a" (y), "m" (*y));
16013 You can put multiple assembler instructions together in a single `asm'
16014 template, separated by the characters normally used in assembly code
16015 for the system. A combination that works in most places is a newline
16016 to break the line, plus a tab character to move to the instruction field
16017 (written as `\n\t'). Sometimes semicolons can be used, if the
16018 assembler allows semicolons as a line-breaking character. Note that
16019 some assembler dialects use semicolons to start a comment. The input
16020 operands are guaranteed not to use any of the clobbered registers, and
16021 neither will the output operands' addresses, so you can read and write
16022 the clobbered registers as many times as you like. Here is an example
16023 of multiple instructions in a template; it assumes the subroutine
16024 `_foo' accepts arguments in registers 9 and 10:
16026 asm ("movl %0,r9\n\tmovl %1,r10\n\tcall _foo"
16028 : "g" (from), "g" (to)
16031 Unless an output operand has the `&' constraint modifier, GCC may
16032 allocate it in the same register as an unrelated input operand, on the
16033 assumption the inputs are consumed before the outputs are produced.
16034 This assumption may be false if the assembler code actually consists of
16035 more than one instruction. In such a case, use `&' for each output
16036 operand that may not overlap an input. *Note Modifiers::.
16038 If you want to test the condition code produced by an assembler
16039 instruction, you must include a branch and a label in the `asm'
16040 construct, as follows:
16042 asm ("clr %0\n\tfrob %1\n\tbeq 0f\n\tmov #1,%0\n0:"
16046 This assumes your assembler supports local labels, as the GNU assembler
16047 and most Unix assemblers do.
16049 Speaking of labels, jumps from one `asm' to another are not supported.
16050 The compiler's optimizers do not know about these jumps, and therefore
16051 they cannot take account of them when deciding how to optimize.
16053 Usually the most convenient way to use these `asm' instructions is to
16054 encapsulate them in macros that look like functions. For example,
16057 ({ double __value, __arg = (x); \
16058 asm ("fsinx %1,%0": "=f" (__value): "f" (__arg)); \
16061 Here the variable `__arg' is used to make sure that the instruction
16062 operates on a proper `double' value, and to accept only those arguments
16063 `x' which can convert automatically to a `double'.
16065 Another way to make sure the instruction operates on the correct data
16066 type is to use a cast in the `asm'. This is different from using a
16067 variable `__arg' in that it converts more different types. For
16068 example, if the desired type were `int', casting the argument to `int'
16069 would accept a pointer with no complaint, while assigning the argument
16070 to an `int' variable named `__arg' would warn about using a pointer
16071 unless the caller explicitly casts it.
16073 If an `asm' has output operands, GCC assumes for optimization purposes
16074 the instruction has no side effects except to change the output
16075 operands. This does not mean instructions with a side effect cannot be
16076 used, but you must be careful, because the compiler may eliminate them
16077 if the output operands aren't used, or move them out of loops, or
16078 replace two with one if they constitute a common subexpression. Also,
16079 if your instruction does have a side effect on a variable that otherwise
16080 appears not to change, the old value of the variable may be reused later
16081 if it happens to be found in a register.
16083 You can prevent an `asm' instruction from being deleted by writing the
16084 keyword `volatile' after the `asm'. For example:
16086 #define get_and_set_priority(new) \
16088 asm volatile ("get_and_set_priority %0, %1" \
16089 : "=g" (__old) : "g" (new)); \
16092 The `volatile' keyword indicates that the instruction has important
16093 side-effects. GCC will not delete a volatile `asm' if it is reachable.
16094 (The instruction can still be deleted if GCC can prove that
16095 control-flow will never reach the location of the instruction.) Note
16096 that even a volatile `asm' instruction can be moved relative to other
16097 code, including across jump instructions. For example, on many targets
16098 there is a system register which can be set to control the rounding
16099 mode of floating point operations. You might try setting it with a
16100 volatile `asm', like this PowerPC example:
16102 asm volatile("mtfsf 255,%0" : : "f" (fpenv));
16105 This will not work reliably, as the compiler may move the addition back
16106 before the volatile `asm'. To make it work you need to add an
16107 artificial dependency to the `asm' referencing a variable in the code
16108 you don't want moved, for example:
16110 asm volatile ("mtfsf 255,%1" : "=X"(sum): "f"(fpenv));
16113 Similarly, you can't expect a sequence of volatile `asm' instructions
16114 to remain perfectly consecutive. If you want consecutive output, use a
16115 single `asm'. Also, GCC will perform some optimizations across a
16116 volatile `asm' instruction; GCC does not "forget everything" when it
16117 encounters a volatile `asm' instruction the way some other compilers do.
16119 An `asm' instruction without any output operands will be treated
16120 identically to a volatile `asm' instruction.
16122 It is a natural idea to look for a way to give access to the condition
16123 code left by the assembler instruction. However, when we attempted to
16124 implement this, we found no way to make it work reliably. The problem
16125 is that output operands might need reloading, which would result in
16126 additional following "store" instructions. On most machines, these
16127 instructions would alter the condition code before there was time to
16128 test it. This problem doesn't arise for ordinary "test" and "compare"
16129 instructions because they don't have any output operands.
16131 For reasons similar to those described above, it is not possible to
16132 give an assembler instruction access to the condition code left by
16133 previous instructions.
16135 If you are writing a header file that should be includable in ISO C
16136 programs, write `__asm__' instead of `asm'. *Note Alternate Keywords::.
16138 5.34.1 Size of an `asm'
16139 -----------------------
16141 Some targets require that GCC track the size of each instruction used in
16142 order to generate correct code. Because the final length of an `asm'
16143 is only known by the assembler, GCC must make an estimate as to how big
16144 it will be. The estimate is formed by counting the number of
16145 statements in the pattern of the `asm' and multiplying that by the
16146 length of the longest instruction on that processor. Statements in the
16147 `asm' are identified by newline characters and whatever statement
16148 separator characters are supported by the assembler; on most processors
16149 this is the ``;'' character.
16151 Normally, GCC's estimate is perfectly adequate to ensure that correct
16152 code is generated, but it is possible to confuse the compiler if you use
16153 pseudo instructions or assembler macros that expand into multiple real
16154 instructions or if you use assembler directives that expand to more
16155 space in the object file than would be needed for a single instruction.
16156 If this happens then the assembler will produce a diagnostic saying that
16157 a label is unreachable.
16159 5.34.2 i386 floating point asm operands
16160 ---------------------------------------
16162 There are several rules on the usage of stack-like regs in asm_operands
16163 insns. These rules apply only to the operands that are stack-like regs:
16165 1. Given a set of input regs that die in an asm_operands, it is
16166 necessary to know which are implicitly popped by the asm, and
16167 which must be explicitly popped by gcc.
16169 An input reg that is implicitly popped by the asm must be
16170 explicitly clobbered, unless it is constrained to match an output
16173 2. For any input reg that is implicitly popped by an asm, it is
16174 necessary to know how to adjust the stack to compensate for the
16175 pop. If any non-popped input is closer to the top of the
16176 reg-stack than the implicitly popped reg, it would not be possible
16177 to know what the stack looked like--it's not clear how the rest of
16178 the stack "slides up".
16180 All implicitly popped input regs must be closer to the top of the
16181 reg-stack than any input that is not implicitly popped.
16183 It is possible that if an input dies in an insn, reload might use
16184 the input reg for an output reload. Consider this example:
16186 asm ("foo" : "=t" (a) : "f" (b));
16188 This asm says that input B is not popped by the asm, and that the
16189 asm pushes a result onto the reg-stack, i.e., the stack is one
16190 deeper after the asm than it was before. But, it is possible that
16191 reload will think that it can use the same reg for both the input
16192 and the output, if input B dies in this insn.
16194 If any input operand uses the `f' constraint, all output reg
16195 constraints must use the `&' earlyclobber.
16197 The asm above would be written as
16199 asm ("foo" : "=&t" (a) : "f" (b));
16201 3. Some operands need to be in particular places on the stack. All
16202 output operands fall in this category--there is no other way to
16203 know which regs the outputs appear in unless the user indicates
16204 this in the constraints.
16206 Output operands must specifically indicate which reg an output
16207 appears in after an asm. `=f' is not allowed: the operand
16208 constraints must select a class with a single reg.
16210 4. Output operands may not be "inserted" between existing stack regs.
16211 Since no 387 opcode uses a read/write operand, all output operands
16212 are dead before the asm_operands, and are pushed by the
16213 asm_operands. It makes no sense to push anywhere but the top of
16216 Output operands must start at the top of the reg-stack: output
16217 operands may not "skip" a reg.
16219 5. Some asm statements may need extra stack space for internal
16220 calculations. This can be guaranteed by clobbering stack registers
16221 unrelated to the inputs and outputs.
16224 Here are a couple of reasonable asms to want to write. This asm takes
16225 one input, which is internally popped, and produces two outputs.
16227 asm ("fsincos" : "=t" (cos), "=u" (sin) : "0" (inp));
16229 This asm takes two inputs, which are popped by the `fyl2xp1' opcode,
16230 and replaces them with one output. The user must code the `st(1)'
16231 clobber for reg-stack.c to know that `fyl2xp1' pops both inputs.
16233 asm ("fyl2xp1" : "=t" (result) : "0" (x), "u" (y) : "st(1)");
16236 File: gcc.info, Node: Constraints, Next: Asm Labels, Prev: Extended Asm, Up: C Extensions
16238 5.35 Constraints for `asm' Operands
16239 ===================================
16241 Here are specific details on what constraint letters you can use with
16242 `asm' operands. Constraints can say whether an operand may be in a
16243 register, and which kinds of register; whether the operand can be a
16244 memory reference, and which kinds of address; whether the operand may
16245 be an immediate constant, and which possible values it may have.
16246 Constraints can also require two operands to match.
16250 * Simple Constraints:: Basic use of constraints.
16251 * Multi-Alternative:: When an insn has two alternative constraint-patterns.
16252 * Modifiers:: More precise control over effects of constraints.
16253 * Machine Constraints:: Special constraints for some particular machines.
16256 File: gcc.info, Node: Simple Constraints, Next: Multi-Alternative, Up: Constraints
16258 5.35.1 Simple Constraints
16259 -------------------------
16261 The simplest kind of constraint is a string full of letters, each of
16262 which describes one kind of operand that is permitted. Here are the
16263 letters that are allowed:
16266 Whitespace characters are ignored and can be inserted at any
16267 position except the first. This enables each alternative for
16268 different operands to be visually aligned in the machine
16269 description even if they have different number of constraints and
16273 A memory operand is allowed, with any kind of address that the
16274 machine supports in general.
16277 A memory operand is allowed, but only if the address is
16278 "offsettable". This means that adding a small integer (actually,
16279 the width in bytes of the operand, as determined by its machine
16280 mode) may be added to the address and the result is also a valid
16283 For example, an address which is constant is offsettable; so is an
16284 address that is the sum of a register and a constant (as long as a
16285 slightly larger constant is also within the range of
16286 address-offsets supported by the machine); but an autoincrement or
16287 autodecrement address is not offsettable. More complicated
16288 indirect/indexed addresses may or may not be offsettable depending
16289 on the other addressing modes that the machine supports.
16291 Note that in an output operand which can be matched by another
16292 operand, the constraint letter `o' is valid only when accompanied
16293 by both `<' (if the target machine has predecrement addressing)
16294 and `>' (if the target machine has preincrement addressing).
16297 A memory operand that is not offsettable. In other words,
16298 anything that would fit the `m' constraint but not the `o'
16302 A memory operand with autodecrement addressing (either
16303 predecrement or postdecrement) is allowed.
16306 A memory operand with autoincrement addressing (either
16307 preincrement or postincrement) is allowed.
16310 A register operand is allowed provided that it is in a general
16314 An immediate integer operand (one with constant value) is allowed.
16315 This includes symbolic constants whose values will be known only at
16316 assembly time or later.
16319 An immediate integer operand with a known numeric value is allowed.
16320 Many systems cannot support assembly-time constants for operands
16321 less than a word wide. Constraints for these operands should use
16322 `n' rather than `i'.
16324 `I', `J', `K', ... `P'
16325 Other letters in the range `I' through `P' may be defined in a
16326 machine-dependent fashion to permit immediate integer operands with
16327 explicit integer values in specified ranges. For example, on the
16328 68000, `I' is defined to stand for the range of values 1 to 8.
16329 This is the range permitted as a shift count in the shift
16333 An immediate floating operand (expression code `const_double') is
16334 allowed, but only if the target floating point format is the same
16335 as that of the host machine (on which the compiler is running).
16338 An immediate floating operand (expression code `const_double' or
16339 `const_vector') is allowed.
16342 `G' and `H' may be defined in a machine-dependent fashion to
16343 permit immediate floating operands in particular ranges of values.
16346 An immediate integer operand whose value is not an explicit
16347 integer is allowed.
16349 This might appear strange; if an insn allows a constant operand
16350 with a value not known at compile time, it certainly must allow
16351 any known value. So why use `s' instead of `i'? Sometimes it
16352 allows better code to be generated.
16354 For example, on the 68000 in a fullword instruction it is possible
16355 to use an immediate operand; but if the immediate value is between
16356 -128 and 127, better code results from loading the value into a
16357 register and using the register. This is because the load into
16358 the register can be done with a `moveq' instruction. We arrange
16359 for this to happen by defining the letter `K' to mean "any integer
16360 outside the range -128 to 127", and then specifying `Ks' in the
16361 operand constraints.
16364 Any register, memory or immediate integer operand is allowed,
16365 except for registers that are not general registers.
16368 Any operand whatsoever is allowed.
16370 `0', `1', `2', ... `9'
16371 An operand that matches the specified operand number is allowed.
16372 If a digit is used together with letters within the same
16373 alternative, the digit should come last.
16375 This number is allowed to be more than a single digit. If multiple
16376 digits are encountered consecutively, they are interpreted as a
16377 single decimal integer. There is scant chance for ambiguity,
16378 since to-date it has never been desirable that `10' be interpreted
16379 as matching either operand 1 _or_ operand 0. Should this be
16380 desired, one can use multiple alternatives instead.
16382 This is called a "matching constraint" and what it really means is
16383 that the assembler has only a single operand that fills two roles
16384 which `asm' distinguishes. For example, an add instruction uses
16385 two input operands and an output operand, but on most CISC
16386 machines an add instruction really has only two operands, one of
16387 them an input-output operand:
16391 Matching constraints are used in these circumstances. More
16392 precisely, the two operands that match must include one input-only
16393 operand and one output-only operand. Moreover, the digit must be a
16394 smaller number than the number of the operand that uses it in the
16398 An operand that is a valid memory address is allowed. This is for
16399 "load address" and "push address" instructions.
16401 `p' in the constraint must be accompanied by `address_operand' as
16402 the predicate in the `match_operand'. This predicate interprets
16403 the mode specified in the `match_operand' as the mode of the memory
16404 reference for which the address would be valid.
16407 Other letters can be defined in machine-dependent fashion to stand
16408 for particular classes of registers or other arbitrary operand
16409 types. `d', `a' and `f' are defined on the 68000/68020 to stand
16410 for data, address and floating point registers.
16414 File: gcc.info, Node: Multi-Alternative, Next: Modifiers, Prev: Simple Constraints, Up: Constraints
16416 5.35.2 Multiple Alternative Constraints
16417 ---------------------------------------
16419 Sometimes a single instruction has multiple alternative sets of possible
16420 operands. For example, on the 68000, a logical-or instruction can
16421 combine register or an immediate value into memory, or it can combine
16422 any kind of operand into a register; but it cannot combine one memory
16423 location into another.
16425 These constraints are represented as multiple alternatives. An
16426 alternative can be described by a series of letters for each operand.
16427 The overall constraint for an operand is made from the letters for this
16428 operand from the first alternative, a comma, the letters for this
16429 operand from the second alternative, a comma, and so on until the last
16432 If all the operands fit any one alternative, the instruction is valid.
16433 Otherwise, for each alternative, the compiler counts how many
16434 instructions must be added to copy the operands so that that
16435 alternative applies. The alternative requiring the least copying is
16436 chosen. If two alternatives need the same amount of copying, the one
16437 that comes first is chosen. These choices can be altered with the `?'
16438 and `!' characters:
16441 Disparage slightly the alternative that the `?' appears in, as a
16442 choice when no alternative applies exactly. The compiler regards
16443 this alternative as one unit more costly for each `?' that appears
16447 Disparage severely the alternative that the `!' appears in. This
16448 alternative can still be used if it fits without reloading, but if
16449 reloading is needed, some other alternative will be used.
16452 File: gcc.info, Node: Modifiers, Next: Machine Constraints, Prev: Multi-Alternative, Up: Constraints
16454 5.35.3 Constraint Modifier Characters
16455 -------------------------------------
16457 Here are constraint modifier characters.
16460 Means that this operand is write-only for this instruction: the
16461 previous value is discarded and replaced by output data.
16464 Means that this operand is both read and written by the
16467 When the compiler fixes up the operands to satisfy the constraints,
16468 it needs to know which operands are inputs to the instruction and
16469 which are outputs from it. `=' identifies an output; `+'
16470 identifies an operand that is both input and output; all other
16471 operands are assumed to be input only.
16473 If you specify `=' or `+' in a constraint, you put it in the first
16474 character of the constraint string.
16477 Means (in a particular alternative) that this operand is an
16478 "earlyclobber" operand, which is modified before the instruction is
16479 finished using the input operands. Therefore, this operand may
16480 not lie in a register that is used as an input operand or as part
16481 of any memory address.
16483 `&' applies only to the alternative in which it is written. In
16484 constraints with multiple alternatives, sometimes one alternative
16485 requires `&' while others do not. See, for example, the `movdf'
16488 An input operand can be tied to an earlyclobber operand if its only
16489 use as an input occurs before the early result is written. Adding
16490 alternatives of this form often allows GCC to produce better code
16491 when only some of the inputs can be affected by the earlyclobber.
16492 See, for example, the `mulsi3' insn of the ARM.
16494 `&' does not obviate the need to write `='.
16497 Declares the instruction to be commutative for this operand and the
16498 following operand. This means that the compiler may interchange
16499 the two operands if that is the cheapest way to make all operands
16500 fit the constraints. GCC can only handle one commutative pair in
16501 an asm; if you use more, the compiler may fail. Note that you
16502 need not use the modifier if the two alternatives are strictly
16503 identical; this would only waste time in the reload pass.
16506 Says that all following characters, up to the next comma, are to be
16507 ignored as a constraint. They are significant only for choosing
16508 register preferences.
16511 Says that the following character should be ignored when choosing
16512 register preferences. `*' has no effect on the meaning of the
16513 constraint as a constraint, and no effect on reloading.
16517 File: gcc.info, Node: Machine Constraints, Prev: Modifiers, Up: Constraints
16519 5.35.4 Constraints for Particular Machines
16520 ------------------------------------------
16522 Whenever possible, you should use the general-purpose constraint letters
16523 in `asm' arguments, since they will convey meaning more readily to
16524 people reading your code. Failing that, use the constraint letters
16525 that usually have very similar meanings across architectures. The most
16526 commonly used constraints are `m' and `r' (for memory and
16527 general-purpose registers respectively; *note Simple Constraints::), and
16528 `I', usually the letter indicating the most common immediate-constant
16531 For each machine architecture, the `config/MACHINE/MACHINE.h' file
16532 defines additional constraints. These constraints are used by the
16533 compiler itself for instruction generation, as well as for `asm'
16534 statements; therefore, some of the constraints are not particularly
16535 interesting for `asm'. The constraints are defined through these
16538 `REG_CLASS_FROM_LETTER'
16539 Register class constraints (usually lowercase).
16541 `CONST_OK_FOR_LETTER_P'
16542 Immediate constant constraints, for non-floating point constants of
16543 word size or smaller precision (usually uppercase).
16545 `CONST_DOUBLE_OK_FOR_LETTER_P'
16546 Immediate constant constraints, for all floating point constants
16547 and for constants of greater than word size precision (usually
16551 Special cases of registers or memory. This macro is not required,
16552 and is only defined for some machines.
16554 Inspecting these macro definitions in the compiler source for your
16555 machine is the best way to be certain you have the right constraints.
16556 However, here is a summary of the machine-dependent constraints
16557 available on some particular machines.
16559 _ARM family--`arm.h'_
16562 Floating-point register
16565 VFP floating-point register
16568 One of the floating-point constants 0.0, 0.5, 1.0, 2.0, 3.0,
16572 Floating-point constant that would satisfy the constraint `F'
16576 Integer that is valid as an immediate operand in a data
16577 processing instruction. That is, an integer in the range 0
16578 to 255 rotated by a multiple of 2
16581 Integer in the range -4095 to 4095
16584 Integer that satisfies constraint `I' when inverted (ones
16588 Integer that satisfies constraint `I' when negated (twos
16592 Integer in the range 0 to 32
16595 A memory reference where the exact address is in a single
16596 register (``m'' is preferable for `asm' statements)
16599 An item in the constant pool
16602 A symbol in the text segment of the current file
16605 A memory reference suitable for VFP load/store insns (reg+constant
16609 A memory reference suitable for iWMMXt load/store instructions.
16612 A memory reference suitable for the ARMv4 ldrsb instruction.
16614 _AVR family--`avr.h'_
16617 Registers from r0 to r15
16620 Registers from r16 to r23
16623 Registers from r16 to r31
16626 Registers from r24 to r31. These registers can be used in
16630 Pointer register (r26-r31)
16633 Base pointer register (r28-r31)
16636 Stack pointer register (SPH:SPL)
16639 Temporary register r0
16642 Register pair X (r27:r26)
16645 Register pair Y (r29:r28)
16648 Register pair Z (r31:r30)
16651 Constant greater than -1, less than 64
16654 Constant greater than -64, less than 1
16663 Constant that fits in 8 bits
16666 Constant integer -1
16669 Constant integer 8, 16, or 24
16675 A floating point constant 0.0
16677 _PowerPC and IBM RS6000--`rs6000.h'_
16680 Address base register
16683 Floating point register
16689 `MQ', `CTR', or `LINK' register
16701 `CR' register (condition register) number 0
16704 `CR' register (condition register)
16707 `FPMEM' stack memory for FPR-GPR transfers
16710 Signed 16-bit constant
16713 Unsigned 16-bit constant shifted left 16 bits (use `L'
16714 instead for `SImode' constants)
16717 Unsigned 16-bit constant
16720 Signed 16-bit constant shifted left 16 bits
16723 Constant larger than 31
16732 Constant whose negation is a signed 16-bit constant
16735 Floating point constant that can be loaded into a register
16736 with one instruction per word
16739 Memory operand that is an offset from a register (`m' is
16740 preferable for `asm' statements)
16746 Constant suitable as a 64-bit mask operand
16749 Constant suitable as a 32-bit mask operand
16752 System V Release 4 small data area reference
16754 _Intel 386--`i386.h'_
16757 `a', `b', `c', or `d' register for the i386. For x86-64 it
16758 is equivalent to `r' class (for 8-bit instructions that do
16759 not use upper halves).
16762 `a', `b', `c', or `d' register (for 8-bit instructions, that
16763 do use upper halves).
16766 Legacy register--equivalent to `r' class in i386 mode. (for
16767 non-8-bit registers used together with 8-bit upper halves in
16768 a single instruction)
16771 Specifies the `a' or `d' registers. This is primarily useful
16772 for 64-bit integer values (when in 32-bit mode) intended to
16773 be returned with the `d' register holding the most
16774 significant bits and the `a' register holding the least
16778 Floating point register
16781 First (top of stack) floating point register
16784 Second floating point register
16796 Specifies constant that can be easily constructed in SSE
16797 register without loading it from memory.
16815 Constant in range 0 to 31 (for 32-bit shifts)
16818 Constant in range 0 to 63 (for 64-bit shifts)
16827 0, 1, 2, or 3 (shifts for `lea' instruction)
16830 Constant in range 0 to 255 (for `out' instruction)
16833 Constant in range 0 to `0xffffffff' or symbolic reference
16834 known to fit specified range. (for using immediates in zero
16835 extending 32-bit to 64-bit x86-64 instructions)
16838 Constant in range -2147483648 to 2147483647 or symbolic
16839 reference known to fit specified range. (for using
16840 immediates in 64-bit x86-64 instructions)
16843 Standard 80387 floating point constant
16845 _Intel IA-64--`ia64.h'_
16848 General register `r0' to `r3' for `addl' instruction
16854 Predicate register (`c' as in "conditional")
16857 Application register residing in M-unit
16860 Application register residing in I-unit
16863 Floating-point register
16866 Memory operand. Remember that `m' allows postincrement and
16867 postdecrement which require printing with `%Pn' on IA-64.
16868 Use `S' to disallow postincrement and postdecrement.
16871 Floating-point constant 0.0 or 1.0
16874 14-bit signed integer constant
16877 22-bit signed integer constant
16880 8-bit signed integer constant for logical instructions
16883 8-bit adjusted signed integer constant for compare pseudo-ops
16886 6-bit unsigned integer constant for shift counts
16889 9-bit signed integer constant for load and store
16896 0 or -1 for `dep' instruction
16899 Non-volatile memory for floating-point loads and stores
16902 Integer constant in the range 1 to 4 for `shladd' instruction
16905 Memory operand except postincrement and postdecrement
16910 Register in the class `ACC_REGS' (`acc0' to `acc7').
16913 Register in the class `EVEN_ACC_REGS' (`acc0' to `acc7').
16916 Register in the class `CC_REGS' (`fcc0' to `fcc3' and `icc0'
16920 Register in the class `GPR_REGS' (`gr0' to `gr63').
16923 Register in the class `EVEN_REGS' (`gr0' to `gr63'). Odd
16924 registers are excluded not in the class but through the use
16925 of a machine mode larger than 4 bytes.
16928 Register in the class `FPR_REGS' (`fr0' to `fr63').
16931 Register in the class `FEVEN_REGS' (`fr0' to `fr63'). Odd
16932 registers are excluded not in the class but through the use
16933 of a machine mode larger than 4 bytes.
16936 Register in the class `LR_REG' (the `lr' register).
16939 Register in the class `QUAD_REGS' (`gr2' to `gr63').
16940 Register numbers not divisible by 4 are excluded not in the
16941 class but through the use of a machine mode larger than 8
16945 Register in the class `ICC_REGS' (`icc0' to `icc3').
16948 Register in the class `FCC_REGS' (`fcc0' to `fcc3').
16951 Register in the class `ICR_REGS' (`cc4' to `cc7').
16954 Register in the class `FCR_REGS' (`cc0' to `cc3').
16957 Register in the class `QUAD_FPR_REGS' (`fr0' to `fr63').
16958 Register numbers not divisible by 4 are excluded not in the
16959 class but through the use of a machine mode larger than 8
16963 Register in the class `SPR_REGS' (`lcr' and `lr').
16966 Register in the class `QUAD_ACC_REGS' (`acc0' to `acc7').
16969 Register in the class `ACCG_REGS' (`accg0' to `accg7').
16972 Register in the class `CR_REGS' (`cc0' to `cc7').
16975 Floating point constant zero
16978 6-bit signed integer constant
16981 10-bit signed integer constant
16984 16-bit signed integer constant
16987 16-bit unsigned integer constant
16990 12-bit signed integer constant that is negative--i.e. in the
16991 range of -2048 to -1
16997 12-bit signed integer constant that is greater than
16998 zero--i.e. in the range of 1 to 2047.
17004 `DP' or `IP' registers (general address)
17028 `DP' or `SP' registers (offsettable address)
17031 Non-pointer registers (not `SP', `DP', `IP')
17034 Non-SP registers (everything except `SP')
17037 Indirect through `IP'--Avoid this except for `QImode', since
17038 we can't access extra bytes
17041 Indirect through `SP' or `DP' with short displacement (0..127)
17044 Data-section immediate value
17047 Integers from -255 to -1
17050 Integers from 0 to 7--valid bit number in a register
17053 Integers from 0 to 127--valid displacement for addressing mode
17056 Integers from 1 to 127
17068 Integers from 0 to 255
17073 General-purpose integer register
17076 Floating-point register (if available)
17085 `Hi' or `Lo' register
17088 General-purpose integer register
17091 Floating-point status register
17094 Signed 16-bit constant (for arithmetic instructions)
17100 Zero-extended 16-bit constant (for logic instructions)
17103 Constant with low 16 bits zero (can be loaded with `lui')
17106 32-bit constant which requires two instructions to load (a
17107 constant which is not `I', `K', or `L')
17110 Negative 16-bit constant
17116 Positive 16-bit constant
17119 Floating point zero
17122 Memory reference that can be loaded with more than one
17123 instruction (`m' is preferable for `asm' statements)
17126 Memory reference that can be loaded with one instruction (`m'
17127 is preferable for `asm' statements)
17130 Memory reference in external OSF/rose PIC format (`m' is
17131 preferable for `asm' statements)
17133 _Motorola 680x0--`m68k.h'_
17142 68881 floating-point register, if available
17145 Integer in the range 1 to 8
17148 16-bit signed number
17151 Signed number whose magnitude is greater than 0x80
17154 Integer in the range -8 to -1
17157 Signed number whose magnitude is greater than 0x100
17160 Floating point constant that is not a 68881 constant
17162 _Motorola 68HC11 & 68HC12 families--`m68hc11.h'_
17177 Temporary soft register _.tmp
17180 A soft register _.d1 to _.d31
17183 Stack pointer register
17192 Pseudo register `z' (replaced by `x' or `y' at the end)
17195 An address register: x, y or z
17198 An address register: x or y
17201 Register pair (x:d) to form a 32-bit value
17204 Constants in the range -65536 to 65535
17207 Constants whose 16-bit low part is zero
17210 Constant integer 1 or -1
17213 Constant integer 16
17216 Constants in the range -8 to 2
17222 Floating-point register on the SPARC-V8 architecture and
17223 lower floating-point register on the SPARC-V9 architecture.
17226 Floating-point register. It is equivalent to `f' on the
17227 SPARC-V8 architecture and contains both lower and upper
17228 floating-point registers on the SPARC-V9 architecture.
17231 Floating-point condition code register.
17234 Lower floating-point register. It is only valid on the
17235 SPARC-V9 architecture when the Visual Instruction Set is
17239 Floating-point register. It is only valid on the SPARC-V9
17240 architecture when the Visual Instruction Set is available.
17243 64-bit global or out register for the SPARC-V8+ architecture.
17246 Signed 13-bit constant
17252 32-bit constant with the low 12 bits clear (a constant that
17253 can be loaded with the `sethi' instruction)
17256 A constant in the range supported by `movcc' instructions
17259 A constant in the range supported by `movrcc' instructions
17262 Same as `K', except that it verifies that bits that are not
17263 in the lower 32-bit range are all zero. Must be used instead
17264 of `K' for modes wider than `SImode'
17270 Floating-point zero
17273 Signed 13-bit constant, sign-extended to 32 or 64 bits
17276 Floating-point constant whose integral representation can be
17277 moved into an integer register using a single sethi
17281 Floating-point constant whose integral representation can be
17282 moved into an integer register using a single mov instruction
17285 Floating-point constant whose integral representation can be
17286 moved into an integer register using a high/lo_sum
17287 instruction sequence
17290 Memory address aligned to an 8-byte boundary
17296 Memory address for `e' constraint registers
17302 _TMS320C3x/C4x--`c4x.h'_
17305 Auxiliary (address) register (ar0-ar7)
17308 Stack pointer register (sp)
17311 Standard (32-bit) precision integer register
17314 Extended (40-bit) precision register (r0-r11)
17317 Block count register (bk)
17320 Extended (40-bit) precision low register (r0-r7)
17323 Extended (40-bit) precision register (r0-r1)
17326 Extended (40-bit) precision register (r2-r3)
17329 Repeat count register (rc)
17332 Index register (ir0-ir1)
17335 Status (condition code) register (st)
17338 Data page register (dp)
17341 Floating-point zero
17344 Immediate 16-bit floating-point constant
17347 Signed 16-bit constant
17350 Signed 8-bit constant
17353 Signed 5-bit constant
17356 Unsigned 16-bit constant
17359 Unsigned 8-bit constant
17362 Ones complement of unsigned 16-bit constant
17365 High 16-bit constant (32-bit constant with 16 LSBs zero)
17368 Indirect memory reference with signed 8-bit or index register
17372 Indirect memory reference with unsigned 5-bit displacement
17375 Indirect memory reference with 1 bit or index register
17379 Direct memory reference
17385 _S/390 and zSeries--`s390.h'_
17388 Address register (general purpose register except r0)
17391 Condition code register
17394 Data register (arbitrary general purpose register)
17397 Floating-point register
17400 Unsigned 8-bit constant (0-255)
17403 Unsigned 12-bit constant (0-4095)
17406 Signed 16-bit constant (-32768-32767)
17409 Value appropriate as displacement.
17411 for short displacement
17413 `(-524288..524287)'
17414 for long displacement
17417 Constant integer with a value of 0x7fffffff.
17420 Multiple letter constraint followed by 4 parameter letters.
17422 number of the part counting from most to least
17429 mode of the containing operand
17432 value of the other parts (F--all bits set)
17433 The constraint matches if the specified part of a constant
17434 has a value different from it's other parts.
17437 Memory reference without index register and with short
17441 Memory reference with index register and short displacement.
17444 Memory reference without index register but with long
17448 Memory reference with index register and long displacement.
17451 Pointer with short displacement.
17454 Pointer with long displacement.
17457 Shift count operand.
17460 _Xstormy16--`stormy16.h'_
17475 Registers r0 through r7.
17478 Registers r0 and r1.
17481 The carry register.
17484 Registers r8 and r9.
17487 A constant between 0 and 3 inclusive.
17490 A constant that has exactly one bit set.
17493 A constant that has exactly one bit clear.
17496 A constant between 0 and 255 inclusive.
17499 A constant between -255 and 0 inclusive.
17502 A constant between -3 and 0 inclusive.
17505 A constant between 1 and 4 inclusive.
17508 A constant between -4 and -1 inclusive.
17511 A memory reference that is a stack push.
17514 A memory reference that is a stack pop.
17517 A memory reference that refers to a constant address of known
17521 The register indicated by Rx (not implemented yet).
17524 A constant that is not between 2 and 15 inclusive.
17530 _Xtensa--`xtensa.h'_
17533 General-purpose 32-bit register
17536 One-bit boolean register
17539 MAC16 40-bit accumulator register
17542 Signed 12-bit integer constant, for use in MOVI instructions
17545 Signed 8-bit integer constant, for use in ADDI instructions
17548 Integer constant valid for BccI instructions
17551 Unsigned constant valid for BccUI instructions
17556 File: gcc.info, Node: Asm Labels, Next: Explicit Reg Vars, Prev: Constraints, Up: C Extensions
17558 5.36 Controlling Names Used in Assembler Code
17559 =============================================
17561 You can specify the name to be used in the assembler code for a C
17562 function or variable by writing the `asm' (or `__asm__') keyword after
17563 the declarator as follows:
17565 int foo asm ("myfoo") = 2;
17567 This specifies that the name to be used for the variable `foo' in the
17568 assembler code should be `myfoo' rather than the usual `_foo'.
17570 On systems where an underscore is normally prepended to the name of a C
17571 function or variable, this feature allows you to define names for the
17572 linker that do not start with an underscore.
17574 It does not make sense to use this feature with a non-static local
17575 variable since such variables do not have assembler names. If you are
17576 trying to put the variable in a particular register, see *Note Explicit
17577 Reg Vars::. GCC presently accepts such code with a warning, but will
17578 probably be changed to issue an error, rather than a warning, in the
17581 You cannot use `asm' in this way in a function _definition_; but you
17582 can get the same effect by writing a declaration for the function
17583 before its definition and putting `asm' there, like this:
17585 extern func () asm ("FUNC");
17591 It is up to you to make sure that the assembler names you choose do not
17592 conflict with any other assembler symbols. Also, you must not use a
17593 register name; that would produce completely invalid assembler code.
17594 GCC does not as yet have the ability to store static variables in
17595 registers. Perhaps that will be added.
17598 File: gcc.info, Node: Explicit Reg Vars, Next: Alternate Keywords, Prev: Asm Labels, Up: C Extensions
17600 5.37 Variables in Specified Registers
17601 =====================================
17603 GNU C allows you to put a few global variables into specified hardware
17604 registers. You can also specify the register in which an ordinary
17605 register variable should be allocated.
17607 * Global register variables reserve registers throughout the program.
17608 This may be useful in programs such as programming language
17609 interpreters which have a couple of global variables that are
17610 accessed very often.
17612 * Local register variables in specific registers do not reserve the
17613 registers, except at the point where they are used as input or
17614 output operands in an `asm' statement and the `asm' statement
17615 itself is not deleted. The compiler's data flow analysis is
17616 capable of determining where the specified registers contain live
17617 values, and where they are available for other uses. Stores into
17618 local register variables may be deleted when they appear to be
17619 dead according to dataflow analysis. References to local register
17620 variables may be deleted or moved or simplified.
17622 These local variables are sometimes convenient for use with the
17623 extended `asm' feature (*note Extended Asm::), if you want to
17624 write one output of the assembler instruction directly into a
17625 particular register. (This will work provided the register you
17626 specify fits the constraints specified for that operand in the
17631 * Global Reg Vars::
17635 File: gcc.info, Node: Global Reg Vars, Next: Local Reg Vars, Up: Explicit Reg Vars
17637 5.37.1 Defining Global Register Variables
17638 -----------------------------------------
17640 You can define a global register variable in GNU C like this:
17642 register int *foo asm ("a5");
17644 Here `a5' is the name of the register which should be used. Choose a
17645 register which is normally saved and restored by function calls on your
17646 machine, so that library routines will not clobber it.
17648 Naturally the register name is cpu-dependent, so you would need to
17649 conditionalize your program according to cpu type. The register `a5'
17650 would be a good choice on a 68000 for a variable of pointer type. On
17651 machines with register windows, be sure to choose a "global" register
17652 that is not affected magically by the function call mechanism.
17654 In addition, operating systems on one type of cpu may differ in how
17655 they name the registers; then you would need additional conditionals.
17656 For example, some 68000 operating systems call this register `%a5'.
17658 Eventually there may be a way of asking the compiler to choose a
17659 register automatically, but first we need to figure out how it should
17660 choose and how to enable you to guide the choice. No solution is
17663 Defining a global register variable in a certain register reserves that
17664 register entirely for this use, at least within the current compilation.
17665 The register will not be allocated for any other purpose in the
17666 functions in the current compilation. The register will not be saved
17667 and restored by these functions. Stores into this register are never
17668 deleted even if they would appear to be dead, but references may be
17669 deleted or moved or simplified.
17671 It is not safe to access the global register variables from signal
17672 handlers, or from more than one thread of control, because the system
17673 library routines may temporarily use the register for other things
17674 (unless you recompile them specially for the task at hand).
17676 It is not safe for one function that uses a global register variable to
17677 call another such function `foo' by way of a third function `lose' that
17678 was compiled without knowledge of this variable (i.e. in a different
17679 source file in which the variable wasn't declared). This is because
17680 `lose' might save the register and put some other value there. For
17681 example, you can't expect a global register variable to be available in
17682 the comparison-function that you pass to `qsort', since `qsort' might
17683 have put something else in that register. (If you are prepared to
17684 recompile `qsort' with the same global register variable, you can solve
17687 If you want to recompile `qsort' or other source files which do not
17688 actually use your global register variable, so that they will not use
17689 that register for any other purpose, then it suffices to specify the
17690 compiler option `-ffixed-REG'. You need not actually add a global
17691 register declaration to their source code.
17693 A function which can alter the value of a global register variable
17694 cannot safely be called from a function compiled without this variable,
17695 because it could clobber the value the caller expects to find there on
17696 return. Therefore, the function which is the entry point into the part
17697 of the program that uses the global register variable must explicitly
17698 save and restore the value which belongs to its caller.
17700 On most machines, `longjmp' will restore to each global register
17701 variable the value it had at the time of the `setjmp'. On some
17702 machines, however, `longjmp' will not change the value of global
17703 register variables. To be portable, the function that called `setjmp'
17704 should make other arrangements to save the values of the global register
17705 variables, and to restore them in a `longjmp'. This way, the same
17706 thing will happen regardless of what `longjmp' does.
17708 All global register variable declarations must precede all function
17709 definitions. If such a declaration could appear after function
17710 definitions, the declaration would be too late to prevent the register
17711 from being used for other purposes in the preceding functions.
17713 Global register variables may not have initial values, because an
17714 executable file has no means to supply initial contents for a register.
17716 On the SPARC, there are reports that g3 ... g7 are suitable registers,
17717 but certain library functions, such as `getwd', as well as the
17718 subroutines for division and remainder, modify g3 and g4. g1 and g2
17719 are local temporaries.
17721 On the 68000, a2 ... a5 should be suitable, as should d2 ... d7. Of
17722 course, it will not do to use more than a few of those.
17725 File: gcc.info, Node: Local Reg Vars, Prev: Global Reg Vars, Up: Explicit Reg Vars
17727 5.37.2 Specifying Registers for Local Variables
17728 -----------------------------------------------
17730 You can define a local register variable with a specified register like
17733 register int *foo asm ("a5");
17735 Here `a5' is the name of the register which should be used. Note that
17736 this is the same syntax used for defining global register variables,
17737 but for a local variable it would appear within a function.
17739 Naturally the register name is cpu-dependent, but this is not a
17740 problem, since specific registers are most often useful with explicit
17741 assembler instructions (*note Extended Asm::). Both of these things
17742 generally require that you conditionalize your program according to cpu
17745 In addition, operating systems on one type of cpu may differ in how
17746 they name the registers; then you would need additional conditionals.
17747 For example, some 68000 operating systems call this register `%a5'.
17749 Defining such a register variable does not reserve the register; it
17750 remains available for other uses in places where flow control determines
17751 the variable's value is not live.
17753 This option does not guarantee that GCC will generate code that has
17754 this variable in the register you specify at all times. You may not
17755 code an explicit reference to this register in the _assembler
17756 instruction template_ part of an `asm' statement and assume it will
17757 always refer to this variable. However, using the variable as an `asm'
17758 _operand_ guarantees that the specified register is used for the
17761 Stores into local register variables may be deleted when they appear
17762 to be dead according to dataflow analysis. References to local
17763 register variables may be deleted or moved or simplified.
17765 As for global register variables, it's recommended that you choose a
17766 register which is normally saved and restored by function calls on your
17767 machine, so that library routines will not clobber it. A common
17768 pitfall is to initialize multiple call-clobbered registers with
17769 arbitrary expressions, where a function call or library call for an
17770 arithmetic operator will overwrite a register value from a previous
17771 assignment, for example `r0' below:
17772 register int *p1 asm ("r0") = ...;
17773 register int *p2 asm ("r1") = ...;
17774 In those cases, a solution is to use a temporary variable for each
17775 arbitrary expression. *Note Example of asm with clobbered asm reg::.
17778 File: gcc.info, Node: Alternate Keywords, Next: Incomplete Enums, Prev: Explicit Reg Vars, Up: C Extensions
17780 5.38 Alternate Keywords
17781 =======================
17783 `-ansi' and the various `-std' options disable certain keywords. This
17784 causes trouble when you want to use GNU C extensions, or a
17785 general-purpose header file that should be usable by all programs,
17786 including ISO C programs. The keywords `asm', `typeof' and `inline'
17787 are not available in programs compiled with `-ansi' or `-std' (although
17788 `inline' can be used in a program compiled with `-std=c99'). The ISO
17789 C99 keyword `restrict' is only available when `-std=gnu99' (which will
17790 eventually be the default) or `-std=c99' (or the equivalent
17791 `-std=iso9899:1999') is used.
17793 The way to solve these problems is to put `__' at the beginning and
17794 end of each problematical keyword. For example, use `__asm__' instead
17795 of `asm', and `__inline__' instead of `inline'.
17797 Other C compilers won't accept these alternative keywords; if you want
17798 to compile with another compiler, you can define the alternate keywords
17799 as macros to replace them with the customary keywords. It looks like
17803 #define __asm__ asm
17806 `-pedantic' and other options cause warnings for many GNU C extensions.
17807 You can prevent such warnings within one expression by writing
17808 `__extension__' before the expression. `__extension__' has no effect
17812 File: gcc.info, Node: Incomplete Enums, Next: Function Names, Prev: Alternate Keywords, Up: C Extensions
17814 5.39 Incomplete `enum' Types
17815 ============================
17817 You can define an `enum' tag without specifying its possible values.
17818 This results in an incomplete type, much like what you get if you write
17819 `struct foo' without describing the elements. A later declaration
17820 which does specify the possible values completes the type.
17822 You can't allocate variables or storage using the type while it is
17823 incomplete. However, you can work with pointers to that type.
17825 This extension may not be very useful, but it makes the handling of
17826 `enum' more consistent with the way `struct' and `union' are handled.
17828 This extension is not supported by GNU C++.
17831 File: gcc.info, Node: Function Names, Next: Return Address, Prev: Incomplete Enums, Up: C Extensions
17833 5.40 Function Names as Strings
17834 ==============================
17836 GCC provides three magic variables which hold the name of the current
17837 function, as a string. The first of these is `__func__', which is part
17838 of the C99 standard:
17840 The identifier `__func__' is implicitly declared by the translator
17841 as if, immediately following the opening brace of each function
17842 definition, the declaration
17843 static const char __func__[] = "function-name";
17845 appeared, where function-name is the name of the lexically-enclosing
17846 function. This name is the unadorned name of the function.
17848 `__FUNCTION__' is another name for `__func__'. Older versions of GCC
17849 recognize only this name. However, it is not standardized. For
17850 maximum portability, we recommend you use `__func__', but provide a
17851 fallback definition with the preprocessor:
17853 #if __STDC_VERSION__ < 199901L
17855 # define __func__ __FUNCTION__
17857 # define __func__ "<unknown>"
17861 In C, `__PRETTY_FUNCTION__' is yet another name for `__func__'.
17862 However, in C++, `__PRETTY_FUNCTION__' contains the type signature of
17863 the function as well as its bare name. For example, this program:
17866 extern int printf (char *, ...);
17873 printf ("__FUNCTION__ = %s\n", __FUNCTION__);
17874 printf ("__PRETTY_FUNCTION__ = %s\n", __PRETTY_FUNCTION__);
17889 __PRETTY_FUNCTION__ = void a::sub(int)
17891 These identifiers are not preprocessor macros. In GCC 3.3 and
17892 earlier, in C only, `__FUNCTION__' and `__PRETTY_FUNCTION__' were
17893 treated as string literals; they could be used to initialize `char'
17894 arrays, and they could be concatenated with other string literals. GCC
17895 3.4 and later treat them as variables, like `__func__'. In C++,
17896 `__FUNCTION__' and `__PRETTY_FUNCTION__' have always been variables.
17899 File: gcc.info, Node: Return Address, Next: Vector Extensions, Prev: Function Names, Up: C Extensions
17901 5.41 Getting the Return or Frame Address of a Function
17902 ======================================================
17904 These functions may be used to get information about the callers of a
17907 -- Built-in Function: void * __builtin_return_address (unsigned int
17909 This function returns the return address of the current function,
17910 or of one of its callers. The LEVEL argument is number of frames
17911 to scan up the call stack. A value of `0' yields the return
17912 address of the current function, a value of `1' yields the return
17913 address of the caller of the current function, and so forth. When
17914 inlining the expected behavior is that the function will return
17915 the address of the function that will be returned to. To work
17916 around this behavior use the `noinline' function attribute.
17918 The LEVEL argument must be a constant integer.
17920 On some machines it may be impossible to determine the return
17921 address of any function other than the current one; in such cases,
17922 or when the top of the stack has been reached, this function will
17923 return `0' or a random value. In addition,
17924 `__builtin_frame_address' may be used to determine if the top of
17925 the stack has been reached.
17927 This function should only be used with a nonzero argument for
17928 debugging purposes.
17930 -- Built-in Function: void * __builtin_frame_address (unsigned int
17932 This function is similar to `__builtin_return_address', but it
17933 returns the address of the function frame rather than the return
17934 address of the function. Calling `__builtin_frame_address' with a
17935 value of `0' yields the frame address of the current function, a
17936 value of `1' yields the frame address of the caller of the current
17937 function, and so forth.
17939 The frame is the area on the stack which holds local variables and
17940 saved registers. The frame address is normally the address of the
17941 first word pushed on to the stack by the function. However, the
17942 exact definition depends upon the processor and the calling
17943 convention. If the processor has a dedicated frame pointer
17944 register, and the function has a frame, then
17945 `__builtin_frame_address' will return the value of the frame
17948 On some machines it may be impossible to determine the frame
17949 address of any function other than the current one; in such cases,
17950 or when the top of the stack has been reached, this function will
17951 return `0' if the first frame pointer is properly initialized by
17954 This function should only be used with a nonzero argument for
17955 debugging purposes.
17958 File: gcc.info, Node: Vector Extensions, Next: Offsetof, Prev: Return Address, Up: C Extensions
17960 5.42 Using vector instructions through built-in functions
17961 =========================================================
17963 On some targets, the instruction set contains SIMD vector instructions
17964 that operate on multiple values contained in one large register at the
17965 same time. For example, on the i386 the MMX, 3Dnow! and SSE extensions
17966 can be used this way.
17968 The first step in using these extensions is to provide the necessary
17969 data types. This should be done using an appropriate `typedef':
17971 typedef int v4si __attribute__ ((vector_size (16)));
17973 The `int' type specifies the base type, while the attribute specifies
17974 the vector size for the variable, measured in bytes. For example, the
17975 declaration above causes the compiler to set the mode for the `v4si'
17976 type to be 16 bytes wide and divided into `int' sized units. For a
17977 32-bit `int' this means a vector of 4 units of 4 bytes, and the
17978 corresponding mode of `foo' will be V4SI.
17980 The `vector_size' attribute is only applicable to integral and float
17981 scalars, although arrays, pointers, and function return values are
17982 allowed in conjunction with this construct.
17984 All the basic integer types can be used as base types, both as signed
17985 and as unsigned: `char', `short', `int', `long', `long long'. In
17986 addition, `float' and `double' can be used to build floating-point
17989 Specifying a combination that is not valid for the current architecture
17990 will cause GCC to synthesize the instructions using a narrower mode.
17991 For example, if you specify a variable of type `V4SI' and your
17992 architecture does not allow for this specific SIMD type, GCC will
17993 produce code that uses 4 `SIs'.
17995 The types defined in this manner can be used with a subset of normal C
17996 operations. Currently, GCC will allow using the following operators on
17997 these types: `+, -, *, /, unary minus, ^, |, &, ~'.
17999 The operations behave like C++ `valarrays'. Addition is defined as
18000 the addition of the corresponding elements of the operands. For
18001 example, in the code below, each of the 4 elements in A will be added
18002 to the corresponding 4 elements in B and the resulting vector will be
18005 typedef int v4si __attribute__ ((vector_size (16)));
18011 Subtraction, multiplication, division, and the logical operations
18012 operate in a similar manner. Likewise, the result of using the unary
18013 minus or complement operators on a vector type is a vector whose
18014 elements are the negative or complemented values of the corresponding
18015 elements in the operand.
18017 You can declare variables and use them in function calls and returns,
18018 as well as in assignments and some casts. You can specify a vector
18019 type as a return type for a function. Vector types can also be used as
18020 function arguments. It is possible to cast from one vector type to
18021 another, provided they are of the same size (in fact, you can also cast
18022 vectors to and from other datatypes of the same size).
18024 You cannot operate between vectors of different lengths or different
18025 signedness without a cast.
18027 A port that supports hardware vector operations, usually provides a set
18028 of built-in functions that can be used to operate on vectors. For
18029 example, a function to add two vectors and multiply the result by a
18030 third could look like this:
18032 v4si f (v4si a, v4si b, v4si c)
18034 v4si tmp = __builtin_addv4si (a, b);
18035 return __builtin_mulv4si (tmp, c);
18039 File: gcc.info, Node: Offsetof, Next: Other Builtins, Prev: Vector Extensions, Up: C Extensions
18044 GCC implements for both C and C++ a syntactic extension to implement
18045 the `offsetof' macro.
18048 "__builtin_offsetof" "(" `typename' "," offsetof_member_designator ")"
18050 offsetof_member_designator:
18052 | offsetof_member_designator "." `identifier'
18053 | offsetof_member_designator "[" `expr' "]"
18055 This extension is sufficient such that
18057 #define offsetof(TYPE, MEMBER) __builtin_offsetof (TYPE, MEMBER)
18059 is a suitable definition of the `offsetof' macro. In C++, TYPE may be
18060 dependent. In either case, MEMBER may consist of a single identifier,
18061 or a sequence of member accesses and array references.
18064 File: gcc.info, Node: Other Builtins, Next: Target Builtins, Prev: Offsetof, Up: C Extensions
18066 5.44 Other built-in functions provided by GCC
18067 =============================================
18069 GCC provides a large number of built-in functions other than the ones
18070 mentioned above. Some of these are for internal use in the processing
18071 of exceptions or variable-length argument lists and will not be
18072 documented here because they may change from time to time; we do not
18073 recommend general use of these functions.
18075 The remaining functions are provided for optimization purposes.
18077 GCC includes built-in versions of many of the functions in the standard
18078 C library. The versions prefixed with `__builtin_' will always be
18079 treated as having the same meaning as the C library function even if you
18080 specify the `-fno-builtin' option. (*note C Dialect Options::) Many of
18081 these functions are only optimized in certain cases; if they are not
18082 optimized in a particular case, a call to the library function will be
18085 Outside strict ISO C mode (`-ansi', `-std=c89' or `-std=c99'), the
18086 functions `_exit', `alloca', `bcmp', `bzero', `dcgettext', `dgettext',
18087 `dremf', `dreml', `drem', `exp10f', `exp10l', `exp10', `ffsll', `ffsl',
18088 `ffs', `fprintf_unlocked', `fputs_unlocked', `gammaf', `gammal',
18089 `gamma', `gettext', `index', `isascii', `j0f', `j0l', `j0', `j1f',
18090 `j1l', `j1', `jnf', `jnl', `jn', `mempcpy', `pow10f', `pow10l', `pow10',
18091 `printf_unlocked', `rindex', `scalbf', `scalbl', `scalb', `signbit',
18092 `signbitf', `signbitl', `significandf', `significandl', `significand',
18093 `sincosf', `sincosl', `sincos', `stpcpy', `strdup', `strfmon',
18094 `toascii', `y0f', `y0l', `y0', `y1f', `y1l', `y1', `ynf', `ynl' and `yn'
18095 may be handled as built-in functions. All these functions have
18096 corresponding versions prefixed with `__builtin_', which may be used
18097 even in strict C89 mode.
18099 The ISO C99 functions `_Exit', `acoshf', `acoshl', `acosh', `asinhf',
18100 `asinhl', `asinh', `atanhf', `atanhl', `atanh', `cabsf', `cabsl',
18101 `cabs', `cacosf', `cacoshf', `cacoshl', `cacosh', `cacosl', `cacos',
18102 `cargf', `cargl', `carg', `casinf', `casinhf', `casinhl', `casinh',
18103 `casinl', `casin', `catanf', `catanhf', `catanhl', `catanh', `catanl',
18104 `catan', `cbrtf', `cbrtl', `cbrt', `ccosf', `ccoshf', `ccoshl',
18105 `ccosh', `ccosl', `ccos', `cexpf', `cexpl', `cexp', `cimagf', `cimagl',
18106 `cimag', `conjf', `conjl', `conj', `copysignf', `copysignl',
18107 `copysign', `cpowf', `cpowl', `cpow', `cprojf', `cprojl', `cproj',
18108 `crealf', `creall', `creal', `csinf', `csinhf', `csinhl', `csinh',
18109 `csinl', `csin', `csqrtf', `csqrtl', `csqrt', `ctanf', `ctanhf',
18110 `ctanhl', `ctanh', `ctanl', `ctan', `erfcf', `erfcl', `erfc', `erff',
18111 `erfl', `erf', `exp2f', `exp2l', `exp2', `expm1f', `expm1l', `expm1',
18112 `fdimf', `fdiml', `fdim', `fmaf', `fmal', `fmaxf', `fmaxl', `fmax',
18113 `fma', `fminf', `fminl', `fmin', `hypotf', `hypotl', `hypot', `ilogbf',
18114 `ilogbl', `ilogb', `imaxabs', `isblank', `iswblank', `lgammaf',
18115 `lgammal', `lgamma', `llabs', `llrintf', `llrintl', `llrint',
18116 `llroundf', `llroundl', `llround', `log1pf', `log1pl', `log1p',
18117 `log2f', `log2l', `log2', `logbf', `logbl', `logb', `lrintf', `lrintl',
18118 `lrint', `lroundf', `lroundl', `lround', `nearbyintf', `nearbyintl',
18119 `nearbyint', `nextafterf', `nextafterl', `nextafter', `nexttowardf',
18120 `nexttowardl', `nexttoward', `remainderf', `remainderl', `remainder',
18121 `remquof', `remquol', `remquo', `rintf', `rintl', `rint', `roundf',
18122 `roundl', `round', `scalblnf', `scalblnl', `scalbln', `scalbnf',
18123 `scalbnl', `scalbn', `snprintf', `tgammaf', `tgammal', `tgamma',
18124 `truncf', `truncl', `trunc', `vfscanf', `vscanf', `vsnprintf' and
18125 `vsscanf' are handled as built-in functions except in strict ISO C90
18126 mode (`-ansi' or `-std=c89').
18128 There are also built-in versions of the ISO C99 functions `acosf',
18129 `acosl', `asinf', `asinl', `atan2f', `atan2l', `atanf', `atanl',
18130 `ceilf', `ceill', `cosf', `coshf', `coshl', `cosl', `expf', `expl',
18131 `fabsf', `fabsl', `floorf', `floorl', `fmodf', `fmodl', `frexpf',
18132 `frexpl', `ldexpf', `ldexpl', `log10f', `log10l', `logf', `logl',
18133 `modfl', `modf', `powf', `powl', `sinf', `sinhf', `sinhl', `sinl',
18134 `sqrtf', `sqrtl', `tanf', `tanhf', `tanhl' and `tanl' that are
18135 recognized in any mode since ISO C90 reserves these names for the
18136 purpose to which ISO C99 puts them. All these functions have
18137 corresponding versions prefixed with `__builtin_'.
18139 The ISO C94 functions `iswalnum', `iswalpha', `iswcntrl', `iswdigit',
18140 `iswgraph', `iswlower', `iswprint', `iswpunct', `iswspace', `iswupper',
18141 `iswxdigit', `towlower' and `towupper' are handled as built-in functions
18142 except in strict ISO C90 mode (`-ansi' or `-std=c89').
18144 The ISO C90 functions `abort', `abs', `acos', `asin', `atan2', `atan',
18145 `calloc', `ceil', `cosh', `cos', `exit', `exp', `fabs', `floor', `fmod',
18146 `fprintf', `fputs', `frexp', `fscanf', `isalnum', `isalpha', `iscntrl',
18147 `isdigit', `isgraph', `islower', `isprint', `ispunct', `isspace',
18148 `isupper', `isxdigit', `tolower', `toupper', `labs', `ldexp', `log10',
18149 `log', `malloc', `memcmp', `memcpy', `memset', `modf', `pow', `printf',
18150 `putchar', `puts', `scanf', `sinh', `sin', `snprintf', `sprintf',
18151 `sqrt', `sscanf', `strcat', `strchr', `strcmp', `strcpy', `strcspn',
18152 `strlen', `strncat', `strncmp', `strncpy', `strpbrk', `strrchr',
18153 `strspn', `strstr', `tanh', `tan', `vfprintf', `vprintf' and `vsprintf'
18154 are all recognized as built-in functions unless `-fno-builtin' is
18155 specified (or `-fno-builtin-FUNCTION' is specified for an individual
18156 function). All of these functions have corresponding versions prefixed
18159 GCC provides built-in versions of the ISO C99 floating point comparison
18160 macros that avoid raising exceptions for unordered operands. They have
18161 the same names as the standard macros ( `isgreater', `isgreaterequal',
18162 `isless', `islessequal', `islessgreater', and `isunordered') , with
18163 `__builtin_' prefixed. We intend for a library implementor to be able
18164 to simply `#define' each standard macro to its built-in equivalent.
18166 -- Built-in Function: int __builtin_types_compatible_p (TYPE1, TYPE2)
18167 You can use the built-in function `__builtin_types_compatible_p' to
18168 determine whether two types are the same.
18170 This built-in function returns 1 if the unqualified versions of the
18171 types TYPE1 and TYPE2 (which are types, not expressions) are
18172 compatible, 0 otherwise. The result of this built-in function can
18173 be used in integer constant expressions.
18175 This built-in function ignores top level qualifiers (e.g., `const',
18176 `volatile'). For example, `int' is equivalent to `const int'.
18178 The type `int[]' and `int[5]' are compatible. On the other hand,
18179 `int' and `char *' are not compatible, even if the size of their
18180 types, on the particular architecture are the same. Also, the
18181 amount of pointer indirection is taken into account when
18182 determining similarity. Consequently, `short *' is not similar to
18183 `short **'. Furthermore, two types that are typedefed are
18184 considered compatible if their underlying types are compatible.
18186 An `enum' type is not considered to be compatible with another
18187 `enum' type even if both are compatible with the same integer
18188 type; this is what the C standard specifies. For example, `enum
18189 {foo, bar}' is not similar to `enum {hot, dog}'.
18191 You would typically use this function in code whose execution
18192 varies depending on the arguments' types. For example:
18197 if (__builtin_types_compatible_p (typeof (x), long double)) \
18198 tmp = foo_long_double (tmp); \
18199 else if (__builtin_types_compatible_p (typeof (x), double)) \
18200 tmp = foo_double (tmp); \
18201 else if (__builtin_types_compatible_p (typeof (x), float)) \
18202 tmp = foo_float (tmp); \
18208 _Note:_ This construct is only available for C.
18211 -- Built-in Function: TYPE __builtin_choose_expr (CONST_EXP, EXP1,
18213 You can use the built-in function `__builtin_choose_expr' to
18214 evaluate code depending on the value of a constant expression.
18215 This built-in function returns EXP1 if CONST_EXP, which is a
18216 constant expression that must be able to be determined at compile
18217 time, is nonzero. Otherwise it returns 0.
18219 This built-in function is analogous to the `? :' operator in C,
18220 except that the expression returned has its type unaltered by
18221 promotion rules. Also, the built-in function does not evaluate
18222 the expression that was not chosen. For example, if CONST_EXP
18223 evaluates to true, EXP2 is not evaluated even if it has
18226 This built-in function can return an lvalue if the chosen argument
18229 If EXP1 is returned, the return type is the same as EXP1's type.
18230 Similarly, if EXP2 is returned, its return type is the same as
18236 __builtin_choose_expr ( \
18237 __builtin_types_compatible_p (typeof (x), double), \
18239 __builtin_choose_expr ( \
18240 __builtin_types_compatible_p (typeof (x), float), \
18242 /* The void expression results in a compile-time error \
18243 when assigning the result to something. */ \
18246 _Note:_ This construct is only available for C. Furthermore, the
18247 unused expression (EXP1 or EXP2 depending on the value of
18248 CONST_EXP) may still generate syntax errors. This may change in
18252 -- Built-in Function: int __builtin_constant_p (EXP)
18253 You can use the built-in function `__builtin_constant_p' to
18254 determine if a value is known to be constant at compile-time and
18255 hence that GCC can perform constant-folding on expressions
18256 involving that value. The argument of the function is the value
18257 to test. The function returns the integer 1 if the argument is
18258 known to be a compile-time constant and 0 if it is not known to be
18259 a compile-time constant. A return of 0 does not indicate that the
18260 value is _not_ a constant, but merely that GCC cannot prove it is
18261 a constant with the specified value of the `-O' option.
18263 You would typically use this function in an embedded application
18264 where memory was a critical resource. If you have some complex
18265 calculation, you may want it to be folded if it involves
18266 constants, but need to call a function if it does not. For
18269 #define Scale_Value(X) \
18270 (__builtin_constant_p (X) \
18271 ? ((X) * SCALE + OFFSET) : Scale (X))
18273 You may use this built-in function in either a macro or an inline
18274 function. However, if you use it in an inlined function and pass
18275 an argument of the function as the argument to the built-in, GCC
18276 will never return 1 when you call the inline function with a
18277 string constant or compound literal (*note Compound Literals::)
18278 and will not return 1 when you pass a constant numeric value to
18279 the inline function unless you specify the `-O' option.
18281 You may also use `__builtin_constant_p' in initializers for static
18282 data. For instance, you can write
18284 static const int table[] = {
18285 __builtin_constant_p (EXPRESSION) ? (EXPRESSION) : -1,
18289 This is an acceptable initializer even if EXPRESSION is not a
18290 constant expression. GCC must be more conservative about
18291 evaluating the built-in in this case, because it has no
18292 opportunity to perform optimization.
18294 Previous versions of GCC did not accept this built-in in data
18295 initializers. The earliest version where it is completely safe is
18298 -- Built-in Function: long __builtin_expect (long EXP, long C)
18299 You may use `__builtin_expect' to provide the compiler with branch
18300 prediction information. In general, you should prefer to use
18301 actual profile feedback for this (`-fprofile-arcs'), as
18302 programmers are notoriously bad at predicting how their programs
18303 actually perform. However, there are applications in which this
18304 data is hard to collect.
18306 The return value is the value of EXP, which should be an integral
18307 expression. The value of C must be a compile-time constant. The
18308 semantics of the built-in are that it is expected that EXP == C.
18311 if (__builtin_expect (x, 0))
18314 would indicate that we do not expect to call `foo', since we
18315 expect `x' to be zero. Since you are limited to integral
18316 expressions for EXP, you should use constructions such as
18318 if (__builtin_expect (ptr != NULL, 1))
18321 when testing pointer or floating-point values.
18323 -- Built-in Function: void __builtin_prefetch (const void *ADDR, ...)
18324 This function is used to minimize cache-miss latency by moving
18325 data into a cache before it is accessed. You can insert calls to
18326 `__builtin_prefetch' into code for which you know addresses of
18327 data in memory that is likely to be accessed soon. If the target
18328 supports them, data prefetch instructions will be generated. If
18329 the prefetch is done early enough before the access then the data
18330 will be in the cache by the time it is accessed.
18332 The value of ADDR is the address of the memory to prefetch. There
18333 are two optional arguments, RW and LOCALITY. The value of RW is a
18334 compile-time constant one or zero; one means that the prefetch is
18335 preparing for a write to the memory address and zero, the default,
18336 means that the prefetch is preparing for a read. The value
18337 LOCALITY must be a compile-time constant integer between zero and
18338 three. A value of zero means that the data has no temporal
18339 locality, so it need not be left in the cache after the access. A
18340 value of three means that the data has a high degree of temporal
18341 locality and should be left in all levels of cache possible.
18342 Values of one and two mean, respectively, a low or moderate degree
18343 of temporal locality. The default is three.
18345 for (i = 0; i < n; i++)
18347 a[i] = a[i] + b[i];
18348 __builtin_prefetch (&a[i+j], 1, 1);
18349 __builtin_prefetch (&b[i+j], 0, 1);
18353 Data prefetch does not generate faults if ADDR is invalid, but the
18354 address expression itself must be valid. For example, a prefetch
18355 of `p->next' will not fault if `p->next' is not a valid address,
18356 but evaluation will fault if `p' is not a valid address.
18358 If the target does not support data prefetch, the address
18359 expression is evaluated if it includes side effects but no other
18360 code is generated and GCC does not issue a warning.
18362 -- Built-in Function: double __builtin_huge_val (void)
18363 Returns a positive infinity, if supported by the floating-point
18364 format, else `DBL_MAX'. This function is suitable for
18365 implementing the ISO C macro `HUGE_VAL'.
18367 -- Built-in Function: float __builtin_huge_valf (void)
18368 Similar to `__builtin_huge_val', except the return type is `float'.
18370 -- Built-in Function: long double __builtin_huge_vall (void)
18371 Similar to `__builtin_huge_val', except the return type is `long
18374 -- Built-in Function: double __builtin_inf (void)
18375 Similar to `__builtin_huge_val', except a warning is generated if
18376 the target floating-point format does not support infinities.
18378 -- Built-in Function: float __builtin_inff (void)
18379 Similar to `__builtin_inf', except the return type is `float'.
18380 This function is suitable for implementing the ISO C99 macro
18383 -- Built-in Function: long double __builtin_infl (void)
18384 Similar to `__builtin_inf', except the return type is `long
18387 -- Built-in Function: double __builtin_nan (const char *str)
18388 This is an implementation of the ISO C99 function `nan'.
18390 Since ISO C99 defines this function in terms of `strtod', which we
18391 do not implement, a description of the parsing is in order. The
18392 string is parsed as by `strtol'; that is, the base is recognized by
18393 leading `0' or `0x' prefixes. The number parsed is placed in the
18394 significand such that the least significant bit of the number is
18395 at the least significant bit of the significand. The number is
18396 truncated to fit the significand field provided. The significand
18397 is forced to be a quiet NaN.
18399 This function, if given a string literal, is evaluated early enough
18400 that it is considered a compile-time constant.
18402 -- Built-in Function: float __builtin_nanf (const char *str)
18403 Similar to `__builtin_nan', except the return type is `float'.
18405 -- Built-in Function: long double __builtin_nanl (const char *str)
18406 Similar to `__builtin_nan', except the return type is `long
18409 -- Built-in Function: double __builtin_nans (const char *str)
18410 Similar to `__builtin_nan', except the significand is forced to be
18411 a signaling NaN. The `nans' function is proposed by WG14 N965.
18413 -- Built-in Function: float __builtin_nansf (const char *str)
18414 Similar to `__builtin_nans', except the return type is `float'.
18416 -- Built-in Function: long double __builtin_nansl (const char *str)
18417 Similar to `__builtin_nans', except the return type is `long
18420 -- Built-in Function: int __builtin_ffs (unsigned int x)
18421 Returns one plus the index of the least significant 1-bit of X, or
18422 if X is zero, returns zero.
18424 -- Built-in Function: int __builtin_clz (unsigned int x)
18425 Returns the number of leading 0-bits in X, starting at the most
18426 significant bit position. If X is 0, the result is undefined.
18428 -- Built-in Function: int __builtin_ctz (unsigned int x)
18429 Returns the number of trailing 0-bits in X, starting at the least
18430 significant bit position. If X is 0, the result is undefined.
18432 -- Built-in Function: int __builtin_popcount (unsigned int x)
18433 Returns the number of 1-bits in X.
18435 -- Built-in Function: int __builtin_parity (unsigned int x)
18436 Returns the parity of X, i.e. the number of 1-bits in X modulo 2.
18438 -- Built-in Function: int __builtin_ffsl (unsigned long)
18439 Similar to `__builtin_ffs', except the argument type is `unsigned
18442 -- Built-in Function: int __builtin_clzl (unsigned long)
18443 Similar to `__builtin_clz', except the argument type is `unsigned
18446 -- Built-in Function: int __builtin_ctzl (unsigned long)
18447 Similar to `__builtin_ctz', except the argument type is `unsigned
18450 -- Built-in Function: int __builtin_popcountl (unsigned long)
18451 Similar to `__builtin_popcount', except the argument type is
18454 -- Built-in Function: int __builtin_parityl (unsigned long)
18455 Similar to `__builtin_parity', except the argument type is
18458 -- Built-in Function: int __builtin_ffsll (unsigned long long)
18459 Similar to `__builtin_ffs', except the argument type is `unsigned
18462 -- Built-in Function: int __builtin_clzll (unsigned long long)
18463 Similar to `__builtin_clz', except the argument type is `unsigned
18466 -- Built-in Function: int __builtin_ctzll (unsigned long long)
18467 Similar to `__builtin_ctz', except the argument type is `unsigned
18470 -- Built-in Function: int __builtin_popcountll (unsigned long long)
18471 Similar to `__builtin_popcount', except the argument type is
18472 `unsigned long long'.
18474 -- Built-in Function: int __builtin_parityll (unsigned long long)
18475 Similar to `__builtin_parity', except the argument type is
18476 `unsigned long long'.
18478 -- Built-in Function: double __builtin_powi (double, int)
18479 Returns the first argument raised to the power of the second.
18480 Unlike the `pow' function no guarantees about precision and
18483 -- Built-in Function: float __builtin_powif (float, int)
18484 Similar to `__builtin_powi', except the argument and return types
18487 -- Built-in Function: long double __builtin_powil (long double, int)
18488 Similar to `__builtin_powi', except the argument and return types
18492 File: gcc.info, Node: Target Builtins, Next: Target Format Checks, Prev: Other Builtins, Up: C Extensions
18494 5.45 Built-in Functions Specific to Particular Target Machines
18495 ==============================================================
18497 On some target machines, GCC supports many built-in functions specific
18498 to those machines. Generally these generate calls to specific machine
18499 instructions, but allow the compiler to schedule those calls.
18503 * Alpha Built-in Functions::
18504 * ARM Built-in Functions::
18505 * FR-V Built-in Functions::
18506 * X86 Built-in Functions::
18507 * MIPS Paired-Single Support::
18508 * PowerPC AltiVec Built-in Functions::
18509 * SPARC VIS Built-in Functions::
18512 File: gcc.info, Node: Alpha Built-in Functions, Next: ARM Built-in Functions, Up: Target Builtins
18514 5.45.1 Alpha Built-in Functions
18515 -------------------------------
18517 These built-in functions are available for the Alpha family of
18518 processors, depending on the command-line switches used.
18520 The following built-in functions are always available. They all
18521 generate the machine instruction that is part of the name.
18523 long __builtin_alpha_implver (void)
18524 long __builtin_alpha_rpcc (void)
18525 long __builtin_alpha_amask (long)
18526 long __builtin_alpha_cmpbge (long, long)
18527 long __builtin_alpha_extbl (long, long)
18528 long __builtin_alpha_extwl (long, long)
18529 long __builtin_alpha_extll (long, long)
18530 long __builtin_alpha_extql (long, long)
18531 long __builtin_alpha_extwh (long, long)
18532 long __builtin_alpha_extlh (long, long)
18533 long __builtin_alpha_extqh (long, long)
18534 long __builtin_alpha_insbl (long, long)
18535 long __builtin_alpha_inswl (long, long)
18536 long __builtin_alpha_insll (long, long)
18537 long __builtin_alpha_insql (long, long)
18538 long __builtin_alpha_inswh (long, long)
18539 long __builtin_alpha_inslh (long, long)
18540 long __builtin_alpha_insqh (long, long)
18541 long __builtin_alpha_mskbl (long, long)
18542 long __builtin_alpha_mskwl (long, long)
18543 long __builtin_alpha_mskll (long, long)
18544 long __builtin_alpha_mskql (long, long)
18545 long __builtin_alpha_mskwh (long, long)
18546 long __builtin_alpha_msklh (long, long)
18547 long __builtin_alpha_mskqh (long, long)
18548 long __builtin_alpha_umulh (long, long)
18549 long __builtin_alpha_zap (long, long)
18550 long __builtin_alpha_zapnot (long, long)
18552 The following built-in functions are always with `-mmax' or
18553 `-mcpu=CPU' where CPU is `pca56' or later. They all generate the
18554 machine instruction that is part of the name.
18556 long __builtin_alpha_pklb (long)
18557 long __builtin_alpha_pkwb (long)
18558 long __builtin_alpha_unpkbl (long)
18559 long __builtin_alpha_unpkbw (long)
18560 long __builtin_alpha_minub8 (long, long)
18561 long __builtin_alpha_minsb8 (long, long)
18562 long __builtin_alpha_minuw4 (long, long)
18563 long __builtin_alpha_minsw4 (long, long)
18564 long __builtin_alpha_maxub8 (long, long)
18565 long __builtin_alpha_maxsb8 (long, long)
18566 long __builtin_alpha_maxuw4 (long, long)
18567 long __builtin_alpha_maxsw4 (long, long)
18568 long __builtin_alpha_perr (long, long)
18570 The following built-in functions are always with `-mcix' or
18571 `-mcpu=CPU' where CPU is `ev67' or later. They all generate the
18572 machine instruction that is part of the name.
18574 long __builtin_alpha_cttz (long)
18575 long __builtin_alpha_ctlz (long)
18576 long __builtin_alpha_ctpop (long)
18578 The following builtins are available on systems that use the OSF/1
18579 PALcode. Normally they invoke the `rduniq' and `wruniq' PAL calls, but
18580 when invoked with `-mtls-kernel', they invoke `rdval' and `wrval'.
18582 void *__builtin_thread_pointer (void)
18583 void __builtin_set_thread_pointer (void *)
18586 File: gcc.info, Node: ARM Built-in Functions, Next: FR-V Built-in Functions, Prev: Alpha Built-in Functions, Up: Target Builtins
18588 5.45.2 ARM Built-in Functions
18589 -----------------------------
18591 These built-in functions are available for the ARM family of
18592 processors, when the `-mcpu=iwmmxt' switch is used:
18594 typedef int v2si __attribute__ ((vector_size (8)));
18595 typedef short v4hi __attribute__ ((vector_size (8)));
18596 typedef char v8qi __attribute__ ((vector_size (8)));
18598 int __builtin_arm_getwcx (int)
18599 void __builtin_arm_setwcx (int, int)
18600 int __builtin_arm_textrmsb (v8qi, int)
18601 int __builtin_arm_textrmsh (v4hi, int)
18602 int __builtin_arm_textrmsw (v2si, int)
18603 int __builtin_arm_textrmub (v8qi, int)
18604 int __builtin_arm_textrmuh (v4hi, int)
18605 int __builtin_arm_textrmuw (v2si, int)
18606 v8qi __builtin_arm_tinsrb (v8qi, int)
18607 v4hi __builtin_arm_tinsrh (v4hi, int)
18608 v2si __builtin_arm_tinsrw (v2si, int)
18609 long long __builtin_arm_tmia (long long, int, int)
18610 long long __builtin_arm_tmiabb (long long, int, int)
18611 long long __builtin_arm_tmiabt (long long, int, int)
18612 long long __builtin_arm_tmiaph (long long, int, int)
18613 long long __builtin_arm_tmiatb (long long, int, int)
18614 long long __builtin_arm_tmiatt (long long, int, int)
18615 int __builtin_arm_tmovmskb (v8qi)
18616 int __builtin_arm_tmovmskh (v4hi)
18617 int __builtin_arm_tmovmskw (v2si)
18618 long long __builtin_arm_waccb (v8qi)
18619 long long __builtin_arm_wacch (v4hi)
18620 long long __builtin_arm_waccw (v2si)
18621 v8qi __builtin_arm_waddb (v8qi, v8qi)
18622 v8qi __builtin_arm_waddbss (v8qi, v8qi)
18623 v8qi __builtin_arm_waddbus (v8qi, v8qi)
18624 v4hi __builtin_arm_waddh (v4hi, v4hi)
18625 v4hi __builtin_arm_waddhss (v4hi, v4hi)
18626 v4hi __builtin_arm_waddhus (v4hi, v4hi)
18627 v2si __builtin_arm_waddw (v2si, v2si)
18628 v2si __builtin_arm_waddwss (v2si, v2si)
18629 v2si __builtin_arm_waddwus (v2si, v2si)
18630 v8qi __builtin_arm_walign (v8qi, v8qi, int)
18631 long long __builtin_arm_wand(long long, long long)
18632 long long __builtin_arm_wandn (long long, long long)
18633 v8qi __builtin_arm_wavg2b (v8qi, v8qi)
18634 v8qi __builtin_arm_wavg2br (v8qi, v8qi)
18635 v4hi __builtin_arm_wavg2h (v4hi, v4hi)
18636 v4hi __builtin_arm_wavg2hr (v4hi, v4hi)
18637 v8qi __builtin_arm_wcmpeqb (v8qi, v8qi)
18638 v4hi __builtin_arm_wcmpeqh (v4hi, v4hi)
18639 v2si __builtin_arm_wcmpeqw (v2si, v2si)
18640 v8qi __builtin_arm_wcmpgtsb (v8qi, v8qi)
18641 v4hi __builtin_arm_wcmpgtsh (v4hi, v4hi)
18642 v2si __builtin_arm_wcmpgtsw (v2si, v2si)
18643 v8qi __builtin_arm_wcmpgtub (v8qi, v8qi)
18644 v4hi __builtin_arm_wcmpgtuh (v4hi, v4hi)
18645 v2si __builtin_arm_wcmpgtuw (v2si, v2si)
18646 long long __builtin_arm_wmacs (long long, v4hi, v4hi)
18647 long long __builtin_arm_wmacsz (v4hi, v4hi)
18648 long long __builtin_arm_wmacu (long long, v4hi, v4hi)
18649 long long __builtin_arm_wmacuz (v4hi, v4hi)
18650 v4hi __builtin_arm_wmadds (v4hi, v4hi)
18651 v4hi __builtin_arm_wmaddu (v4hi, v4hi)
18652 v8qi __builtin_arm_wmaxsb (v8qi, v8qi)
18653 v4hi __builtin_arm_wmaxsh (v4hi, v4hi)
18654 v2si __builtin_arm_wmaxsw (v2si, v2si)
18655 v8qi __builtin_arm_wmaxub (v8qi, v8qi)
18656 v4hi __builtin_arm_wmaxuh (v4hi, v4hi)
18657 v2si __builtin_arm_wmaxuw (v2si, v2si)
18658 v8qi __builtin_arm_wminsb (v8qi, v8qi)
18659 v4hi __builtin_arm_wminsh (v4hi, v4hi)
18660 v2si __builtin_arm_wminsw (v2si, v2si)
18661 v8qi __builtin_arm_wminub (v8qi, v8qi)
18662 v4hi __builtin_arm_wminuh (v4hi, v4hi)
18663 v2si __builtin_arm_wminuw (v2si, v2si)
18664 v4hi __builtin_arm_wmulsm (v4hi, v4hi)
18665 v4hi __builtin_arm_wmulul (v4hi, v4hi)
18666 v4hi __builtin_arm_wmulum (v4hi, v4hi)
18667 long long __builtin_arm_wor (long long, long long)
18668 v2si __builtin_arm_wpackdss (long long, long long)
18669 v2si __builtin_arm_wpackdus (long long, long long)
18670 v8qi __builtin_arm_wpackhss (v4hi, v4hi)
18671 v8qi __builtin_arm_wpackhus (v4hi, v4hi)
18672 v4hi __builtin_arm_wpackwss (v2si, v2si)
18673 v4hi __builtin_arm_wpackwus (v2si, v2si)
18674 long long __builtin_arm_wrord (long long, long long)
18675 long long __builtin_arm_wrordi (long long, int)
18676 v4hi __builtin_arm_wrorh (v4hi, long long)
18677 v4hi __builtin_arm_wrorhi (v4hi, int)
18678 v2si __builtin_arm_wrorw (v2si, long long)
18679 v2si __builtin_arm_wrorwi (v2si, int)
18680 v2si __builtin_arm_wsadb (v8qi, v8qi)
18681 v2si __builtin_arm_wsadbz (v8qi, v8qi)
18682 v2si __builtin_arm_wsadh (v4hi, v4hi)
18683 v2si __builtin_arm_wsadhz (v4hi, v4hi)
18684 v4hi __builtin_arm_wshufh (v4hi, int)
18685 long long __builtin_arm_wslld (long long, long long)
18686 long long __builtin_arm_wslldi (long long, int)
18687 v4hi __builtin_arm_wsllh (v4hi, long long)
18688 v4hi __builtin_arm_wsllhi (v4hi, int)
18689 v2si __builtin_arm_wsllw (v2si, long long)
18690 v2si __builtin_arm_wsllwi (v2si, int)
18691 long long __builtin_arm_wsrad (long long, long long)
18692 long long __builtin_arm_wsradi (long long, int)
18693 v4hi __builtin_arm_wsrah (v4hi, long long)
18694 v4hi __builtin_arm_wsrahi (v4hi, int)
18695 v2si __builtin_arm_wsraw (v2si, long long)
18696 v2si __builtin_arm_wsrawi (v2si, int)
18697 long long __builtin_arm_wsrld (long long, long long)
18698 long long __builtin_arm_wsrldi (long long, int)
18699 v4hi __builtin_arm_wsrlh (v4hi, long long)
18700 v4hi __builtin_arm_wsrlhi (v4hi, int)
18701 v2si __builtin_arm_wsrlw (v2si, long long)
18702 v2si __builtin_arm_wsrlwi (v2si, int)
18703 v8qi __builtin_arm_wsubb (v8qi, v8qi)
18704 v8qi __builtin_arm_wsubbss (v8qi, v8qi)
18705 v8qi __builtin_arm_wsubbus (v8qi, v8qi)
18706 v4hi __builtin_arm_wsubh (v4hi, v4hi)
18707 v4hi __builtin_arm_wsubhss (v4hi, v4hi)
18708 v4hi __builtin_arm_wsubhus (v4hi, v4hi)
18709 v2si __builtin_arm_wsubw (v2si, v2si)
18710 v2si __builtin_arm_wsubwss (v2si, v2si)
18711 v2si __builtin_arm_wsubwus (v2si, v2si)
18712 v4hi __builtin_arm_wunpckehsb (v8qi)
18713 v2si __builtin_arm_wunpckehsh (v4hi)
18714 long long __builtin_arm_wunpckehsw (v2si)
18715 v4hi __builtin_arm_wunpckehub (v8qi)
18716 v2si __builtin_arm_wunpckehuh (v4hi)
18717 long long __builtin_arm_wunpckehuw (v2si)
18718 v4hi __builtin_arm_wunpckelsb (v8qi)
18719 v2si __builtin_arm_wunpckelsh (v4hi)
18720 long long __builtin_arm_wunpckelsw (v2si)
18721 v4hi __builtin_arm_wunpckelub (v8qi)
18722 v2si __builtin_arm_wunpckeluh (v4hi)
18723 long long __builtin_arm_wunpckeluw (v2si)
18724 v8qi __builtin_arm_wunpckihb (v8qi, v8qi)
18725 v4hi __builtin_arm_wunpckihh (v4hi, v4hi)
18726 v2si __builtin_arm_wunpckihw (v2si, v2si)
18727 v8qi __builtin_arm_wunpckilb (v8qi, v8qi)
18728 v4hi __builtin_arm_wunpckilh (v4hi, v4hi)
18729 v2si __builtin_arm_wunpckilw (v2si, v2si)
18730 long long __builtin_arm_wxor (long long, long long)
18731 long long __builtin_arm_wzero ()
18734 File: gcc.info, Node: FR-V Built-in Functions, Next: X86 Built-in Functions, Prev: ARM Built-in Functions, Up: Target Builtins
18736 5.45.3 FR-V Built-in Functions
18737 ------------------------------
18739 GCC provides many FR-V-specific built-in functions. In general, these
18740 functions are intended to be compatible with those described by `FR-V
18741 Family, Softune C/C++ Compiler Manual (V6), Fujitsu Semiconductor'.
18742 The two exceptions are `__MDUNPACKH' and `__MBTOHE', the gcc forms of
18743 which pass 128-bit values by pointer rather than by value.
18745 Most of the functions are named after specific FR-V instructions.
18746 Such functions are said to be "directly mapped" and are summarized here
18752 * Directly-mapped Integer Functions::
18753 * Directly-mapped Media Functions::
18754 * Other Built-in Functions::
18757 File: gcc.info, Node: Argument Types, Next: Directly-mapped Integer Functions, Up: FR-V Built-in Functions
18759 5.45.3.1 Argument Types
18760 .......................
18762 The arguments to the built-in functions can be divided into three
18763 groups: register numbers, compile-time constants and run-time values.
18764 In order to make this classification clear at a glance, the arguments
18765 and return values are given the following pseudo types:
18767 Pseudo type Real C type Constant? Description
18768 `uh' `unsigned short' No an unsigned halfword
18769 `uw1' `unsigned int' No an unsigned word
18770 `sw1' `int' No a signed word
18771 `uw2' `unsigned long long' No an unsigned doubleword
18772 `sw2' `long long' No a signed doubleword
18773 `const' `int' Yes an integer constant
18774 `acc' `int' Yes an ACC register number
18775 `iacc' `int' Yes an IACC register number
18777 These pseudo types are not defined by GCC, they are simply a notational
18778 convenience used in this manual.
18780 Arguments of type `uh', `uw1', `sw1', `uw2' and `sw2' are evaluated at
18781 run time. They correspond to register operands in the underlying FR-V
18784 `const' arguments represent immediate operands in the underlying FR-V
18785 instructions. They must be compile-time constants.
18787 `acc' arguments are evaluated at compile time and specify the number
18788 of an accumulator register. For example, an `acc' argument of 2 will
18789 select the ACC2 register.
18791 `iacc' arguments are similar to `acc' arguments but specify the number
18792 of an IACC register. See *note Other Built-in Functions:: for more
18796 File: gcc.info, Node: Directly-mapped Integer Functions, Next: Directly-mapped Media Functions, Prev: Argument Types, Up: FR-V Built-in Functions
18798 5.45.3.2 Directly-mapped Integer Functions
18799 ..........................................
18801 The functions listed below map directly to FR-V I-type instructions.
18803 Function prototype Example usage Assembly output
18804 `sw1 __ADDSS (sw1, sw1)' `C = __ADDSS (A, B)' `ADDSS A,B,C'
18805 `sw1 __SCAN (sw1, sw1)' `C = __SCAN (A, B)' `SCAN A,B,C'
18806 `sw1 __SCUTSS (sw1)' `B = __SCUTSS (A)' `SCUTSS A,B'
18807 `sw1 __SLASS (sw1, sw1)' `C = __SLASS (A, B)' `SLASS A,B,C'
18808 `void __SMASS (sw1, sw1)' `__SMASS (A, B)' `SMASS A,B'
18809 `void __SMSSS (sw1, sw1)' `__SMSSS (A, B)' `SMSSS A,B'
18810 `void __SMU (sw1, sw1)' `__SMU (A, B)' `SMU A,B'
18811 `sw2 __SMUL (sw1, sw1)' `C = __SMUL (A, B)' `SMUL A,B,C'
18812 `sw1 __SUBSS (sw1, sw1)' `C = __SUBSS (A, B)' `SUBSS A,B,C'
18813 `uw2 __UMUL (uw1, uw1)' `C = __UMUL (A, B)' `UMUL A,B,C'
18816 File: gcc.info, Node: Directly-mapped Media Functions, Next: Other Built-in Functions, Prev: Directly-mapped Integer Functions, Up: FR-V Built-in Functions
18818 5.45.3.3 Directly-mapped Media Functions
18819 ........................................
18821 The functions listed below map directly to FR-V M-type instructions.
18823 Function prototype Example usage Assembly output
18824 `uw1 __MABSHS (sw1)' `B = __MABSHS (A)' `MABSHS A,B'
18825 `void __MADDACCS (acc, acc)' `__MADDACCS (B, A)' `MADDACCS A,B'
18826 `sw1 __MADDHSS (sw1, sw1)' `C = __MADDHSS (A, B)' `MADDHSS A,B,C'
18827 `uw1 __MADDHUS (uw1, uw1)' `C = __MADDHUS (A, B)' `MADDHUS A,B,C'
18828 `uw1 __MAND (uw1, uw1)' `C = __MAND (A, B)' `MAND A,B,C'
18829 `void __MASACCS (acc, acc)' `__MASACCS (B, A)' `MASACCS A,B'
18830 `uw1 __MAVEH (uw1, uw1)' `C = __MAVEH (A, B)' `MAVEH A,B,C'
18831 `uw2 __MBTOH (uw1)' `B = __MBTOH (A)' `MBTOH A,B'
18832 `void __MBTOHE (uw1 *, uw1)' `__MBTOHE (&B, A)' `MBTOHE A,B'
18833 `void __MCLRACC (acc)' `__MCLRACC (A)' `MCLRACC A'
18834 `void __MCLRACCA (void)' `__MCLRACCA ()' `MCLRACCA'
18835 `uw1 __Mcop1 (uw1, uw1)' `C = __Mcop1 (A, B)' `Mcop1 A,B,C'
18836 `uw1 __Mcop2 (uw1, uw1)' `C = __Mcop2 (A, B)' `Mcop2 A,B,C'
18837 `uw1 __MCPLHI (uw2, const)' `C = __MCPLHI (A, B)' `MCPLHI A,#B,C'
18838 `uw1 __MCPLI (uw2, const)' `C = __MCPLI (A, B)' `MCPLI A,#B,C'
18839 `void __MCPXIS (acc, sw1, sw1)' `__MCPXIS (C, A, B)' `MCPXIS A,B,C'
18840 `void __MCPXIU (acc, uw1, uw1)' `__MCPXIU (C, A, B)' `MCPXIU A,B,C'
18841 `void __MCPXRS (acc, sw1, sw1)' `__MCPXRS (C, A, B)' `MCPXRS A,B,C'
18842 `void __MCPXRU (acc, uw1, uw1)' `__MCPXRU (C, A, B)' `MCPXRU A,B,C'
18843 `uw1 __MCUT (acc, uw1)' `C = __MCUT (A, B)' `MCUT A,B,C'
18844 `uw1 __MCUTSS (acc, sw1)' `C = __MCUTSS (A, B)' `MCUTSS A,B,C'
18845 `void __MDADDACCS (acc, acc)' `__MDADDACCS (B, A)' `MDADDACCS A,B'
18846 `void __MDASACCS (acc, acc)' `__MDASACCS (B, A)' `MDASACCS A,B'
18847 `uw2 __MDCUTSSI (acc, const)' `C = __MDCUTSSI (A, B)' `MDCUTSSI A,#B,C'
18848 `uw2 __MDPACKH (uw2, uw2)' `C = __MDPACKH (A, B)' `MDPACKH A,B,C'
18849 `uw2 __MDROTLI (uw2, const)' `C = __MDROTLI (A, B)' `MDROTLI A,#B,C'
18850 `void __MDSUBACCS (acc, acc)' `__MDSUBACCS (B, A)' `MDSUBACCS A,B'
18851 `void __MDUNPACKH (uw1 *, uw2)' `__MDUNPACKH (&B, A)' `MDUNPACKH A,B'
18852 `uw2 __MEXPDHD (uw1, const)' `C = __MEXPDHD (A, B)' `MEXPDHD A,#B,C'
18853 `uw1 __MEXPDHW (uw1, const)' `C = __MEXPDHW (A, B)' `MEXPDHW A,#B,C'
18854 `uw1 __MHDSETH (uw1, const)' `C = __MHDSETH (A, B)' `MHDSETH A,#B,C'
18855 `sw1 __MHDSETS (const)' `B = __MHDSETS (A)' `MHDSETS #A,B'
18856 `uw1 __MHSETHIH (uw1, const)' `B = __MHSETHIH (B, A)' `MHSETHIH #A,B'
18857 `sw1 __MHSETHIS (sw1, const)' `B = __MHSETHIS (B, A)' `MHSETHIS #A,B'
18858 `uw1 __MHSETLOH (uw1, const)' `B = __MHSETLOH (B, A)' `MHSETLOH #A,B'
18859 `sw1 __MHSETLOS (sw1, const)' `B = __MHSETLOS (B, A)' `MHSETLOS #A,B'
18860 `uw1 __MHTOB (uw2)' `B = __MHTOB (A)' `MHTOB A,B'
18861 `void __MMACHS (acc, sw1, sw1)' `__MMACHS (C, A, B)' `MMACHS A,B,C'
18862 `void __MMACHU (acc, uw1, uw1)' `__MMACHU (C, A, B)' `MMACHU A,B,C'
18863 `void __MMRDHS (acc, sw1, sw1)' `__MMRDHS (C, A, B)' `MMRDHS A,B,C'
18864 `void __MMRDHU (acc, uw1, uw1)' `__MMRDHU (C, A, B)' `MMRDHU A,B,C'
18865 `void __MMULHS (acc, sw1, sw1)' `__MMULHS (C, A, B)' `MMULHS A,B,C'
18866 `void __MMULHU (acc, uw1, uw1)' `__MMULHU (C, A, B)' `MMULHU A,B,C'
18867 `void __MMULXHS (acc, sw1, sw1)' `__MMULXHS (C, A, B)' `MMULXHS A,B,C'
18868 `void __MMULXHU (acc, uw1, uw1)' `__MMULXHU (C, A, B)' `MMULXHU A,B,C'
18869 `uw1 __MNOT (uw1)' `B = __MNOT (A)' `MNOT A,B'
18870 `uw1 __MOR (uw1, uw1)' `C = __MOR (A, B)' `MOR A,B,C'
18871 `uw1 __MPACKH (uh, uh)' `C = __MPACKH (A, B)' `MPACKH A,B,C'
18872 `sw2 __MQADDHSS (sw2, sw2)' `C = __MQADDHSS (A, B)' `MQADDHSS A,B,C'
18873 `uw2 __MQADDHUS (uw2, uw2)' `C = __MQADDHUS (A, B)' `MQADDHUS A,B,C'
18874 `void __MQCPXIS (acc, sw2, sw2)' `__MQCPXIS (C, A, B)' `MQCPXIS A,B,C'
18875 `void __MQCPXIU (acc, uw2, uw2)' `__MQCPXIU (C, A, B)' `MQCPXIU A,B,C'
18876 `void __MQCPXRS (acc, sw2, sw2)' `__MQCPXRS (C, A, B)' `MQCPXRS A,B,C'
18877 `void __MQCPXRU (acc, uw2, uw2)' `__MQCPXRU (C, A, B)' `MQCPXRU A,B,C'
18878 `sw2 __MQLCLRHS (sw2, sw2)' `C = __MQLCLRHS (A, B)' `MQLCLRHS A,B,C'
18879 `sw2 __MQLMTHS (sw2, sw2)' `C = __MQLMTHS (A, B)' `MQLMTHS A,B,C'
18880 `void __MQMACHS (acc, sw2, sw2)' `__MQMACHS (C, A, B)' `MQMACHS A,B,C'
18881 `void __MQMACHU (acc, uw2, uw2)' `__MQMACHU (C, A, B)' `MQMACHU A,B,C'
18882 `void __MQMACXHS (acc, sw2, `__MQMACXHS (C, A, B)' `MQMACXHS A,B,C'
18884 `void __MQMULHS (acc, sw2, sw2)' `__MQMULHS (C, A, B)' `MQMULHS A,B,C'
18885 `void __MQMULHU (acc, uw2, uw2)' `__MQMULHU (C, A, B)' `MQMULHU A,B,C'
18886 `void __MQMULXHS (acc, sw2, `__MQMULXHS (C, A, B)' `MQMULXHS A,B,C'
18888 `void __MQMULXHU (acc, uw2, `__MQMULXHU (C, A, B)' `MQMULXHU A,B,C'
18890 `sw2 __MQSATHS (sw2, sw2)' `C = __MQSATHS (A, B)' `MQSATHS A,B,C'
18891 `uw2 __MQSLLHI (uw2, int)' `C = __MQSLLHI (A, B)' `MQSLLHI A,B,C'
18892 `sw2 __MQSRAHI (sw2, int)' `C = __MQSRAHI (A, B)' `MQSRAHI A,B,C'
18893 `sw2 __MQSUBHSS (sw2, sw2)' `C = __MQSUBHSS (A, B)' `MQSUBHSS A,B,C'
18894 `uw2 __MQSUBHUS (uw2, uw2)' `C = __MQSUBHUS (A, B)' `MQSUBHUS A,B,C'
18895 `void __MQXMACHS (acc, sw2, `__MQXMACHS (C, A, B)' `MQXMACHS A,B,C'
18897 `void __MQXMACXHS (acc, sw2, `__MQXMACXHS (C, A, B)' `MQXMACXHS A,B,C'
18899 `uw1 __MRDACC (acc)' `B = __MRDACC (A)' `MRDACC A,B'
18900 `uw1 __MRDACCG (acc)' `B = __MRDACCG (A)' `MRDACCG A,B'
18901 `uw1 __MROTLI (uw1, const)' `C = __MROTLI (A, B)' `MROTLI A,#B,C'
18902 `uw1 __MROTRI (uw1, const)' `C = __MROTRI (A, B)' `MROTRI A,#B,C'
18903 `sw1 __MSATHS (sw1, sw1)' `C = __MSATHS (A, B)' `MSATHS A,B,C'
18904 `uw1 __MSATHU (uw1, uw1)' `C = __MSATHU (A, B)' `MSATHU A,B,C'
18905 `uw1 __MSLLHI (uw1, const)' `C = __MSLLHI (A, B)' `MSLLHI A,#B,C'
18906 `sw1 __MSRAHI (sw1, const)' `C = __MSRAHI (A, B)' `MSRAHI A,#B,C'
18907 `uw1 __MSRLHI (uw1, const)' `C = __MSRLHI (A, B)' `MSRLHI A,#B,C'
18908 `void __MSUBACCS (acc, acc)' `__MSUBACCS (B, A)' `MSUBACCS A,B'
18909 `sw1 __MSUBHSS (sw1, sw1)' `C = __MSUBHSS (A, B)' `MSUBHSS A,B,C'
18910 `uw1 __MSUBHUS (uw1, uw1)' `C = __MSUBHUS (A, B)' `MSUBHUS A,B,C'
18911 `void __MTRAP (void)' `__MTRAP ()' `MTRAP'
18912 `uw2 __MUNPACKH (uw1)' `B = __MUNPACKH (A)' `MUNPACKH A,B'
18913 `uw1 __MWCUT (uw2, uw1)' `C = __MWCUT (A, B)' `MWCUT A,B,C'
18914 `void __MWTACC (acc, uw1)' `__MWTACC (B, A)' `MWTACC A,B'
18915 `void __MWTACCG (acc, uw1)' `__MWTACCG (B, A)' `MWTACCG A,B'
18916 `uw1 __MXOR (uw1, uw1)' `C = __MXOR (A, B)' `MXOR A,B,C'
18919 File: gcc.info, Node: Other Built-in Functions, Prev: Directly-mapped Media Functions, Up: FR-V Built-in Functions
18921 5.45.3.4 Other Built-in Functions
18922 .................................
18924 This section describes built-in functions that are not named after a
18925 specific FR-V instruction.
18927 `sw2 __IACCreadll (iacc REG)'
18928 Return the full 64-bit value of IACC0. The REG argument is
18929 reserved for future expansion and must be 0.
18931 `sw1 __IACCreadl (iacc REG)'
18932 Return the value of IACC0H if REG is 0 and IACC0L if REG is 1.
18933 Other values of REG are rejected as invalid.
18935 `void __IACCsetll (iacc REG, sw2 X)'
18936 Set the full 64-bit value of IACC0 to X. The REG argument is
18937 reserved for future expansion and must be 0.
18939 `void __IACCsetl (iacc REG, sw1 X)'
18940 Set IACC0H to X if REG is 0 and IACC0L to X if REG is 1. Other
18941 values of REG are rejected as invalid.
18943 `void __data_prefetch0 (const void *X)'
18944 Use the `dcpl' instruction to load the contents of address X into
18947 `void __data_prefetch (const void *X)'
18948 Use the `nldub' instruction to load the contents of address X into
18949 the data cache. The instruction will be issued in slot I1.
18952 File: gcc.info, Node: X86 Built-in Functions, Next: MIPS Paired-Single Support, Prev: FR-V Built-in Functions, Up: Target Builtins
18954 5.45.4 X86 Built-in Functions
18955 -----------------------------
18957 These built-in functions are available for the i386 and x86-64 family
18958 of computers, depending on the command-line switches used.
18960 The following machine modes are available for use with MMX built-in
18961 functions (*note Vector Extensions::): `V2SI' for a vector of two
18962 32-bit integers, `V4HI' for a vector of four 16-bit integers, and
18963 `V8QI' for a vector of eight 8-bit integers. Some of the built-in
18964 functions operate on MMX registers as a whole 64-bit entity, these use
18965 `DI' as their mode.
18967 If 3Dnow extensions are enabled, `V2SF' is used as a mode for a vector
18968 of two 32-bit floating point values.
18970 If SSE extensions are enabled, `V4SF' is used for a vector of four
18971 32-bit floating point values. Some instructions use a vector of four
18972 32-bit integers, these use `V4SI'. Finally, some instructions operate
18973 on an entire vector register, interpreting it as a 128-bit integer,
18974 these use mode `TI'.
18976 The following built-in functions are made available by `-mmmx'. All
18977 of them generate the machine instruction that is part of the name.
18979 v8qi __builtin_ia32_paddb (v8qi, v8qi)
18980 v4hi __builtin_ia32_paddw (v4hi, v4hi)
18981 v2si __builtin_ia32_paddd (v2si, v2si)
18982 v8qi __builtin_ia32_psubb (v8qi, v8qi)
18983 v4hi __builtin_ia32_psubw (v4hi, v4hi)
18984 v2si __builtin_ia32_psubd (v2si, v2si)
18985 v8qi __builtin_ia32_paddsb (v8qi, v8qi)
18986 v4hi __builtin_ia32_paddsw (v4hi, v4hi)
18987 v8qi __builtin_ia32_psubsb (v8qi, v8qi)
18988 v4hi __builtin_ia32_psubsw (v4hi, v4hi)
18989 v8qi __builtin_ia32_paddusb (v8qi, v8qi)
18990 v4hi __builtin_ia32_paddusw (v4hi, v4hi)
18991 v8qi __builtin_ia32_psubusb (v8qi, v8qi)
18992 v4hi __builtin_ia32_psubusw (v4hi, v4hi)
18993 v4hi __builtin_ia32_pmullw (v4hi, v4hi)
18994 v4hi __builtin_ia32_pmulhw (v4hi, v4hi)
18995 di __builtin_ia32_pand (di, di)
18996 di __builtin_ia32_pandn (di,di)
18997 di __builtin_ia32_por (di, di)
18998 di __builtin_ia32_pxor (di, di)
18999 v8qi __builtin_ia32_pcmpeqb (v8qi, v8qi)
19000 v4hi __builtin_ia32_pcmpeqw (v4hi, v4hi)
19001 v2si __builtin_ia32_pcmpeqd (v2si, v2si)
19002 v8qi __builtin_ia32_pcmpgtb (v8qi, v8qi)
19003 v4hi __builtin_ia32_pcmpgtw (v4hi, v4hi)
19004 v2si __builtin_ia32_pcmpgtd (v2si, v2si)
19005 v8qi __builtin_ia32_punpckhbw (v8qi, v8qi)
19006 v4hi __builtin_ia32_punpckhwd (v4hi, v4hi)
19007 v2si __builtin_ia32_punpckhdq (v2si, v2si)
19008 v8qi __builtin_ia32_punpcklbw (v8qi, v8qi)
19009 v4hi __builtin_ia32_punpcklwd (v4hi, v4hi)
19010 v2si __builtin_ia32_punpckldq (v2si, v2si)
19011 v8qi __builtin_ia32_packsswb (v4hi, v4hi)
19012 v4hi __builtin_ia32_packssdw (v2si, v2si)
19013 v8qi __builtin_ia32_packuswb (v4hi, v4hi)
19015 The following built-in functions are made available either with
19016 `-msse', or with a combination of `-m3dnow' and `-march=athlon'. All
19017 of them generate the machine instruction that is part of the name.
19019 v4hi __builtin_ia32_pmulhuw (v4hi, v4hi)
19020 v8qi __builtin_ia32_pavgb (v8qi, v8qi)
19021 v4hi __builtin_ia32_pavgw (v4hi, v4hi)
19022 v4hi __builtin_ia32_psadbw (v8qi, v8qi)
19023 v8qi __builtin_ia32_pmaxub (v8qi, v8qi)
19024 v4hi __builtin_ia32_pmaxsw (v4hi, v4hi)
19025 v8qi __builtin_ia32_pminub (v8qi, v8qi)
19026 v4hi __builtin_ia32_pminsw (v4hi, v4hi)
19027 int __builtin_ia32_pextrw (v4hi, int)
19028 v4hi __builtin_ia32_pinsrw (v4hi, int, int)
19029 int __builtin_ia32_pmovmskb (v8qi)
19030 void __builtin_ia32_maskmovq (v8qi, v8qi, char *)
19031 void __builtin_ia32_movntq (di *, di)
19032 void __builtin_ia32_sfence (void)
19034 The following built-in functions are available when `-msse' is used.
19035 All of them generate the machine instruction that is part of the name.
19037 int __builtin_ia32_comieq (v4sf, v4sf)
19038 int __builtin_ia32_comineq (v4sf, v4sf)
19039 int __builtin_ia32_comilt (v4sf, v4sf)
19040 int __builtin_ia32_comile (v4sf, v4sf)
19041 int __builtin_ia32_comigt (v4sf, v4sf)
19042 int __builtin_ia32_comige (v4sf, v4sf)
19043 int __builtin_ia32_ucomieq (v4sf, v4sf)
19044 int __builtin_ia32_ucomineq (v4sf, v4sf)
19045 int __builtin_ia32_ucomilt (v4sf, v4sf)
19046 int __builtin_ia32_ucomile (v4sf, v4sf)
19047 int __builtin_ia32_ucomigt (v4sf, v4sf)
19048 int __builtin_ia32_ucomige (v4sf, v4sf)
19049 v4sf __builtin_ia32_addps (v4sf, v4sf)
19050 v4sf __builtin_ia32_subps (v4sf, v4sf)
19051 v4sf __builtin_ia32_mulps (v4sf, v4sf)
19052 v4sf __builtin_ia32_divps (v4sf, v4sf)
19053 v4sf __builtin_ia32_addss (v4sf, v4sf)
19054 v4sf __builtin_ia32_subss (v4sf, v4sf)
19055 v4sf __builtin_ia32_mulss (v4sf, v4sf)
19056 v4sf __builtin_ia32_divss (v4sf, v4sf)
19057 v4si __builtin_ia32_cmpeqps (v4sf, v4sf)
19058 v4si __builtin_ia32_cmpltps (v4sf, v4sf)
19059 v4si __builtin_ia32_cmpleps (v4sf, v4sf)
19060 v4si __builtin_ia32_cmpgtps (v4sf, v4sf)
19061 v4si __builtin_ia32_cmpgeps (v4sf, v4sf)
19062 v4si __builtin_ia32_cmpunordps (v4sf, v4sf)
19063 v4si __builtin_ia32_cmpneqps (v4sf, v4sf)
19064 v4si __builtin_ia32_cmpnltps (v4sf, v4sf)
19065 v4si __builtin_ia32_cmpnleps (v4sf, v4sf)
19066 v4si __builtin_ia32_cmpngtps (v4sf, v4sf)
19067 v4si __builtin_ia32_cmpngeps (v4sf, v4sf)
19068 v4si __builtin_ia32_cmpordps (v4sf, v4sf)
19069 v4si __builtin_ia32_cmpeqss (v4sf, v4sf)
19070 v4si __builtin_ia32_cmpltss (v4sf, v4sf)
19071 v4si __builtin_ia32_cmpless (v4sf, v4sf)
19072 v4si __builtin_ia32_cmpunordss (v4sf, v4sf)
19073 v4si __builtin_ia32_cmpneqss (v4sf, v4sf)
19074 v4si __builtin_ia32_cmpnlts (v4sf, v4sf)
19075 v4si __builtin_ia32_cmpnless (v4sf, v4sf)
19076 v4si __builtin_ia32_cmpordss (v4sf, v4sf)
19077 v4sf __builtin_ia32_maxps (v4sf, v4sf)
19078 v4sf __builtin_ia32_maxss (v4sf, v4sf)
19079 v4sf __builtin_ia32_minps (v4sf, v4sf)
19080 v4sf __builtin_ia32_minss (v4sf, v4sf)
19081 v4sf __builtin_ia32_andps (v4sf, v4sf)
19082 v4sf __builtin_ia32_andnps (v4sf, v4sf)
19083 v4sf __builtin_ia32_orps (v4sf, v4sf)
19084 v4sf __builtin_ia32_xorps (v4sf, v4sf)
19085 v4sf __builtin_ia32_movss (v4sf, v4sf)
19086 v4sf __builtin_ia32_movhlps (v4sf, v4sf)
19087 v4sf __builtin_ia32_movlhps (v4sf, v4sf)
19088 v4sf __builtin_ia32_unpckhps (v4sf, v4sf)
19089 v4sf __builtin_ia32_unpcklps (v4sf, v4sf)
19090 v4sf __builtin_ia32_cvtpi2ps (v4sf, v2si)
19091 v4sf __builtin_ia32_cvtsi2ss (v4sf, int)
19092 v2si __builtin_ia32_cvtps2pi (v4sf)
19093 int __builtin_ia32_cvtss2si (v4sf)
19094 v2si __builtin_ia32_cvttps2pi (v4sf)
19095 int __builtin_ia32_cvttss2si (v4sf)
19096 v4sf __builtin_ia32_rcpps (v4sf)
19097 v4sf __builtin_ia32_rsqrtps (v4sf)
19098 v4sf __builtin_ia32_sqrtps (v4sf)
19099 v4sf __builtin_ia32_rcpss (v4sf)
19100 v4sf __builtin_ia32_rsqrtss (v4sf)
19101 v4sf __builtin_ia32_sqrtss (v4sf)
19102 v4sf __builtin_ia32_shufps (v4sf, v4sf, int)
19103 void __builtin_ia32_movntps (float *, v4sf)
19104 int __builtin_ia32_movmskps (v4sf)
19106 The following built-in functions are available when `-msse' is used.
19108 `v4sf __builtin_ia32_loadaps (float *)'
19109 Generates the `movaps' machine instruction as a load from memory.
19111 `void __builtin_ia32_storeaps (float *, v4sf)'
19112 Generates the `movaps' machine instruction as a store to memory.
19114 `v4sf __builtin_ia32_loadups (float *)'
19115 Generates the `movups' machine instruction as a load from memory.
19117 `void __builtin_ia32_storeups (float *, v4sf)'
19118 Generates the `movups' machine instruction as a store to memory.
19120 `v4sf __builtin_ia32_loadsss (float *)'
19121 Generates the `movss' machine instruction as a load from memory.
19123 `void __builtin_ia32_storess (float *, v4sf)'
19124 Generates the `movss' machine instruction as a store to memory.
19126 `v4sf __builtin_ia32_loadhps (v4sf, v2si *)'
19127 Generates the `movhps' machine instruction as a load from memory.
19129 `v4sf __builtin_ia32_loadlps (v4sf, v2si *)'
19130 Generates the `movlps' machine instruction as a load from memory
19132 `void __builtin_ia32_storehps (v4sf, v2si *)'
19133 Generates the `movhps' machine instruction as a store to memory.
19135 `void __builtin_ia32_storelps (v4sf, v2si *)'
19136 Generates the `movlps' machine instruction as a store to memory.
19138 The following built-in functions are available when `-msse3' is used.
19139 All of them generate the machine instruction that is part of the name.
19141 v2df __builtin_ia32_addsubpd (v2df, v2df)
19142 v2df __builtin_ia32_addsubps (v2df, v2df)
19143 v2df __builtin_ia32_haddpd (v2df, v2df)
19144 v2df __builtin_ia32_haddps (v2df, v2df)
19145 v2df __builtin_ia32_hsubpd (v2df, v2df)
19146 v2df __builtin_ia32_hsubps (v2df, v2df)
19147 v16qi __builtin_ia32_lddqu (char const *)
19148 void __builtin_ia32_monitor (void *, unsigned int, unsigned int)
19149 v2df __builtin_ia32_movddup (v2df)
19150 v4sf __builtin_ia32_movshdup (v4sf)
19151 v4sf __builtin_ia32_movsldup (v4sf)
19152 void __builtin_ia32_mwait (unsigned int, unsigned int)
19154 The following built-in functions are available when `-msse3' is used.
19156 `v2df __builtin_ia32_loadddup (double const *)'
19157 Generates the `movddup' machine instruction as a load from memory.
19159 The following built-in functions are available when `-m3dnow' is used.
19160 All of them generate the machine instruction that is part of the name.
19162 void __builtin_ia32_femms (void)
19163 v8qi __builtin_ia32_pavgusb (v8qi, v8qi)
19164 v2si __builtin_ia32_pf2id (v2sf)
19165 v2sf __builtin_ia32_pfacc (v2sf, v2sf)
19166 v2sf __builtin_ia32_pfadd (v2sf, v2sf)
19167 v2si __builtin_ia32_pfcmpeq (v2sf, v2sf)
19168 v2si __builtin_ia32_pfcmpge (v2sf, v2sf)
19169 v2si __builtin_ia32_pfcmpgt (v2sf, v2sf)
19170 v2sf __builtin_ia32_pfmax (v2sf, v2sf)
19171 v2sf __builtin_ia32_pfmin (v2sf, v2sf)
19172 v2sf __builtin_ia32_pfmul (v2sf, v2sf)
19173 v2sf __builtin_ia32_pfrcp (v2sf)
19174 v2sf __builtin_ia32_pfrcpit1 (v2sf, v2sf)
19175 v2sf __builtin_ia32_pfrcpit2 (v2sf, v2sf)
19176 v2sf __builtin_ia32_pfrsqrt (v2sf)
19177 v2sf __builtin_ia32_pfrsqrtit1 (v2sf, v2sf)
19178 v2sf __builtin_ia32_pfsub (v2sf, v2sf)
19179 v2sf __builtin_ia32_pfsubr (v2sf, v2sf)
19180 v2sf __builtin_ia32_pi2fd (v2si)
19181 v4hi __builtin_ia32_pmulhrw (v4hi, v4hi)
19183 The following built-in functions are available when both `-m3dnow' and
19184 `-march=athlon' are used. All of them generate the machine instruction
19185 that is part of the name.
19187 v2si __builtin_ia32_pf2iw (v2sf)
19188 v2sf __builtin_ia32_pfnacc (v2sf, v2sf)
19189 v2sf __builtin_ia32_pfpnacc (v2sf, v2sf)
19190 v2sf __builtin_ia32_pi2fw (v2si)
19191 v2sf __builtin_ia32_pswapdsf (v2sf)
19192 v2si __builtin_ia32_pswapdsi (v2si)
19195 File: gcc.info, Node: MIPS Paired-Single Support, Next: PowerPC AltiVec Built-in Functions, Prev: X86 Built-in Functions, Up: Target Builtins
19197 5.45.5 MIPS Paired-Single Support
19198 ---------------------------------
19200 The MIPS64 architecture includes a number of instructions that operate
19201 on pairs of single-precision floating-point values. Each pair is
19202 packed into a 64-bit floating-point register, with one element being
19203 designated the "upper half" and the other being designated the "lower
19206 GCC supports paired-single operations using both the generic vector
19207 extensions (*note Vector Extensions::) and a collection of
19208 MIPS-specific built-in functions. Both kinds of support are enabled by
19209 the `-mpaired-single' command-line option.
19211 The vector type associated with paired-single values is usually called
19212 `v2sf'. It can be defined in C as follows:
19214 typedef float v2sf __attribute__ ((vector_size (8)));
19216 `v2sf' values are initialized in the same way as aggregates. For
19219 v2sf a = {1.5, 9.1};
19224 _Note:_ The CPU's endianness determines which value is stored in the
19225 upper half of a register and which value is stored in the lower half.
19226 On little-endian targets, the first value is the lower one and the
19227 second value is the upper one. The opposite order applies to
19228 big-endian targets. For example, the code above will set the lower
19229 half of `a' to `1.5' on little-endian targets and `9.1' on big-endian
19234 * Paired-Single Arithmetic::
19235 * Paired-Single Built-in Functions::
19236 * MIPS-3D Built-in Functions::
19239 File: gcc.info, Node: Paired-Single Arithmetic, Next: Paired-Single Built-in Functions, Up: MIPS Paired-Single Support
19241 5.45.5.1 Paired-Single Arithmetic
19242 .................................
19244 The table below lists the `v2sf' operations for which hardware support
19245 exists. `a', `b' and `c' are `v2sf' values and `x' is an integral
19248 C code MIPS instruction
19253 `a * b + c' `madd.ps'
19254 `a * b - c' `msub.ps'
19255 `-(a * b + c)' `nmadd.ps'
19256 `-(a * b - c)' `nmsub.ps'
19257 `x ? a : b' `movn.ps'/`movz.ps'
19259 Note that the multiply-accumulate instructions can be disabled using
19260 the command-line option `-mno-fused-madd'.
19263 File: gcc.info, Node: Paired-Single Built-in Functions, Next: MIPS-3D Built-in Functions, Prev: Paired-Single Arithmetic, Up: MIPS Paired-Single Support
19265 5.45.5.2 Paired-Single Built-in Functions
19266 .........................................
19268 The following paired-single functions map directly to a particular MIPS
19269 instruction. Please refer to the architecture specification for
19270 details on what each instruction does.
19272 `v2sf __builtin_mips_pll_ps (v2sf, v2sf)'
19273 Pair lower lower (`pll.ps').
19275 `v2sf __builtin_mips_pul_ps (v2sf, v2sf)'
19276 Pair upper lower (`pul.ps').
19278 `v2sf __builtin_mips_plu_ps (v2sf, v2sf)'
19279 Pair lower upper (`plu.ps').
19281 `v2sf __builtin_mips_puu_ps (v2sf, v2sf)'
19282 Pair upper upper (`puu.ps').
19284 `v2sf __builtin_mips_cvt_ps_s (float, float)'
19285 Convert pair to paired single (`cvt.ps.s').
19287 `float __builtin_mips_cvt_s_pl (v2sf)'
19288 Convert pair lower to single (`cvt.s.pl').
19290 `float __builtin_mips_cvt_s_pu (v2sf)'
19291 Convert pair upper to single (`cvt.s.pu').
19293 `v2sf __builtin_mips_abs_ps (v2sf)'
19294 Absolute value (`abs.ps').
19296 `v2sf __builtin_mips_alnv_ps (v2sf, v2sf, int)'
19297 Align variable (`alnv.ps').
19299 _Note:_ The value of the third parameter must be 0 or 4 modulo 8,
19300 otherwise the result will be unpredictable. Please read the
19301 instruction description for details.
19303 The following multi-instruction functions are also available. In each
19304 case, COND can be any of the 16 floating-point conditions: `f', `un',
19305 `eq', `ueq', `olt', `ult', `ole', `ule', `sf', `ngle', `seq', `ngl',
19306 `lt', `nge', `le' or `ngt'.
19308 `v2sf __builtin_mips_movt_c_COND_ps (v2sf A, v2sf B, v2sf C, v2sf D)'
19309 `v2sf __builtin_mips_movf_c_COND_ps (v2sf A, v2sf B, v2sf C, v2sf D)'
19310 Conditional move based on floating point comparison (`c.COND.ps',
19311 `movt.ps'/`movf.ps').
19313 The `movt' functions return the value X computed by:
19319 The `movf' functions are similar but use `movf.ps' instead of
19322 `int __builtin_mips_upper_c_COND_ps (v2sf A, v2sf B)'
19323 `int __builtin_mips_lower_c_COND_ps (v2sf A, v2sf B)'
19324 Comparison of two paired-single values (`c.COND.ps',
19327 These functions compare A and B using `c.COND.ps' and return
19328 either the upper or lower half of the result. For example:
19331 if (__builtin_mips_upper_c_eq_ps (a, b))
19332 upper_halves_are_equal ();
19334 upper_halves_are_unequal ();
19336 if (__builtin_mips_lower_c_eq_ps (a, b))
19337 lower_halves_are_equal ();
19339 lower_halves_are_unequal ();
19342 File: gcc.info, Node: MIPS-3D Built-in Functions, Prev: Paired-Single Built-in Functions, Up: MIPS Paired-Single Support
19344 5.45.5.3 MIPS-3D Built-in Functions
19345 ...................................
19347 The MIPS-3D Application-Specific Extension (ASE) includes additional
19348 paired-single instructions that are designed to improve the performance
19349 of 3D graphics operations. Support for these instructions is controlled
19350 by the `-mips3d' command-line option.
19352 The functions listed below map directly to a particular MIPS-3D
19353 instruction. Please refer to the architecture specification for more
19354 details on what each instruction does.
19356 `v2sf __builtin_mips_addr_ps (v2sf, v2sf)'
19357 Reduction add (`addr.ps').
19359 `v2sf __builtin_mips_mulr_ps (v2sf, v2sf)'
19360 Reduction multiply (`mulr.ps').
19362 `v2sf __builtin_mips_cvt_pw_ps (v2sf)'
19363 Convert paired single to paired word (`cvt.pw.ps').
19365 `v2sf __builtin_mips_cvt_ps_pw (v2sf)'
19366 Convert paired word to paired single (`cvt.ps.pw').
19368 `float __builtin_mips_recip1_s (float)'
19369 `double __builtin_mips_recip1_d (double)'
19370 `v2sf __builtin_mips_recip1_ps (v2sf)'
19371 Reduced precision reciprocal (sequence step 1) (`recip1.FMT').
19373 `float __builtin_mips_recip2_s (float, float)'
19374 `double __builtin_mips_recip2_d (double, double)'
19375 `v2sf __builtin_mips_recip2_ps (v2sf, v2sf)'
19376 Reduced precision reciprocal (sequence step 2) (`recip2.FMT').
19378 `float __builtin_mips_rsqrt1_s (float)'
19379 `double __builtin_mips_rsqrt1_d (double)'
19380 `v2sf __builtin_mips_rsqrt1_ps (v2sf)'
19381 Reduced precision reciprocal square root (sequence step 1)
19384 `float __builtin_mips_rsqrt2_s (float, float)'
19385 `double __builtin_mips_rsqrt2_d (double, double)'
19386 `v2sf __builtin_mips_rsqrt2_ps (v2sf, v2sf)'
19387 Reduced precision reciprocal square root (sequence step 2)
19390 The following multi-instruction functions are also available. In each
19391 case, COND can be any of the 16 floating-point conditions: `f', `un',
19392 `eq', `ueq', `olt', `ult', `ole', `ule', `sf', `ngle', `seq', `ngl',
19393 `lt', `nge', `le' or `ngt'.
19395 `int __builtin_mips_cabs_COND_s (float A, float B)'
19396 `int __builtin_mips_cabs_COND_d (double A, double B)'
19397 Absolute comparison of two scalar values (`cabs.COND.FMT',
19400 These functions compare A and B using `cabs.COND.s' or
19401 `cabs.COND.d' and return the result as a boolean value. For
19405 if (__builtin_mips_cabs_eq_s (a, b))
19410 `int __builtin_mips_upper_cabs_COND_ps (v2sf A, v2sf B)'
19411 `int __builtin_mips_lower_cabs_COND_ps (v2sf A, v2sf B)'
19412 Absolute comparison of two paired-single values (`cabs.COND.ps',
19415 These functions compare A and B using `cabs.COND.ps' and return
19416 either the upper or lower half of the result. For example:
19419 if (__builtin_mips_upper_cabs_eq_ps (a, b))
19420 upper_halves_are_equal ();
19422 upper_halves_are_unequal ();
19424 if (__builtin_mips_lower_cabs_eq_ps (a, b))
19425 lower_halves_are_equal ();
19427 lower_halves_are_unequal ();
19429 `v2sf __builtin_mips_movt_cabs_COND_ps (v2sf A, v2sf B, v2sf C, v2sf D)'
19430 `v2sf __builtin_mips_movf_cabs_COND_ps (v2sf A, v2sf B, v2sf C, v2sf D)'
19431 Conditional move based on absolute comparison (`cabs.COND.ps',
19432 `movt.ps'/`movf.ps').
19434 The `movt' functions return the value X computed by:
19436 cabs.COND.ps CC,A,B
19440 The `movf' functions are similar but use `movf.ps' instead of
19443 `int __builtin_mips_any_c_COND_ps (v2sf A, v2sf B)'
19444 `int __builtin_mips_all_c_COND_ps (v2sf A, v2sf B)'
19445 `int __builtin_mips_any_cabs_COND_ps (v2sf A, v2sf B)'
19446 `int __builtin_mips_all_cabs_COND_ps (v2sf A, v2sf B)'
19447 Comparison of two paired-single values (`c.COND.ps'/`cabs.COND.ps',
19448 `bc1any2t'/`bc1any2f').
19450 These functions compare A and B using `c.COND.ps' or
19451 `cabs.COND.ps'. The `any' forms return true if either result is
19452 true and the `all' forms return true if both results are true.
19456 if (__builtin_mips_any_c_eq_ps (a, b))
19461 if (__builtin_mips_all_c_eq_ps (a, b))
19466 `int __builtin_mips_any_c_COND_4s (v2sf A, v2sf B, v2sf C, v2sf D)'
19467 `int __builtin_mips_all_c_COND_4s (v2sf A, v2sf B, v2sf C, v2sf D)'
19468 `int __builtin_mips_any_cabs_COND_4s (v2sf A, v2sf B, v2sf C, v2sf D)'
19469 `int __builtin_mips_all_cabs_COND_4s (v2sf A, v2sf B, v2sf C, v2sf D)'
19470 Comparison of four paired-single values
19471 (`c.COND.ps'/`cabs.COND.ps', `bc1any4t'/`bc1any4f').
19473 These functions use `c.COND.ps' or `cabs.COND.ps' to compare A
19474 with B and to compare C with D. The `any' forms return true if
19475 any of the four results are true and the `all' forms return true
19476 if all four results are true. For example:
19479 if (__builtin_mips_any_c_eq_4s (a, b, c, d))
19484 if (__builtin_mips_all_c_eq_4s (a, b, c, d))
19490 File: gcc.info, Node: PowerPC AltiVec Built-in Functions, Next: SPARC VIS Built-in Functions, Prev: MIPS Paired-Single Support, Up: Target Builtins
19492 5.45.6 PowerPC AltiVec Built-in Functions
19493 -----------------------------------------
19495 GCC provides an interface for the PowerPC family of processors to access
19496 the AltiVec operations described in Motorola's AltiVec Programming
19497 Interface Manual. The interface is made available by including
19498 `<altivec.h>' and using `-maltivec' and `-mabi=altivec'. The interface
19499 supports the following vector types.
19501 vector unsigned char
19505 vector unsigned short
19506 vector signed short
19510 vector unsigned int
19515 GCC's implementation of the high-level language interface available
19516 from C and C++ code differs from Motorola's documentation in several
19519 * A vector constant is a list of constant expressions within curly
19522 * A vector initializer requires no cast if the vector constant is of
19523 the same type as the variable it is initializing.
19525 * If `signed' or `unsigned' is omitted, the signedness of the vector
19526 type is the default signedness of the base type. The default
19527 varies depending on the operating system, so a portable program
19528 should always specify the signedness.
19530 * Compiling with `-maltivec' adds keywords `__vector', `__pixel',
19531 and `__bool'. Macros `vector', `pixel', and `bool' are defined in
19532 `<altivec.h>' and can be undefined.
19534 * GCC allows using a `typedef' name as the type specifier for a
19537 * For C, overloaded functions are implemented with macros so the
19538 following does not work:
19540 vec_add ((vector signed int){1, 2, 3, 4}, foo);
19542 Since `vec_add' is a macro, the vector constant in the example is
19543 treated as four separate arguments. Wrap the entire argument in
19544 parentheses for this to work.
19546 _Note:_ Only the `<altivec.h>' interface is supported. Internally,
19547 GCC uses built-in functions to achieve the functionality in the
19548 aforementioned header file, but they are not supported and are subject
19549 to change without notice.
19551 The following interfaces are supported for the generic and specific
19552 AltiVec operations and the AltiVec predicates. In cases where there is
19553 a direct mapping between generic and specific operations, only the
19554 generic names are shown here, although the specific operations can also
19557 Arguments that are documented as `const int' require literal integral
19558 values within the range required for that operation.
19560 vector signed char vec_abs (vector signed char);
19561 vector signed short vec_abs (vector signed short);
19562 vector signed int vec_abs (vector signed int);
19563 vector float vec_abs (vector float);
19565 vector signed char vec_abss (vector signed char);
19566 vector signed short vec_abss (vector signed short);
19567 vector signed int vec_abss (vector signed int);
19569 vector signed char vec_add (vector bool char, vector signed char);
19570 vector signed char vec_add (vector signed char, vector bool char);
19571 vector signed char vec_add (vector signed char, vector signed char);
19572 vector unsigned char vec_add (vector bool char, vector unsigned char);
19573 vector unsigned char vec_add (vector unsigned char, vector bool char);
19574 vector unsigned char vec_add (vector unsigned char,
19575 vector unsigned char);
19576 vector signed short vec_add (vector bool short, vector signed short);
19577 vector signed short vec_add (vector signed short, vector bool short);
19578 vector signed short vec_add (vector signed short, vector signed short);
19579 vector unsigned short vec_add (vector bool short,
19580 vector unsigned short);
19581 vector unsigned short vec_add (vector unsigned short,
19582 vector bool short);
19583 vector unsigned short vec_add (vector unsigned short,
19584 vector unsigned short);
19585 vector signed int vec_add (vector bool int, vector signed int);
19586 vector signed int vec_add (vector signed int, vector bool int);
19587 vector signed int vec_add (vector signed int, vector signed int);
19588 vector unsigned int vec_add (vector bool int, vector unsigned int);
19589 vector unsigned int vec_add (vector unsigned int, vector bool int);
19590 vector unsigned int vec_add (vector unsigned int, vector unsigned int);
19591 vector float vec_add (vector float, vector float);
19593 vector float vec_vaddfp (vector float, vector float);
19595 vector signed int vec_vadduwm (vector bool int, vector signed int);
19596 vector signed int vec_vadduwm (vector signed int, vector bool int);
19597 vector signed int vec_vadduwm (vector signed int, vector signed int);
19598 vector unsigned int vec_vadduwm (vector bool int, vector unsigned int);
19599 vector unsigned int vec_vadduwm (vector unsigned int, vector bool int);
19600 vector unsigned int vec_vadduwm (vector unsigned int,
19601 vector unsigned int);
19603 vector signed short vec_vadduhm (vector bool short,
19604 vector signed short);
19605 vector signed short vec_vadduhm (vector signed short,
19606 vector bool short);
19607 vector signed short vec_vadduhm (vector signed short,
19608 vector signed short);
19609 vector unsigned short vec_vadduhm (vector bool short,
19610 vector unsigned short);
19611 vector unsigned short vec_vadduhm (vector unsigned short,
19612 vector bool short);
19613 vector unsigned short vec_vadduhm (vector unsigned short,
19614 vector unsigned short);
19616 vector signed char vec_vaddubm (vector bool char, vector signed char);
19617 vector signed char vec_vaddubm (vector signed char, vector bool char);
19618 vector signed char vec_vaddubm (vector signed char, vector signed char);
19619 vector unsigned char vec_vaddubm (vector bool char,
19620 vector unsigned char);
19621 vector unsigned char vec_vaddubm (vector unsigned char,
19623 vector unsigned char vec_vaddubm (vector unsigned char,
19624 vector unsigned char);
19626 vector unsigned int vec_addc (vector unsigned int, vector unsigned int);
19628 vector unsigned char vec_adds (vector bool char, vector unsigned char);
19629 vector unsigned char vec_adds (vector unsigned char, vector bool char);
19630 vector unsigned char vec_adds (vector unsigned char,
19631 vector unsigned char);
19632 vector signed char vec_adds (vector bool char, vector signed char);
19633 vector signed char vec_adds (vector signed char, vector bool char);
19634 vector signed char vec_adds (vector signed char, vector signed char);
19635 vector unsigned short vec_adds (vector bool short,
19636 vector unsigned short);
19637 vector unsigned short vec_adds (vector unsigned short,
19638 vector bool short);
19639 vector unsigned short vec_adds (vector unsigned short,
19640 vector unsigned short);
19641 vector signed short vec_adds (vector bool short, vector signed short);
19642 vector signed short vec_adds (vector signed short, vector bool short);
19643 vector signed short vec_adds (vector signed short, vector signed short);
19644 vector unsigned int vec_adds (vector bool int, vector unsigned int);
19645 vector unsigned int vec_adds (vector unsigned int, vector bool int);
19646 vector unsigned int vec_adds (vector unsigned int, vector unsigned int);
19647 vector signed int vec_adds (vector bool int, vector signed int);
19648 vector signed int vec_adds (vector signed int, vector bool int);
19649 vector signed int vec_adds (vector signed int, vector signed int);
19651 vector signed int vec_vaddsws (vector bool int, vector signed int);
19652 vector signed int vec_vaddsws (vector signed int, vector bool int);
19653 vector signed int vec_vaddsws (vector signed int, vector signed int);
19655 vector unsigned int vec_vadduws (vector bool int, vector unsigned int);
19656 vector unsigned int vec_vadduws (vector unsigned int, vector bool int);
19657 vector unsigned int vec_vadduws (vector unsigned int,
19658 vector unsigned int);
19660 vector signed short vec_vaddshs (vector bool short,
19661 vector signed short);
19662 vector signed short vec_vaddshs (vector signed short,
19663 vector bool short);
19664 vector signed short vec_vaddshs (vector signed short,
19665 vector signed short);
19667 vector unsigned short vec_vadduhs (vector bool short,
19668 vector unsigned short);
19669 vector unsigned short vec_vadduhs (vector unsigned short,
19670 vector bool short);
19671 vector unsigned short vec_vadduhs (vector unsigned short,
19672 vector unsigned short);
19674 vector signed char vec_vaddsbs (vector bool char, vector signed char);
19675 vector signed char vec_vaddsbs (vector signed char, vector bool char);
19676 vector signed char vec_vaddsbs (vector signed char, vector signed char);
19678 vector unsigned char vec_vaddubs (vector bool char,
19679 vector unsigned char);
19680 vector unsigned char vec_vaddubs (vector unsigned char,
19682 vector unsigned char vec_vaddubs (vector unsigned char,
19683 vector unsigned char);
19685 vector float vec_and (vector float, vector float);
19686 vector float vec_and (vector float, vector bool int);
19687 vector float vec_and (vector bool int, vector float);
19688 vector bool int vec_and (vector bool int, vector bool int);
19689 vector signed int vec_and (vector bool int, vector signed int);
19690 vector signed int vec_and (vector signed int, vector bool int);
19691 vector signed int vec_and (vector signed int, vector signed int);
19692 vector unsigned int vec_and (vector bool int, vector unsigned int);
19693 vector unsigned int vec_and (vector unsigned int, vector bool int);
19694 vector unsigned int vec_and (vector unsigned int, vector unsigned int);
19695 vector bool short vec_and (vector bool short, vector bool short);
19696 vector signed short vec_and (vector bool short, vector signed short);
19697 vector signed short vec_and (vector signed short, vector bool short);
19698 vector signed short vec_and (vector signed short, vector signed short);
19699 vector unsigned short vec_and (vector bool short,
19700 vector unsigned short);
19701 vector unsigned short vec_and (vector unsigned short,
19702 vector bool short);
19703 vector unsigned short vec_and (vector unsigned short,
19704 vector unsigned short);
19705 vector signed char vec_and (vector bool char, vector signed char);
19706 vector bool char vec_and (vector bool char, vector bool char);
19707 vector signed char vec_and (vector signed char, vector bool char);
19708 vector signed char vec_and (vector signed char, vector signed char);
19709 vector unsigned char vec_and (vector bool char, vector unsigned char);
19710 vector unsigned char vec_and (vector unsigned char, vector bool char);
19711 vector unsigned char vec_and (vector unsigned char,
19712 vector unsigned char);
19714 vector float vec_andc (vector float, vector float);
19715 vector float vec_andc (vector float, vector bool int);
19716 vector float vec_andc (vector bool int, vector float);
19717 vector bool int vec_andc (vector bool int, vector bool int);
19718 vector signed int vec_andc (vector bool int, vector signed int);
19719 vector signed int vec_andc (vector signed int, vector bool int);
19720 vector signed int vec_andc (vector signed int, vector signed int);
19721 vector unsigned int vec_andc (vector bool int, vector unsigned int);
19722 vector unsigned int vec_andc (vector unsigned int, vector bool int);
19723 vector unsigned int vec_andc (vector unsigned int, vector unsigned int);
19724 vector bool short vec_andc (vector bool short, vector bool short);
19725 vector signed short vec_andc (vector bool short, vector signed short);
19726 vector signed short vec_andc (vector signed short, vector bool short);
19727 vector signed short vec_andc (vector signed short, vector signed short);
19728 vector unsigned short vec_andc (vector bool short,
19729 vector unsigned short);
19730 vector unsigned short vec_andc (vector unsigned short,
19731 vector bool short);
19732 vector unsigned short vec_andc (vector unsigned short,
19733 vector unsigned short);
19734 vector signed char vec_andc (vector bool char, vector signed char);
19735 vector bool char vec_andc (vector bool char, vector bool char);
19736 vector signed char vec_andc (vector signed char, vector bool char);
19737 vector signed char vec_andc (vector signed char, vector signed char);
19738 vector unsigned char vec_andc (vector bool char, vector unsigned char);
19739 vector unsigned char vec_andc (vector unsigned char, vector bool char);
19740 vector unsigned char vec_andc (vector unsigned char,
19741 vector unsigned char);
19743 vector unsigned char vec_avg (vector unsigned char,
19744 vector unsigned char);
19745 vector signed char vec_avg (vector signed char, vector signed char);
19746 vector unsigned short vec_avg (vector unsigned short,
19747 vector unsigned short);
19748 vector signed short vec_avg (vector signed short, vector signed short);
19749 vector unsigned int vec_avg (vector unsigned int, vector unsigned int);
19750 vector signed int vec_avg (vector signed int, vector signed int);
19752 vector signed int vec_vavgsw (vector signed int, vector signed int);
19754 vector unsigned int vec_vavguw (vector unsigned int,
19755 vector unsigned int);
19757 vector signed short vec_vavgsh (vector signed short,
19758 vector signed short);
19760 vector unsigned short vec_vavguh (vector unsigned short,
19761 vector unsigned short);
19763 vector signed char vec_vavgsb (vector signed char, vector signed char);
19765 vector unsigned char vec_vavgub (vector unsigned char,
19766 vector unsigned char);
19768 vector float vec_ceil (vector float);
19770 vector signed int vec_cmpb (vector float, vector float);
19772 vector bool char vec_cmpeq (vector signed char, vector signed char);
19773 vector bool char vec_cmpeq (vector unsigned char, vector unsigned char);
19774 vector bool short vec_cmpeq (vector signed short, vector signed short);
19775 vector bool short vec_cmpeq (vector unsigned short,
19776 vector unsigned short);
19777 vector bool int vec_cmpeq (vector signed int, vector signed int);
19778 vector bool int vec_cmpeq (vector unsigned int, vector unsigned int);
19779 vector bool int vec_cmpeq (vector float, vector float);
19781 vector bool int vec_vcmpeqfp (vector float, vector float);
19783 vector bool int vec_vcmpequw (vector signed int, vector signed int);
19784 vector bool int vec_vcmpequw (vector unsigned int, vector unsigned int);
19786 vector bool short vec_vcmpequh (vector signed short,
19787 vector signed short);
19788 vector bool short vec_vcmpequh (vector unsigned short,
19789 vector unsigned short);
19791 vector bool char vec_vcmpequb (vector signed char, vector signed char);
19792 vector bool char vec_vcmpequb (vector unsigned char,
19793 vector unsigned char);
19795 vector bool int vec_cmpge (vector float, vector float);
19797 vector bool char vec_cmpgt (vector unsigned char, vector unsigned char);
19798 vector bool char vec_cmpgt (vector signed char, vector signed char);
19799 vector bool short vec_cmpgt (vector unsigned short,
19800 vector unsigned short);
19801 vector bool short vec_cmpgt (vector signed short, vector signed short);
19802 vector bool int vec_cmpgt (vector unsigned int, vector unsigned int);
19803 vector bool int vec_cmpgt (vector signed int, vector signed int);
19804 vector bool int vec_cmpgt (vector float, vector float);
19806 vector bool int vec_vcmpgtfp (vector float, vector float);
19808 vector bool int vec_vcmpgtsw (vector signed int, vector signed int);
19810 vector bool int vec_vcmpgtuw (vector unsigned int, vector unsigned int);
19812 vector bool short vec_vcmpgtsh (vector signed short,
19813 vector signed short);
19815 vector bool short vec_vcmpgtuh (vector unsigned short,
19816 vector unsigned short);
19818 vector bool char vec_vcmpgtsb (vector signed char, vector signed char);
19820 vector bool char vec_vcmpgtub (vector unsigned char,
19821 vector unsigned char);
19823 vector bool int vec_cmple (vector float, vector float);
19825 vector bool char vec_cmplt (vector unsigned char, vector unsigned char);
19826 vector bool char vec_cmplt (vector signed char, vector signed char);
19827 vector bool short vec_cmplt (vector unsigned short,
19828 vector unsigned short);
19829 vector bool short vec_cmplt (vector signed short, vector signed short);
19830 vector bool int vec_cmplt (vector unsigned int, vector unsigned int);
19831 vector bool int vec_cmplt (vector signed int, vector signed int);
19832 vector bool int vec_cmplt (vector float, vector float);
19834 vector float vec_ctf (vector unsigned int, const int);
19835 vector float vec_ctf (vector signed int, const int);
19837 vector float vec_vcfsx (vector signed int, const int);
19839 vector float vec_vcfux (vector unsigned int, const int);
19841 vector signed int vec_cts (vector float, const int);
19843 vector unsigned int vec_ctu (vector float, const int);
19845 void vec_dss (const int);
19847 void vec_dssall (void);
19849 void vec_dst (const vector unsigned char *, int, const int);
19850 void vec_dst (const vector signed char *, int, const int);
19851 void vec_dst (const vector bool char *, int, const int);
19852 void vec_dst (const vector unsigned short *, int, const int);
19853 void vec_dst (const vector signed short *, int, const int);
19854 void vec_dst (const vector bool short *, int, const int);
19855 void vec_dst (const vector pixel *, int, const int);
19856 void vec_dst (const vector unsigned int *, int, const int);
19857 void vec_dst (const vector signed int *, int, const int);
19858 void vec_dst (const vector bool int *, int, const int);
19859 void vec_dst (const vector float *, int, const int);
19860 void vec_dst (const unsigned char *, int, const int);
19861 void vec_dst (const signed char *, int, const int);
19862 void vec_dst (const unsigned short *, int, const int);
19863 void vec_dst (const short *, int, const int);
19864 void vec_dst (const unsigned int *, int, const int);
19865 void vec_dst (const int *, int, const int);
19866 void vec_dst (const unsigned long *, int, const int);
19867 void vec_dst (const long *, int, const int);
19868 void vec_dst (const float *, int, const int);
19870 void vec_dstst (const vector unsigned char *, int, const int);
19871 void vec_dstst (const vector signed char *, int, const int);
19872 void vec_dstst (const vector bool char *, int, const int);
19873 void vec_dstst (const vector unsigned short *, int, const int);
19874 void vec_dstst (const vector signed short *, int, const int);
19875 void vec_dstst (const vector bool short *, int, const int);
19876 void vec_dstst (const vector pixel *, int, const int);
19877 void vec_dstst (const vector unsigned int *, int, const int);
19878 void vec_dstst (const vector signed int *, int, const int);
19879 void vec_dstst (const vector bool int *, int, const int);
19880 void vec_dstst (const vector float *, int, const int);
19881 void vec_dstst (const unsigned char *, int, const int);
19882 void vec_dstst (const signed char *, int, const int);
19883 void vec_dstst (const unsigned short *, int, const int);
19884 void vec_dstst (const short *, int, const int);
19885 void vec_dstst (const unsigned int *, int, const int);
19886 void vec_dstst (const int *, int, const int);
19887 void vec_dstst (const unsigned long *, int, const int);
19888 void vec_dstst (const long *, int, const int);
19889 void vec_dstst (const float *, int, const int);
19891 void vec_dststt (const vector unsigned char *, int, const int);
19892 void vec_dststt (const vector signed char *, int, const int);
19893 void vec_dststt (const vector bool char *, int, const int);
19894 void vec_dststt (const vector unsigned short *, int, const int);
19895 void vec_dststt (const vector signed short *, int, const int);
19896 void vec_dststt (const vector bool short *, int, const int);
19897 void vec_dststt (const vector pixel *, int, const int);
19898 void vec_dststt (const vector unsigned int *, int, const int);
19899 void vec_dststt (const vector signed int *, int, const int);
19900 void vec_dststt (const vector bool int *, int, const int);
19901 void vec_dststt (const vector float *, int, const int);
19902 void vec_dststt (const unsigned char *, int, const int);
19903 void vec_dststt (const signed char *, int, const int);
19904 void vec_dststt (const unsigned short *, int, const int);
19905 void vec_dststt (const short *, int, const int);
19906 void vec_dststt (const unsigned int *, int, const int);
19907 void vec_dststt (const int *, int, const int);
19908 void vec_dststt (const unsigned long *, int, const int);
19909 void vec_dststt (const long *, int, const int);
19910 void vec_dststt (const float *, int, const int);
19912 void vec_dstt (const vector unsigned char *, int, const int);
19913 void vec_dstt (const vector signed char *, int, const int);
19914 void vec_dstt (const vector bool char *, int, const int);
19915 void vec_dstt (const vector unsigned short *, int, const int);
19916 void vec_dstt (const vector signed short *, int, const int);
19917 void vec_dstt (const vector bool short *, int, const int);
19918 void vec_dstt (const vector pixel *, int, const int);
19919 void vec_dstt (const vector unsigned int *, int, const int);
19920 void vec_dstt (const vector signed int *, int, const int);
19921 void vec_dstt (const vector bool int *, int, const int);
19922 void vec_dstt (const vector float *, int, const int);
19923 void vec_dstt (const unsigned char *, int, const int);
19924 void vec_dstt (const signed char *, int, const int);
19925 void vec_dstt (const unsigned short *, int, const int);
19926 void vec_dstt (const short *, int, const int);
19927 void vec_dstt (const unsigned int *, int, const int);
19928 void vec_dstt (const int *, int, const int);
19929 void vec_dstt (const unsigned long *, int, const int);
19930 void vec_dstt (const long *, int, const int);
19931 void vec_dstt (const float *, int, const int);
19933 vector float vec_expte (vector float);
19935 vector float vec_floor (vector float);
19937 vector float vec_ld (int, const vector float *);
19938 vector float vec_ld (int, const float *);
19939 vector bool int vec_ld (int, const vector bool int *);
19940 vector signed int vec_ld (int, const vector signed int *);
19941 vector signed int vec_ld (int, const int *);
19942 vector signed int vec_ld (int, const long *);
19943 vector unsigned int vec_ld (int, const vector unsigned int *);
19944 vector unsigned int vec_ld (int, const unsigned int *);
19945 vector unsigned int vec_ld (int, const unsigned long *);
19946 vector bool short vec_ld (int, const vector bool short *);
19947 vector pixel vec_ld (int, const vector pixel *);
19948 vector signed short vec_ld (int, const vector signed short *);
19949 vector signed short vec_ld (int, const short *);
19950 vector unsigned short vec_ld (int, const vector unsigned short *);
19951 vector unsigned short vec_ld (int, const unsigned short *);
19952 vector bool char vec_ld (int, const vector bool char *);
19953 vector signed char vec_ld (int, const vector signed char *);
19954 vector signed char vec_ld (int, const signed char *);
19955 vector unsigned char vec_ld (int, const vector unsigned char *);
19956 vector unsigned char vec_ld (int, const unsigned char *);
19958 vector signed char vec_lde (int, const signed char *);
19959 vector unsigned char vec_lde (int, const unsigned char *);
19960 vector signed short vec_lde (int, const short *);
19961 vector unsigned short vec_lde (int, const unsigned short *);
19962 vector float vec_lde (int, const float *);
19963 vector signed int vec_lde (int, const int *);
19964 vector unsigned int vec_lde (int, const unsigned int *);
19965 vector signed int vec_lde (int, const long *);
19966 vector unsigned int vec_lde (int, const unsigned long *);
19968 vector float vec_lvewx (int, float *);
19969 vector signed int vec_lvewx (int, int *);
19970 vector unsigned int vec_lvewx (int, unsigned int *);
19971 vector signed int vec_lvewx (int, long *);
19972 vector unsigned int vec_lvewx (int, unsigned long *);
19974 vector signed short vec_lvehx (int, short *);
19975 vector unsigned short vec_lvehx (int, unsigned short *);
19977 vector signed char vec_lvebx (int, char *);
19978 vector unsigned char vec_lvebx (int, unsigned char *);
19980 vector float vec_ldl (int, const vector float *);
19981 vector float vec_ldl (int, const float *);
19982 vector bool int vec_ldl (int, const vector bool int *);
19983 vector signed int vec_ldl (int, const vector signed int *);
19984 vector signed int vec_ldl (int, const int *);
19985 vector signed int vec_ldl (int, const long *);
19986 vector unsigned int vec_ldl (int, const vector unsigned int *);
19987 vector unsigned int vec_ldl (int, const unsigned int *);
19988 vector unsigned int vec_ldl (int, const unsigned long *);
19989 vector bool short vec_ldl (int, const vector bool short *);
19990 vector pixel vec_ldl (int, const vector pixel *);
19991 vector signed short vec_ldl (int, const vector signed short *);
19992 vector signed short vec_ldl (int, const short *);
19993 vector unsigned short vec_ldl (int, const vector unsigned short *);
19994 vector unsigned short vec_ldl (int, const unsigned short *);
19995 vector bool char vec_ldl (int, const vector bool char *);
19996 vector signed char vec_ldl (int, const vector signed char *);
19997 vector signed char vec_ldl (int, const signed char *);
19998 vector unsigned char vec_ldl (int, const vector unsigned char *);
19999 vector unsigned char vec_ldl (int, const unsigned char *);
20001 vector float vec_loge (vector float);
20003 vector unsigned char vec_lvsl (int, const volatile unsigned char *);
20004 vector unsigned char vec_lvsl (int, const volatile signed char *);
20005 vector unsigned char vec_lvsl (int, const volatile unsigned short *);
20006 vector unsigned char vec_lvsl (int, const volatile short *);
20007 vector unsigned char vec_lvsl (int, const volatile unsigned int *);
20008 vector unsigned char vec_lvsl (int, const volatile int *);
20009 vector unsigned char vec_lvsl (int, const volatile unsigned long *);
20010 vector unsigned char vec_lvsl (int, const volatile long *);
20011 vector unsigned char vec_lvsl (int, const volatile float *);
20013 vector unsigned char vec_lvsr (int, const volatile unsigned char *);
20014 vector unsigned char vec_lvsr (int, const volatile signed char *);
20015 vector unsigned char vec_lvsr (int, const volatile unsigned short *);
20016 vector unsigned char vec_lvsr (int, const volatile short *);
20017 vector unsigned char vec_lvsr (int, const volatile unsigned int *);
20018 vector unsigned char vec_lvsr (int, const volatile int *);
20019 vector unsigned char vec_lvsr (int, const volatile unsigned long *);
20020 vector unsigned char vec_lvsr (int, const volatile long *);
20021 vector unsigned char vec_lvsr (int, const volatile float *);
20023 vector float vec_madd (vector float, vector float, vector float);
20025 vector signed short vec_madds (vector signed short,
20026 vector signed short,
20027 vector signed short);
20029 vector unsigned char vec_max (vector bool char, vector unsigned char);
20030 vector unsigned char vec_max (vector unsigned char, vector bool char);
20031 vector unsigned char vec_max (vector unsigned char,
20032 vector unsigned char);
20033 vector signed char vec_max (vector bool char, vector signed char);
20034 vector signed char vec_max (vector signed char, vector bool char);
20035 vector signed char vec_max (vector signed char, vector signed char);
20036 vector unsigned short vec_max (vector bool short,
20037 vector unsigned short);
20038 vector unsigned short vec_max (vector unsigned short,
20039 vector bool short);
20040 vector unsigned short vec_max (vector unsigned short,
20041 vector unsigned short);
20042 vector signed short vec_max (vector bool short, vector signed short);
20043 vector signed short vec_max (vector signed short, vector bool short);
20044 vector signed short vec_max (vector signed short, vector signed short);
20045 vector unsigned int vec_max (vector bool int, vector unsigned int);
20046 vector unsigned int vec_max (vector unsigned int, vector bool int);
20047 vector unsigned int vec_max (vector unsigned int, vector unsigned int);
20048 vector signed int vec_max (vector bool int, vector signed int);
20049 vector signed int vec_max (vector signed int, vector bool int);
20050 vector signed int vec_max (vector signed int, vector signed int);
20051 vector float vec_max (vector float, vector float);
20053 vector float vec_vmaxfp (vector float, vector float);
20055 vector signed int vec_vmaxsw (vector bool int, vector signed int);
20056 vector signed int vec_vmaxsw (vector signed int, vector bool int);
20057 vector signed int vec_vmaxsw (vector signed int, vector signed int);
20059 vector unsigned int vec_vmaxuw (vector bool int, vector unsigned int);
20060 vector unsigned int vec_vmaxuw (vector unsigned int, vector bool int);
20061 vector unsigned int vec_vmaxuw (vector unsigned int,
20062 vector unsigned int);
20064 vector signed short vec_vmaxsh (vector bool short, vector signed short);
20065 vector signed short vec_vmaxsh (vector signed short, vector bool short);
20066 vector signed short vec_vmaxsh (vector signed short,
20067 vector signed short);
20069 vector unsigned short vec_vmaxuh (vector bool short,
20070 vector unsigned short);
20071 vector unsigned short vec_vmaxuh (vector unsigned short,
20072 vector bool short);
20073 vector unsigned short vec_vmaxuh (vector unsigned short,
20074 vector unsigned short);
20076 vector signed char vec_vmaxsb (vector bool char, vector signed char);
20077 vector signed char vec_vmaxsb (vector signed char, vector bool char);
20078 vector signed char vec_vmaxsb (vector signed char, vector signed char);
20080 vector unsigned char vec_vmaxub (vector bool char,
20081 vector unsigned char);
20082 vector unsigned char vec_vmaxub (vector unsigned char,
20084 vector unsigned char vec_vmaxub (vector unsigned char,
20085 vector unsigned char);
20087 vector bool char vec_mergeh (vector bool char, vector bool char);
20088 vector signed char vec_mergeh (vector signed char, vector signed char);
20089 vector unsigned char vec_mergeh (vector unsigned char,
20090 vector unsigned char);
20091 vector bool short vec_mergeh (vector bool short, vector bool short);
20092 vector pixel vec_mergeh (vector pixel, vector pixel);
20093 vector signed short vec_mergeh (vector signed short,
20094 vector signed short);
20095 vector unsigned short vec_mergeh (vector unsigned short,
20096 vector unsigned short);
20097 vector float vec_mergeh (vector float, vector float);
20098 vector bool int vec_mergeh (vector bool int, vector bool int);
20099 vector signed int vec_mergeh (vector signed int, vector signed int);
20100 vector unsigned int vec_mergeh (vector unsigned int,
20101 vector unsigned int);
20103 vector float vec_vmrghw (vector float, vector float);
20104 vector bool int vec_vmrghw (vector bool int, vector bool int);
20105 vector signed int vec_vmrghw (vector signed int, vector signed int);
20106 vector unsigned int vec_vmrghw (vector unsigned int,
20107 vector unsigned int);
20109 vector bool short vec_vmrghh (vector bool short, vector bool short);
20110 vector signed short vec_vmrghh (vector signed short,
20111 vector signed short);
20112 vector unsigned short vec_vmrghh (vector unsigned short,
20113 vector unsigned short);
20114 vector pixel vec_vmrghh (vector pixel, vector pixel);
20116 vector bool char vec_vmrghb (vector bool char, vector bool char);
20117 vector signed char vec_vmrghb (vector signed char, vector signed char);
20118 vector unsigned char vec_vmrghb (vector unsigned char,
20119 vector unsigned char);
20121 vector bool char vec_mergel (vector bool char, vector bool char);
20122 vector signed char vec_mergel (vector signed char, vector signed char);
20123 vector unsigned char vec_mergel (vector unsigned char,
20124 vector unsigned char);
20125 vector bool short vec_mergel (vector bool short, vector bool short);
20126 vector pixel vec_mergel (vector pixel, vector pixel);
20127 vector signed short vec_mergel (vector signed short,
20128 vector signed short);
20129 vector unsigned short vec_mergel (vector unsigned short,
20130 vector unsigned short);
20131 vector float vec_mergel (vector float, vector float);
20132 vector bool int vec_mergel (vector bool int, vector bool int);
20133 vector signed int vec_mergel (vector signed int, vector signed int);
20134 vector unsigned int vec_mergel (vector unsigned int,
20135 vector unsigned int);
20137 vector float vec_vmrglw (vector float, vector float);
20138 vector signed int vec_vmrglw (vector signed int, vector signed int);
20139 vector unsigned int vec_vmrglw (vector unsigned int,
20140 vector unsigned int);
20141 vector bool int vec_vmrglw (vector bool int, vector bool int);
20143 vector bool short vec_vmrglh (vector bool short, vector bool short);
20144 vector signed short vec_vmrglh (vector signed short,
20145 vector signed short);
20146 vector unsigned short vec_vmrglh (vector unsigned short,
20147 vector unsigned short);
20148 vector pixel vec_vmrglh (vector pixel, vector pixel);
20150 vector bool char vec_vmrglb (vector bool char, vector bool char);
20151 vector signed char vec_vmrglb (vector signed char, vector signed char);
20152 vector unsigned char vec_vmrglb (vector unsigned char,
20153 vector unsigned char);
20155 vector unsigned short vec_mfvscr (void);
20157 vector unsigned char vec_min (vector bool char, vector unsigned char);
20158 vector unsigned char vec_min (vector unsigned char, vector bool char);
20159 vector unsigned char vec_min (vector unsigned char,
20160 vector unsigned char);
20161 vector signed char vec_min (vector bool char, vector signed char);
20162 vector signed char vec_min (vector signed char, vector bool char);
20163 vector signed char vec_min (vector signed char, vector signed char);
20164 vector unsigned short vec_min (vector bool short,
20165 vector unsigned short);
20166 vector unsigned short vec_min (vector unsigned short,
20167 vector bool short);
20168 vector unsigned short vec_min (vector unsigned short,
20169 vector unsigned short);
20170 vector signed short vec_min (vector bool short, vector signed short);
20171 vector signed short vec_min (vector signed short, vector bool short);
20172 vector signed short vec_min (vector signed short, vector signed short);
20173 vector unsigned int vec_min (vector bool int, vector unsigned int);
20174 vector unsigned int vec_min (vector unsigned int, vector bool int);
20175 vector unsigned int vec_min (vector unsigned int, vector unsigned int);
20176 vector signed int vec_min (vector bool int, vector signed int);
20177 vector signed int vec_min (vector signed int, vector bool int);
20178 vector signed int vec_min (vector signed int, vector signed int);
20179 vector float vec_min (vector float, vector float);
20181 vector float vec_vminfp (vector float, vector float);
20183 vector signed int vec_vminsw (vector bool int, vector signed int);
20184 vector signed int vec_vminsw (vector signed int, vector bool int);
20185 vector signed int vec_vminsw (vector signed int, vector signed int);
20187 vector unsigned int vec_vminuw (vector bool int, vector unsigned int);
20188 vector unsigned int vec_vminuw (vector unsigned int, vector bool int);
20189 vector unsigned int vec_vminuw (vector unsigned int,
20190 vector unsigned int);
20192 vector signed short vec_vminsh (vector bool short, vector signed short);
20193 vector signed short vec_vminsh (vector signed short, vector bool short);
20194 vector signed short vec_vminsh (vector signed short,
20195 vector signed short);
20197 vector unsigned short vec_vminuh (vector bool short,
20198 vector unsigned short);
20199 vector unsigned short vec_vminuh (vector unsigned short,
20200 vector bool short);
20201 vector unsigned short vec_vminuh (vector unsigned short,
20202 vector unsigned short);
20204 vector signed char vec_vminsb (vector bool char, vector signed char);
20205 vector signed char vec_vminsb (vector signed char, vector bool char);
20206 vector signed char vec_vminsb (vector signed char, vector signed char);
20208 vector unsigned char vec_vminub (vector bool char,
20209 vector unsigned char);
20210 vector unsigned char vec_vminub (vector unsigned char,
20212 vector unsigned char vec_vminub (vector unsigned char,
20213 vector unsigned char);
20215 vector signed short vec_mladd (vector signed short,
20216 vector signed short,
20217 vector signed short);
20218 vector signed short vec_mladd (vector signed short,
20219 vector unsigned short,
20220 vector unsigned short);
20221 vector signed short vec_mladd (vector unsigned short,
20222 vector signed short,
20223 vector signed short);
20224 vector unsigned short vec_mladd (vector unsigned short,
20225 vector unsigned short,
20226 vector unsigned short);
20228 vector signed short vec_mradds (vector signed short,
20229 vector signed short,
20230 vector signed short);
20232 vector unsigned int vec_msum (vector unsigned char,
20233 vector unsigned char,
20234 vector unsigned int);
20235 vector signed int vec_msum (vector signed char,
20236 vector unsigned char,
20237 vector signed int);
20238 vector unsigned int vec_msum (vector unsigned short,
20239 vector unsigned short,
20240 vector unsigned int);
20241 vector signed int vec_msum (vector signed short,
20242 vector signed short,
20243 vector signed int);
20245 vector signed int vec_vmsumshm (vector signed short,
20246 vector signed short,
20247 vector signed int);
20249 vector unsigned int vec_vmsumuhm (vector unsigned short,
20250 vector unsigned short,
20251 vector unsigned int);
20253 vector signed int vec_vmsummbm (vector signed char,
20254 vector unsigned char,
20255 vector signed int);
20257 vector unsigned int vec_vmsumubm (vector unsigned char,
20258 vector unsigned char,
20259 vector unsigned int);
20261 vector unsigned int vec_msums (vector unsigned short,
20262 vector unsigned short,
20263 vector unsigned int);
20264 vector signed int vec_msums (vector signed short,
20265 vector signed short,
20266 vector signed int);
20268 vector signed int vec_vmsumshs (vector signed short,
20269 vector signed short,
20270 vector signed int);
20272 vector unsigned int vec_vmsumuhs (vector unsigned short,
20273 vector unsigned short,
20274 vector unsigned int);
20276 void vec_mtvscr (vector signed int);
20277 void vec_mtvscr (vector unsigned int);
20278 void vec_mtvscr (vector bool int);
20279 void vec_mtvscr (vector signed short);
20280 void vec_mtvscr (vector unsigned short);
20281 void vec_mtvscr (vector bool short);
20282 void vec_mtvscr (vector pixel);
20283 void vec_mtvscr (vector signed char);
20284 void vec_mtvscr (vector unsigned char);
20285 void vec_mtvscr (vector bool char);
20287 vector unsigned short vec_mule (vector unsigned char,
20288 vector unsigned char);
20289 vector signed short vec_mule (vector signed char,
20290 vector signed char);
20291 vector unsigned int vec_mule (vector unsigned short,
20292 vector unsigned short);
20293 vector signed int vec_mule (vector signed short, vector signed short);
20295 vector signed int vec_vmulesh (vector signed short,
20296 vector signed short);
20298 vector unsigned int vec_vmuleuh (vector unsigned short,
20299 vector unsigned short);
20301 vector signed short vec_vmulesb (vector signed char,
20302 vector signed char);
20304 vector unsigned short vec_vmuleub (vector unsigned char,
20305 vector unsigned char);
20307 vector unsigned short vec_mulo (vector unsigned char,
20308 vector unsigned char);
20309 vector signed short vec_mulo (vector signed char, vector signed char);
20310 vector unsigned int vec_mulo (vector unsigned short,
20311 vector unsigned short);
20312 vector signed int vec_mulo (vector signed short, vector signed short);
20314 vector signed int vec_vmulosh (vector signed short,
20315 vector signed short);
20317 vector unsigned int vec_vmulouh (vector unsigned short,
20318 vector unsigned short);
20320 vector signed short vec_vmulosb (vector signed char,
20321 vector signed char);
20323 vector unsigned short vec_vmuloub (vector unsigned char,
20324 vector unsigned char);
20326 vector float vec_nmsub (vector float, vector float, vector float);
20328 vector float vec_nor (vector float, vector float);
20329 vector signed int vec_nor (vector signed int, vector signed int);
20330 vector unsigned int vec_nor (vector unsigned int, vector unsigned int);
20331 vector bool int vec_nor (vector bool int, vector bool int);
20332 vector signed short vec_nor (vector signed short, vector signed short);
20333 vector unsigned short vec_nor (vector unsigned short,
20334 vector unsigned short);
20335 vector bool short vec_nor (vector bool short, vector bool short);
20336 vector signed char vec_nor (vector signed char, vector signed char);
20337 vector unsigned char vec_nor (vector unsigned char,
20338 vector unsigned char);
20339 vector bool char vec_nor (vector bool char, vector bool char);
20341 vector float vec_or (vector float, vector float);
20342 vector float vec_or (vector float, vector bool int);
20343 vector float vec_or (vector bool int, vector float);
20344 vector bool int vec_or (vector bool int, vector bool int);
20345 vector signed int vec_or (vector bool int, vector signed int);
20346 vector signed int vec_or (vector signed int, vector bool int);
20347 vector signed int vec_or (vector signed int, vector signed int);
20348 vector unsigned int vec_or (vector bool int, vector unsigned int);
20349 vector unsigned int vec_or (vector unsigned int, vector bool int);
20350 vector unsigned int vec_or (vector unsigned int, vector unsigned int);
20351 vector bool short vec_or (vector bool short, vector bool short);
20352 vector signed short vec_or (vector bool short, vector signed short);
20353 vector signed short vec_or (vector signed short, vector bool short);
20354 vector signed short vec_or (vector signed short, vector signed short);
20355 vector unsigned short vec_or (vector bool short, vector unsigned short);
20356 vector unsigned short vec_or (vector unsigned short, vector bool short);
20357 vector unsigned short vec_or (vector unsigned short,
20358 vector unsigned short);
20359 vector signed char vec_or (vector bool char, vector signed char);
20360 vector bool char vec_or (vector bool char, vector bool char);
20361 vector signed char vec_or (vector signed char, vector bool char);
20362 vector signed char vec_or (vector signed char, vector signed char);
20363 vector unsigned char vec_or (vector bool char, vector unsigned char);
20364 vector unsigned char vec_or (vector unsigned char, vector bool char);
20365 vector unsigned char vec_or (vector unsigned char,
20366 vector unsigned char);
20368 vector signed char vec_pack (vector signed short, vector signed short);
20369 vector unsigned char vec_pack (vector unsigned short,
20370 vector unsigned short);
20371 vector bool char vec_pack (vector bool short, vector bool short);
20372 vector signed short vec_pack (vector signed int, vector signed int);
20373 vector unsigned short vec_pack (vector unsigned int,
20374 vector unsigned int);
20375 vector bool short vec_pack (vector bool int, vector bool int);
20377 vector bool short vec_vpkuwum (vector bool int, vector bool int);
20378 vector signed short vec_vpkuwum (vector signed int, vector signed int);
20379 vector unsigned short vec_vpkuwum (vector unsigned int,
20380 vector unsigned int);
20382 vector bool char vec_vpkuhum (vector bool short, vector bool short);
20383 vector signed char vec_vpkuhum (vector signed short,
20384 vector signed short);
20385 vector unsigned char vec_vpkuhum (vector unsigned short,
20386 vector unsigned short);
20388 vector pixel vec_packpx (vector unsigned int, vector unsigned int);
20390 vector unsigned char vec_packs (vector unsigned short,
20391 vector unsigned short);
20392 vector signed char vec_packs (vector signed short, vector signed short);
20393 vector unsigned short vec_packs (vector unsigned int,
20394 vector unsigned int);
20395 vector signed short vec_packs (vector signed int, vector signed int);
20397 vector signed short vec_vpkswss (vector signed int, vector signed int);
20399 vector unsigned short vec_vpkuwus (vector unsigned int,
20400 vector unsigned int);
20402 vector signed char vec_vpkshss (vector signed short,
20403 vector signed short);
20405 vector unsigned char vec_vpkuhus (vector unsigned short,
20406 vector unsigned short);
20408 vector unsigned char vec_packsu (vector unsigned short,
20409 vector unsigned short);
20410 vector unsigned char vec_packsu (vector signed short,
20411 vector signed short);
20412 vector unsigned short vec_packsu (vector unsigned int,
20413 vector unsigned int);
20414 vector unsigned short vec_packsu (vector signed int, vector signed int);
20416 vector unsigned short vec_vpkswus (vector signed int,
20417 vector signed int);
20419 vector unsigned char vec_vpkshus (vector signed short,
20420 vector signed short);
20422 vector float vec_perm (vector float,
20424 vector unsigned char);
20425 vector signed int vec_perm (vector signed int,
20427 vector unsigned char);
20428 vector unsigned int vec_perm (vector unsigned int,
20429 vector unsigned int,
20430 vector unsigned char);
20431 vector bool int vec_perm (vector bool int,
20433 vector unsigned char);
20434 vector signed short vec_perm (vector signed short,
20435 vector signed short,
20436 vector unsigned char);
20437 vector unsigned short vec_perm (vector unsigned short,
20438 vector unsigned short,
20439 vector unsigned char);
20440 vector bool short vec_perm (vector bool short,
20442 vector unsigned char);
20443 vector pixel vec_perm (vector pixel,
20445 vector unsigned char);
20446 vector signed char vec_perm (vector signed char,
20447 vector signed char,
20448 vector unsigned char);
20449 vector unsigned char vec_perm (vector unsigned char,
20450 vector unsigned char,
20451 vector unsigned char);
20452 vector bool char vec_perm (vector bool char,
20454 vector unsigned char);
20456 vector float vec_re (vector float);
20458 vector signed char vec_rl (vector signed char,
20459 vector unsigned char);
20460 vector unsigned char vec_rl (vector unsigned char,
20461 vector unsigned char);
20462 vector signed short vec_rl (vector signed short, vector unsigned short);
20463 vector unsigned short vec_rl (vector unsigned short,
20464 vector unsigned short);
20465 vector signed int vec_rl (vector signed int, vector unsigned int);
20466 vector unsigned int vec_rl (vector unsigned int, vector unsigned int);
20468 vector signed int vec_vrlw (vector signed int, vector unsigned int);
20469 vector unsigned int vec_vrlw (vector unsigned int, vector unsigned int);
20471 vector signed short vec_vrlh (vector signed short,
20472 vector unsigned short);
20473 vector unsigned short vec_vrlh (vector unsigned short,
20474 vector unsigned short);
20476 vector signed char vec_vrlb (vector signed char, vector unsigned char);
20477 vector unsigned char vec_vrlb (vector unsigned char,
20478 vector unsigned char);
20480 vector float vec_round (vector float);
20482 vector float vec_rsqrte (vector float);
20484 vector float vec_sel (vector float, vector float, vector bool int);
20485 vector float vec_sel (vector float, vector float, vector unsigned int);
20486 vector signed int vec_sel (vector signed int,
20489 vector signed int vec_sel (vector signed int,
20491 vector unsigned int);
20492 vector unsigned int vec_sel (vector unsigned int,
20493 vector unsigned int,
20495 vector unsigned int vec_sel (vector unsigned int,
20496 vector unsigned int,
20497 vector unsigned int);
20498 vector bool int vec_sel (vector bool int,
20501 vector bool int vec_sel (vector bool int,
20503 vector unsigned int);
20504 vector signed short vec_sel (vector signed short,
20505 vector signed short,
20506 vector bool short);
20507 vector signed short vec_sel (vector signed short,
20508 vector signed short,
20509 vector unsigned short);
20510 vector unsigned short vec_sel (vector unsigned short,
20511 vector unsigned short,
20512 vector bool short);
20513 vector unsigned short vec_sel (vector unsigned short,
20514 vector unsigned short,
20515 vector unsigned short);
20516 vector bool short vec_sel (vector bool short,
20518 vector bool short);
20519 vector bool short vec_sel (vector bool short,
20521 vector unsigned short);
20522 vector signed char vec_sel (vector signed char,
20523 vector signed char,
20525 vector signed char vec_sel (vector signed char,
20526 vector signed char,
20527 vector unsigned char);
20528 vector unsigned char vec_sel (vector unsigned char,
20529 vector unsigned char,
20531 vector unsigned char vec_sel (vector unsigned char,
20532 vector unsigned char,
20533 vector unsigned char);
20534 vector bool char vec_sel (vector bool char,
20537 vector bool char vec_sel (vector bool char,
20539 vector unsigned char);
20541 vector signed char vec_sl (vector signed char,
20542 vector unsigned char);
20543 vector unsigned char vec_sl (vector unsigned char,
20544 vector unsigned char);
20545 vector signed short vec_sl (vector signed short, vector unsigned short);
20546 vector unsigned short vec_sl (vector unsigned short,
20547 vector unsigned short);
20548 vector signed int vec_sl (vector signed int, vector unsigned int);
20549 vector unsigned int vec_sl (vector unsigned int, vector unsigned int);
20551 vector signed int vec_vslw (vector signed int, vector unsigned int);
20552 vector unsigned int vec_vslw (vector unsigned int, vector unsigned int);
20554 vector signed short vec_vslh (vector signed short,
20555 vector unsigned short);
20556 vector unsigned short vec_vslh (vector unsigned short,
20557 vector unsigned short);
20559 vector signed char vec_vslb (vector signed char, vector unsigned char);
20560 vector unsigned char vec_vslb (vector unsigned char,
20561 vector unsigned char);
20563 vector float vec_sld (vector float, vector float, const int);
20564 vector signed int vec_sld (vector signed int,
20567 vector unsigned int vec_sld (vector unsigned int,
20568 vector unsigned int,
20570 vector bool int vec_sld (vector bool int,
20573 vector signed short vec_sld (vector signed short,
20574 vector signed short,
20576 vector unsigned short vec_sld (vector unsigned short,
20577 vector unsigned short,
20579 vector bool short vec_sld (vector bool short,
20582 vector pixel vec_sld (vector pixel,
20585 vector signed char vec_sld (vector signed char,
20586 vector signed char,
20588 vector unsigned char vec_sld (vector unsigned char,
20589 vector unsigned char,
20591 vector bool char vec_sld (vector bool char,
20595 vector signed int vec_sll (vector signed int,
20596 vector unsigned int);
20597 vector signed int vec_sll (vector signed int,
20598 vector unsigned short);
20599 vector signed int vec_sll (vector signed int,
20600 vector unsigned char);
20601 vector unsigned int vec_sll (vector unsigned int,
20602 vector unsigned int);
20603 vector unsigned int vec_sll (vector unsigned int,
20604 vector unsigned short);
20605 vector unsigned int vec_sll (vector unsigned int,
20606 vector unsigned char);
20607 vector bool int vec_sll (vector bool int,
20608 vector unsigned int);
20609 vector bool int vec_sll (vector bool int,
20610 vector unsigned short);
20611 vector bool int vec_sll (vector bool int,
20612 vector unsigned char);
20613 vector signed short vec_sll (vector signed short,
20614 vector unsigned int);
20615 vector signed short vec_sll (vector signed short,
20616 vector unsigned short);
20617 vector signed short vec_sll (vector signed short,
20618 vector unsigned char);
20619 vector unsigned short vec_sll (vector unsigned short,
20620 vector unsigned int);
20621 vector unsigned short vec_sll (vector unsigned short,
20622 vector unsigned short);
20623 vector unsigned short vec_sll (vector unsigned short,
20624 vector unsigned char);
20625 vector bool short vec_sll (vector bool short, vector unsigned int);
20626 vector bool short vec_sll (vector bool short, vector unsigned short);
20627 vector bool short vec_sll (vector bool short, vector unsigned char);
20628 vector pixel vec_sll (vector pixel, vector unsigned int);
20629 vector pixel vec_sll (vector pixel, vector unsigned short);
20630 vector pixel vec_sll (vector pixel, vector unsigned char);
20631 vector signed char vec_sll (vector signed char, vector unsigned int);
20632 vector signed char vec_sll (vector signed char, vector unsigned short);
20633 vector signed char vec_sll (vector signed char, vector unsigned char);
20634 vector unsigned char vec_sll (vector unsigned char,
20635 vector unsigned int);
20636 vector unsigned char vec_sll (vector unsigned char,
20637 vector unsigned short);
20638 vector unsigned char vec_sll (vector unsigned char,
20639 vector unsigned char);
20640 vector bool char vec_sll (vector bool char, vector unsigned int);
20641 vector bool char vec_sll (vector bool char, vector unsigned short);
20642 vector bool char vec_sll (vector bool char, vector unsigned char);
20644 vector float vec_slo (vector float, vector signed char);
20645 vector float vec_slo (vector float, vector unsigned char);
20646 vector signed int vec_slo (vector signed int, vector signed char);
20647 vector signed int vec_slo (vector signed int, vector unsigned char);
20648 vector unsigned int vec_slo (vector unsigned int, vector signed char);
20649 vector unsigned int vec_slo (vector unsigned int, vector unsigned char);
20650 vector signed short vec_slo (vector signed short, vector signed char);
20651 vector signed short vec_slo (vector signed short, vector unsigned char);
20652 vector unsigned short vec_slo (vector unsigned short,
20653 vector signed char);
20654 vector unsigned short vec_slo (vector unsigned short,
20655 vector unsigned char);
20656 vector pixel vec_slo (vector pixel, vector signed char);
20657 vector pixel vec_slo (vector pixel, vector unsigned char);
20658 vector signed char vec_slo (vector signed char, vector signed char);
20659 vector signed char vec_slo (vector signed char, vector unsigned char);
20660 vector unsigned char vec_slo (vector unsigned char, vector signed char);
20661 vector unsigned char vec_slo (vector unsigned char,
20662 vector unsigned char);
20664 vector signed char vec_splat (vector signed char, const int);
20665 vector unsigned char vec_splat (vector unsigned char, const int);
20666 vector bool char vec_splat (vector bool char, const int);
20667 vector signed short vec_splat (vector signed short, const int);
20668 vector unsigned short vec_splat (vector unsigned short, const int);
20669 vector bool short vec_splat (vector bool short, const int);
20670 vector pixel vec_splat (vector pixel, const int);
20671 vector float vec_splat (vector float, const int);
20672 vector signed int vec_splat (vector signed int, const int);
20673 vector unsigned int vec_splat (vector unsigned int, const int);
20674 vector bool int vec_splat (vector bool int, const int);
20676 vector float vec_vspltw (vector float, const int);
20677 vector signed int vec_vspltw (vector signed int, const int);
20678 vector unsigned int vec_vspltw (vector unsigned int, const int);
20679 vector bool int vec_vspltw (vector bool int, const int);
20681 vector bool short vec_vsplth (vector bool short, const int);
20682 vector signed short vec_vsplth (vector signed short, const int);
20683 vector unsigned short vec_vsplth (vector unsigned short, const int);
20684 vector pixel vec_vsplth (vector pixel, const int);
20686 vector signed char vec_vspltb (vector signed char, const int);
20687 vector unsigned char vec_vspltb (vector unsigned char, const int);
20688 vector bool char vec_vspltb (vector bool char, const int);
20690 vector signed char vec_splat_s8 (const int);
20692 vector signed short vec_splat_s16 (const int);
20694 vector signed int vec_splat_s32 (const int);
20696 vector unsigned char vec_splat_u8 (const int);
20698 vector unsigned short vec_splat_u16 (const int);
20700 vector unsigned int vec_splat_u32 (const int);
20702 vector signed char vec_sr (vector signed char, vector unsigned char);
20703 vector unsigned char vec_sr (vector unsigned char,
20704 vector unsigned char);
20705 vector signed short vec_sr (vector signed short,
20706 vector unsigned short);
20707 vector unsigned short vec_sr (vector unsigned short,
20708 vector unsigned short);
20709 vector signed int vec_sr (vector signed int, vector unsigned int);
20710 vector unsigned int vec_sr (vector unsigned int, vector unsigned int);
20712 vector signed int vec_vsrw (vector signed int, vector unsigned int);
20713 vector unsigned int vec_vsrw (vector unsigned int, vector unsigned int);
20715 vector signed short vec_vsrh (vector signed short,
20716 vector unsigned short);
20717 vector unsigned short vec_vsrh (vector unsigned short,
20718 vector unsigned short);
20720 vector signed char vec_vsrb (vector signed char, vector unsigned char);
20721 vector unsigned char vec_vsrb (vector unsigned char,
20722 vector unsigned char);
20724 vector signed char vec_sra (vector signed char, vector unsigned char);
20725 vector unsigned char vec_sra (vector unsigned char,
20726 vector unsigned char);
20727 vector signed short vec_sra (vector signed short,
20728 vector unsigned short);
20729 vector unsigned short vec_sra (vector unsigned short,
20730 vector unsigned short);
20731 vector signed int vec_sra (vector signed int, vector unsigned int);
20732 vector unsigned int vec_sra (vector unsigned int, vector unsigned int);
20734 vector signed int vec_vsraw (vector signed int, vector unsigned int);
20735 vector unsigned int vec_vsraw (vector unsigned int,
20736 vector unsigned int);
20738 vector signed short vec_vsrah (vector signed short,
20739 vector unsigned short);
20740 vector unsigned short vec_vsrah (vector unsigned short,
20741 vector unsigned short);
20743 vector signed char vec_vsrab (vector signed char, vector unsigned char);
20744 vector unsigned char vec_vsrab (vector unsigned char,
20745 vector unsigned char);
20747 vector signed int vec_srl (vector signed int, vector unsigned int);
20748 vector signed int vec_srl (vector signed int, vector unsigned short);
20749 vector signed int vec_srl (vector signed int, vector unsigned char);
20750 vector unsigned int vec_srl (vector unsigned int, vector unsigned int);
20751 vector unsigned int vec_srl (vector unsigned int,
20752 vector unsigned short);
20753 vector unsigned int vec_srl (vector unsigned int, vector unsigned char);
20754 vector bool int vec_srl (vector bool int, vector unsigned int);
20755 vector bool int vec_srl (vector bool int, vector unsigned short);
20756 vector bool int vec_srl (vector bool int, vector unsigned char);
20757 vector signed short vec_srl (vector signed short, vector unsigned int);
20758 vector signed short vec_srl (vector signed short,
20759 vector unsigned short);
20760 vector signed short vec_srl (vector signed short, vector unsigned char);
20761 vector unsigned short vec_srl (vector unsigned short,
20762 vector unsigned int);
20763 vector unsigned short vec_srl (vector unsigned short,
20764 vector unsigned short);
20765 vector unsigned short vec_srl (vector unsigned short,
20766 vector unsigned char);
20767 vector bool short vec_srl (vector bool short, vector unsigned int);
20768 vector bool short vec_srl (vector bool short, vector unsigned short);
20769 vector bool short vec_srl (vector bool short, vector unsigned char);
20770 vector pixel vec_srl (vector pixel, vector unsigned int);
20771 vector pixel vec_srl (vector pixel, vector unsigned short);
20772 vector pixel vec_srl (vector pixel, vector unsigned char);
20773 vector signed char vec_srl (vector signed char, vector unsigned int);
20774 vector signed char vec_srl (vector signed char, vector unsigned short);
20775 vector signed char vec_srl (vector signed char, vector unsigned char);
20776 vector unsigned char vec_srl (vector unsigned char,
20777 vector unsigned int);
20778 vector unsigned char vec_srl (vector unsigned char,
20779 vector unsigned short);
20780 vector unsigned char vec_srl (vector unsigned char,
20781 vector unsigned char);
20782 vector bool char vec_srl (vector bool char, vector unsigned int);
20783 vector bool char vec_srl (vector bool char, vector unsigned short);
20784 vector bool char vec_srl (vector bool char, vector unsigned char);
20786 vector float vec_sro (vector float, vector signed char);
20787 vector float vec_sro (vector float, vector unsigned char);
20788 vector signed int vec_sro (vector signed int, vector signed char);
20789 vector signed int vec_sro (vector signed int, vector unsigned char);
20790 vector unsigned int vec_sro (vector unsigned int, vector signed char);
20791 vector unsigned int vec_sro (vector unsigned int, vector unsigned char);
20792 vector signed short vec_sro (vector signed short, vector signed char);
20793 vector signed short vec_sro (vector signed short, vector unsigned char);
20794 vector unsigned short vec_sro (vector unsigned short,
20795 vector signed char);
20796 vector unsigned short vec_sro (vector unsigned short,
20797 vector unsigned char);
20798 vector pixel vec_sro (vector pixel, vector signed char);
20799 vector pixel vec_sro (vector pixel, vector unsigned char);
20800 vector signed char vec_sro (vector signed char, vector signed char);
20801 vector signed char vec_sro (vector signed char, vector unsigned char);
20802 vector unsigned char vec_sro (vector unsigned char, vector signed char);
20803 vector unsigned char vec_sro (vector unsigned char,
20804 vector unsigned char);
20806 void vec_st (vector float, int, vector float *);
20807 void vec_st (vector float, int, float *);
20808 void vec_st (vector signed int, int, vector signed int *);
20809 void vec_st (vector signed int, int, int *);
20810 void vec_st (vector unsigned int, int, vector unsigned int *);
20811 void vec_st (vector unsigned int, int, unsigned int *);
20812 void vec_st (vector bool int, int, vector bool int *);
20813 void vec_st (vector bool int, int, unsigned int *);
20814 void vec_st (vector bool int, int, int *);
20815 void vec_st (vector signed short, int, vector signed short *);
20816 void vec_st (vector signed short, int, short *);
20817 void vec_st (vector unsigned short, int, vector unsigned short *);
20818 void vec_st (vector unsigned short, int, unsigned short *);
20819 void vec_st (vector bool short, int, vector bool short *);
20820 void vec_st (vector bool short, int, unsigned short *);
20821 void vec_st (vector pixel, int, vector pixel *);
20822 void vec_st (vector pixel, int, unsigned short *);
20823 void vec_st (vector pixel, int, short *);
20824 void vec_st (vector bool short, int, short *);
20825 void vec_st (vector signed char, int, vector signed char *);
20826 void vec_st (vector signed char, int, signed char *);
20827 void vec_st (vector unsigned char, int, vector unsigned char *);
20828 void vec_st (vector unsigned char, int, unsigned char *);
20829 void vec_st (vector bool char, int, vector bool char *);
20830 void vec_st (vector bool char, int, unsigned char *);
20831 void vec_st (vector bool char, int, signed char *);
20833 void vec_ste (vector signed char, int, signed char *);
20834 void vec_ste (vector unsigned char, int, unsigned char *);
20835 void vec_ste (vector bool char, int, signed char *);
20836 void vec_ste (vector bool char, int, unsigned char *);
20837 void vec_ste (vector signed short, int, short *);
20838 void vec_ste (vector unsigned short, int, unsigned short *);
20839 void vec_ste (vector bool short, int, short *);
20840 void vec_ste (vector bool short, int, unsigned short *);
20841 void vec_ste (vector pixel, int, short *);
20842 void vec_ste (vector pixel, int, unsigned short *);
20843 void vec_ste (vector float, int, float *);
20844 void vec_ste (vector signed int, int, int *);
20845 void vec_ste (vector unsigned int, int, unsigned int *);
20846 void vec_ste (vector bool int, int, int *);
20847 void vec_ste (vector bool int, int, unsigned int *);
20849 void vec_stvewx (vector float, int, float *);
20850 void vec_stvewx (vector signed int, int, int *);
20851 void vec_stvewx (vector unsigned int, int, unsigned int *);
20852 void vec_stvewx (vector bool int, int, int *);
20853 void vec_stvewx (vector bool int, int, unsigned int *);
20855 void vec_stvehx (vector signed short, int, short *);
20856 void vec_stvehx (vector unsigned short, int, unsigned short *);
20857 void vec_stvehx (vector bool short, int, short *);
20858 void vec_stvehx (vector bool short, int, unsigned short *);
20859 void vec_stvehx (vector pixel, int, short *);
20860 void vec_stvehx (vector pixel, int, unsigned short *);
20862 void vec_stvebx (vector signed char, int, signed char *);
20863 void vec_stvebx (vector unsigned char, int, unsigned char *);
20864 void vec_stvebx (vector bool char, int, signed char *);
20865 void vec_stvebx (vector bool char, int, unsigned char *);
20867 void vec_stl (vector float, int, vector float *);
20868 void vec_stl (vector float, int, float *);
20869 void vec_stl (vector signed int, int, vector signed int *);
20870 void vec_stl (vector signed int, int, int *);
20871 void vec_stl (vector unsigned int, int, vector unsigned int *);
20872 void vec_stl (vector unsigned int, int, unsigned int *);
20873 void vec_stl (vector bool int, int, vector bool int *);
20874 void vec_stl (vector bool int, int, unsigned int *);
20875 void vec_stl (vector bool int, int, int *);
20876 void vec_stl (vector signed short, int, vector signed short *);
20877 void vec_stl (vector signed short, int, short *);
20878 void vec_stl (vector unsigned short, int, vector unsigned short *);
20879 void vec_stl (vector unsigned short, int, unsigned short *);
20880 void vec_stl (vector bool short, int, vector bool short *);
20881 void vec_stl (vector bool short, int, unsigned short *);
20882 void vec_stl (vector bool short, int, short *);
20883 void vec_stl (vector pixel, int, vector pixel *);
20884 void vec_stl (vector pixel, int, unsigned short *);
20885 void vec_stl (vector pixel, int, short *);
20886 void vec_stl (vector signed char, int, vector signed char *);
20887 void vec_stl (vector signed char, int, signed char *);
20888 void vec_stl (vector unsigned char, int, vector unsigned char *);
20889 void vec_stl (vector unsigned char, int, unsigned char *);
20890 void vec_stl (vector bool char, int, vector bool char *);
20891 void vec_stl (vector bool char, int, unsigned char *);
20892 void vec_stl (vector bool char, int, signed char *);
20894 vector signed char vec_sub (vector bool char, vector signed char);
20895 vector signed char vec_sub (vector signed char, vector bool char);
20896 vector signed char vec_sub (vector signed char, vector signed char);
20897 vector unsigned char vec_sub (vector bool char, vector unsigned char);
20898 vector unsigned char vec_sub (vector unsigned char, vector bool char);
20899 vector unsigned char vec_sub (vector unsigned char,
20900 vector unsigned char);
20901 vector signed short vec_sub (vector bool short, vector signed short);
20902 vector signed short vec_sub (vector signed short, vector bool short);
20903 vector signed short vec_sub (vector signed short, vector signed short);
20904 vector unsigned short vec_sub (vector bool short,
20905 vector unsigned short);
20906 vector unsigned short vec_sub (vector unsigned short,
20907 vector bool short);
20908 vector unsigned short vec_sub (vector unsigned short,
20909 vector unsigned short);
20910 vector signed int vec_sub (vector bool int, vector signed int);
20911 vector signed int vec_sub (vector signed int, vector bool int);
20912 vector signed int vec_sub (vector signed int, vector signed int);
20913 vector unsigned int vec_sub (vector bool int, vector unsigned int);
20914 vector unsigned int vec_sub (vector unsigned int, vector bool int);
20915 vector unsigned int vec_sub (vector unsigned int, vector unsigned int);
20916 vector float vec_sub (vector float, vector float);
20918 vector float vec_vsubfp (vector float, vector float);
20920 vector signed int vec_vsubuwm (vector bool int, vector signed int);
20921 vector signed int vec_vsubuwm (vector signed int, vector bool int);
20922 vector signed int vec_vsubuwm (vector signed int, vector signed int);
20923 vector unsigned int vec_vsubuwm (vector bool int, vector unsigned int);
20924 vector unsigned int vec_vsubuwm (vector unsigned int, vector bool int);
20925 vector unsigned int vec_vsubuwm (vector unsigned int,
20926 vector unsigned int);
20928 vector signed short vec_vsubuhm (vector bool short,
20929 vector signed short);
20930 vector signed short vec_vsubuhm (vector signed short,
20931 vector bool short);
20932 vector signed short vec_vsubuhm (vector signed short,
20933 vector signed short);
20934 vector unsigned short vec_vsubuhm (vector bool short,
20935 vector unsigned short);
20936 vector unsigned short vec_vsubuhm (vector unsigned short,
20937 vector bool short);
20938 vector unsigned short vec_vsubuhm (vector unsigned short,
20939 vector unsigned short);
20941 vector signed char vec_vsububm (vector bool char, vector signed char);
20942 vector signed char vec_vsububm (vector signed char, vector bool char);
20943 vector signed char vec_vsububm (vector signed char, vector signed char);
20944 vector unsigned char vec_vsububm (vector bool char,
20945 vector unsigned char);
20946 vector unsigned char vec_vsububm (vector unsigned char,
20948 vector unsigned char vec_vsububm (vector unsigned char,
20949 vector unsigned char);
20951 vector unsigned int vec_subc (vector unsigned int, vector unsigned int);
20953 vector unsigned char vec_subs (vector bool char, vector unsigned char);
20954 vector unsigned char vec_subs (vector unsigned char, vector bool char);
20955 vector unsigned char vec_subs (vector unsigned char,
20956 vector unsigned char);
20957 vector signed char vec_subs (vector bool char, vector signed char);
20958 vector signed char vec_subs (vector signed char, vector bool char);
20959 vector signed char vec_subs (vector signed char, vector signed char);
20960 vector unsigned short vec_subs (vector bool short,
20961 vector unsigned short);
20962 vector unsigned short vec_subs (vector unsigned short,
20963 vector bool short);
20964 vector unsigned short vec_subs (vector unsigned short,
20965 vector unsigned short);
20966 vector signed short vec_subs (vector bool short, vector signed short);
20967 vector signed short vec_subs (vector signed short, vector bool short);
20968 vector signed short vec_subs (vector signed short, vector signed short);
20969 vector unsigned int vec_subs (vector bool int, vector unsigned int);
20970 vector unsigned int vec_subs (vector unsigned int, vector bool int);
20971 vector unsigned int vec_subs (vector unsigned int, vector unsigned int);
20972 vector signed int vec_subs (vector bool int, vector signed int);
20973 vector signed int vec_subs (vector signed int, vector bool int);
20974 vector signed int vec_subs (vector signed int, vector signed int);
20976 vector signed int vec_vsubsws (vector bool int, vector signed int);
20977 vector signed int vec_vsubsws (vector signed int, vector bool int);
20978 vector signed int vec_vsubsws (vector signed int, vector signed int);
20980 vector unsigned int vec_vsubuws (vector bool int, vector unsigned int);
20981 vector unsigned int vec_vsubuws (vector unsigned int, vector bool int);
20982 vector unsigned int vec_vsubuws (vector unsigned int,
20983 vector unsigned int);
20985 vector signed short vec_vsubshs (vector bool short,
20986 vector signed short);
20987 vector signed short vec_vsubshs (vector signed short,
20988 vector bool short);
20989 vector signed short vec_vsubshs (vector signed short,
20990 vector signed short);
20992 vector unsigned short vec_vsubuhs (vector bool short,
20993 vector unsigned short);
20994 vector unsigned short vec_vsubuhs (vector unsigned short,
20995 vector bool short);
20996 vector unsigned short vec_vsubuhs (vector unsigned short,
20997 vector unsigned short);
20999 vector signed char vec_vsubsbs (vector bool char, vector signed char);
21000 vector signed char vec_vsubsbs (vector signed char, vector bool char);
21001 vector signed char vec_vsubsbs (vector signed char, vector signed char);
21003 vector unsigned char vec_vsububs (vector bool char,
21004 vector unsigned char);
21005 vector unsigned char vec_vsububs (vector unsigned char,
21007 vector unsigned char vec_vsububs (vector unsigned char,
21008 vector unsigned char);
21010 vector unsigned int vec_sum4s (vector unsigned char,
21011 vector unsigned int);
21012 vector signed int vec_sum4s (vector signed char, vector signed int);
21013 vector signed int vec_sum4s (vector signed short, vector signed int);
21015 vector signed int vec_vsum4shs (vector signed short, vector signed int);
21017 vector signed int vec_vsum4sbs (vector signed char, vector signed int);
21019 vector unsigned int vec_vsum4ubs (vector unsigned char,
21020 vector unsigned int);
21022 vector signed int vec_sum2s (vector signed int, vector signed int);
21024 vector signed int vec_sums (vector signed int, vector signed int);
21026 vector float vec_trunc (vector float);
21028 vector signed short vec_unpackh (vector signed char);
21029 vector bool short vec_unpackh (vector bool char);
21030 vector signed int vec_unpackh (vector signed short);
21031 vector bool int vec_unpackh (vector bool short);
21032 vector unsigned int vec_unpackh (vector pixel);
21034 vector bool int vec_vupkhsh (vector bool short);
21035 vector signed int vec_vupkhsh (vector signed short);
21037 vector unsigned int vec_vupkhpx (vector pixel);
21039 vector bool short vec_vupkhsb (vector bool char);
21040 vector signed short vec_vupkhsb (vector signed char);
21042 vector signed short vec_unpackl (vector signed char);
21043 vector bool short vec_unpackl (vector bool char);
21044 vector unsigned int vec_unpackl (vector pixel);
21045 vector signed int vec_unpackl (vector signed short);
21046 vector bool int vec_unpackl (vector bool short);
21048 vector unsigned int vec_vupklpx (vector pixel);
21050 vector bool int vec_vupklsh (vector bool short);
21051 vector signed int vec_vupklsh (vector signed short);
21053 vector bool short vec_vupklsb (vector bool char);
21054 vector signed short vec_vupklsb (vector signed char);
21056 vector float vec_xor (vector float, vector float);
21057 vector float vec_xor (vector float, vector bool int);
21058 vector float vec_xor (vector bool int, vector float);
21059 vector bool int vec_xor (vector bool int, vector bool int);
21060 vector signed int vec_xor (vector bool int, vector signed int);
21061 vector signed int vec_xor (vector signed int, vector bool int);
21062 vector signed int vec_xor (vector signed int, vector signed int);
21063 vector unsigned int vec_xor (vector bool int, vector unsigned int);
21064 vector unsigned int vec_xor (vector unsigned int, vector bool int);
21065 vector unsigned int vec_xor (vector unsigned int, vector unsigned int);
21066 vector bool short vec_xor (vector bool short, vector bool short);
21067 vector signed short vec_xor (vector bool short, vector signed short);
21068 vector signed short vec_xor (vector signed short, vector bool short);
21069 vector signed short vec_xor (vector signed short, vector signed short);
21070 vector unsigned short vec_xor (vector bool short,
21071 vector unsigned short);
21072 vector unsigned short vec_xor (vector unsigned short,
21073 vector bool short);
21074 vector unsigned short vec_xor (vector unsigned short,
21075 vector unsigned short);
21076 vector signed char vec_xor (vector bool char, vector signed char);
21077 vector bool char vec_xor (vector bool char, vector bool char);
21078 vector signed char vec_xor (vector signed char, vector bool char);
21079 vector signed char vec_xor (vector signed char, vector signed char);
21080 vector unsigned char vec_xor (vector bool char, vector unsigned char);
21081 vector unsigned char vec_xor (vector unsigned char, vector bool char);
21082 vector unsigned char vec_xor (vector unsigned char,
21083 vector unsigned char);
21085 int vec_all_eq (vector signed char, vector bool char);
21086 int vec_all_eq (vector signed char, vector signed char);
21087 int vec_all_eq (vector unsigned char, vector bool char);
21088 int vec_all_eq (vector unsigned char, vector unsigned char);
21089 int vec_all_eq (vector bool char, vector bool char);
21090 int vec_all_eq (vector bool char, vector unsigned char);
21091 int vec_all_eq (vector bool char, vector signed char);
21092 int vec_all_eq (vector signed short, vector bool short);
21093 int vec_all_eq (vector signed short, vector signed short);
21094 int vec_all_eq (vector unsigned short, vector bool short);
21095 int vec_all_eq (vector unsigned short, vector unsigned short);
21096 int vec_all_eq (vector bool short, vector bool short);
21097 int vec_all_eq (vector bool short, vector unsigned short);
21098 int vec_all_eq (vector bool short, vector signed short);
21099 int vec_all_eq (vector pixel, vector pixel);
21100 int vec_all_eq (vector signed int, vector bool int);
21101 int vec_all_eq (vector signed int, vector signed int);
21102 int vec_all_eq (vector unsigned int, vector bool int);
21103 int vec_all_eq (vector unsigned int, vector unsigned int);
21104 int vec_all_eq (vector bool int, vector bool int);
21105 int vec_all_eq (vector bool int, vector unsigned int);
21106 int vec_all_eq (vector bool int, vector signed int);
21107 int vec_all_eq (vector float, vector float);
21109 int vec_all_ge (vector bool char, vector unsigned char);
21110 int vec_all_ge (vector unsigned char, vector bool char);
21111 int vec_all_ge (vector unsigned char, vector unsigned char);
21112 int vec_all_ge (vector bool char, vector signed char);
21113 int vec_all_ge (vector signed char, vector bool char);
21114 int vec_all_ge (vector signed char, vector signed char);
21115 int vec_all_ge (vector bool short, vector unsigned short);
21116 int vec_all_ge (vector unsigned short, vector bool short);
21117 int vec_all_ge (vector unsigned short, vector unsigned short);
21118 int vec_all_ge (vector signed short, vector signed short);
21119 int vec_all_ge (vector bool short, vector signed short);
21120 int vec_all_ge (vector signed short, vector bool short);
21121 int vec_all_ge (vector bool int, vector unsigned int);
21122 int vec_all_ge (vector unsigned int, vector bool int);
21123 int vec_all_ge (vector unsigned int, vector unsigned int);
21124 int vec_all_ge (vector bool int, vector signed int);
21125 int vec_all_ge (vector signed int, vector bool int);
21126 int vec_all_ge (vector signed int, vector signed int);
21127 int vec_all_ge (vector float, vector float);
21129 int vec_all_gt (vector bool char, vector unsigned char);
21130 int vec_all_gt (vector unsigned char, vector bool char);
21131 int vec_all_gt (vector unsigned char, vector unsigned char);
21132 int vec_all_gt (vector bool char, vector signed char);
21133 int vec_all_gt (vector signed char, vector bool char);
21134 int vec_all_gt (vector signed char, vector signed char);
21135 int vec_all_gt (vector bool short, vector unsigned short);
21136 int vec_all_gt (vector unsigned short, vector bool short);
21137 int vec_all_gt (vector unsigned short, vector unsigned short);
21138 int vec_all_gt (vector bool short, vector signed short);
21139 int vec_all_gt (vector signed short, vector bool short);
21140 int vec_all_gt (vector signed short, vector signed short);
21141 int vec_all_gt (vector bool int, vector unsigned int);
21142 int vec_all_gt (vector unsigned int, vector bool int);
21143 int vec_all_gt (vector unsigned int, vector unsigned int);
21144 int vec_all_gt (vector bool int, vector signed int);
21145 int vec_all_gt (vector signed int, vector bool int);
21146 int vec_all_gt (vector signed int, vector signed int);
21147 int vec_all_gt (vector float, vector float);
21149 int vec_all_in (vector float, vector float);
21151 int vec_all_le (vector bool char, vector unsigned char);
21152 int vec_all_le (vector unsigned char, vector bool char);
21153 int vec_all_le (vector unsigned char, vector unsigned char);
21154 int vec_all_le (vector bool char, vector signed char);
21155 int vec_all_le (vector signed char, vector bool char);
21156 int vec_all_le (vector signed char, vector signed char);
21157 int vec_all_le (vector bool short, vector unsigned short);
21158 int vec_all_le (vector unsigned short, vector bool short);
21159 int vec_all_le (vector unsigned short, vector unsigned short);
21160 int vec_all_le (vector bool short, vector signed short);
21161 int vec_all_le (vector signed short, vector bool short);
21162 int vec_all_le (vector signed short, vector signed short);
21163 int vec_all_le (vector bool int, vector unsigned int);
21164 int vec_all_le (vector unsigned int, vector bool int);
21165 int vec_all_le (vector unsigned int, vector unsigned int);
21166 int vec_all_le (vector bool int, vector signed int);
21167 int vec_all_le (vector signed int, vector bool int);
21168 int vec_all_le (vector signed int, vector signed int);
21169 int vec_all_le (vector float, vector float);
21171 int vec_all_lt (vector bool char, vector unsigned char);
21172 int vec_all_lt (vector unsigned char, vector bool char);
21173 int vec_all_lt (vector unsigned char, vector unsigned char);
21174 int vec_all_lt (vector bool char, vector signed char);
21175 int vec_all_lt (vector signed char, vector bool char);
21176 int vec_all_lt (vector signed char, vector signed char);
21177 int vec_all_lt (vector bool short, vector unsigned short);
21178 int vec_all_lt (vector unsigned short, vector bool short);
21179 int vec_all_lt (vector unsigned short, vector unsigned short);
21180 int vec_all_lt (vector bool short, vector signed short);
21181 int vec_all_lt (vector signed short, vector bool short);
21182 int vec_all_lt (vector signed short, vector signed short);
21183 int vec_all_lt (vector bool int, vector unsigned int);
21184 int vec_all_lt (vector unsigned int, vector bool int);
21185 int vec_all_lt (vector unsigned int, vector unsigned int);
21186 int vec_all_lt (vector bool int, vector signed int);
21187 int vec_all_lt (vector signed int, vector bool int);
21188 int vec_all_lt (vector signed int, vector signed int);
21189 int vec_all_lt (vector float, vector float);
21191 int vec_all_nan (vector float);
21193 int vec_all_ne (vector signed char, vector bool char);
21194 int vec_all_ne (vector signed char, vector signed char);
21195 int vec_all_ne (vector unsigned char, vector bool char);
21196 int vec_all_ne (vector unsigned char, vector unsigned char);
21197 int vec_all_ne (vector bool char, vector bool char);
21198 int vec_all_ne (vector bool char, vector unsigned char);
21199 int vec_all_ne (vector bool char, vector signed char);
21200 int vec_all_ne (vector signed short, vector bool short);
21201 int vec_all_ne (vector signed short, vector signed short);
21202 int vec_all_ne (vector unsigned short, vector bool short);
21203 int vec_all_ne (vector unsigned short, vector unsigned short);
21204 int vec_all_ne (vector bool short, vector bool short);
21205 int vec_all_ne (vector bool short, vector unsigned short);
21206 int vec_all_ne (vector bool short, vector signed short);
21207 int vec_all_ne (vector pixel, vector pixel);
21208 int vec_all_ne (vector signed int, vector bool int);
21209 int vec_all_ne (vector signed int, vector signed int);
21210 int vec_all_ne (vector unsigned int, vector bool int);
21211 int vec_all_ne (vector unsigned int, vector unsigned int);
21212 int vec_all_ne (vector bool int, vector bool int);
21213 int vec_all_ne (vector bool int, vector unsigned int);
21214 int vec_all_ne (vector bool int, vector signed int);
21215 int vec_all_ne (vector float, vector float);
21217 int vec_all_nge (vector float, vector float);
21219 int vec_all_ngt (vector float, vector float);
21221 int vec_all_nle (vector float, vector float);
21223 int vec_all_nlt (vector float, vector float);
21225 int vec_all_numeric (vector float);
21227 int vec_any_eq (vector signed char, vector bool char);
21228 int vec_any_eq (vector signed char, vector signed char);
21229 int vec_any_eq (vector unsigned char, vector bool char);
21230 int vec_any_eq (vector unsigned char, vector unsigned char);
21231 int vec_any_eq (vector bool char, vector bool char);
21232 int vec_any_eq (vector bool char, vector unsigned char);
21233 int vec_any_eq (vector bool char, vector signed char);
21234 int vec_any_eq (vector signed short, vector bool short);
21235 int vec_any_eq (vector signed short, vector signed short);
21236 int vec_any_eq (vector unsigned short, vector bool short);
21237 int vec_any_eq (vector unsigned short, vector unsigned short);
21238 int vec_any_eq (vector bool short, vector bool short);
21239 int vec_any_eq (vector bool short, vector unsigned short);
21240 int vec_any_eq (vector bool short, vector signed short);
21241 int vec_any_eq (vector pixel, vector pixel);
21242 int vec_any_eq (vector signed int, vector bool int);
21243 int vec_any_eq (vector signed int, vector signed int);
21244 int vec_any_eq (vector unsigned int, vector bool int);
21245 int vec_any_eq (vector unsigned int, vector unsigned int);
21246 int vec_any_eq (vector bool int, vector bool int);
21247 int vec_any_eq (vector bool int, vector unsigned int);
21248 int vec_any_eq (vector bool int, vector signed int);
21249 int vec_any_eq (vector float, vector float);
21251 int vec_any_ge (vector signed char, vector bool char);
21252 int vec_any_ge (vector unsigned char, vector bool char);
21253 int vec_any_ge (vector unsigned char, vector unsigned char);
21254 int vec_any_ge (vector signed char, vector signed char);
21255 int vec_any_ge (vector bool char, vector unsigned char);
21256 int vec_any_ge (vector bool char, vector signed char);
21257 int vec_any_ge (vector unsigned short, vector bool short);
21258 int vec_any_ge (vector unsigned short, vector unsigned short);
21259 int vec_any_ge (vector signed short, vector signed short);
21260 int vec_any_ge (vector signed short, vector bool short);
21261 int vec_any_ge (vector bool short, vector unsigned short);
21262 int vec_any_ge (vector bool short, vector signed short);
21263 int vec_any_ge (vector signed int, vector bool int);
21264 int vec_any_ge (vector unsigned int, vector bool int);
21265 int vec_any_ge (vector unsigned int, vector unsigned int);
21266 int vec_any_ge (vector signed int, vector signed int);
21267 int vec_any_ge (vector bool int, vector unsigned int);
21268 int vec_any_ge (vector bool int, vector signed int);
21269 int vec_any_ge (vector float, vector float);
21271 int vec_any_gt (vector bool char, vector unsigned char);
21272 int vec_any_gt (vector unsigned char, vector bool char);
21273 int vec_any_gt (vector unsigned char, vector unsigned char);
21274 int vec_any_gt (vector bool char, vector signed char);
21275 int vec_any_gt (vector signed char, vector bool char);
21276 int vec_any_gt (vector signed char, vector signed char);
21277 int vec_any_gt (vector bool short, vector unsigned short);
21278 int vec_any_gt (vector unsigned short, vector bool short);
21279 int vec_any_gt (vector unsigned short, vector unsigned short);
21280 int vec_any_gt (vector bool short, vector signed short);
21281 int vec_any_gt (vector signed short, vector bool short);
21282 int vec_any_gt (vector signed short, vector signed short);
21283 int vec_any_gt (vector bool int, vector unsigned int);
21284 int vec_any_gt (vector unsigned int, vector bool int);
21285 int vec_any_gt (vector unsigned int, vector unsigned int);
21286 int vec_any_gt (vector bool int, vector signed int);
21287 int vec_any_gt (vector signed int, vector bool int);
21288 int vec_any_gt (vector signed int, vector signed int);
21289 int vec_any_gt (vector float, vector float);
21291 int vec_any_le (vector bool char, vector unsigned char);
21292 int vec_any_le (vector unsigned char, vector bool char);
21293 int vec_any_le (vector unsigned char, vector unsigned char);
21294 int vec_any_le (vector bool char, vector signed char);
21295 int vec_any_le (vector signed char, vector bool char);
21296 int vec_any_le (vector signed char, vector signed char);
21297 int vec_any_le (vector bool short, vector unsigned short);
21298 int vec_any_le (vector unsigned short, vector bool short);
21299 int vec_any_le (vector unsigned short, vector unsigned short);
21300 int vec_any_le (vector bool short, vector signed short);
21301 int vec_any_le (vector signed short, vector bool short);
21302 int vec_any_le (vector signed short, vector signed short);
21303 int vec_any_le (vector bool int, vector unsigned int);
21304 int vec_any_le (vector unsigned int, vector bool int);
21305 int vec_any_le (vector unsigned int, vector unsigned int);
21306 int vec_any_le (vector bool int, vector signed int);
21307 int vec_any_le (vector signed int, vector bool int);
21308 int vec_any_le (vector signed int, vector signed int);
21309 int vec_any_le (vector float, vector float);
21311 int vec_any_lt (vector bool char, vector unsigned char);
21312 int vec_any_lt (vector unsigned char, vector bool char);
21313 int vec_any_lt (vector unsigned char, vector unsigned char);
21314 int vec_any_lt (vector bool char, vector signed char);
21315 int vec_any_lt (vector signed char, vector bool char);
21316 int vec_any_lt (vector signed char, vector signed char);
21317 int vec_any_lt (vector bool short, vector unsigned short);
21318 int vec_any_lt (vector unsigned short, vector bool short);
21319 int vec_any_lt (vector unsigned short, vector unsigned short);
21320 int vec_any_lt (vector bool short, vector signed short);
21321 int vec_any_lt (vector signed short, vector bool short);
21322 int vec_any_lt (vector signed short, vector signed short);
21323 int vec_any_lt (vector bool int, vector unsigned int);
21324 int vec_any_lt (vector unsigned int, vector bool int);
21325 int vec_any_lt (vector unsigned int, vector unsigned int);
21326 int vec_any_lt (vector bool int, vector signed int);
21327 int vec_any_lt (vector signed int, vector bool int);
21328 int vec_any_lt (vector signed int, vector signed int);
21329 int vec_any_lt (vector float, vector float);
21331 int vec_any_nan (vector float);
21333 int vec_any_ne (vector signed char, vector bool char);
21334 int vec_any_ne (vector signed char, vector signed char);
21335 int vec_any_ne (vector unsigned char, vector bool char);
21336 int vec_any_ne (vector unsigned char, vector unsigned char);
21337 int vec_any_ne (vector bool char, vector bool char);
21338 int vec_any_ne (vector bool char, vector unsigned char);
21339 int vec_any_ne (vector bool char, vector signed char);
21340 int vec_any_ne (vector signed short, vector bool short);
21341 int vec_any_ne (vector signed short, vector signed short);
21342 int vec_any_ne (vector unsigned short, vector bool short);
21343 int vec_any_ne (vector unsigned short, vector unsigned short);
21344 int vec_any_ne (vector bool short, vector bool short);
21345 int vec_any_ne (vector bool short, vector unsigned short);
21346 int vec_any_ne (vector bool short, vector signed short);
21347 int vec_any_ne (vector pixel, vector pixel);
21348 int vec_any_ne (vector signed int, vector bool int);
21349 int vec_any_ne (vector signed int, vector signed int);
21350 int vec_any_ne (vector unsigned int, vector bool int);
21351 int vec_any_ne (vector unsigned int, vector unsigned int);
21352 int vec_any_ne (vector bool int, vector bool int);
21353 int vec_any_ne (vector bool int, vector unsigned int);
21354 int vec_any_ne (vector bool int, vector signed int);
21355 int vec_any_ne (vector float, vector float);
21357 int vec_any_nge (vector float, vector float);
21359 int vec_any_ngt (vector float, vector float);
21361 int vec_any_nle (vector float, vector float);
21363 int vec_any_nlt (vector float, vector float);
21365 int vec_any_numeric (vector float);
21367 int vec_any_out (vector float, vector float);
21370 File: gcc.info, Node: SPARC VIS Built-in Functions, Prev: PowerPC AltiVec Built-in Functions, Up: Target Builtins
21372 5.45.7 SPARC VIS Built-in Functions
21373 -----------------------------------
21375 GCC supports SIMD operations on the SPARC using both the generic vector
21376 extensions (*note Vector Extensions::) as well as built-in functions for
21377 the SPARC Visual Instruction Set (VIS). When you use the `-mvis'
21378 switch, the VIS extension is exposed as the following built-in
21381 typedef int v2si __attribute__ ((vector_size (8)));
21382 typedef short v4hi __attribute__ ((vector_size (8)));
21383 typedef short v2hi __attribute__ ((vector_size (4)));
21384 typedef char v8qi __attribute__ ((vector_size (8)));
21385 typedef char v4qi __attribute__ ((vector_size (4)));
21387 void * __builtin_vis_alignaddr (void *, long);
21388 int64_t __builtin_vis_faligndatadi (int64_t, int64_t);
21389 v2si __builtin_vis_faligndatav2si (v2si, v2si);
21390 v4hi __builtin_vis_faligndatav4hi (v4si, v4si);
21391 v8qi __builtin_vis_faligndatav8qi (v8qi, v8qi);
21393 v4hi __builtin_vis_fexpand (v4qi);
21395 v4hi __builtin_vis_fmul8x16 (v4qi, v4hi);
21396 v4hi __builtin_vis_fmul8x16au (v4qi, v4hi);
21397 v4hi __builtin_vis_fmul8x16al (v4qi, v4hi);
21398 v4hi __builtin_vis_fmul8sux16 (v8qi, v4hi);
21399 v4hi __builtin_vis_fmul8ulx16 (v8qi, v4hi);
21400 v2si __builtin_vis_fmuld8sux16 (v4qi, v2hi);
21401 v2si __builtin_vis_fmuld8ulx16 (v4qi, v2hi);
21403 v4qi __builtin_vis_fpack16 (v4hi);
21404 v8qi __builtin_vis_fpack32 (v2si, v2si);
21405 v2hi __builtin_vis_fpackfix (v2si);
21406 v8qi __builtin_vis_fpmerge (v4qi, v4qi);
21408 int64_t __builtin_vis_pdist (v8qi, v8qi, int64_t);
21411 File: gcc.info, Node: Target Format Checks, Next: Pragmas, Prev: Target Builtins, Up: C Extensions
21413 5.46 Format Checks Specific to Particular Target Machines
21414 =========================================================
21416 For some target machines, GCC supports additional options to the format
21417 attribute (*note Declaring Attributes of Functions: Function
21422 * Solaris Format Checks::
21425 File: gcc.info, Node: Solaris Format Checks, Up: Target Format Checks
21427 5.46.1 Solaris Format Checks
21428 ----------------------------
21430 Solaris targets support the `cmn_err' (or `__cmn_err__') format check.
21431 `cmn_err' accepts a subset of the standard `printf' conversions, and
21432 the two-argument `%b' conversion for displaying bit-fields. See the
21433 Solaris man page for `cmn_err' for more information.
21436 File: gcc.info, Node: Pragmas, Next: Unnamed Fields, Prev: Target Format Checks, Up: C Extensions
21438 5.47 Pragmas Accepted by GCC
21439 ============================
21441 GCC supports several types of pragmas, primarily in order to compile
21442 code originally written for other compilers. Note that in general we
21443 do not recommend the use of pragmas; *Note Function Attributes::, for
21444 further explanation.
21449 * RS/6000 and PowerPC Pragmas::
21451 * Solaris Pragmas::
21452 * Symbol-Renaming Pragmas::
21453 * Structure-Packing Pragmas::
21457 File: gcc.info, Node: ARM Pragmas, Next: RS/6000 and PowerPC Pragmas, Up: Pragmas
21462 The ARM target defines pragmas for controlling the default addition of
21463 `long_call' and `short_call' attributes to functions. *Note Function
21464 Attributes::, for information about the effects of these attributes.
21467 Set all subsequent functions to have the `long_call' attribute.
21470 Set all subsequent functions to have the `short_call' attribute.
21473 Do not affect the `long_call' or `short_call' attributes of
21474 subsequent functions.
21477 File: gcc.info, Node: RS/6000 and PowerPC Pragmas, Next: Darwin Pragmas, Prev: ARM Pragmas, Up: Pragmas
21479 5.47.2 RS/6000 and PowerPC Pragmas
21480 ----------------------------------
21482 The RS/6000 and PowerPC targets define one pragma for controlling
21483 whether or not the `longcall' attribute is added to function
21484 declarations by default. This pragma overrides the `-mlongcall'
21485 option, but not the `longcall' and `shortcall' attributes. *Note
21486 RS/6000 and PowerPC Options::, for more information about when long
21487 calls are and are not necessary.
21490 Apply the `longcall' attribute to all subsequent function
21494 Do not apply the `longcall' attribute to subsequent function
21498 File: gcc.info, Node: Darwin Pragmas, Next: Solaris Pragmas, Prev: RS/6000 and PowerPC Pragmas, Up: Pragmas
21500 5.47.3 Darwin Pragmas
21501 ---------------------
21503 The following pragmas are available for all architectures running the
21504 Darwin operating system. These are useful for compatibility with other
21508 This pragma is accepted, but has no effect.
21510 `options align=ALIGNMENT'
21511 This pragma sets the alignment of fields in structures. The
21512 values of ALIGNMENT may be `mac68k', to emulate m68k alignment, or
21513 `power', to emulate PowerPC alignment. Uses of this pragma nest
21514 properly; to restore the previous setting, use `reset' for the
21517 `segment TOKENS...'
21518 This pragma is accepted, but has no effect.
21520 `unused (VAR [, VAR]...)'
21521 This pragma declares variables to be possibly unused. GCC will not
21522 produce warnings for the listed variables. The effect is similar
21523 to that of the `unused' attribute, except that this pragma may
21524 appear anywhere within the variables' scopes.
21527 File: gcc.info, Node: Solaris Pragmas, Next: Symbol-Renaming Pragmas, Prev: Darwin Pragmas, Up: Pragmas
21529 5.47.4 Solaris Pragmas
21530 ----------------------
21532 The Solaris target supports `#pragma redefine_extname' (*note
21533 Symbol-Renaming Pragmas::). It also supports additional `#pragma'
21534 directives for compatibility with the system compiler.
21536 `align ALIGNMENT (VARIABLE [, VARIABLE]...)'
21537 Increase the minimum alignment of each VARIABLE to ALIGNMENT.
21538 This is the same as GCC's `aligned' attribute *note Variable
21539 Attributes::). Macro expansion occurs on the arguments to this
21540 pragma when compiling C and Objective-C. It does not currently
21541 occur when compiling C++, but this is a bug which may be fixed in
21544 `fini (FUNCTION [, FUNCTION]...)'
21545 This pragma causes each listed FUNCTION to be called after main,
21546 or during shared module unloading, by adding a call to the `.fini'
21549 `init (FUNCTION [, FUNCTION]...)'
21550 This pragma causes each listed FUNCTION to be called during
21551 initialization (before `main') or during shared module loading, by
21552 adding a call to the `.init' section.
21556 File: gcc.info, Node: Symbol-Renaming Pragmas, Next: Structure-Packing Pragmas, Prev: Solaris Pragmas, Up: Pragmas
21558 5.47.5 Symbol-Renaming Pragmas
21559 ------------------------------
21561 For compatibility with the Solaris and Tru64 UNIX system headers, GCC
21562 supports two `#pragma' directives which change the name used in
21563 assembly for a given declaration. These pragmas are only available on
21564 platforms whose system headers need them. To get this effect on all
21565 platforms supported by GCC, use the asm labels extension (*note Asm
21568 `redefine_extname OLDNAME NEWNAME'
21569 This pragma gives the C function OLDNAME the assembly symbol
21570 NEWNAME. The preprocessor macro `__PRAGMA_REDEFINE_EXTNAME' will
21571 be defined if this pragma is available (currently only on Solaris).
21573 `extern_prefix STRING'
21574 This pragma causes all subsequent external function and variable
21575 declarations to have STRING prepended to their assembly symbols.
21576 This effect may be terminated with another `extern_prefix' pragma
21577 whose argument is an empty string. The preprocessor macro
21578 `__PRAGMA_EXTERN_PREFIX' will be defined if this pragma is
21579 available (currently only on Tru64 UNIX).
21581 These pragmas and the asm labels extension interact in a complicated
21582 manner. Here are some corner cases you may want to be aware of.
21584 1. Both pragmas silently apply only to declarations with external
21585 linkage. Asm labels do not have this restriction.
21587 2. In C++, both pragmas silently apply only to declarations with "C"
21588 linkage. Again, asm labels do not have this restriction.
21590 3. If any of the three ways of changing the assembly name of a
21591 declaration is applied to a declaration whose assembly name has
21592 already been determined (either by a previous use of one of these
21593 features, or because the compiler needed the assembly name in
21594 order to generate code), and the new name is different, a warning
21595 issues and the name does not change.
21597 4. The OLDNAME used by `#pragma redefine_extname' is always the
21600 5. If `#pragma extern_prefix' is in effect, and a declaration occurs
21601 with an asm label attached, the prefix is silently ignored for
21604 6. If `#pragma extern_prefix' and `#pragma redefine_extname' apply to
21605 the same declaration, whichever triggered first wins, and a
21606 warning issues if they contradict each other. (We would like to
21607 have `#pragma redefine_extname' always win, for consistency with
21608 asm labels, but if `#pragma extern_prefix' triggers first we have
21609 no way of knowing that that happened.)
21612 File: gcc.info, Node: Structure-Packing Pragmas, Next: Weak Pragmas, Prev: Symbol-Renaming Pragmas, Up: Pragmas
21614 5.47.6 Structure-Packing Pragmas
21615 --------------------------------
21617 For compatibility with Win32, GCC supports a set of `#pragma'
21618 directives which change the maximum alignment of members of structures,
21619 unions, and classes subsequently defined. The N value below always is
21620 required to be a small power of two and specifies the new alignment in
21623 1. `#pragma pack(N)' simply sets the new alignment.
21625 2. `#pragma pack()' sets the alignment to the one that was in effect
21626 when compilation started (see also command line option
21627 `-fpack-struct[=<n>]' *note Code Gen Options::).
21629 3. `#pragma pack(push[,N])' pushes the current alignment setting on
21630 an internal stack and then optionally sets the new alignment.
21632 4. `#pragma pack(pop)' restores the alignment setting to the one
21633 saved at the top of the internal stack (and removes that stack
21634 entry). Note that `#pragma pack([N])' does not influence this
21635 internal stack; thus it is possible to have `#pragma pack(push)'
21636 followed by multiple `#pragma pack(N)' instances and finalized by
21637 a single `#pragma pack(pop)'.
21640 File: gcc.info, Node: Weak Pragmas, Prev: Structure-Packing Pragmas, Up: Pragmas
21642 5.47.7 Weak Pragmas
21643 -------------------
21645 For compatibility with SVR4, GCC supports a set of `#pragma' directives
21646 for declaring symbols to be weak, and defining weak aliases.
21648 `#pragma weak SYMBOL'
21649 This pragma declares SYMBOL to be weak, as if the declaration had
21650 the attribute of the same name. The pragma may appear before or
21651 after the declaration of SYMBOL, but must appear before either its
21652 first use or its definition. It is not an error for SYMBOL to
21653 never be defined at all.
21655 `#pragma weak SYMBOL1 = SYMBOL2'
21656 This pragma declares SYMBOL1 to be a weak alias of SYMBOL2. It is
21657 an error if SYMBOL2 is not defined in the current translation unit.
21660 File: gcc.info, Node: Unnamed Fields, Next: Thread-Local, Prev: Pragmas, Up: C Extensions
21662 5.48 Unnamed struct/union fields within structs/unions
21663 ======================================================
21665 For compatibility with other compilers, GCC allows you to define a
21666 structure or union that contains, as fields, structures and unions
21667 without names. For example:
21678 In this example, the user would be able to access members of the
21679 unnamed union with code like `foo.b'. Note that only unnamed structs
21680 and unions are allowed, you may not have, for example, an unnamed `int'.
21682 You must never create such structures that cause ambiguous field
21683 definitions. For example, this structure:
21692 It is ambiguous which `a' is being referred to with `foo.a'. Such
21693 constructs are not supported and must be avoided. In the future, such
21694 constructs may be detected and treated as compilation errors.
21696 Unless `-fms-extensions' is used, the unnamed field must be a
21697 structure or union definition without a tag (for example, `struct { int
21698 a; };'). If `-fms-extensions' is used, the field may also be a
21699 definition with a tag such as `struct foo { int a; };', a reference to
21700 a previously defined structure or union such as `struct foo;', or a
21701 reference to a `typedef' name for a previously defined structure or
21705 File: gcc.info, Node: Thread-Local, Prev: Unnamed Fields, Up: C Extensions
21707 5.49 Thread-Local Storage
21708 =========================
21710 Thread-local storage (TLS) is a mechanism by which variables are
21711 allocated such that there is one instance of the variable per extant
21712 thread. The run-time model GCC uses to implement this originates in
21713 the IA-64 processor-specific ABI, but has since been migrated to other
21714 processors as well. It requires significant support from the linker
21715 (`ld'), dynamic linker (`ld.so'), and system libraries (`libc.so' and
21716 `libpthread.so'), so it is not available everywhere.
21718 At the user level, the extension is visible with a new storage class
21719 keyword: `__thread'. For example:
21722 extern __thread struct state s;
21723 static __thread char *p;
21725 The `__thread' specifier may be used alone, with the `extern' or
21726 `static' specifiers, but with no other storage class specifier. When
21727 used with `extern' or `static', `__thread' must appear immediately
21728 after the other storage class specifier.
21730 The `__thread' specifier may be applied to any global, file-scoped
21731 static, function-scoped static, or static data member of a class. It
21732 may not be applied to block-scoped automatic or non-static data member.
21734 When the address-of operator is applied to a thread-local variable, it
21735 is evaluated at run-time and returns the address of the current thread's
21736 instance of that variable. An address so obtained may be used by any
21737 thread. When a thread terminates, any pointers to thread-local
21738 variables in that thread become invalid.
21740 No static initialization may refer to the address of a thread-local
21743 In C++, if an initializer is present for a thread-local variable, it
21744 must be a CONSTANT-EXPRESSION, as defined in 5.19.2 of the ANSI/ISO C++
21747 See ELF Handling For Thread-Local Storage
21748 (http://people.redhat.com/drepper/tls.pdf) for a detailed explanation of
21749 the four thread-local storage addressing models, and how the run-time
21750 is expected to function.
21754 * C99 Thread-Local Edits::
21755 * C++98 Thread-Local Edits::
21758 File: gcc.info, Node: C99 Thread-Local Edits, Next: C++98 Thread-Local Edits, Up: Thread-Local
21760 5.49.1 ISO/IEC 9899:1999 Edits for Thread-Local Storage
21761 -------------------------------------------------------
21763 The following are a set of changes to ISO/IEC 9899:1999 (aka C99) that
21764 document the exact semantics of the language extension.
21766 * `5.1.2 Execution environments'
21768 Add new text after paragraph 1
21770 Within either execution environment, a "thread" is a flow of
21771 control within a program. It is implementation defined
21772 whether or not there may be more than one thread associated
21773 with a program. It is implementation defined how threads
21774 beyond the first are created, the name and type of the
21775 function called at thread startup, and how threads may be
21776 terminated. However, objects with thread storage duration
21777 shall be initialized before thread startup.
21779 * `6.2.4 Storage durations of objects'
21781 Add new text before paragraph 3
21783 An object whose identifier is declared with the storage-class
21784 specifier `__thread' has "thread storage duration". Its
21785 lifetime is the entire execution of the thread, and its
21786 stored value is initialized only once, prior to thread
21793 * `6.7.1 Storage-class specifiers'
21795 Add `__thread' to the list of storage class specifiers in
21798 Change paragraph 2 to
21800 With the exception of `__thread', at most one storage-class
21801 specifier may be given [...]. The `__thread' specifier may
21802 be used alone, or immediately following `extern' or `static'.
21804 Add new text after paragraph 6
21806 The declaration of an identifier for a variable that has
21807 block scope that specifies `__thread' shall also specify
21808 either `extern' or `static'.
21810 The `__thread' specifier shall be used only with variables.
21813 File: gcc.info, Node: C++98 Thread-Local Edits, Prev: C99 Thread-Local Edits, Up: Thread-Local
21815 5.49.2 ISO/IEC 14882:1998 Edits for Thread-Local Storage
21816 --------------------------------------------------------
21818 The following are a set of changes to ISO/IEC 14882:1998 (aka C++98)
21819 that document the exact semantics of the language extension.
21821 * [intro.execution]
21823 New text after paragraph 4
21825 A "thread" is a flow of control within the abstract machine.
21826 It is implementation defined whether or not there may be more
21829 New text after paragraph 7
21831 It is unspecified whether additional action must be taken to
21832 ensure when and whether side effects are visible to other
21839 * [basic.start.main]
21841 Add after paragraph 5
21843 The thread that begins execution at the `main' function is
21844 called the "main thread". It is implementation defined how
21845 functions beginning threads other than the main thread are
21846 designated or typed. A function so designated, as well as
21847 the `main' function, is called a "thread startup function".
21848 It is implementation defined what happens if a thread startup
21849 function returns. It is implementation defined what happens
21850 to other threads when any thread calls `exit'.
21852 * [basic.start.init]
21854 Add after paragraph 4
21856 The storage for an object of thread storage duration shall be
21857 statically initialized before the first statement of the
21858 thread startup function. An object of thread storage
21859 duration shall not require dynamic initialization.
21861 * [basic.start.term]
21863 Add after paragraph 3
21865 The type of an object with thread storage duration shall not
21866 have a non-trivial destructor, nor shall it be an array type
21867 whose elements (directly or indirectly) have non-trivial
21872 Add "thread storage duration" to the list in paragraph 1.
21876 Thread, static, and automatic storage durations are
21877 associated with objects introduced by declarations [...].
21879 Add `__thread' to the list of specifiers in paragraph 3.
21881 * [basic.stc.thread]
21883 New section before [basic.stc.static]
21885 The keyword `__thread' applied to a non-local object gives the
21886 object thread storage duration.
21888 A local variable or class data member declared both `static'
21889 and `__thread' gives the variable or member thread storage
21892 * [basic.stc.static]
21896 All objects which have neither thread storage duration,
21897 dynamic storage duration nor are local [...].
21901 Add `__thread' to the list in paragraph 1.
21905 With the exception of `__thread', at most one
21906 STORAGE-CLASS-SPECIFIER shall appear in a given
21907 DECL-SPECIFIER-SEQ. The `__thread' specifier may be used
21908 alone, or immediately following the `extern' or `static'
21911 Add after paragraph 5
21913 The `__thread' specifier can be applied only to the names of
21914 objects and to anonymous unions.
21918 Add after paragraph 6
21920 Non-`static' members shall not be `__thread'.
21923 File: gcc.info, Node: C++ Extensions, Next: Objective-C, Prev: C Extensions, Up: Top
21925 6 Extensions to the C++ Language
21926 ********************************
21928 The GNU compiler provides these extensions to the C++ language (and you
21929 can also use most of the C language extensions in your C++ programs).
21930 If you want to write code that checks whether these features are
21931 available, you can test for the GNU compiler the same way as for C
21932 programs: check for a predefined macro `__GNUC__'. You can also use
21933 `__GNUG__' to test specifically for GNU C++ (*note Predefined Macros:
21934 (cpp)Common Predefined Macros.).
21938 * Volatiles:: What constitutes an access to a volatile object.
21939 * Restricted Pointers:: C99 restricted pointers and references.
21940 * Vague Linkage:: Where G++ puts inlines, vtables and such.
21941 * C++ Interface:: You can use a single C++ header file for both
21942 declarations and definitions.
21943 * Template Instantiation:: Methods for ensuring that exactly one copy of
21944 each needed template instantiation is emitted.
21945 * Bound member functions:: You can extract a function pointer to the
21946 method denoted by a `->*' or `.*' expression.
21947 * C++ Attributes:: Variable, function, and type attributes for C++ only.
21948 * Strong Using:: Strong using-directives for namespace composition.
21949 * Java Exceptions:: Tweaking exception handling to work with Java.
21950 * Deprecated Features:: Things will disappear from g++.
21951 * Backwards Compatibility:: Compatibilities with earlier definitions of C++.
21954 File: gcc.info, Node: Volatiles, Next: Restricted Pointers, Up: C++ Extensions
21956 6.1 When is a Volatile Object Accessed?
21957 =======================================
21959 Both the C and C++ standard have the concept of volatile objects. These
21960 are normally accessed by pointers and used for accessing hardware. The
21961 standards encourage compilers to refrain from optimizations concerning
21962 accesses to volatile objects that it might perform on non-volatile
21963 objects. The C standard leaves it implementation defined as to what
21964 constitutes a volatile access. The C++ standard omits to specify this,
21965 except to say that C++ should behave in a similar manner to C with
21966 respect to volatiles, where possible. The minimum either standard
21967 specifies is that at a sequence point all previous accesses to volatile
21968 objects have stabilized and no subsequent accesses have occurred. Thus
21969 an implementation is free to reorder and combine volatile accesses
21970 which occur between sequence points, but cannot do so for accesses
21971 across a sequence point. The use of volatiles does not allow you to
21972 violate the restriction on updating objects multiple times within a
21975 In most expressions, it is intuitively obvious what is a read and what
21976 is a write. For instance
21978 volatile int *dst = SOMEVALUE;
21979 volatile int *src = SOMEOTHERVALUE;
21982 will cause a read of the volatile object pointed to by SRC and stores
21983 the value into the volatile object pointed to by DST. There is no
21984 guarantee that these reads and writes are atomic, especially for objects
21987 Less obvious expressions are where something which looks like an access
21988 is used in a void context. An example would be,
21990 volatile int *src = SOMEVALUE;
21993 With C, such expressions are rvalues, and as rvalues cause a read of
21994 the object, GCC interprets this as a read of the volatile being pointed
21995 to. The C++ standard specifies that such expressions do not undergo
21996 lvalue to rvalue conversion, and that the type of the dereferenced
21997 object may be incomplete. The C++ standard does not specify explicitly
21998 that it is this lvalue to rvalue conversion which is responsible for
21999 causing an access. However, there is reason to believe that it is,
22000 because otherwise certain simple expressions become undefined. However,
22001 because it would surprise most programmers, G++ treats dereferencing a
22002 pointer to volatile object of complete type in a void context as a read
22003 of the object. When the object has incomplete type, G++ issues a
22008 volatile S *ptr1 = SOMEVALUE;
22009 volatile T *ptr2 = SOMEVALUE;
22013 In this example, a warning is issued for `*ptr1', and `*ptr2' causes a
22014 read of the object pointed to. If you wish to force an error on the
22015 first case, you must force a conversion to rvalue with, for instance a
22016 static cast, `static_cast<S>(*ptr1)'.
22018 When using a reference to volatile, G++ does not treat equivalent
22019 expressions as accesses to volatiles, but instead issues a warning that
22020 no volatile is accessed. The rationale for this is that otherwise it
22021 becomes difficult to determine where volatile access occur, and not
22022 possible to ignore the return value from functions returning volatile
22023 references. Again, if you wish to force a read, cast the reference to
22027 File: gcc.info, Node: Restricted Pointers, Next: Vague Linkage, Prev: Volatiles, Up: C++ Extensions
22029 6.2 Restricting Pointer Aliasing
22030 ================================
22032 As with the C front end, G++ understands the C99 feature of restricted
22033 pointers, specified with the `__restrict__', or `__restrict' type
22034 qualifier. Because you cannot compile C++ by specifying the `-std=c99'
22035 language flag, `restrict' is not a keyword in C++.
22037 In addition to allowing restricted pointers, you can specify restricted
22038 references, which indicate that the reference is not aliased in the
22041 void fn (int *__restrict__ rptr, int &__restrict__ rref)
22046 In the body of `fn', RPTR points to an unaliased integer and RREF
22047 refers to a (different) unaliased integer.
22049 You may also specify whether a member function's THIS pointer is
22050 unaliased by using `__restrict__' as a member function qualifier.
22052 void T::fn () __restrict__
22057 Within the body of `T::fn', THIS will have the effective definition `T
22058 *__restrict__ const this'. Notice that the interpretation of a
22059 `__restrict__' member function qualifier is different to that of
22060 `const' or `volatile' qualifier, in that it is applied to the pointer
22061 rather than the object. This is consistent with other compilers which
22062 implement restricted pointers.
22064 As with all outermost parameter qualifiers, `__restrict__' is ignored
22065 in function definition matching. This means you only need to specify
22066 `__restrict__' in a function definition, rather than in a function
22070 File: gcc.info, Node: Vague Linkage, Next: C++ Interface, Prev: Restricted Pointers, Up: C++ Extensions
22075 There are several constructs in C++ which require space in the object
22076 file but are not clearly tied to a single translation unit. We say that
22077 these constructs have "vague linkage". Typically such constructs are
22078 emitted wherever they are needed, though sometimes we can be more
22082 Inline functions are typically defined in a header file which can
22083 be included in many different compilations. Hopefully they can
22084 usually be inlined, but sometimes an out-of-line copy is
22085 necessary, if the address of the function is taken or if inlining
22086 fails. In general, we emit an out-of-line copy in all translation
22087 units where one is needed. As an exception, we only emit inline
22088 virtual functions with the vtable, since it will always require a
22091 Local static variables and string constants used in an inline
22092 function are also considered to have vague linkage, since they
22093 must be shared between all inlined and out-of-line instances of
22097 C++ virtual functions are implemented in most compilers using a
22098 lookup table, known as a vtable. The vtable contains pointers to
22099 the virtual functions provided by a class, and each object of the
22100 class contains a pointer to its vtable (or vtables, in some
22101 multiple-inheritance situations). If the class declares any
22102 non-inline, non-pure virtual functions, the first one is chosen as
22103 the "key method" for the class, and the vtable is only emitted in
22104 the translation unit where the key method is defined.
22106 _Note:_ If the chosen key method is later defined as inline, the
22107 vtable will still be emitted in every translation unit which
22108 defines it. Make sure that any inline virtuals are declared
22109 inline in the class body, even if they are not defined there.
22112 C++ requires information about types to be written out in order to
22113 implement `dynamic_cast', `typeid' and exception handling. For
22114 polymorphic classes (classes with virtual functions), the type_info
22115 object is written out along with the vtable so that `dynamic_cast'
22116 can determine the dynamic type of a class object at runtime. For
22117 all other types, we write out the type_info object when it is
22118 used: when applying `typeid' to an expression, throwing an object,
22119 or referring to a type in a catch clause or exception
22122 Template Instantiations
22123 Most everything in this section also applies to template
22124 instantiations, but there are other options as well. *Note
22125 Where's the Template?: Template Instantiation.
22128 When used with GNU ld version 2.8 or later on an ELF system such as
22129 GNU/Linux or Solaris 2, or on Microsoft Windows, duplicate copies of
22130 these constructs will be discarded at link time. This is known as
22133 On targets that don't support COMDAT, but do support weak symbols, GCC
22134 will use them. This way one copy will override all the others, but the
22135 unused copies will still take up space in the executable.
22137 For targets which do not support either COMDAT or weak symbols, most
22138 entities with vague linkage will be emitted as local symbols to avoid
22139 duplicate definition errors from the linker. This will not happen for
22140 local statics in inlines, however, as having multiple copies will
22141 almost certainly break things.
22143 *Note Declarations and Definitions in One Header: C++ Interface, for
22144 another way to control placement of these constructs.
22147 File: gcc.info, Node: C++ Interface, Next: Template Instantiation, Prev: Vague Linkage, Up: C++ Extensions
22149 6.4 #pragma interface and implementation
22150 ========================================
22152 `#pragma interface' and `#pragma implementation' provide the user with
22153 a way of explicitly directing the compiler to emit entities with vague
22154 linkage (and debugging information) in a particular translation unit.
22156 _Note:_ As of GCC 2.7.2, these `#pragma's are not useful in most
22157 cases, because of COMDAT support and the "key method" heuristic
22158 mentioned in *Note Vague Linkage::. Using them can actually cause your
22159 program to grow due to unnecessary out-of-line copies of inline
22160 functions. Currently (3.4) the only benefit of these `#pragma's is
22161 reduced duplication of debugging information, and that should be
22162 addressed soon on DWARF 2 targets with the use of COMDAT groups.
22164 `#pragma interface'
22165 `#pragma interface "SUBDIR/OBJECTS.h"'
22166 Use this directive in _header files_ that define object classes,
22167 to save space in most of the object files that use those classes.
22168 Normally, local copies of certain information (backup copies of
22169 inline member functions, debugging information, and the internal
22170 tables that implement virtual functions) must be kept in each
22171 object file that includes class definitions. You can use this
22172 pragma to avoid such duplication. When a header file containing
22173 `#pragma interface' is included in a compilation, this auxiliary
22174 information will not be generated (unless the main input source
22175 file itself uses `#pragma implementation'). Instead, the object
22176 files will contain references to be resolved at link time.
22178 The second form of this directive is useful for the case where you
22179 have multiple headers with the same name in different directories.
22180 If you use this form, you must specify the same string to `#pragma
22183 `#pragma implementation'
22184 `#pragma implementation "OBJECTS.h"'
22185 Use this pragma in a _main input file_, when you want full output
22186 from included header files to be generated (and made globally
22187 visible). The included header file, in turn, should use `#pragma
22188 interface'. Backup copies of inline member functions, debugging
22189 information, and the internal tables used to implement virtual
22190 functions are all generated in implementation files.
22192 If you use `#pragma implementation' with no argument, it applies to
22193 an include file with the same basename(1) as your source file.
22194 For example, in `allclass.cc', giving just `#pragma implementation'
22195 by itself is equivalent to `#pragma implementation "allclass.h"'.
22197 In versions of GNU C++ prior to 2.6.0 `allclass.h' was treated as
22198 an implementation file whenever you would include it from
22199 `allclass.cc' even if you never specified `#pragma
22200 implementation'. This was deemed to be more trouble than it was
22201 worth, however, and disabled.
22203 Use the string argument if you want a single implementation file to
22204 include code from multiple header files. (You must also use
22205 `#include' to include the header file; `#pragma implementation'
22206 only specifies how to use the file--it doesn't actually include
22209 There is no way to split up the contents of a single header file
22210 into multiple implementation files.
22212 `#pragma implementation' and `#pragma interface' also have an effect
22213 on function inlining.
22215 If you define a class in a header file marked with `#pragma
22216 interface', the effect on an inline function defined in that class is
22217 similar to an explicit `extern' declaration--the compiler emits no code
22218 at all to define an independent version of the function. Its
22219 definition is used only for inlining with its callers.
22221 Conversely, when you include the same header file in a main source file
22222 that declares it as `#pragma implementation', the compiler emits code
22223 for the function itself; this defines a version of the function that
22224 can be found via pointers (or by callers compiled without inlining).
22225 If all calls to the function can be inlined, you can avoid emitting the
22226 function by compiling with `-fno-implement-inlines'. If any calls were
22227 not inlined, you will get linker errors.
22229 ---------- Footnotes ----------
22231 (1) A file's "basename" was the name stripped of all leading path
22232 information and of trailing suffixes, such as `.h' or `.C' or `.cc'.
22235 File: gcc.info, Node: Template Instantiation, Next: Bound member functions, Prev: C++ Interface, Up: C++ Extensions
22237 6.5 Where's the Template?
22238 =========================
22240 C++ templates are the first language feature to require more
22241 intelligence from the environment than one usually finds on a UNIX
22242 system. Somehow the compiler and linker have to make sure that each
22243 template instance occurs exactly once in the executable if it is needed,
22244 and not at all otherwise. There are two basic approaches to this
22245 problem, which are referred to as the Borland model and the Cfront
22249 Borland C++ solved the template instantiation problem by adding
22250 the code equivalent of common blocks to their linker; the compiler
22251 emits template instances in each translation unit that uses them,
22252 and the linker collapses them together. The advantage of this
22253 model is that the linker only has to consider the object files
22254 themselves; there is no external complexity to worry about. This
22255 disadvantage is that compilation time is increased because the
22256 template code is being compiled repeatedly. Code written for this
22257 model tends to include definitions of all templates in the header
22258 file, since they must be seen to be instantiated.
22261 The AT&T C++ translator, Cfront, solved the template instantiation
22262 problem by creating the notion of a template repository, an
22263 automatically maintained place where template instances are
22264 stored. A more modern version of the repository works as follows:
22265 As individual object files are built, the compiler places any
22266 template definitions and instantiations encountered in the
22267 repository. At link time, the link wrapper adds in the objects in
22268 the repository and compiles any needed instances that were not
22269 previously emitted. The advantages of this model are more optimal
22270 compilation speed and the ability to use the system linker; to
22271 implement the Borland model a compiler vendor also needs to
22272 replace the linker. The disadvantages are vastly increased
22273 complexity, and thus potential for error; for some code this can be
22274 just as transparent, but in practice it can been very difficult to
22275 build multiple programs in one directory and one program in
22276 multiple directories. Code written for this model tends to
22277 separate definitions of non-inline member templates into a
22278 separate file, which should be compiled separately.
22280 When used with GNU ld version 2.8 or later on an ELF system such as
22281 GNU/Linux or Solaris 2, or on Microsoft Windows, G++ supports the
22282 Borland model. On other systems, G++ implements neither automatic
22285 A future version of G++ will support a hybrid model whereby the
22286 compiler will emit any instantiations for which the template definition
22287 is included in the compile, and store template definitions and
22288 instantiation context information into the object file for the rest.
22289 The link wrapper will extract that information as necessary and invoke
22290 the compiler to produce the remaining instantiations. The linker will
22291 then combine duplicate instantiations.
22293 In the mean time, you have the following options for dealing with
22294 template instantiations:
22296 1. Compile your template-using code with `-frepo'. The compiler will
22297 generate files with the extension `.rpo' listing all of the
22298 template instantiations used in the corresponding object files
22299 which could be instantiated there; the link wrapper, `collect2',
22300 will then update the `.rpo' files to tell the compiler where to
22301 place those instantiations and rebuild any affected object files.
22302 The link-time overhead is negligible after the first pass, as the
22303 compiler will continue to place the instantiations in the same
22306 This is your best option for application code written for the
22307 Borland model, as it will just work. Code written for the Cfront
22308 model will need to be modified so that the template definitions
22309 are available at one or more points of instantiation; usually this
22310 is as simple as adding `#include <tmethods.cc>' to the end of each
22313 For library code, if you want the library to provide all of the
22314 template instantiations it needs, just try to link all of its
22315 object files together; the link will fail, but cause the
22316 instantiations to be generated as a side effect. Be warned,
22317 however, that this may cause conflicts if multiple libraries try
22318 to provide the same instantiations. For greater control, use
22319 explicit instantiation as described in the next option.
22321 2. Compile your code with `-fno-implicit-templates' to disable the
22322 implicit generation of template instances, and explicitly
22323 instantiate all the ones you use. This approach requires more
22324 knowledge of exactly which instances you need than do the others,
22325 but it's less mysterious and allows greater control. You can
22326 scatter the explicit instantiations throughout your program,
22327 perhaps putting them in the translation units where the instances
22328 are used or the translation units that define the templates
22329 themselves; you can put all of the explicit instantiations you
22330 need into one big file; or you can create small files like
22335 template class Foo<int>;
22336 template ostream& operator <<
22337 (ostream&, const Foo<int>&);
22339 for each of the instances you need, and create a template
22340 instantiation library from those.
22342 If you are using Cfront-model code, you can probably get away with
22343 not using `-fno-implicit-templates' when compiling files that don't
22344 `#include' the member template definitions.
22346 If you use one big file to do the instantiations, you may want to
22347 compile it without `-fno-implicit-templates' so you get all of the
22348 instances required by your explicit instantiations (but not by any
22349 other files) without having to specify them as well.
22351 G++ has extended the template instantiation syntax given in the ISO
22352 standard to allow forward declaration of explicit instantiations
22353 (with `extern'), instantiation of the compiler support data for a
22354 template class (i.e. the vtable) without instantiating any of its
22355 members (with `inline'), and instantiation of only the static data
22356 members of a template class, without the support data or member
22357 functions (with (`static'):
22359 extern template int max (int, int);
22360 inline template class Foo<int>;
22361 static template class Foo<int>;
22363 3. Do nothing. Pretend G++ does implement automatic instantiation
22364 management. Code written for the Borland model will work fine, but
22365 each translation unit will contain instances of each of the
22366 templates it uses. In a large program, this can lead to an
22367 unacceptable amount of code duplication.
22370 File: gcc.info, Node: Bound member functions, Next: C++ Attributes, Prev: Template Instantiation, Up: C++ Extensions
22372 6.6 Extracting the function pointer from a bound pointer to member function
22373 ===========================================================================
22375 In C++, pointer to member functions (PMFs) are implemented using a wide
22376 pointer of sorts to handle all the possible call mechanisms; the PMF
22377 needs to store information about how to adjust the `this' pointer, and
22378 if the function pointed to is virtual, where to find the vtable, and
22379 where in the vtable to look for the member function. If you are using
22380 PMFs in an inner loop, you should really reconsider that decision. If
22381 that is not an option, you can extract the pointer to the function that
22382 would be called for a given object/PMF pair and call it directly inside
22383 the inner loop, to save a bit of time.
22385 Note that you will still be paying the penalty for the call through a
22386 function pointer; on most modern architectures, such a call defeats the
22387 branch prediction features of the CPU. This is also true of normal
22388 virtual function calls.
22390 The syntax for this extension is
22393 extern int (A::*fp)();
22394 typedef int (*fptr)(A *);
22396 fptr p = (fptr)(a.*fp);
22398 For PMF constants (i.e. expressions of the form `&Klasse::Member'), no
22399 object is needed to obtain the address of the function. They can be
22400 converted to function pointers directly:
22402 fptr p1 = (fptr)(&A::foo);
22404 You must specify `-Wno-pmf-conversions' to use this extension.
22407 File: gcc.info, Node: C++ Attributes, Next: Strong Using, Prev: Bound member functions, Up: C++ Extensions
22409 6.7 C++-Specific Variable, Function, and Type Attributes
22410 ========================================================
22412 Some attributes only make sense for C++ programs.
22414 `init_priority (PRIORITY)'
22415 In Standard C++, objects defined at namespace scope are guaranteed
22416 to be initialized in an order in strict accordance with that of
22417 their definitions _in a given translation unit_. No guarantee is
22418 made for initializations across translation units. However, GNU
22419 C++ allows users to control the order of initialization of objects
22420 defined at namespace scope with the `init_priority' attribute by
22421 specifying a relative PRIORITY, a constant integral expression
22422 currently bounded between 101 and 65535 inclusive. Lower numbers
22423 indicate a higher priority.
22425 In the following example, `A' would normally be created before
22426 `B', but the `init_priority' attribute has reversed that order:
22428 Some_Class A __attribute__ ((init_priority (2000)));
22429 Some_Class B __attribute__ ((init_priority (543)));
22431 Note that the particular values of PRIORITY do not matter; only
22432 their relative ordering.
22435 This type attribute informs C++ that the class is a Java
22436 interface. It may only be applied to classes declared within an
22437 `extern "Java"' block. Calls to methods declared in this
22438 interface will be dispatched using GCJ's interface table
22439 mechanism, instead of regular virtual table dispatch.
22442 See also *Note Strong Using::.
22445 File: gcc.info, Node: Strong Using, Next: Java Exceptions, Prev: C++ Attributes, Up: C++ Extensions
22450 *Caution:* The semantics of this extension are not fully defined.
22451 Users should refrain from using this extension as its semantics may
22452 change subtly over time. It is possible that this extension wil be
22453 removed in future versions of G++.
22455 A using-directive with `__attribute ((strong))' is stronger than a
22456 normal using-directive in two ways:
22458 * Templates from the used namespace can be specialized as though
22459 they were members of the using namespace.
22461 * The using namespace is considered an associated namespace of all
22462 templates in the used namespace for purposes of argument-dependent
22465 This is useful for composing a namespace transparently from
22466 implementation namespaces. For example:
22470 template <class T> struct A { };
22472 using namespace debug __attribute ((__strong__));
22473 template <> struct A<int> { }; // ok to specialize
22475 template <class T> void f (A<T>);
22480 f (std::A<float>()); // lookup finds std::f
22485 File: gcc.info, Node: Java Exceptions, Next: Deprecated Features, Prev: Strong Using, Up: C++ Extensions
22487 6.9 Java Exceptions
22488 ===================
22490 The Java language uses a slightly different exception handling model
22491 from C++. Normally, GNU C++ will automatically detect when you are
22492 writing C++ code that uses Java exceptions, and handle them
22493 appropriately. However, if C++ code only needs to execute destructors
22494 when Java exceptions are thrown through it, GCC will guess incorrectly.
22495 Sample problematic code is:
22497 struct S { ~S(); };
22498 extern void bar(); // is written in Java, and may throw exceptions
22505 The usual effect of an incorrect guess is a link failure, complaining of
22506 a missing routine called `__gxx_personality_v0'.
22508 You can inform the compiler that Java exceptions are to be used in a
22509 translation unit, irrespective of what it might think, by writing
22510 `#pragma GCC java_exceptions' at the head of the file. This `#pragma'
22511 must appear before any functions that throw or catch exceptions, or run
22512 destructors when exceptions are thrown through them.
22514 You cannot mix Java and C++ exceptions in the same translation unit.
22515 It is believed to be safe to throw a C++ exception from one file through
22516 another file compiled for the Java exception model, or vice versa, but
22517 there may be bugs in this area.
22520 File: gcc.info, Node: Deprecated Features, Next: Backwards Compatibility, Prev: Java Exceptions, Up: C++ Extensions
22522 6.10 Deprecated Features
22523 ========================
22525 In the past, the GNU C++ compiler was extended to experiment with new
22526 features, at a time when the C++ language was still evolving. Now that
22527 the C++ standard is complete, some of those features are superseded by
22528 superior alternatives. Using the old features might cause a warning in
22529 some cases that the feature will be dropped in the future. In other
22530 cases, the feature might be gone already.
22532 While the list below is not exhaustive, it documents some of the
22533 options that are now deprecated:
22535 `-fexternal-templates'
22536 `-falt-external-templates'
22537 These are two of the many ways for G++ to implement template
22538 instantiation. *Note Template Instantiation::. The C++ standard
22539 clearly defines how template definitions have to be organized
22540 across implementation units. G++ has an implicit instantiation
22541 mechanism that should work just fine for standard-conforming code.
22543 `-fstrict-prototype'
22544 `-fno-strict-prototype'
22545 Previously it was possible to use an empty prototype parameter
22546 list to indicate an unspecified number of parameters (like C),
22547 rather than no parameters, as C++ demands. This feature has been
22548 removed, except where it is required for backwards compatibility
22549 *Note Backwards Compatibility::.
22551 G++ allows a virtual function returning `void *' to be overridden by
22552 one returning a different pointer type. This extension to the
22553 covariant return type rules is now deprecated and will be removed from a
22556 The G++ minimum and maximum operators (`<?' and `>?') and their
22557 compound forms (`<?=') and `>?=') have been deprecated and will be
22558 removed in a future version. Code using these operators should be
22559 modified to use `std::min' and `std::max' instead.
22561 The named return value extension has been deprecated, and is now
22564 The use of initializer lists with new expressions has been deprecated,
22565 and is now removed from G++.
22567 Floating and complex non-type template parameters have been deprecated,
22568 and are now removed from G++.
22570 The implicit typename extension has been deprecated and is now removed
22573 The use of default arguments in function pointers, function typedefs
22574 and and other places where they are not permitted by the standard is
22575 deprecated and will be removed from a future version of G++.
22577 G++ allows floating-point literals to appear in integral constant
22578 expressions, e.g. ` enum E { e = int(2.2 * 3.7) } ' This extension is
22579 deprecated and will be removed from a future version.
22581 G++ allows static data members of const floating-point type to be
22582 declared with an initializer in a class definition. The standard only
22583 allows initializers for static members of const integral types and const
22584 enumeration types so this extension has been deprecated and will be
22585 removed from a future version.
22588 File: gcc.info, Node: Backwards Compatibility, Prev: Deprecated Features, Up: C++ Extensions
22590 6.11 Backwards Compatibility
22591 ============================
22593 Now that there is a definitive ISO standard C++, G++ has a specification
22594 to adhere to. The C++ language evolved over time, and features that
22595 used to be acceptable in previous drafts of the standard, such as the
22596 ARM [Annotated C++ Reference Manual], are no longer accepted. In order
22597 to allow compilation of C++ written to such drafts, G++ contains some
22598 backwards compatibilities. _All such backwards compatibility features
22599 are liable to disappear in future versions of G++._ They should be
22600 considered deprecated *Note Deprecated Features::.
22603 If a variable is declared at for scope, it used to remain in scope
22604 until the end of the scope which contained the for statement
22605 (rather than just within the for scope). G++ retains this, but
22606 issues a warning, if such a variable is accessed outside the for
22609 `Implicit C language'
22610 Old C system header files did not contain an `extern "C" {...}'
22611 scope to set the language. On such systems, all header files are
22612 implicitly scoped inside a C language scope. Also, an empty
22613 prototype `()' will be treated as an unspecified number of
22614 arguments, rather than no arguments, as C++ demands.
22617 File: gcc.info, Node: Objective-C, Next: Compatibility, Prev: C++ Extensions, Up: Top
22619 7 GNU Objective-C runtime features
22620 **********************************
22622 This document is meant to describe some of the GNU Objective-C runtime
22623 features. It is not intended to teach you Objective-C, there are
22624 several resources on the Internet that present the language. Questions
22625 and comments about this document to Ovidiu Predescu <ovidiu@cup.hp.com>.
22629 * Executing code before main::
22631 * Garbage Collection::
22632 * Constant string objects::
22633 * compatibility_alias::
22636 File: gcc.info, Node: Executing code before main, Next: Type encoding, Prev: Objective-C, Up: Objective-C
22638 7.1 `+load': Executing code before main
22639 =======================================
22641 The GNU Objective-C runtime provides a way that allows you to execute
22642 code before the execution of the program enters the `main' function.
22643 The code is executed on a per-class and a per-category basis, through a
22644 special class method `+load'.
22646 This facility is very useful if you want to initialize global variables
22647 which can be accessed by the program directly, without sending a message
22648 to the class first. The usual way to initialize global variables, in
22649 the `+initialize' method, might not be useful because `+initialize' is
22650 only called when the first message is sent to a class object, which in
22651 some cases could be too late.
22653 Suppose for example you have a `FileStream' class that declares
22654 `Stdin', `Stdout' and `Stderr' as global variables, like below:
22657 FileStream *Stdin = nil;
22658 FileStream *Stdout = nil;
22659 FileStream *Stderr = nil;
22661 @implementation FileStream
22665 Stdin = [[FileStream new] initWithFd:0];
22666 Stdout = [[FileStream new] initWithFd:1];
22667 Stderr = [[FileStream new] initWithFd:2];
22670 /* Other methods here */
22673 In this example, the initialization of `Stdin', `Stdout' and `Stderr'
22674 in `+initialize' occurs too late. The programmer can send a message to
22675 one of these objects before the variables are actually initialized,
22676 thus sending messages to the `nil' object. The `+initialize' method
22677 which actually initializes the global variables is not invoked until
22678 the first message is sent to the class object. The solution would
22679 require these variables to be initialized just before entering `main'.
22681 The correct solution of the above problem is to use the `+load' method
22682 instead of `+initialize':
22685 @implementation FileStream
22689 Stdin = [[FileStream new] initWithFd:0];
22690 Stdout = [[FileStream new] initWithFd:1];
22691 Stderr = [[FileStream new] initWithFd:2];
22694 /* Other methods here */
22697 The `+load' is a method that is not overridden by categories. If a
22698 class and a category of it both implement `+load', both methods are
22699 invoked. This allows some additional initializations to be performed in
22702 This mechanism is not intended to be a replacement for `+initialize'.
22703 You should be aware of its limitations when you decide to use it
22704 instead of `+initialize'.
22708 * What you can and what you cannot do in +load::
22711 File: gcc.info, Node: What you can and what you cannot do in +load, Prev: Executing code before main, Up: Executing code before main
22713 7.1.1 What you can and what you cannot do in `+load'
22714 ----------------------------------------------------
22716 The `+load' implementation in the GNU runtime guarantees you the
22719 * you can write whatever C code you like;
22721 * you can send messages to Objective-C constant strings (`@"this is a
22722 constant string"');
22724 * you can allocate and send messages to objects whose class is
22725 implemented in the same file;
22727 * the `+load' implementation of all super classes of a class are
22728 executed before the `+load' of that class is executed;
22730 * the `+load' implementation of a class is executed before the
22731 `+load' implementation of any category.
22734 In particular, the following things, even if they can work in a
22735 particular case, are not guaranteed:
22737 * allocation of or sending messages to arbitrary objects;
22739 * allocation of or sending messages to objects whose classes have a
22740 category implemented in the same file;
22743 You should make no assumptions about receiving `+load' in sibling
22744 classes when you write `+load' of a class. The order in which sibling
22745 classes receive `+load' is not guaranteed.
22747 The order in which `+load' and `+initialize' are called could be
22748 problematic if this matters. If you don't allocate objects inside
22749 `+load', it is guaranteed that `+load' is called before `+initialize'.
22750 If you create an object inside `+load' the `+initialize' method of
22751 object's class is invoked even if `+load' was not invoked. Note if you
22752 explicitly call `+load' on a class, `+initialize' will be called first.
22753 To avoid possible problems try to implement only one of these methods.
22755 The `+load' method is also invoked when a bundle is dynamically loaded
22756 into your running program. This happens automatically without any
22757 intervening operation from you. When you write bundles and you need to
22758 write `+load' you can safely create and send messages to objects whose
22759 classes already exist in the running program. The same restrictions as
22760 above apply to classes defined in bundle.
22763 File: gcc.info, Node: Type encoding, Next: Garbage Collection, Prev: Executing code before main, Up: Objective-C
22768 The Objective-C compiler generates type encodings for all the types.
22769 These type encodings are used at runtime to find out information about
22770 selectors and methods and about objects and classes.
22772 The types are encoded in the following way:
22775 `unsigned char' `C'
22777 `unsigned short' `S'
22781 `unsigned long' `L'
22793 bit-fields `b' followed by the starting position of the
22794 bit-field, the type of the bit-field and the size of
22795 the bit-field (the bit-fields encoding was changed
22796 from the NeXT's compiler encoding, see below)
22798 The encoding of bit-fields has changed to allow bit-fields to be
22799 properly handled by the runtime functions that compute sizes and
22800 alignments of types that contain bit-fields. The previous encoding
22801 contained only the size of the bit-field. Using only this information
22802 it is not possible to reliably compute the size occupied by the
22803 bit-field. This is very important in the presence of the Boehm's
22804 garbage collector because the objects are allocated using the typed
22805 memory facility available in this collector. The typed memory
22806 allocation requires information about where the pointers are located
22809 The position in the bit-field is the position, counting in bits, of the
22810 bit closest to the beginning of the structure.
22812 The non-atomic types are encoded as follows:
22814 pointers `^' followed by the pointed type.
22815 arrays `[' followed by the number of elements in the array
22816 followed by the type of the elements followed by `]'
22817 structures `{' followed by the name of the structure (or `?' if the
22818 structure is unnamed), the `=' sign, the type of the
22820 unions `(' followed by the name of the structure (or `?' if the
22821 union is unnamed), the `=' sign, the type of the members
22824 Here are some types and their encodings, as they are generated by the
22825 compiler on an i386 machine:
22828 Objective-C type Compiler encoding
22830 struct { `{?=i[3f]b128i3b131i2c}'
22839 In addition to the types the compiler also encodes the type
22840 specifiers. The table below describes the encoding of the current
22841 Objective-C type specifiers:
22853 The type specifiers are encoded just before the type. Unlike types
22854 however, the type specifiers are only encoded when they appear in method
22858 File: gcc.info, Node: Garbage Collection, Next: Constant string objects, Prev: Type encoding, Up: Objective-C
22860 7.3 Garbage Collection
22861 ======================
22863 Support for a new memory management policy has been added by using a
22864 powerful conservative garbage collector, known as the
22865 Boehm-Demers-Weiser conservative garbage collector. It is available
22866 from `http://www.hpl.hp.com/personal/Hans_Boehm/gc/'.
22868 To enable the support for it you have to configure the compiler using
22869 an additional argument, `--enable-objc-gc'. You need to have garbage
22870 collector installed before building the compiler. This will build an
22871 additional runtime library which has several enhancements to support
22872 the garbage collector. The new library has a new name, `libobjc_gc.a'
22873 to not conflict with the non-garbage-collected library.
22875 When the garbage collector is used, the objects are allocated using the
22876 so-called typed memory allocation mechanism available in the
22877 Boehm-Demers-Weiser collector. This mode requires precise information
22878 on where pointers are located inside objects. This information is
22879 computed once per class, immediately after the class has been
22882 There is a new runtime function `class_ivar_set_gcinvisible()' which
22883 can be used to declare a so-called "weak pointer" reference. Such a
22884 pointer is basically hidden for the garbage collector; this can be
22885 useful in certain situations, especially when you want to keep track of
22886 the allocated objects, yet allow them to be collected. This kind of
22887 pointers can only be members of objects, you cannot declare a global
22888 pointer as a weak reference. Every type which is a pointer type can be
22889 declared a weak pointer, including `id', `Class' and `SEL'.
22891 Here is an example of how to use this feature. Suppose you want to
22892 implement a class whose instances hold a weak pointer reference; the
22893 following class does this:
22896 @interface WeakPointer : Object
22898 const void* weakPointer;
22901 - initWithPointer:(const void*)p;
22902 - (const void*)weakPointer;
22906 @implementation WeakPointer
22910 class_ivar_set_gcinvisible (self, "weakPointer", YES);
22913 - initWithPointer:(const void*)p
22919 - (const void*)weakPointer
22921 return weakPointer;
22926 Weak pointers are supported through a new type character specifier
22927 represented by the `!' character. The `class_ivar_set_gcinvisible()'
22928 function adds or removes this specifier to the string type description
22929 of the instance variable named as argument.
22932 File: gcc.info, Node: Constant string objects, Next: compatibility_alias, Prev: Garbage Collection, Up: Objective-C
22934 7.4 Constant string objects
22935 ===========================
22937 GNU Objective-C provides constant string objects that are generated
22938 directly by the compiler. You declare a constant string object by
22939 prefixing a C constant string with the character `@':
22941 id myString = @"this is a constant string object";
22943 The constant string objects are by default instances of the
22944 `NXConstantString' class which is provided by the GNU Objective-C
22945 runtime. To get the definition of this class you must include the
22946 `objc/NXConstStr.h' header file.
22948 User defined libraries may want to implement their own constant string
22949 class. To be able to support them, the GNU Objective-C compiler
22950 provides a new command line options
22951 `-fconstant-string-class=CLASS-NAME'. The provided class should adhere
22952 to a strict structure, the same as `NXConstantString''s structure:
22955 @interface MyConstantStringClass
22963 `NXConstantString' inherits from `Object'; user class libraries may
22964 choose to inherit the customized constant string class from a different
22965 class than `Object'. There is no requirement in the methods the
22966 constant string class has to implement, but the final ivar layout of
22967 the class must be the compatible with the given structure.
22969 When the compiler creates the statically allocated constant string
22970 object, the `c_string' field will be filled by the compiler with the
22971 string; the `length' field will be filled by the compiler with the
22972 string length; the `isa' pointer will be filled with `NULL' by the
22973 compiler, and it will later be fixed up automatically at runtime by the
22974 GNU Objective-C runtime library to point to the class which was set by
22975 the `-fconstant-string-class' option when the object file is loaded (if
22976 you wonder how it works behind the scenes, the name of the class to
22977 use, and the list of static objects to fixup, are stored by the
22978 compiler in the object file in a place where the GNU runtime library
22979 will find them at runtime).
22981 As a result, when a file is compiled with the
22982 `-fconstant-string-class' option, all the constant string objects will
22983 be instances of the class specified as argument to this option. It is
22984 possible to have multiple compilation units referring to different
22985 constant string classes, neither the compiler nor the linker impose any
22986 restrictions in doing this.
22989 File: gcc.info, Node: compatibility_alias, Prev: Constant string objects, Up: Objective-C
22991 7.5 compatibility_alias
22992 =======================
22994 This is a feature of the Objective-C compiler rather than of the
22995 runtime, anyway since it is documented nowhere and its existence was
22996 forgotten, we are documenting it here.
22998 The keyword `@compatibility_alias' allows you to define a class name
22999 as equivalent to another class name. For example:
23001 @compatibility_alias WOApplication GSWApplication;
23003 tells the compiler that each time it encounters `WOApplication' as a
23004 class name, it should replace it with `GSWApplication' (that is,
23005 `WOApplication' is just an alias for `GSWApplication').
23007 There are some constraints on how this can be used--
23009 * `WOApplication' (the alias) must not be an existing class;
23011 * `GSWApplication' (the real class) must be an existing class.
23015 File: gcc.info, Node: Compatibility, Next: Gcov, Prev: Objective-C, Up: Top
23017 8 Binary Compatibility
23018 **********************
23020 Binary compatibility encompasses several related concepts:
23022 "application binary interface (ABI)"
23023 The set of runtime conventions followed by all of the tools that
23024 deal with binary representations of a program, including
23025 compilers, assemblers, linkers, and language runtime support.
23026 Some ABIs are formal with a written specification, possibly
23027 designed by multiple interested parties. Others are simply the
23028 way things are actually done by a particular set of tools.
23031 A compiler conforms to an ABI if it generates code that follows
23032 all of the specifications enumerated by that ABI. A library
23033 conforms to an ABI if it is implemented according to that ABI. An
23034 application conforms to an ABI if it is built using tools that
23035 conform to that ABI and does not contain source code that
23036 specifically changes behavior specified by the ABI.
23038 "calling conventions"
23039 Calling conventions are a subset of an ABI that specify of how
23040 arguments are passed and function results are returned.
23043 Different sets of tools are interoperable if they generate files
23044 that can be used in the same program. The set of tools includes
23045 compilers, assemblers, linkers, libraries, header files, startup
23046 files, and debuggers. Binaries produced by different sets of
23047 tools are not interoperable unless they implement the same ABI.
23048 This applies to different versions of the same tools as well as
23049 tools from different vendors.
23052 Whether a function in a binary built by one set of tools can call a
23053 function in a binary built by a different set of tools is a subset
23054 of interoperability.
23056 "implementation-defined features"
23057 Language standards include lists of implementation-defined
23058 features whose behavior can vary from one implementation to
23059 another. Some of these features are normally covered by a
23060 platform's ABI and others are not. The features that are not
23061 covered by an ABI generally affect how a program behaves, but not
23065 Conformance to the same ABI and the same behavior of
23066 implementation-defined features are both relevant for
23069 The application binary interface implemented by a C or C++ compiler
23070 affects code generation and runtime support for:
23072 * size and alignment of data types
23074 * layout of structured types
23076 * calling conventions
23078 * register usage conventions
23080 * interfaces for runtime arithmetic support
23082 * object file formats
23084 In addition, the application binary interface implemented by a C++
23085 compiler affects code generation and runtime support for:
23088 * exception handling
23090 * invoking constructors and destructors
23092 * layout, alignment, and padding of classes
23094 * layout and alignment of virtual tables
23096 Some GCC compilation options cause the compiler to generate code that
23097 does not conform to the platform's default ABI. Other options cause
23098 different program behavior for implementation-defined features that are
23099 not covered by an ABI. These options are provided for consistency with
23100 other compilers that do not follow the platform's default ABI or the
23101 usual behavior of implementation-defined features for the platform. Be
23102 very careful about using such options.
23104 Most platforms have a well-defined ABI that covers C code, but ABIs
23105 that cover C++ functionality are not yet common.
23107 Starting with GCC 3.2, GCC binary conventions for C++ are based on a
23108 written, vendor-neutral C++ ABI that was designed to be specific to
23109 64-bit Itanium but also includes generic specifications that apply to
23110 any platform. This C++ ABI is also implemented by other compiler
23111 vendors on some platforms, notably GNU/Linux and BSD systems. We have
23112 tried hard to provide a stable ABI that will be compatible with future
23113 GCC releases, but it is possible that we will encounter problems that
23114 make this difficult. Such problems could include different
23115 interpretations of the C++ ABI by different vendors, bugs in the ABI, or
23116 bugs in the implementation of the ABI in different compilers. GCC's
23117 `-Wabi' switch warns when G++ generates code that is probably not
23118 compatible with the C++ ABI.
23120 The C++ library used with a C++ compiler includes the Standard C++
23121 Library, with functionality defined in the C++ Standard, plus language
23122 runtime support. The runtime support is included in a C++ ABI, but
23123 there is no formal ABI for the Standard C++ Library. Two
23124 implementations of that library are interoperable if one follows the
23125 de-facto ABI of the other and if they are both built with the same
23126 compiler, or with compilers that conform to the same ABI for C++
23127 compiler and runtime support.
23129 When G++ and another C++ compiler conform to the same C++ ABI, but the
23130 implementations of the Standard C++ Library that they normally use do
23131 not follow the same ABI for the Standard C++ Library, object files
23132 built with those compilers can be used in the same program only if they
23133 use the same C++ library. This requires specifying the location of the
23134 C++ library header files when invoking the compiler whose usual library
23135 is not being used. The location of GCC's C++ header files depends on
23136 how the GCC build was configured, but can be seen by using the G++ `-v'
23137 option. With default configuration options for G++ 3.3 the compile
23138 line for a different C++ compiler needs to include
23140 -IGCC_INSTALL_DIRECTORY/include/c++/3.3
23142 Similarly, compiling code with G++ that must use a C++ library other
23143 than the GNU C++ library requires specifying the location of the header
23144 files for that other library.
23146 The most straightforward way to link a program to use a particular C++
23147 library is to use a C++ driver that specifies that C++ library by
23148 default. The `g++' driver, for example, tells the linker where to find
23149 GCC's C++ library (`libstdc++') plus the other libraries and startup
23150 files it needs, in the proper order.
23152 If a program must use a different C++ library and it's not possible to
23153 do the final link using a C++ driver that uses that library by default,
23154 it is necessary to tell `g++' the location and name of that library.
23155 It might also be necessary to specify different startup files and other
23156 runtime support libraries, and to suppress the use of GCC's support
23157 libraries with one or more of the options `-nostdlib', `-nostartfiles',
23158 and `-nodefaultlibs'.
23161 File: gcc.info, Node: Gcov, Next: Trouble, Prev: Compatibility, Up: Top
23163 9 `gcov'--a Test Coverage Program
23164 *********************************
23166 `gcov' is a tool you can use in conjunction with GCC to test code
23167 coverage in your programs.
23171 * Gcov Intro:: Introduction to gcov.
23172 * Invoking Gcov:: How to use gcov.
23173 * Gcov and Optimization:: Using gcov with GCC optimization.
23174 * Gcov Data Files:: The files used by gcov.
23177 File: gcc.info, Node: Gcov Intro, Next: Invoking Gcov, Up: Gcov
23179 9.1 Introduction to `gcov'
23180 ==========================
23182 `gcov' is a test coverage program. Use it in concert with GCC to
23183 analyze your programs to help create more efficient, faster running
23184 code and to discover untested parts of your program. You can use
23185 `gcov' as a profiling tool to help discover where your optimization
23186 efforts will best affect your code. You can also use `gcov' along with
23187 the other profiling tool, `gprof', to assess which parts of your code
23188 use the greatest amount of computing time.
23190 Profiling tools help you analyze your code's performance. Using a
23191 profiler such as `gcov' or `gprof', you can find out some basic
23192 performance statistics, such as:
23194 * how often each line of code executes
23196 * what lines of code are actually executed
23198 * how much computing time each section of code uses
23200 Once you know these things about how your code works when compiled, you
23201 can look at each module to see which modules should be optimized.
23202 `gcov' helps you determine where to work on optimization.
23204 Software developers also use coverage testing in concert with
23205 testsuites, to make sure software is actually good enough for a release.
23206 Testsuites can verify that a program works as expected; a coverage
23207 program tests to see how much of the program is exercised by the
23208 testsuite. Developers can then determine what kinds of test cases need
23209 to be added to the testsuites to create both better testing and a better
23212 You should compile your code without optimization if you plan to use
23213 `gcov' because the optimization, by combining some lines of code into
23214 one function, may not give you as much information as you need to look
23215 for `hot spots' where the code is using a great deal of computer time.
23216 Likewise, because `gcov' accumulates statistics by line (at the lowest
23217 resolution), it works best with a programming style that places only
23218 one statement on each line. If you use complicated macros that expand
23219 to loops or to other control structures, the statistics are less
23220 helpful--they only report on the line where the macro call appears. If
23221 your complex macros behave like functions, you can replace them with
23222 inline functions to solve this problem.
23224 `gcov' creates a logfile called `SOURCEFILE.gcov' which indicates how
23225 many times each line of a source file `SOURCEFILE.c' has executed. You
23226 can use these logfiles along with `gprof' to aid in fine-tuning the
23227 performance of your programs. `gprof' gives timing information you can
23228 use along with the information you get from `gcov'.
23230 `gcov' works only on code compiled with GCC. It is not compatible
23231 with any other profiling or test coverage mechanism.
23234 File: gcc.info, Node: Invoking Gcov, Next: Gcov and Optimization, Prev: Gcov Intro, Up: Gcov
23239 gcov [OPTIONS] SOURCEFILE
23241 `gcov' accepts the following options:
23245 Display help about using `gcov' (on the standard output), and exit
23246 without doing any further processing.
23250 Display the `gcov' version number (on the standard output), and
23251 exit without doing any further processing.
23255 Write individual execution counts for every basic block. Normally
23256 gcov outputs execution counts only for the main blocks of a line.
23257 With this option you can determine if blocks within a single line
23258 are not being executed.
23261 `--branch-probabilities'
23262 Write branch frequencies to the output file, and write branch
23263 summary info to the standard output. This option allows you to
23264 see how often each branch in your program was taken.
23265 Unconditional branches will not be shown, unless the `-u' option
23270 Write branch frequencies as the number of branches taken, rather
23271 than the percentage of branches taken.
23275 Do not create the `gcov' output file.
23278 `--long-file-names'
23279 Create long file names for included source files. For example, if
23280 the header file `x.h' contains code, and was included in the file
23281 `a.c', then running `gcov' on the file `a.c' will produce an
23282 output file called `a.c##x.h.gcov' instead of `x.h.gcov'. This
23283 can be useful if `x.h' is included in multiple source files. If
23284 you use the `-p' option, both the including and included file
23285 names will be complete path names.
23289 Preserve complete path information in the names of generated
23290 `.gcov' files. Without this option, just the filename component is
23291 used. With this option, all directories are used, with `/'
23292 characters translated to `#' characters, `.' directory components
23293 removed and `..' components renamed to `^'. This is useful if
23294 sourcefiles are in several different directories. It also affects
23298 `--function-summaries'
23299 Output summaries for each function in addition to the file level
23302 `-o DIRECTORY|FILE'
23303 `--object-directory DIRECTORY'
23304 `--object-file FILE'
23305 Specify either the directory containing the gcov data files, or the
23306 object path name. The `.gcno', and `.gcda' data files are
23307 searched for using this option. If a directory is specified, the
23308 data files are in that directory and named after the source file
23309 name, without its extension. If a file is specified here, the
23310 data files are named after that file, without its extension. If
23311 this option is not supplied, it defaults to the current directory.
23314 `--unconditional-branches'
23315 When branch probabilities are given, include those of
23316 unconditional branches. Unconditional branches are normally not
23320 `gcov' should be run with the current directory the same as that when
23321 you invoked the compiler. Otherwise it will not be able to locate the
23322 source files. `gcov' produces files called `MANGLEDNAME.gcov' in the
23323 current directory. These contain the coverage information of the
23324 source file they correspond to. One `.gcov' file is produced for each
23325 source file containing code, which was compiled to produce the data
23326 files. The MANGLEDNAME part of the output file name is usually simply
23327 the source file name, but can be something more complicated if the `-l'
23328 or `-p' options are given. Refer to those options for details.
23330 The `.gcov' files contain the `:' separated fields along with program
23331 source code. The format is
23333 EXECUTION_COUNT:LINE_NUMBER:SOURCE LINE TEXT
23335 Additional block information may succeed each line, when requested by
23336 command line option. The EXECUTION_COUNT is `-' for lines containing
23337 no code and `#####' for lines which were never executed. Some lines of
23338 information at the start have LINE_NUMBER of zero.
23340 The preamble lines are of the form
23344 The ordering and number of these preamble lines will be augmented as
23345 `gcov' development progresses -- do not rely on them remaining
23346 unchanged. Use TAG to locate a particular preamble line.
23348 The additional block information is of the form
23352 The INFORMATION is human readable, but designed to be simple enough
23353 for machine parsing too.
23355 When printing percentages, 0% and 100% are only printed when the values
23356 are _exactly_ 0% and 100% respectively. Other values which would
23357 conventionally be rounded to 0% or 100% are instead printed as the
23358 nearest non-boundary value.
23360 When using `gcov', you must first compile your program with two
23361 special GCC options: `-fprofile-arcs -ftest-coverage'. This tells the
23362 compiler to generate additional information needed by gcov (basically a
23363 flow graph of the program) and also includes additional code in the
23364 object files for generating the extra profiling information needed by
23365 gcov. These additional files are placed in the directory where the
23366 object file is located.
23368 Running the program will cause profile output to be generated. For
23369 each source file compiled with `-fprofile-arcs', an accompanying
23370 `.gcda' file will be placed in the object file directory.
23372 Running `gcov' with your program's source file names as arguments will
23373 now produce a listing of the code along with frequency of execution for
23374 each line. For example, if your program is called `tmp.c', this is
23375 what you see when you use the basic `gcov' facility:
23377 $ gcc -fprofile-arcs -ftest-coverage tmp.c
23380 90.00% of 10 source lines executed in file tmp.c
23381 Creating tmp.c.gcov.
23383 The file `tmp.c.gcov' contains output from `gcov'. Here is a sample:
23386 -: 0:Graph:tmp.gcno
23390 -: 1:#include <stdio.h>
23392 -: 3:int main (void)
23394 1: 5: int i, total;
23398 11: 9: for (i = 0; i < 10; i++)
23399 10: 10: total += i;
23401 1: 12: if (total != 45)
23402 #####: 13: printf ("Failure\n");
23404 1: 15: printf ("Success\n");
23408 When you use the `-a' option, you will get individual block counts,
23409 and the output looks like this:
23412 -: 0:Graph:tmp.gcno
23416 -: 1:#include <stdio.h>
23418 -: 3:int main (void)
23421 1: 5: int i, total;
23425 11: 9: for (i = 0; i < 10; i++)
23427 10: 10: total += i;
23430 1: 12: if (total != 45)
23432 #####: 13: printf ("Failure\n");
23435 1: 15: printf ("Success\n");
23441 In this mode, each basic block is only shown on one line - the last
23442 line of the block. A multi-line block will only contribute to the
23443 execution count of that last line, and other lines will not be shown to
23444 contain code, unless previous blocks end on those lines. The total
23445 execution count of a line is shown and subsequent lines show the
23446 execution counts for individual blocks that end on that line. After
23447 each block, the branch and call counts of the block will be shown, if
23448 the `-b' option is given.
23450 Because of the way GCC instruments calls, a call count can be shown
23451 after a line with no individual blocks. As you can see, line 13
23452 contains a basic block that was not executed.
23454 When you use the `-b' option, your output looks like this:
23457 90.00% of 10 source lines executed in file tmp.c
23458 80.00% of 5 branches executed in file tmp.c
23459 80.00% of 5 branches taken at least once in file tmp.c
23460 50.00% of 2 calls executed in file tmp.c
23461 Creating tmp.c.gcov.
23463 Here is a sample of a resulting `tmp.c.gcov' file:
23466 -: 0:Graph:tmp.gcno
23470 -: 1:#include <stdio.h>
23472 -: 3:int main (void)
23473 function main called 1 returned 1 blocks executed 75%
23475 1: 5: int i, total;
23479 11: 9: for (i = 0; i < 10; i++)
23480 branch 0 taken 91% (fallthrough)
23482 10: 10: total += i;
23484 1: 12: if (total != 45)
23485 branch 0 taken 0% (fallthrough)
23486 branch 1 taken 100%
23487 #####: 13: printf ("Failure\n");
23488 call 0 never executed
23490 1: 15: printf ("Success\n");
23491 call 0 called 1 returned 100%
23495 For each function, a line is printed showing how many times the
23496 function is called, how many times it returns and what percentage of the
23497 function's blocks were executed.
23499 For each basic block, a line is printed after the last line of the
23500 basic block describing the branch or call that ends the basic block.
23501 There can be multiple branches and calls listed for a single source
23502 line if there are multiple basic blocks that end on that line. In this
23503 case, the branches and calls are each given a number. There is no
23504 simple way to map these branches and calls back to source constructs.
23505 In general, though, the lowest numbered branch or call will correspond
23506 to the leftmost construct on the source line.
23508 For a branch, if it was executed at least once, then a percentage
23509 indicating the number of times the branch was taken divided by the
23510 number of times the branch was executed will be printed. Otherwise, the
23511 message "never executed" is printed.
23513 For a call, if it was executed at least once, then a percentage
23514 indicating the number of times the call returned divided by the number
23515 of times the call was executed will be printed. This will usually be
23516 100%, but may be less for functions call `exit' or `longjmp', and thus
23517 may not return every time they are called.
23519 The execution counts are cumulative. If the example program were
23520 executed again without removing the `.gcda' file, the count for the
23521 number of times each line in the source was executed would be added to
23522 the results of the previous run(s). This is potentially useful in
23523 several ways. For example, it could be used to accumulate data over a
23524 number of program runs as part of a test verification suite, or to
23525 provide more accurate long-term information over a large number of
23528 The data in the `.gcda' files is saved immediately before the program
23529 exits. For each source file compiled with `-fprofile-arcs', the
23530 profiling code first attempts to read in an existing `.gcda' file; if
23531 the file doesn't match the executable (differing number of basic block
23532 counts) it will ignore the contents of the file. It then adds in the
23533 new execution counts and finally writes the data to the file.
23536 File: gcc.info, Node: Gcov and Optimization, Next: Gcov Data Files, Prev: Invoking Gcov, Up: Gcov
23538 9.3 Using `gcov' with GCC Optimization
23539 ======================================
23541 If you plan to use `gcov' to help optimize your code, you must first
23542 compile your program with two special GCC options: `-fprofile-arcs
23543 -ftest-coverage'. Aside from that, you can use any other GCC options;
23544 but if you want to prove that every single line in your program was
23545 executed, you should not compile with optimization at the same time.
23546 On some machines the optimizer can eliminate some simple code lines by
23547 combining them with other lines. For example, code like this:
23554 can be compiled into one instruction on some machines. In this case,
23555 there is no way for `gcov' to calculate separate execution counts for
23556 each line because there isn't separate code for each line. Hence the
23557 `gcov' output looks like this if you compiled the program with
23560 100: 12:if (a != b)
23565 The output shows that this block of code, combined by optimization,
23566 executed 100 times. In one sense this result is correct, because there
23567 was only one instruction representing all four of these lines. However,
23568 the output does not indicate how many times the result was 0 and how
23569 many times the result was 1.
23571 Inlineable functions can create unexpected line counts. Line counts
23572 are shown for the source code of the inlineable function, but what is
23573 shown depends on where the function is inlined, or if it is not inlined
23576 If the function is not inlined, the compiler must emit an out of line
23577 copy of the function, in any object file that needs it. If `fileA.o'
23578 and `fileB.o' both contain out of line bodies of a particular
23579 inlineable function, they will also both contain coverage counts for
23580 that function. When `fileA.o' and `fileB.o' are linked together, the
23581 linker will, on many systems, select one of those out of line bodies
23582 for all calls to that function, and remove or ignore the other.
23583 Unfortunately, it will not remove the coverage counters for the unused
23584 function body. Hence when instrumented, all but one use of that
23585 function will show zero counts.
23587 If the function is inlined in several places, the block structure in
23588 each location might not be the same. For instance, a condition might
23589 now be calculable at compile time in some instances. Because the
23590 coverage of all the uses of the inline function will be shown for the
23591 same source lines, the line counts themselves might seem inconsistent.
23594 File: gcc.info, Node: Gcov Data Files, Prev: Gcov and Optimization, Up: Gcov
23596 9.4 Brief description of `gcov' data files
23597 ==========================================
23599 `gcov' uses two files for profiling. The names of these files are
23600 derived from the original _object_ file by substituting the file suffix
23601 with either `.gcno', or `.gcda'. All of these files are placed in the
23602 same directory as the object file, and contain data stored in a
23603 platform-independent format.
23605 The `.gcno' file is generated when the source file is compiled with
23606 the GCC `-ftest-coverage' option. It contains information to
23607 reconstruct the basic block graphs and assign source line numbers to
23610 The `.gcda' file is generated when a program containing object files
23611 built with the GCC `-fprofile-arcs' option is executed. A separate
23612 `.gcda' file is created for each object file compiled with this option.
23613 It contains arc transition counts, and some summary information.
23615 The full details of the file format is specified in `gcov-io.h', and
23616 functions provided in that header file should be used to access the
23620 File: gcc.info, Node: Trouble, Next: Bugs, Prev: Gcov, Up: Top
23622 10 Known Causes of Trouble with GCC
23623 ***********************************
23625 This section describes known problems that affect users of GCC. Most
23626 of these are not GCC bugs per se--if they were, we would fix them. But
23627 the result for a user may be like the result of a bug.
23629 Some of these problems are due to bugs in other software, some are
23630 missing features that are too much work to add, and some are places
23631 where people's opinions differ as to what is best.
23635 * Actual Bugs:: Bugs we will fix later.
23636 * Cross-Compiler Problems:: Common problems of cross compiling with GCC.
23637 * Interoperation:: Problems using GCC with other compilers,
23638 and with certain linkers, assemblers and debuggers.
23639 * Incompatibilities:: GCC is incompatible with traditional C.
23640 * Fixed Headers:: GCC uses corrected versions of system header files.
23641 This is necessary, but doesn't always work smoothly.
23642 * Standard Libraries:: GCC uses the system C library, which might not be
23643 compliant with the ISO C standard.
23644 * Disappointments:: Regrettable things we can't change, but not quite bugs.
23645 * C++ Misunderstandings:: Common misunderstandings with GNU C++.
23646 * Protoize Caveats:: Things to watch out for when using `protoize'.
23647 * Non-bugs:: Things we think are right, but some others disagree.
23648 * Warnings and Errors:: Which problems in your code get warnings,
23649 and which get errors.
23652 File: gcc.info, Node: Actual Bugs, Next: Cross-Compiler Problems, Up: Trouble
23654 10.1 Actual Bugs We Haven't Fixed Yet
23655 =====================================
23657 * The `fixincludes' script interacts badly with automounters; if the
23658 directory of system header files is automounted, it tends to be
23659 unmounted while `fixincludes' is running. This would seem to be a
23660 bug in the automounter. We don't know any good way to work around
23663 * The `fixproto' script will sometimes add prototypes for the
23664 `sigsetjmp' and `siglongjmp' functions that reference the
23665 `jmp_buf' type before that type is defined. To work around this,
23666 edit the offending file and place the typedef in front of the
23670 File: gcc.info, Node: Cross-Compiler Problems, Next: Interoperation, Prev: Actual Bugs, Up: Trouble
23672 10.2 Cross-Compiler Problems
23673 ============================
23675 You may run into problems with cross compilation on certain machines,
23676 for several reasons.
23678 * At present, the program `mips-tfile' which adds debug support to
23679 object files on MIPS systems does not work in a cross compile
23683 File: gcc.info, Node: Interoperation, Next: Incompatibilities, Prev: Cross-Compiler Problems, Up: Trouble
23685 10.3 Interoperation
23686 ===================
23688 This section lists various difficulties encountered in using GCC
23689 together with other compilers or with the assemblers, linkers,
23690 libraries and debuggers on certain systems.
23692 * On many platforms, GCC supports a different ABI for C++ than do
23693 other compilers, so the object files compiled by GCC cannot be
23694 used with object files generated by another C++ compiler.
23696 An area where the difference is most apparent is name mangling.
23697 The use of different name mangling is intentional, to protect you
23698 from more subtle problems. Compilers differ as to many internal
23699 details of C++ implementation, including: how class instances are
23700 laid out, how multiple inheritance is implemented, and how virtual
23701 function calls are handled. If the name encoding were made the
23702 same, your programs would link against libraries provided from
23703 other compilers--but the programs would then crash when run.
23704 Incompatible libraries are then detected at link time, rather than
23707 * On some BSD systems, including some versions of Ultrix, use of
23708 profiling causes static variable destructors (currently used only
23709 in C++) not to be run.
23711 * On some SGI systems, when you use `-lgl_s' as an option, it gets
23712 translated magically to `-lgl_s -lX11_s -lc_s'. Naturally, this
23713 does not happen when you use GCC. You must specify all three
23714 options explicitly.
23716 * On a SPARC, GCC aligns all values of type `double' on an 8-byte
23717 boundary, and it expects every `double' to be so aligned. The Sun
23718 compiler usually gives `double' values 8-byte alignment, with one
23719 exception: function arguments of type `double' may not be aligned.
23721 As a result, if a function compiled with Sun CC takes the address
23722 of an argument of type `double' and passes this pointer of type
23723 `double *' to a function compiled with GCC, dereferencing the
23724 pointer may cause a fatal signal.
23726 One way to solve this problem is to compile your entire program
23727 with GCC. Another solution is to modify the function that is
23728 compiled with Sun CC to copy the argument into a local variable;
23729 local variables are always properly aligned. A third solution is
23730 to modify the function that uses the pointer to dereference it via
23731 the following function `access_double' instead of directly with
23735 access_double (double *unaligned_ptr)
23737 union d2i { double d; int i[2]; };
23739 union d2i *p = (union d2i *) unaligned_ptr;
23748 Storing into the pointer can be done likewise with the same union.
23750 * On Solaris, the `malloc' function in the `libmalloc.a' library may
23751 allocate memory that is only 4 byte aligned. Since GCC on the
23752 SPARC assumes that doubles are 8 byte aligned, this may result in a
23753 fatal signal if doubles are stored in memory allocated by the
23754 `libmalloc.a' library.
23756 The solution is to not use the `libmalloc.a' library. Use instead
23757 `malloc' and related functions from `libc.a'; they do not have
23760 * On the HP PA machine, ADB sometimes fails to work on functions
23761 compiled with GCC. Specifically, it fails to work on functions
23762 that use `alloca' or variable-size arrays. This is because GCC
23763 doesn't generate HP-UX unwind descriptors for such functions. It
23764 may even be impossible to generate them.
23766 * Debugging (`-g') is not supported on the HP PA machine, unless you
23767 use the preliminary GNU tools.
23769 * Taking the address of a label may generate errors from the HP-UX
23770 PA assembler. GAS for the PA does not have this problem.
23772 * Using floating point parameters for indirect calls to static
23773 functions will not work when using the HP assembler. There simply
23774 is no way for GCC to specify what registers hold arguments for
23775 static functions when using the HP assembler. GAS for the PA does
23776 not have this problem.
23778 * In extremely rare cases involving some very large functions you may
23779 receive errors from the HP linker complaining about an out of
23780 bounds unconditional branch offset. This used to occur more often
23781 in previous versions of GCC, but is now exceptionally rare. If
23782 you should run into it, you can work around by making your
23785 * GCC compiled code sometimes emits warnings from the HP-UX
23786 assembler of the form:
23788 (warning) Use of GR3 when
23789 frame >= 8192 may cause conflict.
23791 These warnings are harmless and can be safely ignored.
23793 * In extremely rare cases involving some very large functions you may
23794 receive errors from the AIX Assembler complaining about a
23795 displacement that is too large. If you should run into it, you
23796 can work around by making your function smaller.
23798 * The `libstdc++.a' library in GCC relies on the SVR4 dynamic linker
23799 semantics which merges global symbols between libraries and
23800 applications, especially necessary for C++ streams functionality.
23801 This is not the default behavior of AIX shared libraries and
23802 dynamic linking. `libstdc++.a' is built on AIX with
23803 "runtime-linking" enabled so that symbol merging can occur. To
23804 utilize this feature, the application linked with `libstdc++.a'
23805 must include the `-Wl,-brtl' flag on the link line. G++ cannot
23806 impose this because this option may interfere with the semantics
23807 of the user program and users may not always use `g++' to link his
23808 or her application. Applications are not required to use the
23809 `-Wl,-brtl' flag on the link line--the rest of the `libstdc++.a'
23810 library which is not dependent on the symbol merging semantics
23811 will continue to function correctly.
23813 * An application can interpose its own definition of functions for
23814 functions invoked by `libstdc++.a' with "runtime-linking" enabled
23815 on AIX. To accomplish this the application must be linked with
23816 "runtime-linking" option and the functions explicitly must be
23817 exported by the application (`-Wl,-brtl,-bE:exportfile').
23819 * AIX on the RS/6000 provides support (NLS) for environments outside
23820 of the United States. Compilers and assemblers use NLS to support
23821 locale-specific representations of various objects including
23822 floating-point numbers (`.' vs `,' for separating decimal
23823 fractions). There have been problems reported where the library
23824 linked with GCC does not produce the same floating-point formats
23825 that the assembler accepts. If you have this problem, set the
23826 `LANG' environment variable to `C' or `En_US'.
23828 * Even if you specify `-fdollars-in-identifiers', you cannot
23829 successfully use `$' in identifiers on the RS/6000 due to a
23830 restriction in the IBM assembler. GAS supports these identifiers.
23832 * On Ultrix, the Fortran compiler expects registers 2 through 5 to
23833 be saved by function calls. However, the C compiler uses
23834 conventions compatible with BSD Unix: registers 2 through 5 may be
23835 clobbered by function calls.
23837 GCC uses the same convention as the Ultrix C compiler. You can use
23838 these options to produce code compatible with the Fortran compiler:
23840 -fcall-saved-r2 -fcall-saved-r3 -fcall-saved-r4 -fcall-saved-r5
23843 File: gcc.info, Node: Incompatibilities, Next: Fixed Headers, Prev: Interoperation, Up: Trouble
23845 10.4 Incompatibilities of GCC
23846 =============================
23848 There are several noteworthy incompatibilities between GNU C and K&R
23849 (non-ISO) versions of C.
23851 * GCC normally makes string constants read-only. If several
23852 identical-looking string constants are used, GCC stores only one
23853 copy of the string.
23855 One consequence is that you cannot call `mktemp' with a string
23856 constant argument. The function `mktemp' always alters the string
23857 its argument points to.
23859 Another consequence is that `sscanf' does not work on some very
23860 old systems when passed a string constant as its format control
23861 string or input. This is because `sscanf' incorrectly tries to
23862 write into the string constant. Likewise `fscanf' and `scanf'.
23864 The solution to these problems is to change the program to use
23865 `char'-array variables with initialization strings for these
23866 purposes instead of string constants.
23868 * `-2147483648' is positive.
23870 This is because 2147483648 cannot fit in the type `int', so
23871 (following the ISO C rules) its data type is `unsigned long int'.
23872 Negating this value yields 2147483648 again.
23874 * GCC does not substitute macro arguments when they appear inside of
23875 string constants. For example, the following macro in GCC
23879 will produce output `"a"' regardless of what the argument A is.
23881 * When you use `setjmp' and `longjmp', the only automatic variables
23882 guaranteed to remain valid are those declared `volatile'. This is
23883 a consequence of automatic register allocation. Consider this
23897 /* `longjmp (j)' may occur in `fun3'. */
23898 return a + fun3 ();
23901 Here `a' may or may not be restored to its first value when the
23902 `longjmp' occurs. If `a' is allocated in a register, then its
23903 first value is restored; otherwise, it keeps the last value stored
23906 If you use the `-W' option with the `-O' option, you will get a
23907 warning when GCC thinks such a problem might be possible.
23909 * Programs that use preprocessing directives in the middle of macro
23910 arguments do not work with GCC. For example, a program like this
23917 ISO C does not permit such a construct.
23919 * K&R compilers allow comments to cross over an inclusion boundary
23920 (i.e. started in an include file and ended in the including file).
23922 * Declarations of external variables and functions within a block
23923 apply only to the block containing the declaration. In other
23924 words, they have the same scope as any other declaration in the
23927 In some other C compilers, a `extern' declaration affects all the
23928 rest of the file even if it happens within a block.
23930 * In traditional C, you can combine `long', etc., with a typedef
23931 name, as shown here:
23934 typedef long foo bar;
23936 In ISO C, this is not allowed: `long' and other type modifiers
23937 require an explicit `int'.
23939 * PCC allows typedef names to be used as function parameters.
23941 * Traditional C allows the following erroneous pair of declarations
23942 to appear together in a given scope:
23947 * GCC treats all characters of identifiers as significant.
23948 According to K&R-1 (2.2), "No more than the first eight characters
23949 are significant, although more may be used.". Also according to
23950 K&R-1 (2.2), "An identifier is a sequence of letters and digits;
23951 the first character must be a letter. The underscore _ counts as
23952 a letter.", but GCC also allows dollar signs in identifiers.
23954 * PCC allows whitespace in the middle of compound assignment
23955 operators such as `+='. GCC, following the ISO standard, does not
23958 * GCC complains about unterminated character constants inside of
23959 preprocessing conditionals that fail. Some programs have English
23960 comments enclosed in conditionals that are guaranteed to fail; if
23961 these comments contain apostrophes, GCC will probably report an
23962 error. For example, this code would produce an error:
23965 You can't expect this to work.
23968 The best solution to such a problem is to put the text into an
23969 actual C comment delimited by `/*...*/'.
23971 * Many user programs contain the declaration `long time ();'. In the
23972 past, the system header files on many systems did not actually
23973 declare `time', so it did not matter what type your program
23974 declared it to return. But in systems with ISO C headers, `time'
23975 is declared to return `time_t', and if that is not the same as
23976 `long', then `long time ();' is erroneous.
23978 The solution is to change your program to use appropriate system
23979 headers (`<time.h>' on systems with ISO C headers) and not to
23980 declare `time' if the system header files declare it, or failing
23981 that to use `time_t' as the return type of `time'.
23983 * When compiling functions that return `float', PCC converts it to a
23984 double. GCC actually returns a `float'. If you are concerned
23985 with PCC compatibility, you should declare your functions to return
23986 `double'; you might as well say what you mean.
23988 * When compiling functions that return structures or unions, GCC
23989 output code normally uses a method different from that used on most
23990 versions of Unix. As a result, code compiled with GCC cannot call
23991 a structure-returning function compiled with PCC, and vice versa.
23993 The method used by GCC is as follows: a structure or union which is
23994 1, 2, 4 or 8 bytes long is returned like a scalar. A structure or
23995 union with any other size is stored into an address supplied by
23996 the caller (usually in a special, fixed register, but on some
23997 machines it is passed on the stack). The target hook
23998 `TARGET_STRUCT_VALUE_RTX' tells GCC where to pass this address.
24000 By contrast, PCC on most target machines returns structures and
24001 unions of any size by copying the data into an area of static
24002 storage, and then returning the address of that storage as if it
24003 were a pointer value. The caller must copy the data from that
24004 memory area to the place where the value is wanted. GCC does not
24005 use this method because it is slower and nonreentrant.
24007 On some newer machines, PCC uses a reentrant convention for all
24008 structure and union returning. GCC on most of these machines uses
24009 a compatible convention when returning structures and unions in
24010 memory, but still returns small structures and unions in registers.
24012 You can tell GCC to use a compatible convention for all structure
24013 and union returning with the option `-fpcc-struct-return'.
24015 * GCC complains about program fragments such as `0x74ae-0x4000'
24016 which appear to be two hexadecimal constants separated by the minus
24017 operator. Actually, this string is a single "preprocessing token".
24018 Each such token must correspond to one token in C. Since this
24019 does not, GCC prints an error message. Although it may appear
24020 obvious that what is meant is an operator and two values, the ISO
24021 C standard specifically requires that this be treated as erroneous.
24023 A "preprocessing token" is a "preprocessing number" if it begins
24024 with a digit and is followed by letters, underscores, digits,
24025 periods and `e+', `e-', `E+', `E-', `p+', `p-', `P+', or `P-'
24026 character sequences. (In strict C89 mode, the sequences `p+',
24027 `p-', `P+' and `P-' cannot appear in preprocessing numbers.)
24029 To make the above program fragment valid, place whitespace in
24030 front of the minus sign. This whitespace will end the
24031 preprocessing number.
24034 File: gcc.info, Node: Fixed Headers, Next: Standard Libraries, Prev: Incompatibilities, Up: Trouble
24036 10.5 Fixed Header Files
24037 =======================
24039 GCC needs to install corrected versions of some system header files.
24040 This is because most target systems have some header files that won't
24041 work with GCC unless they are changed. Some have bugs, some are
24042 incompatible with ISO C, and some depend on special features of other
24045 Installing GCC automatically creates and installs the fixed header
24046 files, by running a program called `fixincludes'. Normally, you don't
24047 need to pay attention to this. But there are cases where it doesn't do
24048 the right thing automatically.
24050 * If you update the system's header files, such as by installing a
24051 new system version, the fixed header files of GCC are not
24052 automatically updated. They can be updated using the `mkheaders'
24053 script installed in `LIBEXECDIR/gcc/TARGET/VERSION/install-tools/'.
24055 * On some systems, header file directories contain machine-specific
24056 symbolic links in certain places. This makes it possible to share
24057 most of the header files among hosts running the same version of
24058 the system on different machine models.
24060 The programs that fix the header files do not understand this
24061 special way of using symbolic links; therefore, the directory of
24062 fixed header files is good only for the machine model used to
24065 It is possible to make separate sets of fixed header files for the
24066 different machine models, and arrange a structure of symbolic
24067 links so as to use the proper set, but you'll have to do this by
24071 File: gcc.info, Node: Standard Libraries, Next: Disappointments, Prev: Fixed Headers, Up: Trouble
24073 10.6 Standard Libraries
24074 =======================
24076 GCC by itself attempts to be a conforming freestanding implementation.
24077 *Note Language Standards Supported by GCC: Standards, for details of
24078 what this means. Beyond the library facilities required of such an
24079 implementation, the rest of the C library is supplied by the vendor of
24080 the operating system. If that C library doesn't conform to the C
24081 standards, then your programs might get warnings (especially when using
24082 `-Wall') that you don't expect.
24084 For example, the `sprintf' function on SunOS 4.1.3 returns `char *'
24085 while the C standard says that `sprintf' returns an `int'. The
24086 `fixincludes' program could make the prototype for this function match
24087 the Standard, but that would be wrong, since the function will still
24090 If you need a Standard compliant library, then you need to find one, as
24091 GCC does not provide one. The GNU C library (called `glibc') provides
24092 ISO C, POSIX, BSD, SystemV and X/Open compatibility for GNU/Linux and
24093 HURD-based GNU systems; no recent version of it supports other systems,
24094 though some very old versions did. Version 2.2 of the GNU C library
24095 includes nearly complete C99 support. You could also ask your
24096 operating system vendor if newer libraries are available.
24099 File: gcc.info, Node: Disappointments, Next: C++ Misunderstandings, Prev: Standard Libraries, Up: Trouble
24101 10.7 Disappointments and Misunderstandings
24102 ==========================================
24104 These problems are perhaps regrettable, but we don't know any practical
24107 * Certain local variables aren't recognized by debuggers when you
24108 compile with optimization.
24110 This occurs because sometimes GCC optimizes the variable out of
24111 existence. There is no way to tell the debugger how to compute the
24112 value such a variable "would have had", and it is not clear that
24113 would be desirable anyway. So GCC simply does not mention the
24114 eliminated variable when it writes debugging information.
24116 You have to expect a certain amount of disagreement between the
24117 executable and your source code, when you use optimization.
24119 * Users often think it is a bug when GCC reports an error for code
24122 int foo (struct mumble *);
24124 struct mumble { ... };
24126 int foo (struct mumble *x)
24129 This code really is erroneous, because the scope of `struct
24130 mumble' in the prototype is limited to the argument list
24131 containing it. It does not refer to the `struct mumble' defined
24132 with file scope immediately below--they are two unrelated types
24133 with similar names in different scopes.
24135 But in the definition of `foo', the file-scope type is used
24136 because that is available to be inherited. Thus, the definition
24137 and the prototype do not match, and you get an error.
24139 This behavior may seem silly, but it's what the ISO standard
24140 specifies. It is easy enough for you to make your code work by
24141 moving the definition of `struct mumble' above the prototype.
24142 It's not worth being incompatible with ISO C just to avoid an
24143 error for the example shown above.
24145 * Accesses to bit-fields even in volatile objects works by accessing
24146 larger objects, such as a byte or a word. You cannot rely on what
24147 size of object is accessed in order to read or write the
24148 bit-field; it may even vary for a given bit-field according to the
24151 If you care about controlling the amount of memory that is
24152 accessed, use volatile but do not use bit-fields.
24154 * GCC comes with shell scripts to fix certain known problems in
24155 system header files. They install corrected copies of various
24156 header files in a special directory where only GCC will normally
24157 look for them. The scripts adapt to various systems by searching
24158 all the system header files for the problem cases that we know
24161 If new system header files are installed, nothing automatically
24162 arranges to update the corrected header files. They can be
24163 updated using the `mkheaders' script installed in
24164 `LIBEXECDIR/gcc/TARGET/VERSION/install-tools/'.
24166 * On 68000 and x86 systems, for instance, you can get paradoxical
24167 results if you test the precise values of floating point numbers.
24168 For example, you can find that a floating point value which is not
24169 a NaN is not equal to itself. This results from the fact that the
24170 floating point registers hold a few more bits of precision than
24171 fit in a `double' in memory. Compiled code moves values between
24172 memory and floating point registers at its convenience, and moving
24173 them into memory truncates them.
24175 You can partially avoid this problem by using the `-ffloat-store'
24176 option (*note Optimize Options::).
24178 * On AIX and other platforms without weak symbol support, templates
24179 need to be instantiated explicitly and symbols for static members
24180 of templates will not be generated.
24182 * On AIX, GCC scans object files and library archives for static
24183 constructors and destructors when linking an application before the
24184 linker prunes unreferenced symbols. This is necessary to prevent
24185 the AIX linker from mistakenly assuming that static constructor or
24186 destructor are unused and removing them before the scanning can
24187 occur. All static constructors and destructors found will be
24188 referenced even though the modules in which they occur may not be
24189 used by the program. This may lead to both increased executable
24190 size and unexpected symbol references.
24193 File: gcc.info, Node: C++ Misunderstandings, Next: Protoize Caveats, Prev: Disappointments, Up: Trouble
24195 10.8 Common Misunderstandings with GNU C++
24196 ==========================================
24198 C++ is a complex language and an evolving one, and its standard
24199 definition (the ISO C++ standard) was only recently completed. As a
24200 result, your C++ compiler may occasionally surprise you, even when its
24201 behavior is correct. This section discusses some areas that frequently
24202 give rise to questions of this sort.
24206 * Static Definitions:: Static member declarations are not definitions
24207 * Name lookup:: Name lookup, templates, and accessing members of base classes
24208 * Temporaries:: Temporaries may vanish before you expect
24209 * Copy Assignment:: Copy Assignment operators copy virtual bases twice
24212 File: gcc.info, Node: Static Definitions, Next: Name lookup, Up: C++ Misunderstandings
24214 10.8.1 Declare _and_ Define Static Members
24215 ------------------------------------------
24217 When a class has static data members, it is not enough to _declare_ the
24218 static member; you must also _define_ it. For example:
24227 This declaration only establishes that the class `Foo' has an `int'
24228 named `Foo::bar', and a member function named `Foo::method'. But you
24229 still need to define _both_ `method' and `bar' elsewhere. According to
24230 the ISO standard, you must supply an initializer in one (and only one)
24231 source file, such as:
24235 Other C++ compilers may not correctly implement the standard behavior.
24236 As a result, when you switch to `g++' from one of these compilers, you
24237 may discover that a program that appeared to work correctly in fact
24238 does not conform to the standard: `g++' reports as undefined symbols
24239 any static data members that lack definitions.
24242 File: gcc.info, Node: Name lookup, Next: Temporaries, Prev: Static Definitions, Up: C++ Misunderstandings
24244 10.8.2 Name lookup, templates, and accessing members of base classes
24245 --------------------------------------------------------------------
24247 The C++ standard prescribes that all names that are not dependent on
24248 template parameters are bound to their present definitions when parsing
24249 a template function or class.(1) Only names that are dependent are
24250 looked up at the point of instantiation. For example, consider
24255 template <typename T>
24264 static const int N;
24267 Here, the names `foo' and `N' appear in a context that does not depend
24268 on the type of `T'. The compiler will thus require that they are
24269 defined in the context of use in the template, not only before the
24270 point of instantiation, and will here use `::foo(double)' and `A::N',
24271 respectively. In particular, it will convert the integer value to a
24272 `double' when passing it to `::foo(double)'.
24274 Conversely, `bar' and the call to `foo' in the fourth marked line are
24275 used in contexts that do depend on the type of `T', so they are only
24276 looked up at the point of instantiation, and you can provide
24277 declarations for them after declaring the template, but before
24278 instantiating it. In particular, if you instantiate `A::f<int>', the
24279 last line will call an overloaded `::foo(int)' if one was provided,
24280 even if after the declaration of `struct A'.
24282 This distinction between lookup of dependent and non-dependent names is
24283 called two-stage (or dependent) name lookup. G++ implements it since
24286 Two-stage name lookup sometimes leads to situations with behavior
24287 different from non-template codes. The most common is probably this:
24289 template <typename T> struct Base {
24293 template <typename T> struct Derived : public Base<T> {
24294 int get_i() { return i; }
24297 In `get_i()', `i' is not used in a dependent context, so the compiler
24298 will look for a name declared at the enclosing namespace scope (which
24299 is the global scope here). It will not look into the base class, since
24300 that is dependent and you may declare specializations of `Base' even
24301 after declaring `Derived', so the compiler can't really know what `i'
24302 would refer to. If there is no global variable `i', then you will get
24305 In order to make it clear that you want the member of the base class,
24306 you need to defer lookup until instantiation time, at which the base
24307 class is known. For this, you need to access `i' in a dependent
24308 context, by either using `this->i' (remember that `this' is of type
24309 `Derived<T>*', so is obviously dependent), or using `Base<T>::i'.
24310 Alternatively, `Base<T>::i' might be brought into scope by a
24311 `using'-declaration.
24313 Another, similar example involves calling member functions of a base
24316 template <typename T> struct Base {
24320 template <typename T> struct Derived : Base<T> {
24321 int g() { return f(); };
24324 Again, the call to `f()' is not dependent on template arguments (there
24325 are no arguments that depend on the type `T', and it is also not
24326 otherwise specified that the call should be in a dependent context).
24327 Thus a global declaration of such a function must be available, since
24328 the one in the base class is not visible until instantiation time. The
24329 compiler will consequently produce the following error message:
24331 x.cc: In member function `int Derived<T>::g()':
24332 x.cc:6: error: there are no arguments to `f' that depend on a template
24333 parameter, so a declaration of `f' must be available
24334 x.cc:6: error: (if you use `-fpermissive', G++ will accept your code, but
24335 allowing the use of an undeclared name is deprecated)
24337 To make the code valid either use `this->f()', or `Base<T>::f()'.
24338 Using the `-fpermissive' flag will also let the compiler accept the
24339 code, by marking all function calls for which no declaration is visible
24340 at the time of definition of the template for later lookup at
24341 instantiation time, as if it were a dependent call. We do not
24342 recommend using `-fpermissive' to work around invalid code, and it will
24343 also only catch cases where functions in base classes are called, not
24344 where variables in base classes are used (as in the example above).
24346 Note that some compilers (including G++ versions prior to 3.4) get
24347 these examples wrong and accept above code without an error. Those
24348 compilers do not implement two-stage name lookup correctly.
24350 ---------- Footnotes ----------
24352 (1) The C++ standard just uses the term "dependent" for names that
24353 depend on the type or value of template parameters. This shorter term
24354 will also be used in the rest of this section.
24357 File: gcc.info, Node: Temporaries, Next: Copy Assignment, Prev: Name lookup, Up: C++ Misunderstandings
24359 10.8.3 Temporaries May Vanish Before You Expect
24360 -----------------------------------------------
24362 It is dangerous to use pointers or references to _portions_ of a
24363 temporary object. The compiler may very well delete the object before
24364 you expect it to, leaving a pointer to garbage. The most common place
24365 where this problem crops up is in classes like string classes,
24366 especially ones that define a conversion function to type `char *' or
24367 `const char *'--which is one reason why the standard `string' class
24368 requires you to call the `c_str' member function. However, any class
24369 that returns a pointer to some internal structure is potentially
24370 subject to this problem.
24372 For example, a program may use a function `strfunc' that returns
24373 `string' objects, and another function `charfunc' that operates on
24374 pointers to `char':
24377 void charfunc (const char *);
24382 const char *p = strfunc().c_str();
24389 In this situation, it may seem reasonable to save a pointer to the C
24390 string returned by the `c_str' member function and use that rather than
24391 call `c_str' repeatedly. However, the temporary string created by the
24392 call to `strfunc' is destroyed after `p' is initialized, at which point
24393 `p' is left pointing to freed memory.
24395 Code like this may run successfully under some other compilers,
24396 particularly obsolete cfront-based compilers that delete temporaries
24397 along with normal local variables. However, the GNU C++ behavior is
24398 standard-conforming, so if your program depends on late destruction of
24399 temporaries it is not portable.
24401 The safe way to write such code is to give the temporary a name, which
24402 forces it to remain until the end of the scope of the name. For
24405 const string& tmp = strfunc ();
24406 charfunc (tmp.c_str ());
24409 File: gcc.info, Node: Copy Assignment, Prev: Temporaries, Up: C++ Misunderstandings
24411 10.8.4 Implicit Copy-Assignment for Virtual Bases
24412 -------------------------------------------------
24414 When a base class is virtual, only one subobject of the base class
24415 belongs to each full object. Also, the constructors and destructors are
24416 invoked only once, and called from the most-derived class. However,
24417 such objects behave unspecified when being assigned. For example:
24421 Base(char *n) : name(strdup(n)){}
24422 Base& operator= (const Base& other){
24424 name = strdup (other.name);
24428 struct A:virtual Base{
24433 struct B:virtual Base{
24438 struct Derived:public A, public B{
24439 Derived():Base("Derived"){}
24442 void func(Derived &d1, Derived &d2)
24447 The C++ standard specifies that `Base::Base' is only called once when
24448 constructing or copy-constructing a Derived object. It is unspecified
24449 whether `Base::operator=' is called more than once when the implicit
24450 copy-assignment for Derived objects is invoked (as it is inside `func'
24453 G++ implements the "intuitive" algorithm for copy-assignment: assign
24454 all direct bases, then assign all members. In that algorithm, the
24455 virtual base subobject can be encountered more than once. In the
24456 example, copying proceeds in the following order: `val', `name' (via
24457 `strdup'), `bval', and `name' again.
24459 If application code relies on copy-assignment, a user-defined
24460 copy-assignment operator removes any uncertainties. With such an
24461 operator, the application can define whether and how the virtual base
24462 subobject is assigned.
24465 File: gcc.info, Node: Protoize Caveats, Next: Non-bugs, Prev: C++ Misunderstandings, Up: Trouble
24467 10.9 Caveats of using `protoize'
24468 ================================
24470 The conversion programs `protoize' and `unprotoize' can sometimes
24471 change a source file in a way that won't work unless you rearrange it.
24473 * `protoize' can insert references to a type name or type tag before
24474 the definition, or in a file where they are not defined.
24476 If this happens, compiler error messages should show you where the
24477 new references are, so fixing the file by hand is straightforward.
24479 * There are some C constructs which `protoize' cannot figure out.
24480 For example, it can't determine argument types for declaring a
24481 pointer-to-function variable; this you must do by hand. `protoize'
24482 inserts a comment containing `???' each time it finds such a
24483 variable; so you can find all such variables by searching for this
24484 string. ISO C does not require declaring the argument types of
24485 pointer-to-function types.
24487 * Using `unprotoize' can easily introduce bugs. If the program
24488 relied on prototypes to bring about conversion of arguments, these
24489 conversions will not take place in the program without prototypes.
24490 One case in which you can be sure `unprotoize' is safe is when you
24491 are removing prototypes that were made with `protoize'; if the
24492 program worked before without any prototypes, it will work again
24495 You can find all the places where this problem might occur by
24496 compiling the program with the `-Wconversion' option. It prints a
24497 warning whenever an argument is converted.
24499 * Both conversion programs can be confused if there are macro calls
24500 in and around the text to be converted. In other words, the
24501 standard syntax for a declaration or definition must not result
24502 from expanding a macro. This problem is inherent in the design of
24503 C and cannot be fixed. If only a few functions have confusing
24504 macro calls, you can easily convert them manually.
24506 * `protoize' cannot get the argument types for a function whose
24507 definition was not actually compiled due to preprocessing
24508 conditionals. When this happens, `protoize' changes nothing in
24509 regard to such a function. `protoize' tries to detect such
24510 instances and warn about them.
24512 You can generally work around this problem by using `protoize' step
24513 by step, each time specifying a different set of `-D' options for
24514 compilation, until all of the functions have been converted.
24515 There is no automatic way to verify that you have got them all,
24518 * Confusion may result if there is an occasion to convert a function
24519 declaration or definition in a region of source code where there
24520 is more than one formal parameter list present. Thus, attempts to
24521 convert code containing multiple (conditionally compiled) versions
24522 of a single function header (in the same vicinity) may not produce
24523 the desired (or expected) results.
24525 If you plan on converting source files which contain such code, it
24526 is recommended that you first make sure that each conditionally
24527 compiled region of source code which contains an alternative
24528 function header also contains at least one additional follower
24529 token (past the final right parenthesis of the function header).
24530 This should circumvent the problem.
24532 * `unprotoize' can become confused when trying to convert a function
24533 definition or declaration which contains a declaration for a
24534 pointer-to-function formal argument which has the same name as the
24535 function being defined or declared. We recommend you avoid such
24536 choices of formal parameter names.
24538 * You might also want to correct some of the indentation by hand and
24539 break long lines. (The conversion programs don't write lines
24540 longer than eighty characters in any case.)
24543 File: gcc.info, Node: Non-bugs, Next: Warnings and Errors, Prev: Protoize Caveats, Up: Trouble
24545 10.10 Certain Changes We Don't Want to Make
24546 ===========================================
24548 This section lists changes that people frequently request, but which we
24549 do not make because we think GCC is better without them.
24551 * Checking the number and type of arguments to a function which has
24552 an old-fashioned definition and no prototype.
24554 Such a feature would work only occasionally--only for calls that
24555 appear in the same file as the called function, following the
24556 definition. The only way to check all calls reliably is to add a
24557 prototype for the function. But adding a prototype eliminates the
24558 motivation for this feature. So the feature is not worthwhile.
24560 * Warning about using an expression whose type is signed as a shift
24563 Shift count operands are probably signed more often than unsigned.
24564 Warning about this would cause far more annoyance than good.
24566 * Warning about assigning a signed value to an unsigned variable.
24568 Such assignments must be very common; warning about them would
24569 cause more annoyance than good.
24571 * Warning when a non-void function value is ignored.
24573 C contains many standard functions that return a value that most
24574 programs choose to ignore. One obvious example is `printf'.
24575 Warning about this practice only leads the defensive programmer to
24576 clutter programs with dozens of casts to `void'. Such casts are
24577 required so frequently that they become visual noise. Writing
24578 those casts becomes so automatic that they no longer convey useful
24579 information about the intentions of the programmer. For functions
24580 where the return value should never be ignored, use the
24581 `warn_unused_result' function attribute (*note Function
24584 * Making `-fshort-enums' the default.
24586 This would cause storage layout to be incompatible with most other
24587 C compilers. And it doesn't seem very important, given that you
24588 can get the same result in other ways. The case where it matters
24589 most is when the enumeration-valued object is inside a structure,
24590 and in that case you can specify a field width explicitly.
24592 * Making bit-fields unsigned by default on particular machines where
24593 "the ABI standard" says to do so.
24595 The ISO C standard leaves it up to the implementation whether a
24596 bit-field declared plain `int' is signed or not. This in effect
24597 creates two alternative dialects of C.
24599 The GNU C compiler supports both dialects; you can specify the
24600 signed dialect with `-fsigned-bitfields' and the unsigned dialect
24601 with `-funsigned-bitfields'. However, this leaves open the
24602 question of which dialect to use by default.
24604 Currently, the preferred dialect makes plain bit-fields signed,
24605 because this is simplest. Since `int' is the same as `signed int'
24606 in every other context, it is cleanest for them to be the same in
24607 bit-fields as well.
24609 Some computer manufacturers have published Application Binary
24610 Interface standards which specify that plain bit-fields should be
24611 unsigned. It is a mistake, however, to say anything about this
24612 issue in an ABI. This is because the handling of plain bit-fields
24613 distinguishes two dialects of C. Both dialects are meaningful on
24614 every type of machine. Whether a particular object file was
24615 compiled using signed bit-fields or unsigned is of no concern to
24616 other object files, even if they access the same bit-fields in the
24617 same data structures.
24619 A given program is written in one or the other of these two
24620 dialects. The program stands a chance to work on most any machine
24621 if it is compiled with the proper dialect. It is unlikely to work
24622 at all if compiled with the wrong dialect.
24624 Many users appreciate the GNU C compiler because it provides an
24625 environment that is uniform across machines. These users would be
24626 inconvenienced if the compiler treated plain bit-fields
24627 differently on certain machines.
24629 Occasionally users write programs intended only for a particular
24630 machine type. On these occasions, the users would benefit if the
24631 GNU C compiler were to support by default the same dialect as the
24632 other compilers on that machine. But such applications are rare.
24633 And users writing a program to run on more than one type of
24634 machine cannot possibly benefit from this kind of compatibility.
24636 This is why GCC does and will treat plain bit-fields in the same
24637 fashion on all types of machines (by default).
24639 There are some arguments for making bit-fields unsigned by default
24640 on all machines. If, for example, this becomes a universal de
24641 facto standard, it would make sense for GCC to go along with it.
24642 This is something to be considered in the future.
24644 (Of course, users strongly concerned about portability should
24645 indicate explicitly in each bit-field whether it is signed or not.
24646 In this way, they write programs which have the same meaning in
24649 * Undefining `__STDC__' when `-ansi' is not used.
24651 Currently, GCC defines `__STDC__' unconditionally. This provides
24652 good results in practice.
24654 Programmers normally use conditionals on `__STDC__' to ask whether
24655 it is safe to use certain features of ISO C, such as function
24656 prototypes or ISO token concatenation. Since plain `gcc' supports
24657 all the features of ISO C, the correct answer to these questions is
24660 Some users try to use `__STDC__' to check for the availability of
24661 certain library facilities. This is actually incorrect usage in
24662 an ISO C program, because the ISO C standard says that a conforming
24663 freestanding implementation should define `__STDC__' even though it
24664 does not have the library facilities. `gcc -ansi -pedantic' is a
24665 conforming freestanding implementation, and it is therefore
24666 required to define `__STDC__', even though it does not come with
24669 Sometimes people say that defining `__STDC__' in a compiler that
24670 does not completely conform to the ISO C standard somehow violates
24671 the standard. This is illogical. The standard is a standard for
24672 compilers that claim to support ISO C, such as `gcc -ansi'--not
24673 for other compilers such as plain `gcc'. Whatever the ISO C
24674 standard says is relevant to the design of plain `gcc' without
24675 `-ansi' only for pragmatic reasons, not as a requirement.
24677 GCC normally defines `__STDC__' to be 1, and in addition defines
24678 `__STRICT_ANSI__' if you specify the `-ansi' option, or a `-std'
24679 option for strict conformance to some version of ISO C. On some
24680 hosts, system include files use a different convention, where
24681 `__STDC__' is normally 0, but is 1 if the user specifies strict
24682 conformance to the C Standard. GCC follows the host convention
24683 when processing system include files, but when processing user
24684 files it follows the usual GNU C convention.
24686 * Undefining `__STDC__' in C++.
24688 Programs written to compile with C++-to-C translators get the
24689 value of `__STDC__' that goes with the C compiler that is
24690 subsequently used. These programs must test `__STDC__' to
24691 determine what kind of C preprocessor that compiler uses: whether
24692 they should concatenate tokens in the ISO C fashion or in the
24693 traditional fashion.
24695 These programs work properly with GNU C++ if `__STDC__' is defined.
24696 They would not work otherwise.
24698 In addition, many header files are written to provide prototypes
24699 in ISO C but not in traditional C. Many of these header files can
24700 work without change in C++ provided `__STDC__' is defined. If
24701 `__STDC__' is not defined, they will all fail, and will all need
24702 to be changed to test explicitly for C++ as well.
24704 * Deleting "empty" loops.
24706 Historically, GCC has not deleted "empty" loops under the
24707 assumption that the most likely reason you would put one in a
24708 program is to have a delay, so deleting them will not make real
24709 programs run any faster.
24711 However, the rationale here is that optimization of a nonempty loop
24712 cannot produce an empty one. This held for carefully written C
24713 compiled with less powerful optimizers but is not always the case
24714 for carefully written C++ or with more powerful optimizers.
24716 Thus GCC will remove operations from loops whenever it can
24717 determine those operations are not externally visible (apart from
24718 the time taken to execute them, of course). As GCC improves, it
24719 will remove the loop itself. Indeed, with `-funroll-loops' small
24720 loops can already be removed, so leaving an empty non-unrolled
24721 loop is both sub-optimal and inconsistent.
24723 Be aware of this when performing timing tests, for instance the
24724 following loop can be completely removed, provided
24725 `some_expression' can provably not change any global state.
24731 for (ix = 0; ix != 10000; ix++)
24732 sum += some_expression;
24735 Even though `sum' is accumulated in the loop, no use is made of
24736 that summation, so the accumulation can be removed.
24738 * Making side effects happen in the same order as in some other
24741 It is never safe to depend on the order of evaluation of side
24742 effects. For example, a function call like this may very well
24743 behave differently from one compiler to another:
24745 void func (int, int);
24750 There is no guarantee (in either the C or the C++ standard language
24751 definitions) that the increments will be evaluated in any
24752 particular order. Either increment might happen first. `func'
24753 might get the arguments `2, 3', or it might get `3, 2', or even
24756 * Making certain warnings into errors by default.
24758 Some ISO C testsuites report failure when the compiler does not
24759 produce an error message for a certain program.
24761 ISO C requires a "diagnostic" message for certain kinds of invalid
24762 programs, but a warning is defined by GCC to count as a
24763 diagnostic. If GCC produces a warning but not an error, that is
24764 correct ISO C support. If testsuites call this "failure", they
24765 should be run with the GCC option `-pedantic-errors', which will
24766 turn these warnings into errors.
24770 File: gcc.info, Node: Warnings and Errors, Prev: Non-bugs, Up: Trouble
24772 10.11 Warning Messages and Error Messages
24773 =========================================
24775 The GNU compiler can produce two kinds of diagnostics: errors and
24776 warnings. Each kind has a different purpose:
24778 "Errors" report problems that make it impossible to compile your
24779 program. GCC reports errors with the source file name and line
24780 number where the problem is apparent.
24782 "Warnings" report other unusual conditions in your code that _may_
24783 indicate a problem, although compilation can (and does) proceed.
24784 Warning messages also report the source file name and line number,
24785 but include the text `warning:' to distinguish them from error
24788 Warnings may indicate danger points where you should check to make sure
24789 that your program really does what you intend; or the use of obsolete
24790 features; or the use of nonstandard features of GNU C or C++. Many
24791 warnings are issued only if you ask for them, with one of the `-W'
24792 options (for instance, `-Wall' requests a variety of useful warnings).
24794 GCC always tries to compile your program if possible; it never
24795 gratuitously rejects a program whose meaning is clear merely because
24796 (for instance) it fails to conform to a standard. In some cases,
24797 however, the C and C++ standards specify that certain extensions are
24798 forbidden, and a diagnostic _must_ be issued by a conforming compiler.
24799 The `-pedantic' option tells GCC to issue warnings in such cases;
24800 `-pedantic-errors' says to make them errors instead. This does not
24801 mean that _all_ non-ISO constructs get warnings or errors.
24803 *Note Options to Request or Suppress Warnings: Warning Options, for
24804 more detail on these and related command-line options.
24807 File: gcc.info, Node: Bugs, Next: Service, Prev: Trouble, Up: Top
24812 Your bug reports play an essential role in making GCC reliable.
24814 When you encounter a problem, the first thing to do is to see if it is
24815 already known. *Note Trouble::. If it isn't known, then you should
24816 report the problem.
24820 * Criteria: Bug Criteria. Have you really found a bug?
24821 * Reporting: Bug Reporting. How to report a bug effectively.
24822 * Known: Trouble. Known problems.
24823 * Help: Service. Where to ask for help.
24826 File: gcc.info, Node: Bug Criteria, Next: Bug Reporting, Up: Bugs
24828 11.1 Have You Found a Bug?
24829 ==========================
24831 If you are not sure whether you have found a bug, here are some
24834 * If the compiler gets a fatal signal, for any input whatever, that
24835 is a compiler bug. Reliable compilers never crash.
24837 * If the compiler produces invalid assembly code, for any input
24838 whatever (except an `asm' statement), that is a compiler bug,
24839 unless the compiler reports errors (not just warnings) which would
24840 ordinarily prevent the assembler from being run.
24842 * If the compiler produces valid assembly code that does not
24843 correctly execute the input source code, that is a compiler bug.
24845 However, you must double-check to make sure, because you may have a
24846 program whose behavior is undefined, which happened by chance to
24847 give the desired results with another C or C++ compiler.
24849 For example, in many nonoptimizing compilers, you can write `x;'
24850 at the end of a function instead of `return x;', with the same
24851 results. But the value of the function is undefined if `return'
24852 is omitted; it is not a bug when GCC produces different results.
24854 Problems often result from expressions with two increment
24855 operators, as in `f (*p++, *p++)'. Your previous compiler might
24856 have interpreted that expression the way you intended; GCC might
24857 interpret it another way. Neither compiler is wrong. The bug is
24860 After you have localized the error to a single source line, it
24861 should be easy to check for these things. If your program is
24862 correct and well defined, you have found a compiler bug.
24864 * If the compiler produces an error message for valid input, that is
24867 * If the compiler does not produce an error message for invalid
24868 input, that is a compiler bug. However, you should note that your
24869 idea of "invalid input" might be someone else's idea of "an
24870 extension" or "support for traditional practice".
24872 * If you are an experienced user of one of the languages GCC
24873 supports, your suggestions for improvement of GCC are welcome in
24877 File: gcc.info, Node: Bug Reporting, Prev: Bug Criteria, Up: Bugs
24879 11.2 How and where to Report Bugs
24880 =================================
24882 Bugs should be reported to the GCC bug database. Please refer to
24883 `http://gcc.gnu.org/bugs.html' for up-to-date instructions how to
24884 submit bug reports. Copies of this file in HTML (`bugs.html') and
24885 plain text (`BUGS') are also part of GCC releases.
24888 File: gcc.info, Node: Service, Next: Contributing, Prev: Bugs, Up: Top
24890 12 How To Get Help with GCC
24891 ***************************
24893 If you need help installing, using or changing GCC, there are two ways
24896 * Send a message to a suitable network mailing list. First try
24897 <gcc-help@gcc.gnu.org> (for help installing or using GCC), and if
24898 that brings no response, try <gcc@gcc.gnu.org>. For help changing
24899 GCC, ask <gcc@gcc.gnu.org>. If you think you have found a bug in
24900 GCC, please report it following the instructions at *note Bug
24903 * Look in the service directory for someone who might help you for a
24904 fee. The service directory is found at
24905 `http://www.gnu.org/prep/service.html'.
24907 For further information, see `http://gcc.gnu.org/faq.html#support'.
24910 File: gcc.info, Node: Contributing, Next: Funding, Prev: Service, Up: Top
24912 13 Contributing to GCC Development
24913 **********************************
24915 If you would like to help pretest GCC releases to assure they work well,
24916 current development sources are available by CVS (see
24917 `http://gcc.gnu.org/cvs.html'). Source and binary snapshots are also
24918 available for FTP; see `http://gcc.gnu.org/snapshots.html'.
24920 If you would like to work on improvements to GCC, please read the
24921 advice at these URLs:
24923 `http://gcc.gnu.org/contribute.html'
24924 `http://gcc.gnu.org/contributewhy.html'
24926 for information on how to make useful contributions and avoid
24927 duplication of effort. Suggested projects are listed at
24928 `http://gcc.gnu.org/projects/'.
24931 File: gcc.info, Node: Funding, Next: GNU Project, Prev: Contributing, Up: Top
24933 Funding Free Software
24934 *********************
24936 If you want to have more free software a few years from now, it makes
24937 sense for you to help encourage people to contribute funds for its
24938 development. The most effective approach known is to encourage
24939 commercial redistributors to donate.
24941 Users of free software systems can boost the pace of development by
24942 encouraging for-a-fee distributors to donate part of their selling price
24943 to free software developers--the Free Software Foundation, and others.
24945 The way to convince distributors to do this is to demand it and expect
24946 it from them. So when you compare distributors, judge them partly by
24947 how much they give to free software development. Show distributors
24948 they must compete to be the one who gives the most.
24950 To make this approach work, you must insist on numbers that you can
24951 compare, such as, "We will donate ten dollars to the Frobnitz project
24952 for each disk sold." Don't be satisfied with a vague promise, such as
24953 "A portion of the profits are donated," since it doesn't give a basis
24956 Even a precise fraction "of the profits from this disk" is not very
24957 meaningful, since creative accounting and unrelated business decisions
24958 can greatly alter what fraction of the sales price counts as profit.
24959 If the price you pay is $50, ten percent of the profit is probably less
24960 than a dollar; it might be a few cents, or nothing at all.
24962 Some redistributors do development work themselves. This is useful
24963 too; but to keep everyone honest, you need to inquire how much they do,
24964 and what kind. Some kinds of development make much more long-term
24965 difference than others. For example, maintaining a separate version of
24966 a program contributes very little; maintaining the standard version of a
24967 program for the whole community contributes much. Easy new ports
24968 contribute little, since someone else would surely do them; difficult
24969 ports such as adding a new CPU to the GNU Compiler Collection
24970 contribute more; major new features or packages contribute the most.
24972 By establishing the idea that supporting further development is "the
24973 proper thing to do" when distributing free software for a fee, we can
24974 assure a steady flow of resources into making more free software.
24976 Copyright (C) 1994 Free Software Foundation, Inc.
24977 Verbatim copying and redistribution of this section is permitted
24978 without royalty; alteration is not permitted.
24981 File: gcc.info, Node: GNU Project, Next: Copying, Prev: Funding, Up: Top
24983 The GNU Project and GNU/Linux
24984 *****************************
24986 The GNU Project was launched in 1984 to develop a complete Unix-like
24987 operating system which is free software: the GNU system. (GNU is a
24988 recursive acronym for "GNU's Not Unix"; it is pronounced "guh-NEW".)
24989 Variants of the GNU operating system, which use the kernel Linux, are
24990 now widely used; though these systems are often referred to as "Linux",
24991 they are more accurately called GNU/Linux systems.
24993 For more information, see:
24994 `http://www.gnu.org/'
24995 `http://www.gnu.org/gnu/linux-and-gnu.html'
24998 File: gcc.info, Node: Copying, Next: GNU Free Documentation License, Prev: GNU Project, Up: Top
25000 GNU GENERAL PUBLIC LICENSE
25001 **************************
25003 Version 2, June 1991
25005 Copyright (C) 1989, 1991 Free Software Foundation, Inc.
25006 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
25008 Everyone is permitted to copy and distribute verbatim copies
25009 of this license document, but changing it is not allowed.
25014 The licenses for most software are designed to take away your freedom
25015 to share and change it. By contrast, the GNU General Public License is
25016 intended to guarantee your freedom to share and change free
25017 software--to make sure the software is free for all its users. This
25018 General Public License applies to most of the Free Software
25019 Foundation's software and to any other program whose authors commit to
25020 using it. (Some other Free Software Foundation software is covered by
25021 the GNU Library General Public License instead.) You can apply it to
25022 your programs, too.
25024 When we speak of free software, we are referring to freedom, not
25025 price. Our General Public Licenses are designed to make sure that you
25026 have the freedom to distribute copies of free software (and charge for
25027 this service if you wish), that you receive source code or can get it
25028 if you want it, that you can change the software or use pieces of it in
25029 new free programs; and that you know you can do these things.
25031 To protect your rights, we need to make restrictions that forbid
25032 anyone to deny you these rights or to ask you to surrender the rights.
25033 These restrictions translate to certain responsibilities for you if you
25034 distribute copies of the software, or if you modify it.
25036 For example, if you distribute copies of such a program, whether
25037 gratis or for a fee, you must give the recipients all the rights that
25038 you have. You must make sure that they, too, receive or can get the
25039 source code. And you must show them these terms so they know their
25042 We protect your rights with two steps: (1) copyright the software, and
25043 (2) offer you this license which gives you legal permission to copy,
25044 distribute and/or modify the software.
25046 Also, for each author's protection and ours, we want to make certain
25047 that everyone understands that there is no warranty for this free
25048 software. If the software is modified by someone else and passed on, we
25049 want its recipients to know that what they have is not the original, so
25050 that any problems introduced by others will not reflect on the original
25051 authors' reputations.
25053 Finally, any free program is threatened constantly by software
25054 patents. We wish to avoid the danger that redistributors of a free
25055 program will individually obtain patent licenses, in effect making the
25056 program proprietary. To prevent this, we have made it clear that any
25057 patent must be licensed for everyone's free use or not licensed at all.
25059 The precise terms and conditions for copying, distribution and
25060 modification follow.
25062 TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
25063 0. This License applies to any program or other work which contains a
25064 notice placed by the copyright holder saying it may be distributed
25065 under the terms of this General Public License. The "Program",
25066 below, refers to any such program or work, and a "work based on
25067 the Program" means either the Program or any derivative work under
25068 copyright law: that is to say, a work containing the Program or a
25069 portion of it, either verbatim or with modifications and/or
25070 translated into another language. (Hereinafter, translation is
25071 included without limitation in the term "modification".) Each
25072 licensee is addressed as "you".
25074 Activities other than copying, distribution and modification are
25075 not covered by this License; they are outside its scope. The act
25076 of running the Program is not restricted, and the output from the
25077 Program is covered only if its contents constitute a work based on
25078 the Program (independent of having been made by running the
25079 Program). Whether that is true depends on what the Program does.
25081 1. You may copy and distribute verbatim copies of the Program's
25082 source code as you receive it, in any medium, provided that you
25083 conspicuously and appropriately publish on each copy an appropriate
25084 copyright notice and disclaimer of warranty; keep intact all the
25085 notices that refer to this License and to the absence of any
25086 warranty; and give any other recipients of the Program a copy of
25087 this License along with the Program.
25089 You may charge a fee for the physical act of transferring a copy,
25090 and you may at your option offer warranty protection in exchange
25093 2. You may modify your copy or copies of the Program or any portion
25094 of it, thus forming a work based on the Program, and copy and
25095 distribute such modifications or work under the terms of Section 1
25096 above, provided that you also meet all of these conditions:
25098 a. You must cause the modified files to carry prominent notices
25099 stating that you changed the files and the date of any change.
25101 b. You must cause any work that you distribute or publish, that
25102 in whole or in part contains or is derived from the Program
25103 or any part thereof, to be licensed as a whole at no charge
25104 to all third parties under the terms of this License.
25106 c. If the modified program normally reads commands interactively
25107 when run, you must cause it, when started running for such
25108 interactive use in the most ordinary way, to print or display
25109 an announcement including an appropriate copyright notice and
25110 a notice that there is no warranty (or else, saying that you
25111 provide a warranty) and that users may redistribute the
25112 program under these conditions, and telling the user how to
25113 view a copy of this License. (Exception: if the Program
25114 itself is interactive but does not normally print such an
25115 announcement, your work based on the Program is not required
25116 to print an announcement.)
25118 These requirements apply to the modified work as a whole. If
25119 identifiable sections of that work are not derived from the
25120 Program, and can be reasonably considered independent and separate
25121 works in themselves, then this License, and its terms, do not
25122 apply to those sections when you distribute them as separate
25123 works. But when you distribute the same sections as part of a
25124 whole which is a work based on the Program, the distribution of
25125 the whole must be on the terms of this License, whose permissions
25126 for other licensees extend to the entire whole, and thus to each
25127 and every part regardless of who wrote it.
25129 Thus, it is not the intent of this section to claim rights or
25130 contest your rights to work written entirely by you; rather, the
25131 intent is to exercise the right to control the distribution of
25132 derivative or collective works based on the Program.
25134 In addition, mere aggregation of another work not based on the
25135 Program with the Program (or with a work based on the Program) on
25136 a volume of a storage or distribution medium does not bring the
25137 other work under the scope of this License.
25139 3. You may copy and distribute the Program (or a work based on it,
25140 under Section 2) in object code or executable form under the terms
25141 of Sections 1 and 2 above provided that you also do one of the
25144 a. Accompany it with the complete corresponding machine-readable
25145 source code, which must be distributed under the terms of
25146 Sections 1 and 2 above on a medium customarily used for
25147 software interchange; or,
25149 b. Accompany it with a written offer, valid for at least three
25150 years, to give any third party, for a charge no more than your
25151 cost of physically performing source distribution, a complete
25152 machine-readable copy of the corresponding source code, to be
25153 distributed under the terms of Sections 1 and 2 above on a
25154 medium customarily used for software interchange; or,
25156 c. Accompany it with the information you received as to the offer
25157 to distribute corresponding source code. (This alternative is
25158 allowed only for noncommercial distribution and only if you
25159 received the program in object code or executable form with
25160 such an offer, in accord with Subsection b above.)
25162 The source code for a work means the preferred form of the work for
25163 making modifications to it. For an executable work, complete
25164 source code means all the source code for all modules it contains,
25165 plus any associated interface definition files, plus the scripts
25166 used to control compilation and installation of the executable.
25167 However, as a special exception, the source code distributed need
25168 not include anything that is normally distributed (in either
25169 source or binary form) with the major components (compiler,
25170 kernel, and so on) of the operating system on which the executable
25171 runs, unless that component itself accompanies the executable.
25173 If distribution of executable or object code is made by offering
25174 access to copy from a designated place, then offering equivalent
25175 access to copy the source code from the same place counts as
25176 distribution of the source code, even though third parties are not
25177 compelled to copy the source along with the object code.
25179 4. You may not copy, modify, sublicense, or distribute the Program
25180 except as expressly provided under this License. Any attempt
25181 otherwise to copy, modify, sublicense or distribute the Program is
25182 void, and will automatically terminate your rights under this
25183 License. However, parties who have received copies, or rights,
25184 from you under this License will not have their licenses
25185 terminated so long as such parties remain in full compliance.
25187 5. You are not required to accept this License, since you have not
25188 signed it. However, nothing else grants you permission to modify
25189 or distribute the Program or its derivative works. These actions
25190 are prohibited by law if you do not accept this License.
25191 Therefore, by modifying or distributing the Program (or any work
25192 based on the Program), you indicate your acceptance of this
25193 License to do so, and all its terms and conditions for copying,
25194 distributing or modifying the Program or works based on it.
25196 6. Each time you redistribute the Program (or any work based on the
25197 Program), the recipient automatically receives a license from the
25198 original licensor to copy, distribute or modify the Program
25199 subject to these terms and conditions. You may not impose any
25200 further restrictions on the recipients' exercise of the rights
25201 granted herein. You are not responsible for enforcing compliance
25202 by third parties to this License.
25204 7. If, as a consequence of a court judgment or allegation of patent
25205 infringement or for any other reason (not limited to patent
25206 issues), conditions are imposed on you (whether by court order,
25207 agreement or otherwise) that contradict the conditions of this
25208 License, they do not excuse you from the conditions of this
25209 License. If you cannot distribute so as to satisfy simultaneously
25210 your obligations under this License and any other pertinent
25211 obligations, then as a consequence you may not distribute the
25212 Program at all. For example, if a patent license would not permit
25213 royalty-free redistribution of the Program by all those who
25214 receive copies directly or indirectly through you, then the only
25215 way you could satisfy both it and this License would be to refrain
25216 entirely from distribution of the Program.
25218 If any portion of this section is held invalid or unenforceable
25219 under any particular circumstance, the balance of the section is
25220 intended to apply and the section as a whole is intended to apply
25221 in other circumstances.
25223 It is not the purpose of this section to induce you to infringe any
25224 patents or other property right claims or to contest validity of
25225 any such claims; this section has the sole purpose of protecting
25226 the integrity of the free software distribution system, which is
25227 implemented by public license practices. Many people have made
25228 generous contributions to the wide range of software distributed
25229 through that system in reliance on consistent application of that
25230 system; it is up to the author/donor to decide if he or she is
25231 willing to distribute software through any other system and a
25232 licensee cannot impose that choice.
25234 This section is intended to make thoroughly clear what is believed
25235 to be a consequence of the rest of this License.
25237 8. If the distribution and/or use of the Program is restricted in
25238 certain countries either by patents or by copyrighted interfaces,
25239 the original copyright holder who places the Program under this
25240 License may add an explicit geographical distribution limitation
25241 excluding those countries, so that distribution is permitted only
25242 in or among countries not thus excluded. In such case, this
25243 License incorporates the limitation as if written in the body of
25246 9. The Free Software Foundation may publish revised and/or new
25247 versions of the General Public License from time to time. Such
25248 new versions will be similar in spirit to the present version, but
25249 may differ in detail to address new problems or concerns.
25251 Each version is given a distinguishing version number. If the
25252 Program specifies a version number of this License which applies
25253 to it and "any later version", you have the option of following
25254 the terms and conditions either of that version or of any later
25255 version published by the Free Software Foundation. If the Program
25256 does not specify a version number of this License, you may choose
25257 any version ever published by the Free Software Foundation.
25259 10. If you wish to incorporate parts of the Program into other free
25260 programs whose distribution conditions are different, write to the
25261 author to ask for permission. For software which is copyrighted
25262 by the Free Software Foundation, write to the Free Software
25263 Foundation; we sometimes make exceptions for this. Our decision
25264 will be guided by the two goals of preserving the free status of
25265 all derivatives of our free software and of promoting the sharing
25266 and reuse of software generally.
25269 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO
25270 WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE
25271 LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
25272 HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT
25273 WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT
25274 NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
25275 FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE
25276 QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
25277 PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY
25278 SERVICING, REPAIR OR CORRECTION.
25280 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
25281 WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY
25282 MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE
25283 LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL,
25284 INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR
25285 INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
25286 DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU
25287 OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY
25288 OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN
25289 ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
25291 END OF TERMS AND CONDITIONS
25292 How to Apply These Terms to Your New Programs
25293 =============================================
25295 If you develop a new program, and you want it to be of the greatest
25296 possible use to the public, the best way to achieve this is to make it
25297 free software which everyone can redistribute and change under these
25300 To do so, attach the following notices to the program. It is safest
25301 to attach them to the start of each source file to most effectively
25302 convey the exclusion of warranty; and each file should have at least
25303 the "copyright" line and a pointer to where the full notice is found.
25305 ONE LINE TO GIVE THE PROGRAM'S NAME AND A BRIEF IDEA OF WHAT IT DOES.
25306 Copyright (C) YEAR NAME OF AUTHOR
25308 This program is free software; you can redistribute it and/or modify
25309 it under the terms of the GNU General Public License as published by
25310 the Free Software Foundation; either version 2 of the License, or
25311 (at your option) any later version.
25313 This program is distributed in the hope that it will be useful,
25314 but WITHOUT ANY WARRANTY; without even the implied warranty of
25315 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25316 GNU General Public License for more details.
25318 You should have received a copy of the GNU General Public License
25319 along with this program; if not, write to the Free Software Foundation,
25320 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
25322 Also add information on how to contact you by electronic and paper
25325 If the program is interactive, make it output a short notice like this
25326 when it starts in an interactive mode:
25328 Gnomovision version 69, Copyright (C) YEAR NAME OF AUTHOR
25329 Gnomovision comes with ABSOLUTELY NO WARRANTY; for details
25331 This is free software, and you are welcome to redistribute it
25332 under certain conditions; type `show c' for details.
25334 The hypothetical commands `show w' and `show c' should show the
25335 appropriate parts of the General Public License. Of course, the
25336 commands you use may be called something other than `show w' and `show
25337 c'; they could even be mouse-clicks or menu items--whatever suits your
25340 You should also get your employer (if you work as a programmer) or your
25341 school, if any, to sign a "copyright disclaimer" for the program, if
25342 necessary. Here is a sample; alter the names:
25344 Yoyodyne, Inc., hereby disclaims all copyright interest in the program
25345 `Gnomovision' (which makes passes at compilers) written by James Hacker.
25347 SIGNATURE OF TY COON, 1 April 1989
25348 Ty Coon, President of Vice
25350 This General Public License does not permit incorporating your program
25351 into proprietary programs. If your program is a subroutine library,
25352 you may consider it more useful to permit linking proprietary
25353 applications with the library. If this is what you want to do, use the
25354 GNU Library General Public License instead of this License.
25357 File: gcc.info, Node: GNU Free Documentation License, Next: Contributors, Prev: Copying, Up: Top
25359 GNU Free Documentation License
25360 ******************************
25362 Version 1.2, November 2002
25364 Copyright (C) 2000,2001,2002 Free Software Foundation, Inc.
25365 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA
25367 Everyone is permitted to copy and distribute verbatim copies
25368 of this license document, but changing it is not allowed.
25372 The purpose of this License is to make a manual, textbook, or other
25373 functional and useful document "free" in the sense of freedom: to
25374 assure everyone the effective freedom to copy and redistribute it,
25375 with or without modifying it, either commercially or
25376 noncommercially. Secondarily, this License preserves for the
25377 author and publisher a way to get credit for their work, while not
25378 being considered responsible for modifications made by others.
25380 This License is a kind of "copyleft", which means that derivative
25381 works of the document must themselves be free in the same sense.
25382 It complements the GNU General Public License, which is a copyleft
25383 license designed for free software.
25385 We have designed this License in order to use it for manuals for
25386 free software, because free software needs free documentation: a
25387 free program should come with manuals providing the same freedoms
25388 that the software does. But this License is not limited to
25389 software manuals; it can be used for any textual work, regardless
25390 of subject matter or whether it is published as a printed book.
25391 We recommend this License principally for works whose purpose is
25392 instruction or reference.
25394 1. APPLICABILITY AND DEFINITIONS
25396 This License applies to any manual or other work, in any medium,
25397 that contains a notice placed by the copyright holder saying it
25398 can be distributed under the terms of this License. Such a notice
25399 grants a world-wide, royalty-free license, unlimited in duration,
25400 to use that work under the conditions stated herein. The
25401 "Document", below, refers to any such manual or work. Any member
25402 of the public is a licensee, and is addressed as "you". You
25403 accept the license if you copy, modify or distribute the work in a
25404 way requiring permission under copyright law.
25406 A "Modified Version" of the Document means any work containing the
25407 Document or a portion of it, either copied verbatim, or with
25408 modifications and/or translated into another language.
25410 A "Secondary Section" is a named appendix or a front-matter section
25411 of the Document that deals exclusively with the relationship of the
25412 publishers or authors of the Document to the Document's overall
25413 subject (or to related matters) and contains nothing that could
25414 fall directly within that overall subject. (Thus, if the Document
25415 is in part a textbook of mathematics, a Secondary Section may not
25416 explain any mathematics.) The relationship could be a matter of
25417 historical connection with the subject or with related matters, or
25418 of legal, commercial, philosophical, ethical or political position
25421 The "Invariant Sections" are certain Secondary Sections whose
25422 titles are designated, as being those of Invariant Sections, in
25423 the notice that says that the Document is released under this
25424 License. If a section does not fit the above definition of
25425 Secondary then it is not allowed to be designated as Invariant.
25426 The Document may contain zero Invariant Sections. If the Document
25427 does not identify any Invariant Sections then there are none.
25429 The "Cover Texts" are certain short passages of text that are
25430 listed, as Front-Cover Texts or Back-Cover Texts, in the notice
25431 that says that the Document is released under this License. A
25432 Front-Cover Text may be at most 5 words, and a Back-Cover Text may
25433 be at most 25 words.
25435 A "Transparent" copy of the Document means a machine-readable copy,
25436 represented in a format whose specification is available to the
25437 general public, that is suitable for revising the document
25438 straightforwardly with generic text editors or (for images
25439 composed of pixels) generic paint programs or (for drawings) some
25440 widely available drawing editor, and that is suitable for input to
25441 text formatters or for automatic translation to a variety of
25442 formats suitable for input to text formatters. A copy made in an
25443 otherwise Transparent file format whose markup, or absence of
25444 markup, has been arranged to thwart or discourage subsequent
25445 modification by readers is not Transparent. An image format is
25446 not Transparent if used for any substantial amount of text. A
25447 copy that is not "Transparent" is called "Opaque".
25449 Examples of suitable formats for Transparent copies include plain
25450 ASCII without markup, Texinfo input format, LaTeX input format,
25451 SGML or XML using a publicly available DTD, and
25452 standard-conforming simple HTML, PostScript or PDF designed for
25453 human modification. Examples of transparent image formats include
25454 PNG, XCF and JPG. Opaque formats include proprietary formats that
25455 can be read and edited only by proprietary word processors, SGML or
25456 XML for which the DTD and/or processing tools are not generally
25457 available, and the machine-generated HTML, PostScript or PDF
25458 produced by some word processors for output purposes only.
25460 The "Title Page" means, for a printed book, the title page itself,
25461 plus such following pages as are needed to hold, legibly, the
25462 material this License requires to appear in the title page. For
25463 works in formats which do not have any title page as such, "Title
25464 Page" means the text near the most prominent appearance of the
25465 work's title, preceding the beginning of the body of the text.
25467 A section "Entitled XYZ" means a named subunit of the Document
25468 whose title either is precisely XYZ or contains XYZ in parentheses
25469 following text that translates XYZ in another language. (Here XYZ
25470 stands for a specific section name mentioned below, such as
25471 "Acknowledgements", "Dedications", "Endorsements", or "History".)
25472 To "Preserve the Title" of such a section when you modify the
25473 Document means that it remains a section "Entitled XYZ" according
25474 to this definition.
25476 The Document may include Warranty Disclaimers next to the notice
25477 which states that this License applies to the Document. These
25478 Warranty Disclaimers are considered to be included by reference in
25479 this License, but only as regards disclaiming warranties: any other
25480 implication that these Warranty Disclaimers may have is void and
25481 has no effect on the meaning of this License.
25483 2. VERBATIM COPYING
25485 You may copy and distribute the Document in any medium, either
25486 commercially or noncommercially, provided that this License, the
25487 copyright notices, and the license notice saying this License
25488 applies to the Document are reproduced in all copies, and that you
25489 add no other conditions whatsoever to those of this License. You
25490 may not use technical measures to obstruct or control the reading
25491 or further copying of the copies you make or distribute. However,
25492 you may accept compensation in exchange for copies. If you
25493 distribute a large enough number of copies you must also follow
25494 the conditions in section 3.
25496 You may also lend copies, under the same conditions stated above,
25497 and you may publicly display copies.
25499 3. COPYING IN QUANTITY
25501 If you publish printed copies (or copies in media that commonly
25502 have printed covers) of the Document, numbering more than 100, and
25503 the Document's license notice requires Cover Texts, you must
25504 enclose the copies in covers that carry, clearly and legibly, all
25505 these Cover Texts: Front-Cover Texts on the front cover, and
25506 Back-Cover Texts on the back cover. Both covers must also clearly
25507 and legibly identify you as the publisher of these copies. The
25508 front cover must present the full title with all words of the
25509 title equally prominent and visible. You may add other material
25510 on the covers in addition. Copying with changes limited to the
25511 covers, as long as they preserve the title of the Document and
25512 satisfy these conditions, can be treated as verbatim copying in
25515 If the required texts for either cover are too voluminous to fit
25516 legibly, you should put the first ones listed (as many as fit
25517 reasonably) on the actual cover, and continue the rest onto
25520 If you publish or distribute Opaque copies of the Document
25521 numbering more than 100, you must either include a
25522 machine-readable Transparent copy along with each Opaque copy, or
25523 state in or with each Opaque copy a computer-network location from
25524 which the general network-using public has access to download
25525 using public-standard network protocols a complete Transparent
25526 copy of the Document, free of added material. If you use the
25527 latter option, you must take reasonably prudent steps, when you
25528 begin distribution of Opaque copies in quantity, to ensure that
25529 this Transparent copy will remain thus accessible at the stated
25530 location until at least one year after the last time you
25531 distribute an Opaque copy (directly or through your agents or
25532 retailers) of that edition to the public.
25534 It is requested, but not required, that you contact the authors of
25535 the Document well before redistributing any large number of
25536 copies, to give them a chance to provide you with an updated
25537 version of the Document.
25541 You may copy and distribute a Modified Version of the Document
25542 under the conditions of sections 2 and 3 above, provided that you
25543 release the Modified Version under precisely this License, with
25544 the Modified Version filling the role of the Document, thus
25545 licensing distribution and modification of the Modified Version to
25546 whoever possesses a copy of it. In addition, you must do these
25547 things in the Modified Version:
25549 A. Use in the Title Page (and on the covers, if any) a title
25550 distinct from that of the Document, and from those of
25551 previous versions (which should, if there were any, be listed
25552 in the History section of the Document). You may use the
25553 same title as a previous version if the original publisher of
25554 that version gives permission.
25556 B. List on the Title Page, as authors, one or more persons or
25557 entities responsible for authorship of the modifications in
25558 the Modified Version, together with at least five of the
25559 principal authors of the Document (all of its principal
25560 authors, if it has fewer than five), unless they release you
25561 from this requirement.
25563 C. State on the Title page the name of the publisher of the
25564 Modified Version, as the publisher.
25566 D. Preserve all the copyright notices of the Document.
25568 E. Add an appropriate copyright notice for your modifications
25569 adjacent to the other copyright notices.
25571 F. Include, immediately after the copyright notices, a license
25572 notice giving the public permission to use the Modified
25573 Version under the terms of this License, in the form shown in
25574 the Addendum below.
25576 G. Preserve in that license notice the full lists of Invariant
25577 Sections and required Cover Texts given in the Document's
25580 H. Include an unaltered copy of this License.
25582 I. Preserve the section Entitled "History", Preserve its Title,
25583 and add to it an item stating at least the title, year, new
25584 authors, and publisher of the Modified Version as given on
25585 the Title Page. If there is no section Entitled "History" in
25586 the Document, create one stating the title, year, authors,
25587 and publisher of the Document as given on its Title Page,
25588 then add an item describing the Modified Version as stated in
25589 the previous sentence.
25591 J. Preserve the network location, if any, given in the Document
25592 for public access to a Transparent copy of the Document, and
25593 likewise the network locations given in the Document for
25594 previous versions it was based on. These may be placed in
25595 the "History" section. You may omit a network location for a
25596 work that was published at least four years before the
25597 Document itself, or if the original publisher of the version
25598 it refers to gives permission.
25600 K. For any section Entitled "Acknowledgements" or "Dedications",
25601 Preserve the Title of the section, and preserve in the
25602 section all the substance and tone of each of the contributor
25603 acknowledgements and/or dedications given therein.
25605 L. Preserve all the Invariant Sections of the Document,
25606 unaltered in their text and in their titles. Section numbers
25607 or the equivalent are not considered part of the section
25610 M. Delete any section Entitled "Endorsements". Such a section
25611 may not be included in the Modified Version.
25613 N. Do not retitle any existing section to be Entitled
25614 "Endorsements" or to conflict in title with any Invariant
25617 O. Preserve any Warranty Disclaimers.
25619 If the Modified Version includes new front-matter sections or
25620 appendices that qualify as Secondary Sections and contain no
25621 material copied from the Document, you may at your option
25622 designate some or all of these sections as invariant. To do this,
25623 add their titles to the list of Invariant Sections in the Modified
25624 Version's license notice. These titles must be distinct from any
25625 other section titles.
25627 You may add a section Entitled "Endorsements", provided it contains
25628 nothing but endorsements of your Modified Version by various
25629 parties--for example, statements of peer review or that the text
25630 has been approved by an organization as the authoritative
25631 definition of a standard.
25633 You may add a passage of up to five words as a Front-Cover Text,
25634 and a passage of up to 25 words as a Back-Cover Text, to the end
25635 of the list of Cover Texts in the Modified Version. Only one
25636 passage of Front-Cover Text and one of Back-Cover Text may be
25637 added by (or through arrangements made by) any one entity. If the
25638 Document already includes a cover text for the same cover,
25639 previously added by you or by arrangement made by the same entity
25640 you are acting on behalf of, you may not add another; but you may
25641 replace the old one, on explicit permission from the previous
25642 publisher that added the old one.
25644 The author(s) and publisher(s) of the Document do not by this
25645 License give permission to use their names for publicity for or to
25646 assert or imply endorsement of any Modified Version.
25648 5. COMBINING DOCUMENTS
25650 You may combine the Document with other documents released under
25651 this License, under the terms defined in section 4 above for
25652 modified versions, provided that you include in the combination
25653 all of the Invariant Sections of all of the original documents,
25654 unmodified, and list them all as Invariant Sections of your
25655 combined work in its license notice, and that you preserve all
25656 their Warranty Disclaimers.
25658 The combined work need only contain one copy of this License, and
25659 multiple identical Invariant Sections may be replaced with a single
25660 copy. If there are multiple Invariant Sections with the same name
25661 but different contents, make the title of each such section unique
25662 by adding at the end of it, in parentheses, the name of the
25663 original author or publisher of that section if known, or else a
25664 unique number. Make the same adjustment to the section titles in
25665 the list of Invariant Sections in the license notice of the
25668 In the combination, you must combine any sections Entitled
25669 "History" in the various original documents, forming one section
25670 Entitled "History"; likewise combine any sections Entitled
25671 "Acknowledgements", and any sections Entitled "Dedications". You
25672 must delete all sections Entitled "Endorsements."
25674 6. COLLECTIONS OF DOCUMENTS
25676 You may make a collection consisting of the Document and other
25677 documents released under this License, and replace the individual
25678 copies of this License in the various documents with a single copy
25679 that is included in the collection, provided that you follow the
25680 rules of this License for verbatim copying of each of the
25681 documents in all other respects.
25683 You may extract a single document from such a collection, and
25684 distribute it individually under this License, provided you insert
25685 a copy of this License into the extracted document, and follow
25686 this License in all other respects regarding verbatim copying of
25689 7. AGGREGATION WITH INDEPENDENT WORKS
25691 A compilation of the Document or its derivatives with other
25692 separate and independent documents or works, in or on a volume of
25693 a storage or distribution medium, is called an "aggregate" if the
25694 copyright resulting from the compilation is not used to limit the
25695 legal rights of the compilation's users beyond what the individual
25696 works permit. When the Document is included an aggregate, this
25697 License does not apply to the other works in the aggregate which
25698 are not themselves derivative works of the Document.
25700 If the Cover Text requirement of section 3 is applicable to these
25701 copies of the Document, then if the Document is less than one half
25702 of the entire aggregate, the Document's Cover Texts may be placed
25703 on covers that bracket the Document within the aggregate, or the
25704 electronic equivalent of covers if the Document is in electronic
25705 form. Otherwise they must appear on printed covers that bracket
25706 the whole aggregate.
25710 Translation is considered a kind of modification, so you may
25711 distribute translations of the Document under the terms of section
25712 4. Replacing Invariant Sections with translations requires special
25713 permission from their copyright holders, but you may include
25714 translations of some or all Invariant Sections in addition to the
25715 original versions of these Invariant Sections. You may include a
25716 translation of this License, and all the license notices in the
25717 Document, and any Warrany Disclaimers, provided that you also
25718 include the original English version of this License and the
25719 original versions of those notices and disclaimers. In case of a
25720 disagreement between the translation and the original version of
25721 this License or a notice or disclaimer, the original version will
25724 If a section in the Document is Entitled "Acknowledgements",
25725 "Dedications", or "History", the requirement (section 4) to
25726 Preserve its Title (section 1) will typically require changing the
25731 You may not copy, modify, sublicense, or distribute the Document
25732 except as expressly provided for under this License. Any other
25733 attempt to copy, modify, sublicense or distribute the Document is
25734 void, and will automatically terminate your rights under this
25735 License. However, parties who have received copies, or rights,
25736 from you under this License will not have their licenses
25737 terminated so long as such parties remain in full compliance.
25739 10. FUTURE REVISIONS OF THIS LICENSE
25741 The Free Software Foundation may publish new, revised versions of
25742 the GNU Free Documentation License from time to time. Such new
25743 versions will be similar in spirit to the present version, but may
25744 differ in detail to address new problems or concerns. See
25745 `http://www.gnu.org/copyleft/'.
25747 Each version of the License is given a distinguishing version
25748 number. If the Document specifies that a particular numbered
25749 version of this License "or any later version" applies to it, you
25750 have the option of following the terms and conditions either of
25751 that specified version or of any later version that has been
25752 published (not as a draft) by the Free Software Foundation. If
25753 the Document does not specify a version number of this License,
25754 you may choose any version ever published (not as a draft) by the
25755 Free Software Foundation.
25757 ADDENDUM: How to use this License for your documents
25758 ====================================================
25760 To use this License in a document you have written, include a copy of
25761 the License in the document and put the following copyright and license
25762 notices just after the title page:
25764 Copyright (C) YEAR YOUR NAME.
25765 Permission is granted to copy, distribute and/or modify this document
25766 under the terms of the GNU Free Documentation License, Version 1.2
25767 or any later version published by the Free Software Foundation;
25768 with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
25769 A copy of the license is included in the section entitled ``GNU
25770 Free Documentation License''.
25772 If you have Invariant Sections, Front-Cover Texts and Back-Cover Texts,
25773 replace the "with...Texts." line with this:
25775 with the Invariant Sections being LIST THEIR TITLES, with
25776 the Front-Cover Texts being LIST, and with the Back-Cover Texts
25779 If you have Invariant Sections without Cover Texts, or some other
25780 combination of the three, merge those two alternatives to suit the
25783 If your document contains nontrivial examples of program code, we
25784 recommend releasing these examples in parallel under your choice of
25785 free software license, such as the GNU General Public License, to
25786 permit their use in free software.
25789 File: gcc.info, Node: Contributors, Next: Option Index, Prev: GNU Free Documentation License, Up: Top
25791 Contributors to GCC
25792 *******************
25794 The GCC project would like to thank its many contributors. Without
25795 them the project would not have been nearly as successful as it has
25796 been. Any omissions in this list are accidental. Feel free to contact
25797 <law@redhat.com> or <gerald@pfeifer.com> if you have been left out or
25798 some of your contributions are not listed. Please keep this list in
25799 alphabetical order.
25801 * Analog Devices helped implement the support for complex data types
25804 * John David Anglin for threading-related fixes and improvements to
25805 libstdc++-v3, and the HP-UX port.
25807 * James van Artsdalen wrote the code that makes efficient use of the
25808 Intel 80387 register stack.
25810 * Abramo and Roberto Bagnara for the SysV68 Motorola 3300 Delta
25813 * Alasdair Baird for various bug fixes.
25815 * Giovanni Bajo for analyzing lots of complicated C++ problem
25818 * Peter Barada for his work to improve code generation for new
25821 * Gerald Baumgartner added the signature extension to the C++ front
25824 * Godmar Back for his Java improvements and encouragement.
25826 * Scott Bambrough for help porting the Java compiler.
25828 * Wolfgang Bangerth for processing tons of bug reports.
25830 * Jon Beniston for his Microsoft Windows port of Java.
25832 * Daniel Berlin for better DWARF2 support, faster/better
25833 optimizations, improved alias analysis, plus migrating GCC to
25836 * Geoff Berry for his Java object serialization work and various
25839 * Eric Blake for helping to make GCJ and libgcj conform to the
25842 * Janne Blomqvist for contributions to gfortran.
25844 * Segher Boessenkool for various fixes.
25846 * Hans-J. Boehm for his garbage collector, IA-64 libffi port, and
25849 * Neil Booth for work on cpplib, lang hooks, debug hooks and other
25850 miscellaneous clean-ups.
25852 * Steven Bosscher for integrating the gfortran front end into GCC
25853 and for contributing to the tree-ssa branch.
25855 * Eric Botcazou for fixing middle- and backend bugs left and right.
25857 * Per Bothner for his direction via the steering committee and
25858 various improvements to the infrastructure for supporting new
25859 languages. Chill front end implementation. Initial
25860 implementations of cpplib, fix-header, config.guess, libio, and
25861 past C++ library (libg++) maintainer. Dreaming up, designing and
25862 implementing much of GCJ.
25864 * Devon Bowen helped port GCC to the Tahoe.
25866 * Don Bowman for mips-vxworks contributions.
25868 * Dave Brolley for work on cpplib and Chill.
25870 * Paul Brook for work on the ARM architecture and maintaining
25873 * Robert Brown implemented the support for Encore 32000 systems.
25875 * Christian Bruel for improvements to local store elimination.
25877 * Herman A.J. ten Brugge for various fixes.
25879 * Joerg Brunsmann for Java compiler hacking and help with the GCJ
25882 * Joe Buck for his direction via the steering committee.
25884 * Craig Burley for leadership of the G77 Fortran effort.
25886 * Stephan Buys for contributing Doxygen notes for libstdc++.
25888 * Paolo Carlini for libstdc++ work: lots of efficiency improvements
25889 to the C++ strings, streambufs and formatted I/O, hard detective
25890 work on the frustrating localization issues, and keeping up with
25891 the problem reports.
25893 * John Carr for his alias work, SPARC hacking, infrastructure
25894 improvements, previous contributions to the steering committee,
25895 loop optimizations, etc.
25897 * Stephane Carrez for 68HC11 and 68HC12 ports.
25899 * Steve Chamberlain for support for the Renesas SH and H8 processors
25900 and the PicoJava processor, and for GCJ config fixes.
25902 * Glenn Chambers for help with the GCJ FAQ.
25904 * John-Marc Chandonia for various libgcj patches.
25906 * Scott Christley for his Objective-C contributions.
25908 * Eric Christopher for his Java porting help and clean-ups.
25910 * Branko Cibej for more warning contributions.
25912 * The GNU Classpath project for all of their merged runtime code.
25914 * Nick Clifton for arm, mcore, fr30, v850, m32r work, `--help', and
25915 other random hacking.
25917 * Michael Cook for libstdc++ cleanup patches to reduce warnings.
25919 * R. Kelley Cook for making GCC buildable from a read-only directory
25920 as well as other miscellaneous build process and documentation
25923 * Ralf Corsepius for SH testing and minor bugfixing.
25925 * Stan Cox for care and feeding of the x86 port and lots of behind
25926 the scenes hacking.
25928 * Alex Crain provided changes for the 3b1.
25930 * Ian Dall for major improvements to the NS32k port.
25932 * Paul Dale for his work to add uClinux platform support to the m68k
25935 * Dario Dariol contributed the four varieties of sample programs
25936 that print a copy of their source.
25938 * Russell Davidson for fstream and stringstream fixes in libstdc++.
25940 * Bud Davis for work on the G77 and gfortran compilers.
25942 * Mo DeJong for GCJ and libgcj bug fixes.
25944 * DJ Delorie for the DJGPP port, build and libiberty maintenance, and
25947 * Arnaud Desitter for helping to debug gfortran.
25949 * Gabriel Dos Reis for contributions to G++, contributions and
25950 maintenance of GCC diagnostics infrastructure, libstdc++-v3,
25951 including `valarray<>', `complex<>', maintaining the numerics
25952 library (including that pesky `<limits>' :-) and keeping
25953 up-to-date anything to do with numbers.
25955 * Ulrich Drepper for his work on glibc, testing of GCC using glibc,
25956 ISO C99 support, CFG dumping support, etc., plus support of the
25957 C++ runtime libraries including for all kinds of C interface
25958 issues, contributing and maintaining `complex<>', sanity checking
25959 and disbursement, configuration architecture, libio maintenance,
25960 and early math work.
25962 * Zdenek Dvorak for a new loop unroller and various fixes.
25964 * Richard Earnshaw for his ongoing work with the ARM.
25966 * David Edelsohn for his direction via the steering committee,
25967 ongoing work with the RS6000/PowerPC port, help cleaning up Haifa
25968 loop changes, doing the entire AIX port of libstdc++ with his bare
25969 hands, and for ensuring GCC properly keeps working on AIX.
25971 * Kevin Ediger for the floating point formatting of num_put::do_put
25974 * Phil Edwards for libstdc++ work including configuration hackery,
25975 documentation maintainer, chief breaker of the web pages, the
25976 occasional iostream bug fix, and work on shared library symbol
25979 * Paul Eggert for random hacking all over GCC.
25981 * Mark Elbrecht for various DJGPP improvements, and for libstdc++
25982 configuration support for locales and fstream-related fixes.
25984 * Vadim Egorov for libstdc++ fixes in strings, streambufs, and
25987 * Christian Ehrhardt for dealing with bug reports.
25989 * Ben Elliston for his work to move the Objective-C runtime into its
25990 own subdirectory and for his work on autoconf.
25992 * Marc Espie for OpenBSD support.
25994 * Doug Evans for much of the global optimization framework, arc,
25995 m32r, and SPARC work.
25997 * Christopher Faylor for his work on the Cygwin port and for caring
25998 and feeding the gcc.gnu.org box and saving its users tons of spam.
26000 * Fred Fish for BeOS support and Ada fixes.
26002 * Ivan Fontes Garcia for the Portuguese translation of the GCJ FAQ.
26004 * Peter Gerwinski for various bug fixes and the Pascal front end.
26006 * Kaveh Ghazi for his direction via the steering committee, amazing
26007 work to make `-W -Wall' useful, and continuously testing GCC on a
26008 plethora of platforms.
26010 * John Gilmore for a donation to the FSF earmarked improving GNU
26013 * Judy Goldberg for c++ contributions.
26015 * Torbjorn Granlund for various fixes and the c-torture testsuite,
26016 multiply- and divide-by-constant optimization, improved long long
26017 support, improved leaf function register allocation, and his
26018 direction via the steering committee.
26020 * Anthony Green for his `-Os' contributions and Java front end work.
26022 * Stu Grossman for gdb hacking, allowing GCJ developers to debug
26025 * Michael K. Gschwind contributed the port to the PDP-11.
26027 * Ron Guilmette implemented the `protoize' and `unprotoize' tools,
26028 the support for Dwarf symbolic debugging information, and much of
26029 the support for System V Release 4. He has also worked heavily on
26030 the Intel 386 and 860 support.
26032 * Bruno Haible for improvements in the runtime overhead for EH, new
26033 warnings and assorted bug fixes.
26035 * Andrew Haley for his amazing Java compiler and library efforts.
26037 * Chris Hanson assisted in making GCC work on HP-UX for the 9000
26040 * Michael Hayes for various thankless work he's done trying to get
26041 the c30/c40 ports functional. Lots of loop and unroll
26042 improvements and fixes.
26044 * Dara Hazeghi for wading through myriads of target-specific bug
26047 * Kate Hedstrom for staking the G77 folks with an initial testsuite.
26049 * Richard Henderson for his ongoing SPARC, alpha, ia32, and ia64
26050 work, loop opts, and generally fixing lots of old problems we've
26051 ignored for years, flow rewrite and lots of further stuff,
26052 including reviewing tons of patches.
26054 * Aldy Hernandez for working on the PowerPC port, SIMD support, and
26057 * Nobuyuki Hikichi of Software Research Associates, Tokyo,
26058 contributed the support for the Sony NEWS machine.
26060 * Kazu Hirata for caring and feeding the Renesas H8/300 port and
26063 * Katherine Holcomb for work on gfortran.
26065 * Manfred Hollstein for his ongoing work to keep the m88k alive, lots
26066 of testing and bug fixing, particularly of GCC configury code.
26068 * Steve Holmgren for MachTen patches.
26070 * Jan Hubicka for his x86 port improvements.
26072 * Falk Hueffner for working on C and optimization bug reports.
26074 * Bernardo Innocenti for his m68k work, including merging of
26075 ColdFire improvements and uClinux support.
26077 * Christian Iseli for various bug fixes.
26079 * Kamil Iskra for general m68k hacking.
26081 * Lee Iverson for random fixes and MIPS testing.
26083 * Andreas Jaeger for testing and benchmarking of GCC and various bug
26086 * Jakub Jelinek for his SPARC work and sibling call optimizations as
26087 well as lots of bug fixes and test cases, and for improving the
26090 * Janis Johnson for ia64 testing and fixes, her quality improvement
26091 sidetracks, and web page maintenance.
26093 * Kean Johnston for SCO OpenServer support and various fixes.
26095 * Tim Josling for the sample language treelang based originally on
26096 Richard Kenner's "toy" language.
26098 * Nicolai Josuttis for additional libstdc++ documentation.
26100 * Klaus Kaempf for his ongoing work to make alpha-vms a viable
26103 * Steven G. Kargl for work on gfortran.
26105 * David Kashtan of SRI adapted GCC to VMS.
26107 * Ryszard Kabatek for many, many libstdc++ bug fixes and
26108 optimizations of strings, especially member functions, and for
26111 * Geoffrey Keating for his ongoing work to make the PPC work for
26112 GNU/Linux and his automatic regression tester.
26114 * Brendan Kehoe for his ongoing work with G++ and for a lot of early
26115 work in just about every part of libstdc++.
26117 * Oliver M. Kellogg of Deutsche Aerospace contributed the port to the
26120 * Richard Kenner of the New York University Ultracomputer Research
26121 Laboratory wrote the machine descriptions for the AMD 29000, the
26122 DEC Alpha, the IBM RT PC, and the IBM RS/6000 as well as the
26123 support for instruction attributes. He also made changes to
26124 better support RISC processors including changes to common
26125 subexpression elimination, strength reduction, function calling
26126 sequence handling, and condition code support, in addition to
26127 generalizing the code for frame pointer elimination and delay slot
26128 scheduling. Richard Kenner was also the head maintainer of GCC
26131 * Mumit Khan for various contributions to the Cygwin and Mingw32
26132 ports and maintaining binary releases for Microsoft Windows hosts,
26133 and for massive libstdc++ porting work to Cygwin/Mingw32.
26135 * Robin Kirkham for cpu32 support.
26137 * Mark Klein for PA improvements.
26139 * Thomas Koenig for various bug fixes.
26141 * Bruce Korb for the new and improved fixincludes code.
26143 * Benjamin Kosnik for his G++ work and for leading the libstdc++-v3
26146 * Charles LaBrec contributed the support for the Integrated Solutions
26149 * Jeff Law for his direction via the steering committee,
26150 coordinating the entire egcs project and GCC 2.95, rolling out
26151 snapshots and releases, handling merges from GCC2, reviewing tons
26152 of patches that might have fallen through the cracks else, and
26153 random but extensive hacking.
26155 * Marc Lehmann for his direction via the steering committee and
26156 helping with analysis and improvements of x86 performance.
26158 * Victor Leikehman for work on gfortran.
26160 * Ted Lemon wrote parts of the RTL reader and printer.
26162 * Kriang Lerdsuwanakij for C++ improvements including template as
26163 template parameter support, and many C++ fixes.
26165 * Warren Levy for tremendous work on libgcj (Java Runtime Library)
26166 and random work on the Java front end.
26168 * Alain Lichnewsky ported GCC to the MIPS CPU.
26170 * Oskar Liljeblad for hacking on AWT and his many Java bug reports
26173 * Robert Lipe for OpenServer support, new testsuites, testing, etc.
26175 * Weiwen Liu for testing and various bug fixes.
26177 * Dave Love for his ongoing work with the Fortran front end and
26180 * Martin von Lo"wis for internal consistency checking infrastructure,
26181 various C++ improvements including namespace support, and tons of
26182 assistance with libstdc++/compiler merges.
26184 * H.J. Lu for his previous contributions to the steering committee,
26185 many x86 bug reports, prototype patches, and keeping the GNU/Linux
26188 * Greg McGary for random fixes and (someday) bounded pointers.
26190 * Andrew MacLeod for his ongoing work in building a real EH system,
26191 various code generation improvements, work on the global
26194 * Vladimir Makarov for hacking some ugly i960 problems, PowerPC
26195 hacking improvements to compile-time performance, overall
26196 knowledge and direction in the area of instruction scheduling, and
26197 design and implementation of the automaton based instruction
26200 * Bob Manson for his behind the scenes work on dejagnu.
26202 * Philip Martin for lots of libstdc++ string and vector iterator
26203 fixes and improvements, and string clean up and testsuites.
26205 * All of the Mauve project contributors, for Java test code.
26207 * Bryce McKinlay for numerous GCJ and libgcj fixes and improvements.
26209 * Adam Megacz for his work on the Microsoft Windows port of GCJ.
26211 * Michael Meissner for LRS framework, ia32, m32r, v850, m88k, MIPS,
26212 powerpc, haifa, ECOFF debug support, and other assorted hacking.
26214 * Jason Merrill for his direction via the steering committee and
26215 leading the G++ effort.
26217 * David Miller for his direction via the steering committee, lots of
26218 SPARC work, improvements in jump.c and interfacing with the Linux
26221 * Gary Miller ported GCC to Charles River Data Systems machines.
26223 * Alfred Minarik for libstdc++ string and ios bug fixes, and turning
26224 the entire libstdc++ testsuite namespace-compatible.
26226 * Mark Mitchell for his direction via the steering committee,
26227 mountains of C++ work, load/store hoisting out of loops, alias
26228 analysis improvements, ISO C `restrict' support, and serving as
26229 release manager for GCC 3.x.
26231 * Alan Modra for various GNU/Linux bits and testing.
26233 * Toon Moene for his direction via the steering committee, Fortran
26234 maintenance, and his ongoing work to make us make Fortran run fast.
26236 * Jason Molenda for major help in the care and feeding of all the
26237 services on the gcc.gnu.org (formerly egcs.cygnus.com)
26238 machine--mail, web services, ftp services, etc etc. Doing all
26239 this work on scrap paper and the backs of envelopes would have
26242 * Catherine Moore for fixing various ugly problems we have sent her
26243 way, including the haifa bug which was killing the Alpha & PowerPC
26246 * Mike Moreton for his various Java patches.
26248 * David Mosberger-Tang for various Alpha improvements, and for the
26249 initial IA-64 port.
26251 * Stephen Moshier contributed the floating point emulator that
26252 assists in cross-compilation and permits support for floating
26253 point numbers wider than 64 bits and for ISO C99 support.
26255 * Bill Moyer for his behind the scenes work on various issues.
26257 * Philippe De Muyter for his work on the m68k port.
26259 * Joseph S. Myers for his work on the PDP-11 port, format checking
26260 and ISO C99 support, and continuous emphasis on (and contributions
26263 * Nathan Myers for his work on libstdc++-v3: architecture and
26264 authorship through the first three snapshots, including
26265 implementation of locale infrastructure, string, shadow C headers,
26266 and the initial project documentation (DESIGN, CHECKLIST, and so
26267 forth). Later, more work on MT-safe string and shadow headers.
26269 * Felix Natter for documentation on porting libstdc++.
26271 * Nathanael Nerode for cleaning up the configuration/build process.
26273 * NeXT, Inc. donated the front end that supports the Objective-C
26276 * Hans-Peter Nilsson for the CRIS and MMIX ports, improvements to
26277 the search engine setup, various documentation fixes and other
26280 * Geoff Noer for his work on getting cygwin native builds working.
26282 * Diego Novillo for his SPEC performance tracking web pages and
26283 assorted fixes in the middle end and various back ends.
26285 * David O'Brien for the FreeBSD/alpha, FreeBSD/AMD x86-64,
26286 FreeBSD/ARM, FreeBSD/PowerPC, and FreeBSD/SPARC64 ports and
26287 related infrastructure improvements.
26289 * Alexandre Oliva for various build infrastructure improvements,
26290 scripts and amazing testing work, including keeping libtool issues
26293 * Stefan Olsson for work on mt_alloc.
26295 * Melissa O'Neill for various NeXT fixes.
26297 * Rainer Orth for random MIPS work, including improvements to GCC's
26298 o32 ABI support, improvements to dejagnu's MIPS support, Java
26299 configuration clean-ups and porting work, etc.
26301 * Hartmut Penner for work on the s390 port.
26303 * Paul Petersen wrote the machine description for the Alliant FX/8.
26305 * Alexandre Petit-Bianco for implementing much of the Java compiler
26306 and continued Java maintainership.
26308 * Matthias Pfaller for major improvements to the NS32k port.
26310 * Gerald Pfeifer for his direction via the steering committee,
26311 pointing out lots of problems we need to solve, maintenance of the
26312 web pages, and taking care of documentation maintenance in general.
26314 * Andrew Pinski for processing bug reports by the dozen.
26316 * Ovidiu Predescu for his work on the Objective-C front end and
26319 * Jerry Quinn for major performance improvements in C++ formatted
26322 * Ken Raeburn for various improvements to checker, MIPS ports and
26323 various cleanups in the compiler.
26325 * Rolf W. Rasmussen for hacking on AWT.
26327 * David Reese of Sun Microsystems contributed to the Solaris on
26330 * Volker Reichelt for keeping up with the problem reports.
26332 * Joern Rennecke for maintaining the sh port, loop, regmove & reload
26335 * Loren J. Rittle for improvements to libstdc++-v3 including the
26336 FreeBSD port, threading fixes, thread-related configury changes,
26337 critical threading documentation, and solutions to really tricky
26338 I/O problems, as well as keeping GCC properly working on FreeBSD
26339 and continuous testing.
26341 * Craig Rodrigues for processing tons of bug reports.
26343 * Ola Ro"nnerup for work on mt_alloc.
26345 * Gavin Romig-Koch for lots of behind the scenes MIPS work.
26347 * David Ronis inspired and encouraged Craig to rewrite the G77
26348 documentation in texinfo format by contributing a first pass at a
26349 translation of the old `g77-0.5.16/f/DOC' file.
26351 * Ken Rose for fixes to GCC's delay slot filling code.
26353 * Paul Rubin wrote most of the preprocessor.
26355 * Pe'tur Runo'lfsson for major performance improvements in C++
26356 formatted I/O and large file support in C++ filebuf.
26358 * Chip Salzenberg for libstdc++ patches and improvements to locales,
26359 traits, Makefiles, libio, libtool hackery, and "long long" support.
26361 * Juha Sarlin for improvements to the H8 code generator.
26363 * Greg Satz assisted in making GCC work on HP-UX for the 9000 series
26366 * Roger Sayle for improvements to constant folding and GCC's RTL
26367 optimizers as well as for fixing numerous bugs.
26369 * Bradley Schatz for his work on the GCJ FAQ.
26371 * Peter Schauer wrote the code to allow debugging to work on the
26374 * William Schelter did most of the work on the Intel 80386 support.
26376 * Tobias Schlu"ter for work on gfortran.
26378 * Bernd Schmidt for various code generation improvements and major
26379 work in the reload pass as well a serving as release manager for
26382 * Peter Schmid for constant testing of libstdc++--especially
26383 application testing, going above and beyond what was requested for
26384 the release criteria--and libstdc++ header file tweaks.
26386 * Jason Schroeder for jcf-dump patches.
26388 * Andreas Schwab for his work on the m68k port.
26390 * Lars Segerlund for work on gfortran.
26392 * Joel Sherrill for his direction via the steering committee, RTEMS
26393 contributions and RTEMS testing.
26395 * Nathan Sidwell for many C++ fixes/improvements.
26397 * Jeffrey Siegal for helping RMS with the original design of GCC,
26398 some code which handles the parse tree and RTL data structures,
26399 constant folding and help with the original VAX & m68k ports.
26401 * Kenny Simpson for prompting libstdc++ fixes due to defect reports
26402 from the LWG (thereby keeping GCC in line with updates from the
26405 * Franz Sirl for his ongoing work with making the PPC port stable
26408 * Andrey Slepuhin for assorted AIX hacking.
26410 * Christopher Smith did the port for Convex machines.
26412 * Danny Smith for his major efforts on the Mingw (and Cygwin) ports.
26414 * Randy Smith finished the Sun FPA support.
26416 * Scott Snyder for queue, iterator, istream, and string fixes and
26417 libstdc++ testsuite entries. Also for providing the patch to G77
26418 to add rudimentary support for `INTEGER*1', `INTEGER*2', and
26421 * Brad Spencer for contributions to the GLIBCPP_FORCE_NEW technique.
26423 * Richard Stallman, for writing the original GCC and launching the
26426 * Jan Stein of the Chalmers Computer Society provided support for
26427 Genix, as well as part of the 32000 machine description.
26429 * Nigel Stephens for various mips16 related fixes/improvements.
26431 * Jonathan Stone wrote the machine description for the Pyramid
26434 * Graham Stott for various infrastructure improvements.
26436 * John Stracke for his Java HTTP protocol fixes.
26438 * Mike Stump for his Elxsi port, G++ contributions over the years
26439 and more recently his vxworks contributions
26441 * Jeff Sturm for Java porting help, bug fixes, and encouragement.
26443 * Shigeya Suzuki for this fixes for the bsdi platforms.
26445 * Ian Lance Taylor for his mips16 work, general configury hacking,
26448 * Holger Teutsch provided the support for the Clipper CPU.
26450 * Gary Thomas for his ongoing work to make the PPC work for
26453 * Philipp Thomas for random bug fixes throughout the compiler
26455 * Jason Thorpe for thread support in libstdc++ on NetBSD.
26457 * Kresten Krab Thorup wrote the run time support for the Objective-C
26458 language and the fantastic Java bytecode interpreter.
26460 * Michael Tiemann for random bug fixes, the first instruction
26461 scheduler, initial C++ support, function integration, NS32k, SPARC
26462 and M88k machine description work, delay slot scheduling.
26464 * Andreas Tobler for his work porting libgcj to Darwin.
26466 * Teemu Torma for thread safe exception handling support.
26468 * Leonard Tower wrote parts of the parser, RTL generator, and RTL
26469 definitions, and of the VAX machine description.
26471 * Tom Tromey for internationalization support and for his many Java
26472 contributions and libgcj maintainership.
26474 * Lassi Tuura for improvements to config.guess to determine HP
26477 * Petter Urkedal for libstdc++ CXXFLAGS, math, and algorithms fixes.
26479 * Andy Vaught for the design and initial implementation of the
26480 gfortran front end.
26482 * Brent Verner for work with the libstdc++ cshadow files and their
26483 associated configure steps.
26485 * Todd Vierling for contributions for NetBSD ports.
26487 * Jonathan Wakely for contributing libstdc++ Doxygen notes and XHTML
26490 * Dean Wakerley for converting the install documentation from HTML
26491 to texinfo in time for GCC 3.0.
26493 * Krister Walfridsson for random bug fixes.
26495 * Feng Wang for contributions to gfortran.
26497 * Stephen M. Webb for time and effort on making libstdc++ shadow
26498 files work with the tricky Solaris 8+ headers, and for pushing the
26499 build-time header tree.
26501 * John Wehle for various improvements for the x86 code generator,
26502 related infrastructure improvements to help x86 code generation,
26503 value range propagation and other work, WE32k port.
26505 * Ulrich Weigand for work on the s390 port.
26507 * Zack Weinberg for major work on cpplib and various other bug fixes.
26509 * Matt Welsh for help with Linux Threads support in GCJ.
26511 * Urban Widmark for help fixing java.io.
26513 * Mark Wielaard for new Java library code and his work integrating
26516 * Dale Wiles helped port GCC to the Tahoe.
26518 * Bob Wilson from Tensilica, Inc. for the Xtensa port.
26520 * Jim Wilson for his direction via the steering committee, tackling
26521 hard problems in various places that nobody else wanted to work
26522 on, strength reduction and other loop optimizations.
26524 * Carlo Wood for various fixes.
26526 * Tom Wood for work on the m88k port.
26528 * Canqun Yang for work on gfortran.
26530 * Masanobu Yuhara of Fujitsu Laboratories implemented the machine
26531 description for the Tron architecture (specifically, the Gmicro).
26533 * Kevin Zachmann helped port GCC to the Tahoe.
26535 * Xiaoqiang Zhang for work on gfortran.
26537 * Gilles Zunino for help porting Java to Irix.
26540 The following people are recognized for their contributions to GNAT,
26541 the Ada front end of GCC:
26544 * Romain Berrendonner
26594 * Hristian Kirtchev
26637 In addition to the above, all of which also contributed time and
26638 energy in testing GCC, we would like to thank the following for their
26639 contributions to testing:
26641 * Michael Abd-El-Malek
26651 * David Billinghurst
26655 * Stephane Bortzmeyer
26665 * Bradford Castalia
26685 * Charles-Antoine Gauthier
26707 * Kevin B. Hendricks
26711 * Christian Joensson
26719 * Anand Krishnaswamy
26721 * A. O. V. Le Blanc
26785 * Pedro A. M. Vazquez
26795 And finally we'd like to thank everyone who uses the compiler, submits
26796 bug reports and generally reminds us why we're doing this work in the
26800 File: gcc.info, Node: Option Index, Next: Keyword Index, Prev: Contributors, Up: Top
26805 GCC's command line options are indexed here without any initial `-' or
26806 `--'. Where an option has both positive and negative forms (such as
26807 `-fOPTION' and `-fno-OPTION'), relevant entries in the manual are
26808 indexed under the most appropriate form; it may sometimes be useful to
26809 look up both forms.
26814 * ###: Overall Options. (line 184)
26815 * -dynamiclib: Darwin Options. (line 108)
26816 * -force_cpusubtype_ALL: Darwin Options. (line 113)
26817 * -fsplit-ivs-in-unroller: Optimize Options. (line 695)
26818 * -fvariable-expansion-in-unroller: Optimize Options. (line 710)
26819 * -gfull: Darwin Options. (line 64)
26820 * -gused: Darwin Options. (line 59)
26821 * -mone-byte-bool: Darwin Options. (line 67)
26822 * A: Preprocessor Options.
26824 * all_load: Darwin Options. (line 87)
26825 * allowable_client: Darwin Options. (line 174)
26826 * ansi <1>: Non-bugs. (line 107)
26827 * ansi <2>: Other Builtins. (line 22)
26828 * ansi <3>: Preprocessor Options.
26830 * ansi <4>: C Dialect Options. (line 11)
26831 * ansi: Standards. (line 13)
26832 * arch_errors_fatal: Darwin Options. (line 91)
26833 * aux-info: C Dialect Options. (line 98)
26834 * b: Target Options. (line 13)
26835 * B: Directory Options. (line 41)
26836 * bcopy-builtin: PDP-11 Options. (line 32)
26837 * bind_at_load: Darwin Options. (line 95)
26838 * bundle: Darwin Options. (line 100)
26839 * bundle_loader: Darwin Options. (line 104)
26840 * c: Link Options. (line 20)
26841 * C: Preprocessor Options.
26843 * c: Overall Options. (line 139)
26844 * client_name: Darwin Options. (line 174)
26845 * combine: Overall Options. (line 195)
26846 * compatibility_version: Darwin Options. (line 174)
26847 * crossjumping: Optimize Options. (line 436)
26848 * current_version: Darwin Options. (line 174)
26849 * D: Preprocessor Options.
26851 * d: Debugging Options. (line 216)
26852 * da: Debugging Options. (line 387)
26853 * dA: Debugging Options. (line 229)
26854 * dB: Debugging Options. (line 238)
26855 * db: Debugging Options. (line 234)
26856 * dC: Debugging Options. (line 248)
26857 * dc: Debugging Options. (line 242)
26858 * dD <1>: Preprocessor Options.
26860 * dD: Debugging Options. (line 262)
26861 * dd: Debugging Options. (line 256)
26862 * dE: Debugging Options. (line 267)
26863 * dead_strip: Darwin Options. (line 174)
26864 * dependency-file: Darwin Options. (line 174)
26865 * df: Debugging Options. (line 272)
26866 * dG: Debugging Options. (line 284)
26867 * dg: Debugging Options. (line 279)
26868 * dH: Debugging Options. (line 390)
26869 * dh: Debugging Options. (line 291)
26870 * dI: Preprocessor Options.
26872 * di: Debugging Options. (line 295)
26873 * dj: Debugging Options. (line 299)
26874 * dk: Debugging Options. (line 303)
26875 * dL: Debugging Options. (line 313)
26876 * dl: Debugging Options. (line 308)
26877 * dM: Preprocessor Options.
26879 * dm: Debugging Options. (line 393)
26880 * dM: Debugging Options. (line 324)
26881 * dm: Debugging Options. (line 320)
26882 * dN <1>: Preprocessor Options.
26884 * dN: Debugging Options. (line 333)
26885 * dn: Debugging Options. (line 329)
26886 * do: Debugging Options. (line 337)
26887 * dP: Debugging Options. (line 402)
26888 * dp: Debugging Options. (line 397)
26889 * dR: Debugging Options. (line 345)
26890 * dr: Debugging Options. (line 341)
26891 * dS: Debugging Options. (line 354)
26892 * ds: Debugging Options. (line 349)
26893 * dT: Debugging Options. (line 363)
26894 * dt: Debugging Options. (line 358)
26895 * dumpmachine: Debugging Options. (line 719)
26896 * dumpspecs: Debugging Options. (line 727)
26897 * dumpversion: Debugging Options. (line 723)
26898 * dv: Debugging Options. (line 406)
26899 * dV: Debugging Options. (line 368)
26900 * dw: Debugging Options. (line 375)
26901 * dx: Debugging Options. (line 411)
26902 * dy: Debugging Options. (line 415)
26903 * dylib_file: Darwin Options. (line 174)
26904 * dylinker_install_name: Darwin Options. (line 174)
26905 * dynamic: Darwin Options. (line 174)
26906 * dZ: Debugging Options. (line 383)
26907 * dz: Debugging Options. (line 379)
26908 * E <1>: Link Options. (line 20)
26909 * E: Overall Options. (line 160)
26910 * EB <1>: MIPS Options. (line 7)
26911 * EB: ARC Options. (line 12)
26912 * EL <1>: MIPS Options. (line 10)
26913 * EL: ARC Options. (line 9)
26914 * exported_symbols_list: Darwin Options. (line 174)
26915 * F: Darwin Options. (line 32)
26916 * fabi-version: C++ Dialect Options.
26918 * falign-functions: Optimize Options. (line 823)
26919 * falign-jumps: Optimize Options. (line 873)
26920 * falign-labels: Optimize Options. (line 841)
26921 * falign-loops: Optimize Options. (line 859)
26922 * fargument-alias: Code Gen Options. (line 328)
26923 * fargument-noalias: Code Gen Options. (line 328)
26924 * fargument-noalias-global: Code Gen Options. (line 328)
26925 * fasynchronous-unwind-tables: Code Gen Options. (line 64)
26926 * fbounds-check <1>: Code Gen Options. (line 15)
26927 * fbounds-check: Optimize Options. (line 312)
26928 * fbranch-probabilities: Optimize Options. (line 1089)
26929 * fbranch-target-load-optimize: Optimize Options. (line 1221)
26930 * fbranch-target-load-optimize2: Optimize Options. (line 1227)
26931 * fbtr-bb-exclusive: Optimize Options. (line 1231)
26932 * fcall-saved <1>: Interoperation. (line 150)
26933 * fcall-saved: Code Gen Options. (line 230)
26934 * fcall-used: Code Gen Options. (line 216)
26935 * fcaller-saves: Optimize Options. (line 576)
26936 * fcheck-new: C++ Dialect Options.
26938 * fcommon: Variable Attributes.
26940 * fcond-mismatch: C Dialect Options. (line 208)
26941 * fconserve-space: C++ Dialect Options.
26943 * fconstant-string-class: Objective-C and Objective-C++ Dialect Options.
26945 * fcse-follow-jumps: Optimize Options. (line 355)
26946 * fcse-skip-blocks: Optimize Options. (line 364)
26947 * fcx-limited-range: Optimize Options. (line 1075)
26948 * fdata-sections: Optimize Options. (line 1202)
26949 * fdelayed-branch: Optimize Options. (line 489)
26950 * fdelete-null-pointer-checks: Optimize Options. (line 458)
26951 * fdiagnostics-show-location: Language Independent Options.
26953 * fdollars-in-identifiers <1>: Interoperation. (line 146)
26954 * fdollars-in-identifiers: Preprocessor Options.
26956 * fdump-class-hierarchy: Debugging Options. (line 434)
26957 * fdump-ipa: Debugging Options. (line 441)
26958 * fdump-rtl-all: Debugging Options. (line 387)
26959 * fdump-rtl-bbro: Debugging Options. (line 238)
26960 * fdump-rtl-bp: Debugging Options. (line 234)
26961 * fdump-rtl-btl: Debugging Options. (line 256)
26962 * fdump-rtl-bypass: Debugging Options. (line 284)
26963 * fdump-rtl-ce1: Debugging Options. (line 248)
26964 * fdump-rtl-ce2: Debugging Options. (line 248)
26965 * fdump-rtl-ce3: Debugging Options. (line 267)
26966 * fdump-rtl-cfg: Debugging Options. (line 272)
26967 * fdump-rtl-combine: Debugging Options. (line 242)
26968 * fdump-rtl-cse: Debugging Options. (line 349)
26969 * fdump-rtl-cse2: Debugging Options. (line 358)
26970 * fdump-rtl-dbr: Debugging Options. (line 256)
26971 * fdump-rtl-eh: Debugging Options. (line 291)
26972 * fdump-rtl-expand: Debugging Options. (line 341)
26973 * fdump-rtl-flow2: Debugging Options. (line 375)
26974 * fdump-rtl-gcse: Debugging Options. (line 284)
26975 * fdump-rtl-greg: Debugging Options. (line 279)
26976 * fdump-rtl-jump: Debugging Options. (line 299)
26977 * fdump-rtl-life: Debugging Options. (line 272)
26978 * fdump-rtl-loop: Debugging Options. (line 313)
26979 * fdump-rtl-loop2: Debugging Options. (line 313)
26980 * fdump-rtl-lreg: Debugging Options. (line 308)
26981 * fdump-rtl-mach: Debugging Options. (line 324)
26982 * fdump-rtl-peephole2: Debugging Options. (line 379)
26983 * fdump-rtl-postreload: Debugging Options. (line 337)
26984 * fdump-rtl-regmove: Debugging Options. (line 333)
26985 * fdump-rtl-rnreg: Debugging Options. (line 329)
26986 * fdump-rtl-sched: Debugging Options. (line 354)
26987 * fdump-rtl-sched2: Debugging Options. (line 345)
26988 * fdump-rtl-sibling: Debugging Options. (line 295)
26989 * fdump-rtl-sms: Debugging Options. (line 320)
26990 * fdump-rtl-stack: Debugging Options. (line 303)
26991 * fdump-rtl-tracer: Debugging Options. (line 363)
26992 * fdump-rtl-vartrack: Debugging Options. (line 368)
26993 * fdump-rtl-vpt: Debugging Options. (line 368)
26994 * fdump-rtl-web: Debugging Options. (line 383)
26995 * fdump-translation-unit: Debugging Options. (line 426)
26996 * fdump-tree: Debugging Options. (line 456)
26997 * fdump-tree-alias: Debugging Options. (line 539)
26998 * fdump-tree-all: Debugging Options. (line 604)
26999 * fdump-tree-ccp: Debugging Options. (line 543)
27000 * fdump-tree-cfg: Debugging Options. (line 519)
27001 * fdump-tree-ch: Debugging Options. (line 531)
27002 * fdump-tree-copyrename: Debugging Options. (line 589)
27003 * fdump-tree-dce: Debugging Options. (line 555)
27004 * fdump-tree-dom: Debugging Options. (line 569)
27005 * fdump-tree-dse: Debugging Options. (line 574)
27006 * fdump-tree-forwprop: Debugging Options. (line 584)
27007 * fdump-tree-fre: Debugging Options. (line 551)
27008 * fdump-tree-gimple: Debugging Options. (line 514)
27009 * fdump-tree-mudflap: Debugging Options. (line 559)
27010 * fdump-tree-nrv: Debugging Options. (line 594)
27011 * fdump-tree-phiopt: Debugging Options. (line 579)
27012 * fdump-tree-pre: Debugging Options. (line 547)
27013 * fdump-tree-sra: Debugging Options. (line 564)
27014 * fdump-tree-ssa: Debugging Options. (line 535)
27015 * fdump-tree-vcg: Debugging Options. (line 523)
27016 * fdump-tree-vect: Debugging Options. (line 599)
27017 * fdump-unnumbered: Debugging Options. (line 418)
27018 * feliminate-dwarf2-dups: Debugging Options. (line 117)
27019 * feliminate-unused-debug-symbols: Debugging Options. (line 52)
27020 * feliminate-unused-debug-types: Debugging Options. (line 731)
27021 * fexceptions: Code Gen Options. (line 34)
27022 * fexec-charset: Preprocessor Options.
27024 * fexpensive-optimizations: Optimize Options. (line 471)
27025 * ffast-math: Optimize Options. (line 970)
27026 * ffinite-math-only: Optimize Options. (line 1010)
27027 * ffix-and-continue: Darwin Options. (line 81)
27028 * ffixed: Code Gen Options. (line 204)
27029 * ffloat-store <1>: Disappointments. (line 77)
27030 * ffloat-store: Optimize Options. (line 956)
27031 * ffor-scope: C++ Dialect Options.
27033 * fforce-addr: Optimize Options. (line 156)
27034 * fforce-mem: Optimize Options. (line 147)
27035 * ffreestanding <1>: Function Attributes.
27037 * ffreestanding <2>: Warning Options. (line 94)
27038 * ffreestanding <3>: C Dialect Options. (line 169)
27039 * ffreestanding: Standards. (line 81)
27040 * ffunction-sections: Optimize Options. (line 1202)
27041 * fgcse: Optimize Options. (line 383)
27042 * fgcse-after-reload: Optimize Options. (line 419)
27043 * fgcse-las: Optimize Options. (line 412)
27044 * fgcse-lm: Optimize Options. (line 394)
27045 * fgcse-sm: Optimize Options. (line 403)
27046 * fgnu-runtime: Objective-C and Objective-C++ Dialect Options.
27048 * fhosted: C Dialect Options. (line 162)
27049 * filelist: Darwin Options. (line 174)
27050 * findirect-data: Darwin Options. (line 81)
27051 * finhibit-size-directive: Code Gen Options. (line 154)
27052 * finline-functions: Optimize Options. (line 188)
27053 * finline-limit: Optimize Options. (line 199)
27054 * finput-charset: Preprocessor Options.
27056 * finstrument-functions <1>: Function Attributes.
27058 * finstrument-functions: Code Gen Options. (line 260)
27059 * fkeep-inline-functions <1>: Inline. (line 51)
27060 * fkeep-inline-functions: Optimize Options. (line 237)
27061 * fkeep-static-consts: Optimize Options. (line 244)
27062 * flat_namespace: Darwin Options. (line 174)
27063 * fleading-underscore: Code Gen Options. (line 343)
27064 * floop-optimize: Optimize Options. (line 424)
27065 * floop-optimize2: Optimize Options. (line 431)
27066 * fmem-report: Debugging Options. (line 142)
27067 * fmessage-length: Language Independent Options.
27069 * fmodulo-sched: Optimize Options. (line 273)
27070 * fmove-loop-invariants: Optimize Options. (line 1185)
27071 * fms-extensions <1>: Unnamed Fields. (line 37)
27072 * fms-extensions <2>: C++ Dialect Options.
27074 * fms-extensions: C Dialect Options. (line 179)
27075 * fmudflap: Optimize Options. (line 319)
27076 * fmudflapir: Optimize Options. (line 319)
27077 * fmudflapth: Optimize Options. (line 319)
27078 * fnext-runtime: Objective-C and Objective-C++ Dialect Options.
27080 * fno-access-control: C++ Dialect Options.
27082 * fno-asm: C Dialect Options. (line 114)
27083 * fno-branch-count-reg: Optimize Options. (line 278)
27084 * fno-builtin <1>: Other Builtins. (line 14)
27085 * fno-builtin <2>: Function Attributes.
27087 * fno-builtin <3>: Warning Options. (line 94)
27088 * fno-builtin: C Dialect Options. (line 128)
27089 * fno-common <1>: Variable Attributes.
27091 * fno-common: Code Gen Options. (line 142)
27092 * fno-const-strings: C++ Dialect Options.
27094 * fno-cprop-registers: Optimize Options. (line 928)
27095 * fno-cx-limited-range: Optimize Options. (line 1075)
27096 * fno-default-inline <1>: Inline. (line 46)
27097 * fno-default-inline <2>: Optimize Options. (line 132)
27098 * fno-default-inline: C++ Dialect Options.
27100 * fno-defer-pop: Optimize Options. (line 139)
27101 * fno-elide-constructors: C++ Dialect Options.
27103 * fno-enforce-eh-specs: C++ Dialect Options.
27105 * fno-for-scope: C++ Dialect Options.
27107 * fno-function-cse: Optimize Options. (line 289)
27108 * fno-gnu-keywords: C++ Dialect Options.
27110 * fno-guess-branch-probability: Optimize Options. (line 733)
27111 * fno-ident: Code Gen Options. (line 151)
27112 * fno-implement-inlines <1>: C++ Interface. (line 75)
27113 * fno-implement-inlines: C++ Dialect Options.
27115 * fno-implicit-inline-templates: C++ Dialect Options.
27117 * fno-implicit-templates <1>: Template Instantiation.
27119 * fno-implicit-templates: C++ Dialect Options.
27121 * fno-inline: Optimize Options. (line 182)
27122 * fno-math-errno: Optimize Options. (line 983)
27123 * fno-nil-receivers: Objective-C and Objective-C++ Dialect Options.
27125 * fno-nonansi-builtins: C++ Dialect Options.
27127 * fno-operator-names: C++ Dialect Options.
27129 * fno-optional-diags: C++ Dialect Options.
27131 * fno-peephole: Optimize Options. (line 724)
27132 * fno-peephole2: Optimize Options. (line 724)
27133 * fno-rtti: C++ Dialect Options.
27135 * fno-sched-interblock: Optimize Options. (line 515)
27136 * fno-sched-spec: Optimize Options. (line 520)
27137 * fno-show-column: Preprocessor Options.
27139 * fno-signed-bitfields: C Dialect Options. (line 241)
27140 * fno-stack-limit: Code Gen Options. (line 312)
27141 * fno-threadsafe-statics: C++ Dialect Options.
27143 * fno-trapping-math: Optimize Options. (line 1020)
27144 * fno-unsigned-bitfields: C Dialect Options. (line 241)
27145 * fno-weak: C++ Dialect Options.
27147 * fno-working-directory: Preprocessor Options.
27149 * fno-zero-initialized-in-bss: Optimize Options. (line 300)
27150 * fnon-call-exceptions: Code Gen Options. (line 48)
27151 * fobjc-exceptions: Objective-C and Objective-C++ Dialect Options.
27153 * fomit-frame-pointer: Optimize Options. (line 161)
27154 * foptimize-register-move: Optimize Options. (line 478)
27155 * foptimize-sibling-calls: Optimize Options. (line 177)
27156 * force_flat_namespace: Darwin Options. (line 174)
27157 * fpack-struct: Code Gen Options. (line 247)
27158 * fpcc-struct-return <1>: Incompatibilities. (line 170)
27159 * fpcc-struct-return: Code Gen Options. (line 70)
27160 * fpch-deps: Preprocessor Options.
27162 * fpch-preprocess: Preprocessor Options.
27164 * fpeel-loops: Optimize Options. (line 1177)
27165 * fpermissive: C++ Dialect Options.
27167 * fPIC: Code Gen Options. (line 188)
27168 * fpic: Code Gen Options. (line 170)
27169 * fPIE: Code Gen Options. (line 198)
27170 * fpie: Code Gen Options. (line 198)
27171 * fprefetch-loop-arrays: Optimize Options. (line 715)
27172 * fpreprocessed: Preprocessor Options.
27174 * fprofile-arcs <1>: Other Builtins. (line 236)
27175 * fprofile-arcs: Debugging Options. (line 146)
27176 * fprofile-generate: Optimize Options. (line 935)
27177 * fprofile-use: Optimize Options. (line 944)
27178 * fprofile-values: Optimize Options. (line 1108)
27179 * frandom-string: Debugging Options. (line 614)
27180 * freg-struct-return: Code Gen Options. (line 88)
27181 * fregmove: Optimize Options. (line 478)
27182 * frename-registers: Optimize Options. (line 1144)
27183 * freorder-blocks: Optimize Options. (line 750)
27184 * freorder-blocks-and-partition: Optimize Options. (line 756)
27185 * freorder-functions: Optimize Options. (line 767)
27186 * freplace-objc-classes: Objective-C and Objective-C++ Dialect Options.
27188 * frepo <1>: Template Instantiation.
27190 * frepo: C++ Dialect Options.
27192 * frerun-cse-after-loop: Optimize Options. (line 372)
27193 * frerun-loop-opt: Optimize Options. (line 378)
27194 * frounding-math: Optimize Options. (line 1035)
27195 * fsched-spec-load: Optimize Options. (line 525)
27196 * fsched-spec-load-dangerous: Optimize Options. (line 530)
27197 * fsched-stalled-insns: Optimize Options. (line 535)
27198 * fsched-stalled-insns-dep: Optimize Options. (line 540)
27199 * fsched-verbose: Debugging Options. (line 624)
27200 * fsched2-use-superblocks: Optimize Options. (line 547)
27201 * fsched2-use-traces: Optimize Options. (line 558)
27202 * fschedule-insns: Optimize Options. (line 496)
27203 * fschedule-insns2: Optimize Options. (line 506)
27204 * fscheduling-in-modulo-scheduled-loops: Optimize Options. (line 570)
27205 * fshared-data: Code Gen Options. (line 135)
27206 * fshort-double: Code Gen Options. (line 117)
27207 * fshort-enums <1>: Non-bugs. (line 42)
27208 * fshort-enums <2>: Type Attributes. (line 112)
27209 * fshort-enums <3>: Structures unions enumerations and bit-fields implementation.
27211 * fshort-enums: Code Gen Options. (line 106)
27212 * fshort-wchar: Code Gen Options. (line 125)
27213 * fsignaling-nans: Optimize Options. (line 1055)
27214 * fsigned-bitfields <1>: Non-bugs. (line 57)
27215 * fsigned-bitfields: C Dialect Options. (line 241)
27216 * fsigned-char <1>: Characters implementation.
27218 * fsigned-char: C Dialect Options. (line 231)
27219 * fsingle-precision-constant: Optimize Options. (line 1070)
27220 * fspeculative-prefetching: Optimize Options. (line 1127)
27221 * fstack-check: Code Gen Options. (line 297)
27222 * fstack-limit-register: Code Gen Options. (line 312)
27223 * fstack-limit-symbol: Code Gen Options. (line 312)
27224 * fstats: C++ Dialect Options.
27226 * fstrength-reduce: Optimize Options. (line 340)
27227 * fstrict-aliasing: Optimize Options. (line 780)
27228 * fsyntax-only: Warning Options. (line 23)
27229 * ftabstop: Preprocessor Options.
27231 * ftemplate-depth: C++ Dialect Options.
27233 * ftest-coverage: Debugging Options. (line 205)
27234 * fthread-jumps: Optimize Options. (line 346)
27235 * ftime-report: Debugging Options. (line 138)
27236 * ftracer: Optimize Options. (line 678)
27237 * ftrapv: Code Gen Options. (line 22)
27238 * ftree-based-profiling: Debugging Options. (line 195)
27239 * ftree-vectorizer-verbose: Debugging Options. (line 608)
27240 * funit-at-a-time: Optimize Options. (line 886)
27241 * funroll-all-loops: Optimize Options. (line 689)
27242 * funroll-loops <1>: Non-bugs. (line 174)
27243 * funroll-loops: Optimize Options. (line 683)
27244 * funsafe-math-optimizations: Optimize Options. (line 996)
27245 * funsigned-bitfields <1>: Non-bugs. (line 57)
27246 * funsigned-bitfields <2>: Structures unions enumerations and bit-fields implementation.
27248 * funsigned-bitfields: C Dialect Options. (line 241)
27249 * funsigned-char <1>: Characters implementation.
27251 * funsigned-char: C Dialect Options. (line 213)
27252 * funswitch-loops: Optimize Options. (line 1189)
27253 * funwind-tables: Code Gen Options. (line 57)
27254 * fuse-cxa-atexit: C++ Dialect Options.
27256 * fvar-tracking: Debugging Options. (line 667)
27257 * fverbose-asm: Code Gen Options. (line 161)
27258 * fvisibility: Code Gen Options. (line 362)
27259 * fvisibility-inlines-hidden: C++ Dialect Options.
27261 * fvpt: Optimize Options. (line 1118)
27262 * fweb: Optimize Options. (line 915)
27263 * fwide-exec-charset: Preprocessor Options.
27265 * fworking-directory: Preprocessor Options.
27267 * fwrapv: Code Gen Options. (line 26)
27268 * fzero-link: Objective-C and Objective-C++ Dialect Options.
27270 * G <1>: System V Options. (line 10)
27271 * G <2>: RS/6000 and PowerPC Options.
27273 * G <3>: MIPS Options. (line 195)
27274 * G: M32R/D Options. (line 57)
27275 * g: Debugging Options. (line 10)
27276 * gcoff: Debugging Options. (line 62)
27277 * gdwarf-2: Debugging Options. (line 80)
27278 * gen-decls: Objective-C and Objective-C++ Dialect Options.
27280 * ggdb: Debugging Options. (line 38)
27281 * gnu-ld: HPPA Options. (line 113)
27282 * gstabs: Debugging Options. (line 44)
27283 * gstabs+: Debugging Options. (line 56)
27284 * gvms: Debugging Options. (line 87)
27285 * gxcoff: Debugging Options. (line 67)
27286 * gxcoff+: Debugging Options. (line 72)
27287 * H: Preprocessor Options.
27289 * headerpad_max_install_names: Darwin Options. (line 174)
27290 * help <1>: Preprocessor Options.
27292 * help: Overall Options. (line 211)
27293 * hp-ld: HPPA Options. (line 123)
27294 * I <1>: Directory Options. (line 10)
27295 * I: Preprocessor Options.
27297 * I- <1>: Directory Options. (line 92)
27298 * I-: Preprocessor Options.
27300 * idirafter: Preprocessor Options.
27302 * if-conversion: Optimize Options. (line 443)
27303 * if-conversion2: Optimize Options. (line 452)
27304 * imacros: Preprocessor Options.
27306 * image_base: Darwin Options. (line 174)
27307 * include: Preprocessor Options.
27309 * init: Darwin Options. (line 174)
27310 * install_name: Darwin Options. (line 174)
27311 * iprefix: Preprocessor Options.
27313 * iquote <1>: Directory Options. (line 31)
27314 * iquote: Preprocessor Options.
27316 * isystem: Preprocessor Options.
27318 * iwithprefix: Preprocessor Options.
27320 * iwithprefixbefore: Preprocessor Options.
27322 * keep_private_externs: Darwin Options. (line 174)
27323 * L: Directory Options. (line 37)
27324 * l: Link Options. (line 26)
27325 * lobjc: Link Options. (line 53)
27326 * M: Preprocessor Options.
27328 * m1: SH Options. (line 9)
27329 * m10: PDP-11 Options. (line 29)
27330 * m128bit-long-double: i386 and x86-64 Options.
27332 * m16-bit: CRIS Options. (line 69)
27333 * m2: SH Options. (line 12)
27334 * m210: MCore Options. (line 43)
27335 * m3: SH Options. (line 18)
27336 * m31: S/390 and zSeries Options.
27338 * m32 <1>: SPARC Options. (line 187)
27339 * m32 <2>: RS/6000 and PowerPC Options.
27341 * m32: i386 and x86-64 Options.
27343 * m32-bit: CRIS Options. (line 69)
27344 * m32032: NS32K Options. (line 13)
27345 * m32081: NS32K Options. (line 27)
27346 * m32332: NS32K Options. (line 18)
27347 * m32381: NS32K Options. (line 31)
27348 * m32532: NS32K Options. (line 23)
27349 * m32r: M32R/D Options. (line 15)
27350 * m32r2: M32R/D Options. (line 9)
27351 * m32rx: M32R/D Options. (line 12)
27352 * m340: MCore Options. (line 43)
27353 * m386: i386 and x86-64 Options.
27355 * m3dnow: i386 and x86-64 Options.
27357 * m3e: SH Options. (line 21)
27358 * m4: SH Options. (line 35)
27359 * m4-nofpu: SH Options. (line 24)
27360 * m4-single: SH Options. (line 31)
27361 * m4-single-only: SH Options. (line 27)
27362 * m40: PDP-11 Options. (line 23)
27363 * m45: PDP-11 Options. (line 26)
27364 * m486: i386 and x86-64 Options.
27366 * m4a: SH Options. (line 50)
27367 * m4a-nofpu: SH Options. (line 38)
27368 * m4a-single: SH Options. (line 46)
27369 * m4a-single-only: SH Options. (line 42)
27370 * m4al: SH Options. (line 53)
27371 * m4byte-functions: MCore Options. (line 27)
27372 * m5200: M680x0 Options. (line 59)
27373 * m64 <1>: SPARC Options. (line 187)
27374 * m64 <2>: S/390 and zSeries Options.
27376 * m64 <3>: RS/6000 and PowerPC Options.
27378 * m64: i386 and x86-64 Options.
27380 * m68000: M680x0 Options. (line 13)
27381 * m68020: M680x0 Options. (line 21)
27382 * m68020-40: M680x0 Options. (line 66)
27383 * m68020-60: M680x0 Options. (line 73)
27384 * m68030: M680x0 Options. (line 30)
27385 * m68040: M680x0 Options. (line 34)
27386 * m68060: M680x0 Options. (line 42)
27387 * m6811: M68hc1x Options. (line 13)
27388 * m6812: M68hc1x Options. (line 18)
27389 * m68881: M680x0 Options. (line 25)
27390 * m68hc11: M68hc1x Options. (line 13)
27391 * m68hc12: M68hc1x Options. (line 18)
27392 * m68hcs12: M68hc1x Options. (line 23)
27393 * m68S12: M68hc1x Options. (line 23)
27394 * m8-bit: CRIS Options. (line 69)
27395 * m96bit-long-double: i386 and x86-64 Options.
27397 * mabi: ARM Options. (line 10)
27398 * mabi-mmixware: MMIX Options. (line 20)
27399 * mabi=32: MIPS Options. (line 87)
27400 * mabi=64: MIPS Options. (line 87)
27401 * mabi=altivec: RS/6000 and PowerPC Options.
27403 * mabi=eabi: MIPS Options. (line 87)
27404 * mabi=gnu: MMIX Options. (line 20)
27405 * mabi=n32: MIPS Options. (line 87)
27406 * mabi=no-altivec: RS/6000 and PowerPC Options.
27408 * mabi=no-spe: RS/6000 and PowerPC Options.
27410 * mabi=o64: MIPS Options. (line 87)
27411 * mabi=spe: RS/6000 and PowerPC Options.
27413 * mabicalls: MIPS Options. (line 98)
27414 * mabort-on-noreturn: ARM Options. (line 144)
27415 * mabshi: PDP-11 Options. (line 55)
27416 * mac0: PDP-11 Options. (line 16)
27417 * macc-4: FRV Options. (line 113)
27418 * macc-8: FRV Options. (line 116)
27419 * maccumulate-outgoing-args: i386 and x86-64 Options.
27421 * mads: RS/6000 and PowerPC Options.
27423 * maix-struct-return: RS/6000 and PowerPC Options.
27425 * maix32: RS/6000 and PowerPC Options.
27427 * maix64: RS/6000 and PowerPC Options.
27429 * malign-300: H8/300 Options. (line 31)
27430 * malign-double: i386 and x86-64 Options.
27432 * malign-int: M680x0 Options. (line 128)
27433 * malign-labels: FRV Options. (line 104)
27434 * malign-loops: M32R/D Options. (line 73)
27435 * malign-natural: RS/6000 and PowerPC Options.
27437 * malign-power: RS/6000 and PowerPC Options.
27439 * malloc-cc: FRV Options. (line 25)
27440 * malpha-as: DEC Alpha Options. (line 159)
27441 * maltivec: RS/6000 and PowerPC Options.
27443 * mam33: MN10300 Options. (line 17)
27444 * maout: CRIS Options. (line 92)
27445 * mapcs: ARM Options. (line 22)
27446 * mapcs-frame: ARM Options. (line 14)
27447 * mapp-regs <1>: V850 Options. (line 57)
27448 * mapp-regs: SPARC Options. (line 10)
27449 * march <1>: S/390 and zSeries Options.
27451 * march <2>: MIPS Options. (line 14)
27452 * march <3>: i386 and x86-64 Options.
27454 * march <4>: HPPA Options. (line 9)
27455 * march <5>: CRIS Options. (line 10)
27456 * march: ARM Options. (line 109)
27457 * masm=DIALECT: i386 and x86-64 Options.
27459 * mauto-incdec: M68hc1x Options. (line 26)
27460 * mauto-pic: IA-64 Options. (line 50)
27461 * mb: SH Options. (line 58)
27462 * mbackchain: S/390 and zSeries Options.
27464 * mbase-addresses: MMIX Options. (line 54)
27465 * mbcopy: PDP-11 Options. (line 36)
27466 * mbig <1>: TMS320C3x/C4x Options.
27468 * mbig: RS/6000 and PowerPC Options.
27470 * mbig-endian <1>: RS/6000 and PowerPC Options.
27472 * mbig-endian <2>: MCore Options. (line 39)
27473 * mbig-endian <3>: IA-64 Options. (line 9)
27474 * mbig-endian: ARM Options. (line 72)
27475 * mbig-memory: TMS320C3x/C4x Options.
27477 * mbig-switch <1>: V850 Options. (line 52)
27478 * mbig-switch: HPPA Options. (line 23)
27479 * mbigtable: SH Options. (line 74)
27480 * mbit-align: RS/6000 and PowerPC Options.
27482 * mbitfield <1>: NS32K Options. (line 66)
27483 * mbitfield: M680x0 Options. (line 100)
27484 * mbk: TMS320C3x/C4x Options.
27486 * mbranch-cheap: PDP-11 Options. (line 65)
27487 * mbranch-cost=NUMBER: M32R/D Options. (line 82)
27488 * mbranch-expensive: PDP-11 Options. (line 61)
27489 * mbranch-likely: MIPS Options. (line 346)
27490 * mbranch-predict: MMIX Options. (line 49)
27491 * mbuild-constants: DEC Alpha Options. (line 142)
27492 * mbwx: DEC Alpha Options. (line 171)
27493 * mc68000: M680x0 Options. (line 13)
27494 * mc68020: M680x0 Options. (line 21)
27495 * mcall-gnu: RS/6000 and PowerPC Options.
27497 * mcall-linux: RS/6000 and PowerPC Options.
27499 * mcall-netbsd: RS/6000 and PowerPC Options.
27501 * mcall-prologues: AVR Options. (line 43)
27502 * mcall-solaris: RS/6000 and PowerPC Options.
27504 * mcall-sysv: RS/6000 and PowerPC Options.
27506 * mcall-sysv-eabi: RS/6000 and PowerPC Options.
27508 * mcall-sysv-noeabi: RS/6000 and PowerPC Options.
27510 * mcallee-super-interworking: ARM Options. (line 234)
27511 * mcaller-super-interworking: ARM Options. (line 240)
27512 * mcallgraph-data: MCore Options. (line 31)
27513 * mcc-init: CRIS Options. (line 46)
27514 * mcheck-zero-division: MIPS Options. (line 233)
27515 * mcirrus-fix-invalid-insns: ARM Options. (line 187)
27516 * mcix: DEC Alpha Options. (line 171)
27517 * mcmodel=embmedany: SPARC Options. (line 209)
27518 * mcmodel=kernel: i386 and x86-64 Options.
27520 * mcmodel=large: i386 and x86-64 Options.
27522 * mcmodel=medany: SPARC Options. (line 203)
27523 * mcmodel=medium: i386 and x86-64 Options.
27525 * mcmodel=medlow: SPARC Options. (line 192)
27526 * mcmodel=medmid: SPARC Options. (line 197)
27527 * mcmodel=small: i386 and x86-64 Options.
27529 * mcond-exec: FRV Options. (line 152)
27530 * mcond-move: FRV Options. (line 128)
27531 * mconst-align: CRIS Options. (line 60)
27532 * mconst16: Xtensa Options. (line 10)
27533 * mconstant-gp: IA-64 Options. (line 46)
27534 * mcpu <1>: TMS320C3x/C4x Options.
27536 * mcpu <2>: SPARC Options. (line 96)
27537 * mcpu <3>: RS/6000 and PowerPC Options.
27539 * mcpu <4>: i386 and x86-64 Options.
27541 * mcpu <5>: FRV Options. (line 204)
27542 * mcpu <6>: DEC Alpha Options. (line 223)
27543 * mcpu <7>: CRIS Options. (line 10)
27544 * mcpu <8>: ARM Options. (line 84)
27545 * mcpu: ARC Options. (line 23)
27546 * mcpu32: M680x0 Options. (line 51)
27547 * MD: Preprocessor Options.
27549 * mdalign: SH Options. (line 64)
27550 * mdata: ARC Options. (line 30)
27551 * mdata-align: CRIS Options. (line 60)
27552 * mdb: TMS320C3x/C4x Options.
27554 * mdebug <1>: S/390 and zSeries Options.
27556 * mdebug: M32R/D Options. (line 69)
27557 * mdec-asm: PDP-11 Options. (line 78)
27558 * mdisable-callt: V850 Options. (line 80)
27559 * mdisable-fpregs: HPPA Options. (line 33)
27560 * mdisable-indexing: HPPA Options. (line 40)
27561 * mdiv: MCore Options. (line 15)
27562 * mdivide-breaks: MIPS Options. (line 238)
27563 * mdivide-traps: MIPS Options. (line 238)
27564 * mdouble: FRV Options. (line 38)
27565 * mdouble-float: MIPS Options. (line 149)
27566 * mdp-isr-reload: TMS320C3x/C4x Options.
27568 * mdwarf2-asm: IA-64 Options. (line 79)
27569 * mdword: FRV Options. (line 32)
27570 * mdynamic-no-pic: RS/6000 and PowerPC Options.
27572 * meabi: RS/6000 and PowerPC Options.
27574 * mearly-stop-bits: IA-64 Options. (line 85)
27575 * melf <1>: MMIX Options. (line 44)
27576 * melf: CRIS Options. (line 95)
27577 * melinux: CRIS Options. (line 99)
27578 * melinux-stacksize: CRIS Options. (line 25)
27579 * memb: RS/6000 and PowerPC Options.
27581 * membedded-data: MIPS Options. (line 204)
27582 * mep: V850 Options. (line 16)
27583 * mepsilon: MMIX Options. (line 15)
27584 * mesa: S/390 and zSeries Options.
27586 * metrax100: CRIS Options. (line 31)
27587 * metrax4: CRIS Options. (line 31)
27588 * mexplicit-relocs <1>: MIPS Options. (line 224)
27589 * mexplicit-relocs: DEC Alpha Options. (line 184)
27590 * MF: Preprocessor Options.
27592 * mfast-fix: TMS320C3x/C4x Options.
27594 * mfast-indirect-calls: HPPA Options. (line 52)
27595 * mfaster-structs: SPARC Options. (line 71)
27596 * mfdpic: FRV Options. (line 56)
27597 * mfix: DEC Alpha Options. (line 171)
27598 * mfix-and-continue: Darwin Options. (line 81)
27599 * mfix-r4000: MIPS Options. (line 288)
27600 * mfix-r4400: MIPS Options. (line 302)
27601 * mfix-sb1: MIPS Options. (line 330)
27602 * mfix-vr4120: MIPS Options. (line 309)
27603 * mfix-vr4130: MIPS Options. (line 323)
27604 * mfixed-cc: FRV Options. (line 28)
27605 * mfixed-range <1>: IA-64 Options. (line 90)
27606 * mfixed-range: HPPA Options. (line 59)
27607 * mfloat-abi: ARM Options. (line 59)
27608 * mfloat-gprs: RS/6000 and PowerPC Options.
27610 * mfloat-ieee: DEC Alpha Options. (line 179)
27611 * mfloat-vax: DEC Alpha Options. (line 179)
27612 * mfloat32: PDP-11 Options. (line 52)
27613 * mfloat64: PDP-11 Options. (line 48)
27614 * mflush-func: MIPS Options. (line 336)
27615 * mflush-func=NAME: M32R/D Options. (line 94)
27616 * mflush-trap=NUMBER: M32R/D Options. (line 87)
27617 * mfmovd: SH Options. (line 78)
27618 * mfp: ARM Options. (line 119)
27619 * mfp-exceptions: MIPS Options. (line 357)
27620 * mfp-reg: DEC Alpha Options. (line 25)
27621 * mfp-rounding-mode: DEC Alpha Options. (line 85)
27622 * mfp-trap-mode: DEC Alpha Options. (line 63)
27623 * mfp32: MIPS Options. (line 132)
27624 * mfp64: MIPS Options. (line 135)
27625 * mfpe: ARM Options. (line 119)
27626 * mfpr-32: FRV Options. (line 13)
27627 * mfpr-64: FRV Options. (line 16)
27628 * mfpu <1>: SPARC Options. (line 20)
27629 * mfpu <2>: PDP-11 Options. (line 9)
27630 * mfpu: ARM Options. (line 119)
27631 * mfull-toc: RS/6000 and PowerPC Options.
27633 * mfused-madd <1>: Xtensa Options. (line 19)
27634 * mfused-madd <2>: S/390 and zSeries Options.
27636 * mfused-madd <3>: RS/6000 and PowerPC Options.
27638 * mfused-madd: MIPS Options. (line 273)
27639 * mg: VAX Options. (line 17)
27640 * MG: Preprocessor Options.
27642 * mgas <1>: HPPA Options. (line 75)
27643 * mgas: DEC Alpha Options. (line 159)
27644 * mgnu: VAX Options. (line 13)
27645 * mgnu-as: IA-64 Options. (line 18)
27646 * mgnu-ld: IA-64 Options. (line 23)
27647 * mgotplt: CRIS Options. (line 86)
27648 * mgp32: MIPS Options. (line 126)
27649 * mgp64: MIPS Options. (line 129)
27650 * mgpr-32: FRV Options. (line 7)
27651 * mgpr-64: FRV Options. (line 10)
27652 * mgprel-ro: FRV Options. (line 79)
27653 * mh: H8/300 Options. (line 14)
27654 * mhard-float <1>: SPARC Options. (line 20)
27655 * mhard-float <2>: S/390 and zSeries Options.
27657 * mhard-float <3>: RS/6000 and PowerPC Options.
27659 * mhard-float <4>: MIPS Options. (line 138)
27660 * mhard-float <5>: FRV Options. (line 19)
27661 * mhard-float: ARM Options. (line 41)
27662 * mhard-quad-float: SPARC Options. (line 41)
27663 * mhardlit: MCore Options. (line 10)
27664 * mhimem: NS32K Options. (line 111)
27665 * mhitachi: SH Options. (line 81)
27666 * mieee <1>: SH Options. (line 96)
27667 * mieee: DEC Alpha Options. (line 39)
27668 * mieee-compare: NS32K Options. (line 55)
27669 * mieee-conformant: DEC Alpha Options. (line 134)
27670 * mieee-fp: i386 and x86-64 Options.
27672 * mieee-with-inexact: DEC Alpha Options. (line 52)
27673 * milp32: IA-64 Options. (line 114)
27674 * mimpure-text: SPARC Options. (line 81)
27675 * minit-stack: AVR Options. (line 35)
27676 * minline-all-stringops: i386 and x86-64 Options.
27678 * minline-float-divide-max-throughput: IA-64 Options. (line 58)
27679 * minline-float-divide-min-latency: IA-64 Options. (line 54)
27680 * minline-int-divide-max-throughput: IA-64 Options. (line 66)
27681 * minline-int-divide-min-latency: IA-64 Options. (line 62)
27682 * minline-plt: FRV Options. (line 64)
27683 * minline-sqrt-max-throughput: IA-64 Options. (line 74)
27684 * minline-sqrt-min-latency: IA-64 Options. (line 70)
27685 * minmax: M68hc1x Options. (line 31)
27686 * minsert-sched-nops: RS/6000 and PowerPC Options.
27688 * mint16: PDP-11 Options. (line 40)
27689 * mint32 <1>: PDP-11 Options. (line 44)
27690 * mint32: H8/300 Options. (line 28)
27691 * mint64: MIPS Options. (line 165)
27692 * mint8: AVR Options. (line 53)
27693 * mips1: MIPS Options. (line 58)
27694 * mips16: MIPS Options. (line 80)
27695 * mips2: MIPS Options. (line 61)
27696 * mips3: MIPS Options. (line 64)
27697 * mips32: MIPS Options. (line 70)
27698 * mips32r2: MIPS Options. (line 73)
27699 * mips3d: MIPS Options. (line 161)
27700 * mips4: MIPS Options. (line 67)
27701 * mips64: MIPS Options. (line 76)
27702 * misel: RS/6000 and PowerPC Options.
27704 * misize: SH Options. (line 99)
27705 * missue-rate=NUMBER: M32R/D Options. (line 79)
27706 * mjump-in-delay: HPPA Options. (line 28)
27707 * mknuthdiv: MMIX Options. (line 33)
27708 * ml: SH Options. (line 61)
27709 * mlarge-data: DEC Alpha Options. (line 195)
27710 * mlarge-text: DEC Alpha Options. (line 213)
27711 * mlibfuncs: MMIX Options. (line 10)
27712 * mlibrary-pic: FRV Options. (line 110)
27713 * mlinked-fp: FRV Options. (line 94)
27714 * mlinker-opt: HPPA Options. (line 85)
27715 * mlinux: CRIS Options. (line 104)
27716 * mlittle: RS/6000 and PowerPC Options.
27718 * mlittle-endian <1>: SPARC Options. (line 181)
27719 * mlittle-endian <2>: RS/6000 and PowerPC Options.
27721 * mlittle-endian <3>: MCore Options. (line 39)
27722 * mlittle-endian <4>: IA-64 Options. (line 13)
27723 * mlittle-endian: ARM Options. (line 68)
27724 * mlong-calls <1>: V850 Options. (line 10)
27725 * mlong-calls <2>: MIPS Options. (line 259)
27726 * mlong-calls <3>: M68hc1x Options. (line 35)
27727 * mlong-calls <4>: FRV Options. (line 99)
27728 * mlong-calls: ARM Options. (line 149)
27729 * mlong-load-store: HPPA Options. (line 66)
27730 * mlong32: MIPS Options. (line 178)
27731 * mlong64: MIPS Options. (line 173)
27732 * mlongcall: RS/6000 and PowerPC Options.
27734 * mlongcalls: Xtensa Options. (line 60)
27735 * mloop-unsigned: TMS320C3x/C4x Options.
27737 * mlp64: IA-64 Options. (line 114)
27738 * MM: Preprocessor Options.
27740 * mmad: MIPS Options. (line 268)
27741 * mmangle-cpu: ARC Options. (line 15)
27742 * mmax: DEC Alpha Options. (line 171)
27743 * mmax-stack-frame: CRIS Options. (line 22)
27744 * mmcu: AVR Options. (line 9)
27745 * MMD: Preprocessor Options.
27747 * mmedia: FRV Options. (line 44)
27748 * mmemcpy: MIPS Options. (line 253)
27749 * mmemory-latency: DEC Alpha Options. (line 266)
27750 * mmemparm: TMS320C3x/C4x Options.
27752 * mminimal-toc: RS/6000 and PowerPC Options.
27754 * mmmx: i386 and x86-64 Options.
27756 * mmodel=large: M32R/D Options. (line 33)
27757 * mmodel=medium: M32R/D Options. (line 27)
27758 * mmodel=small: M32R/D Options. (line 18)
27759 * mmpyi: TMS320C3x/C4x Options.
27761 * mmul-bug-workaround: CRIS Options. (line 36)
27762 * mmuladd: FRV Options. (line 50)
27763 * mmult-bug: MN10300 Options. (line 9)
27764 * mmulti-add: NS32K Options. (line 37)
27765 * mmulti-cond-exec: FRV Options. (line 176)
27766 * mmultiple: RS/6000 and PowerPC Options.
27768 * mmvcle: S/390 and zSeries Options.
27770 * mmvme: RS/6000 and PowerPC Options.
27772 * mn: H8/300 Options. (line 20)
27773 * mnested-cond-exec: FRV Options. (line 189)
27774 * mnew-mnemonics: RS/6000 and PowerPC Options.
27776 * mno-3dnow: i386 and x86-64 Options.
27778 * mno-4byte-functions: MCore Options. (line 27)
27779 * mno-abicalls: MIPS Options. (line 98)
27780 * mno-abshi: PDP-11 Options. (line 58)
27781 * mno-ac0: PDP-11 Options. (line 20)
27782 * mno-align-double: i386 and x86-64 Options.
27784 * mno-align-int: M680x0 Options. (line 128)
27785 * mno-align-loops: M32R/D Options. (line 76)
27786 * mno-align-stringops: i386 and x86-64 Options.
27788 * mno-altivec: RS/6000 and PowerPC Options.
27790 * mno-am33: MN10300 Options. (line 20)
27791 * mno-app-regs <1>: V850 Options. (line 61)
27792 * mno-app-regs: SPARC Options. (line 10)
27793 * mno-backchain: S/390 and zSeries Options.
27795 * mno-base-addresses: MMIX Options. (line 54)
27796 * mno-bit-align: RS/6000 and PowerPC Options.
27798 * mno-bk: TMS320C3x/C4x Options.
27800 * mno-branch-likely: MIPS Options. (line 346)
27801 * mno-branch-predict: MMIX Options. (line 49)
27802 * mno-bwx: DEC Alpha Options. (line 171)
27803 * mno-callgraph-data: MCore Options. (line 31)
27804 * mno-check-zero-division: MIPS Options. (line 233)
27805 * mno-cirrus-fix-invalid-insns: ARM Options. (line 187)
27806 * mno-cix: DEC Alpha Options. (line 171)
27807 * mno-cond-exec: FRV Options. (line 158)
27808 * mno-cond-move: FRV Options. (line 134)
27809 * mno-const-align: CRIS Options. (line 60)
27810 * mno-const16: Xtensa Options. (line 10)
27811 * mno-crt0: MN10300 Options. (line 24)
27812 * mno-data-align: CRIS Options. (line 60)
27813 * mno-db: TMS320C3x/C4x Options.
27815 * mno-debug: S/390 and zSeries Options.
27817 * mno-div: MCore Options. (line 15)
27818 * mno-double: FRV Options. (line 41)
27819 * mno-dwarf2-asm: IA-64 Options. (line 79)
27820 * mno-dword: FRV Options. (line 35)
27821 * mno-eabi: RS/6000 and PowerPC Options.
27823 * mno-early-stop-bits: IA-64 Options. (line 85)
27824 * mno-eflags: FRV Options. (line 125)
27825 * mno-embedded-data: MIPS Options. (line 204)
27826 * mno-ep: V850 Options. (line 16)
27827 * mno-epsilon: MMIX Options. (line 15)
27828 * mno-explicit-relocs <1>: MIPS Options. (line 224)
27829 * mno-explicit-relocs: DEC Alpha Options. (line 184)
27830 * mno-fancy-math-387: i386 and x86-64 Options.
27832 * mno-fast-fix: TMS320C3x/C4x Options.
27834 * mno-faster-structs: SPARC Options. (line 71)
27835 * mno-fix: DEC Alpha Options. (line 171)
27836 * mno-fix-r4000: MIPS Options. (line 288)
27837 * mno-fix-r4400: MIPS Options. (line 302)
27838 * mno-float32: PDP-11 Options. (line 48)
27839 * mno-float64: PDP-11 Options. (line 52)
27840 * mno-flush-func: M32R/D Options. (line 99)
27841 * mno-flush-trap: M32R/D Options. (line 91)
27842 * mno-fp-in-toc: RS/6000 and PowerPC Options.
27844 * mno-fp-regs: DEC Alpha Options. (line 25)
27845 * mno-fp-ret-in-387: i386 and x86-64 Options.
27847 * mno-fpu: SPARC Options. (line 25)
27848 * mno-fused-madd <1>: Xtensa Options. (line 19)
27849 * mno-fused-madd <2>: S/390 and zSeries Options.
27851 * mno-fused-madd <3>: RS/6000 and PowerPC Options.
27853 * mno-fused-madd: MIPS Options. (line 273)
27854 * mno-gnu-as: IA-64 Options. (line 18)
27855 * mno-gnu-ld: IA-64 Options. (line 23)
27856 * mno-gotplt: CRIS Options. (line 86)
27857 * mno-hardlit: MCore Options. (line 10)
27858 * mno-ieee-compare: NS32K Options. (line 55)
27859 * mno-ieee-fp: i386 and x86-64 Options.
27861 * mno-int16: PDP-11 Options. (line 44)
27862 * mno-int32: PDP-11 Options. (line 40)
27863 * mno-interrupts: AVR Options. (line 39)
27864 * mno-knuthdiv: MMIX Options. (line 33)
27865 * mno-libfuncs: MMIX Options. (line 10)
27866 * mno-long-calls <1>: V850 Options. (line 10)
27867 * mno-long-calls <2>: MIPS Options. (line 259)
27868 * mno-long-calls <3>: M68hc1x Options. (line 35)
27869 * mno-long-calls <4>: HPPA Options. (line 134)
27870 * mno-long-calls: ARM Options. (line 149)
27871 * mno-longcall: RS/6000 and PowerPC Options.
27873 * mno-longcalls: Xtensa Options. (line 60)
27874 * mno-loop-unsigned: TMS320C3x/C4x Options.
27876 * mno-mad: MIPS Options. (line 268)
27877 * mno-max: DEC Alpha Options. (line 171)
27878 * mno-media: FRV Options. (line 47)
27879 * mno-memcpy: MIPS Options. (line 253)
27880 * mno-mips16: MIPS Options. (line 80)
27881 * mno-mips3d: MIPS Options. (line 161)
27882 * mno-mmx: i386 and x86-64 Options.
27884 * mno-mpyi: TMS320C3x/C4x Options.
27886 * mno-mul-bug-workaround: CRIS Options. (line 36)
27887 * mno-muladd: FRV Options. (line 53)
27888 * mno-mult-bug: MN10300 Options. (line 13)
27889 * mno-multi-cond-exec: FRV Options. (line 183)
27890 * mno-multiple: RS/6000 and PowerPC Options.
27892 * mno-mvcle: S/390 and zSeries Options.
27894 * mno-nested-cond-exec: FRV Options. (line 195)
27895 * mno-pack: FRV Options. (line 122)
27896 * mno-packed-stack: S/390 and zSeries Options.
27898 * mno-paired-single: MIPS Options. (line 154)
27899 * mno-parallel-insns: TMS320C3x/C4x Options.
27901 * mno-parallel-mpy: TMS320C3x/C4x Options.
27903 * mno-pic: IA-64 Options. (line 26)
27904 * mno-power: RS/6000 and PowerPC Options.
27906 * mno-power2: RS/6000 and PowerPC Options.
27908 * mno-powerpc: RS/6000 and PowerPC Options.
27910 * mno-powerpc-gfxopt: RS/6000 and PowerPC Options.
27912 * mno-powerpc-gpopt: RS/6000 and PowerPC Options.
27914 * mno-powerpc64: RS/6000 and PowerPC Options.
27916 * mno-prolog-function: V850 Options. (line 23)
27917 * mno-prologue-epilogue: CRIS Options. (line 76)
27918 * mno-prototype: RS/6000 and PowerPC Options.
27920 * mno-push-args: i386 and x86-64 Options.
27922 * mno-register-names: IA-64 Options. (line 37)
27923 * mno-regnames: RS/6000 and PowerPC Options.
27925 * mno-relax-immediate: MCore Options. (line 19)
27926 * mno-relocatable: RS/6000 and PowerPC Options.
27928 * mno-relocatable-lib: RS/6000 and PowerPC Options.
27930 * mno-rptb: TMS320C3x/C4x Options.
27932 * mno-rpts: TMS320C3x/C4x Options.
27934 * mno-scc: FRV Options. (line 146)
27935 * mno-sched-prolog: ARM Options. (line 32)
27936 * mno-sdata <1>: RS/6000 and PowerPC Options.
27938 * mno-sdata: IA-64 Options. (line 42)
27939 * mno-side-effects: CRIS Options. (line 51)
27940 * mno-single-exit: MMIX Options. (line 66)
27941 * mno-slow-bytes: MCore Options. (line 35)
27942 * mno-small-exec: S/390 and zSeries Options.
27944 * mno-soft-float: DEC Alpha Options. (line 10)
27945 * mno-space-regs: HPPA Options. (line 45)
27946 * mno-split: PDP-11 Options. (line 71)
27947 * mno-split-addresses: MIPS Options. (line 218)
27948 * mno-sse: i386 and x86-64 Options.
27950 * mno-stack-align: CRIS Options. (line 60)
27951 * mno-stack-bias: SPARC Options. (line 218)
27952 * mno-strict-align <1>: RS/6000 and PowerPC Options.
27954 * mno-strict-align: M680x0 Options. (line 148)
27955 * mno-string: RS/6000 and PowerPC Options.
27957 * mno-sum-in-toc: RS/6000 and PowerPC Options.
27959 * mno-svr3-shlib: i386 and x86-64 Options.
27961 * mno-sym32: MIPS Options. (line 188)
27962 * mno-tablejump: AVR Options. (line 47)
27963 * mno-target-align: Xtensa Options. (line 47)
27964 * mno-text-section-literals: Xtensa Options. (line 35)
27965 * mno-toc: RS/6000 and PowerPC Options.
27967 * mno-toplevel-symbols: MMIX Options. (line 40)
27968 * mno-tpf-trace: S/390 and zSeries Options.
27970 * mno-unaligned-doubles: SPARC Options. (line 59)
27971 * mno-uninit-const-in-rodata: MIPS Options. (line 212)
27972 * mno-update: RS/6000 and PowerPC Options.
27974 * mno-v8plus: SPARC Options. (line 166)
27975 * mno-vis: SPARC Options. (line 173)
27976 * mno-vliw-branch: FRV Options. (line 170)
27977 * mno-volatile-asm-stop: IA-64 Options. (line 32)
27978 * mno-wide-bitfields: MCore Options. (line 23)
27979 * mno-xgot: MIPS Options. (line 103)
27980 * mno-xl-compat: RS/6000 and PowerPC Options.
27982 * mno-zero-extend: MMIX Options. (line 27)
27983 * mnobitfield <1>: NS32K Options. (line 61)
27984 * mnobitfield: M680x0 Options. (line 96)
27985 * mnohimem: NS32K Options. (line 118)
27986 * mnomacsave: SH Options. (line 92)
27987 * mnominmax: M68hc1x Options. (line 31)
27988 * mnomulti-add: NS32K Options. (line 46)
27989 * mnop-fun-dllimport: ARM Options. (line 174)
27990 * mnoregparam: NS32K Options. (line 97)
27991 * mnosb: NS32K Options. (line 105)
27992 * mold-mnemonics: RS/6000 and PowerPC Options.
27994 * momit-leaf-frame-pointer: i386 and x86-64 Options.
27996 * MP: Preprocessor Options.
27998 * mpa-risc-1-0: HPPA Options. (line 19)
27999 * mpa-risc-1-1: HPPA Options. (line 19)
28000 * mpa-risc-2-0: HPPA Options. (line 19)
28001 * mpack: FRV Options. (line 119)
28002 * mpacked-stack: S/390 and zSeries Options.
28004 * mpadstruct: SH Options. (line 102)
28005 * mpaired-single: MIPS Options. (line 154)
28006 * mparallel-insns: TMS320C3x/C4x Options.
28008 * mparallel-mpy: TMS320C3x/C4x Options.
28010 * mparanoid: TMS320C3x/C4x Options.
28012 * mpcrel: M680x0 Options. (line 140)
28013 * mpdebug: CRIS Options. (line 40)
28014 * mpe: RS/6000 and PowerPC Options.
28016 * mpentium: i386 and x86-64 Options.
28018 * mpentiumpro: i386 and x86-64 Options.
28020 * mpic-register: ARM Options. (line 183)
28021 * mpoke-function-name: ARM Options. (line 197)
28022 * mportable-runtime: HPPA Options. (line 71)
28023 * mpower: RS/6000 and PowerPC Options.
28025 * mpower2: RS/6000 and PowerPC Options.
28027 * mpowerpc: RS/6000 and PowerPC Options.
28029 * mpowerpc-gfxopt: RS/6000 and PowerPC Options.
28031 * mpowerpc-gpopt: RS/6000 and PowerPC Options.
28033 * mpowerpc64: RS/6000 and PowerPC Options.
28035 * mprefergot: SH Options. (line 109)
28036 * mpreferred-stack-boundary: i386 and x86-64 Options.
28038 * mprioritize-restricted-insns: RS/6000 and PowerPC Options.
28040 * mprolog-function: V850 Options. (line 23)
28041 * mprologue-epilogue: CRIS Options. (line 76)
28042 * mprototype: RS/6000 and PowerPC Options.
28044 * mpush-args: i386 and x86-64 Options.
28046 * MQ: Preprocessor Options.
28048 * mregister-names: IA-64 Options. (line 37)
28049 * mregnames: RS/6000 and PowerPC Options.
28051 * mregparam: NS32K Options. (line 89)
28052 * mregparm <1>: TMS320C3x/C4x Options.
28054 * mregparm: i386 and x86-64 Options.
28056 * mrelax <1>: SH Options. (line 70)
28057 * mrelax <2>: MN10300 Options. (line 27)
28058 * mrelax: H8/300 Options. (line 9)
28059 * mrelax-immediate: MCore Options. (line 19)
28060 * mrelocatable: RS/6000 and PowerPC Options.
28062 * mrelocatable-lib: RS/6000 and PowerPC Options.
28064 * mrodata: ARC Options. (line 30)
28065 * mrptb: TMS320C3x/C4x Options.
28067 * mrpts: TMS320C3x/C4x Options.
28069 * mrtd <1>: Function Attributes.
28071 * mrtd <2>: NS32K Options. (line 70)
28072 * mrtd <3>: M680x0 Options. (line 105)
28073 * mrtd: i386 and x86-64 Options.
28075 * ms: H8/300 Options. (line 17)
28076 * ms2600: H8/300 Options. (line 24)
28077 * msb: NS32K Options. (line 101)
28078 * mscc: FRV Options. (line 140)
28079 * msched-costly-dep: RS/6000 and PowerPC Options.
28081 * mschedule: HPPA Options. (line 78)
28082 * msda: V850 Options. (line 40)
28083 * msdata <1>: RS/6000 and PowerPC Options.
28085 * msdata: IA-64 Options. (line 42)
28086 * msdata-data: RS/6000 and PowerPC Options.
28088 * msdata=default: RS/6000 and PowerPC Options.
28090 * msdata=eabi: RS/6000 and PowerPC Options.
28092 * msdata=none <1>: RS/6000 and PowerPC Options.
28094 * msdata=none: M32R/D Options. (line 40)
28095 * msdata=sdata: M32R/D Options. (line 49)
28096 * msdata=sysv: RS/6000 and PowerPC Options.
28098 * msdata=use: M32R/D Options. (line 53)
28099 * mshort <1>: M68hc1x Options. (line 40)
28100 * mshort: M680x0 Options. (line 90)
28101 * msim <1>: Xstormy16 Options. (line 9)
28102 * msim: RS/6000 and PowerPC Options.
28104 * msingle-exit: MMIX Options. (line 66)
28105 * msingle-float: MIPS Options. (line 145)
28106 * msingle-pic-base: ARM Options. (line 177)
28107 * msio: HPPA Options. (line 107)
28108 * msize: AVR Options. (line 32)
28109 * mslow-bytes: MCore Options. (line 35)
28110 * msmall: TMS320C3x/C4x Options.
28112 * msmall-data: DEC Alpha Options. (line 195)
28113 * msmall-exec: S/390 and zSeries Options.
28115 * msmall-memory: TMS320C3x/C4x Options.
28117 * msmall-text: DEC Alpha Options. (line 213)
28118 * msoft-float <1>: SPARC Options. (line 25)
28119 * msoft-float <2>: S/390 and zSeries Options.
28121 * msoft-float <3>: RS/6000 and PowerPC Options.
28123 * msoft-float <4>: PDP-11 Options. (line 13)
28124 * msoft-float <5>: NS32K Options. (line 50)
28125 * msoft-float <6>: MIPS Options. (line 141)
28126 * msoft-float <7>: M680x0 Options. (line 80)
28127 * msoft-float <8>: i386 and x86-64 Options.
28129 * msoft-float <9>: HPPA Options. (line 91)
28130 * msoft-float <10>: FRV Options. (line 22)
28131 * msoft-float <11>: DEC Alpha Options. (line 10)
28132 * msoft-float: ARM Options. (line 45)
28133 * msoft-quad-float: SPARC Options. (line 45)
28134 * msoft-reg-count: M68hc1x Options. (line 43)
28135 * mspace <1>: V850 Options. (line 30)
28136 * mspace: SH Options. (line 106)
28137 * mspe: RS/6000 and PowerPC Options.
28139 * msplit: PDP-11 Options. (line 68)
28140 * msplit-addresses: MIPS Options. (line 218)
28141 * msse: i386 and x86-64 Options.
28143 * mstack-align: CRIS Options. (line 60)
28144 * mstack-bias: SPARC Options. (line 218)
28145 * mstack-guard: S/390 and zSeries Options.
28147 * mstack-size: S/390 and zSeries Options.
28149 * mstrict-align <1>: RS/6000 and PowerPC Options.
28151 * mstrict-align: M680x0 Options. (line 148)
28152 * mstring: RS/6000 and PowerPC Options.
28154 * mstructure-size-boundary: ARM Options. (line 129)
28155 * msvr3-shlib: i386 and x86-64 Options.
28157 * msvr4-struct-return: RS/6000 and PowerPC Options.
28159 * msym32: MIPS Options. (line 188)
28160 * mt: IA-64 Options. (line 106)
28161 * MT: Preprocessor Options.
28163 * mtarget-align: Xtensa Options. (line 47)
28164 * mtda: V850 Options. (line 34)
28165 * mtext: ARC Options. (line 30)
28166 * mtext-section-literals: Xtensa Options. (line 35)
28167 * mthreads: i386 and x86-64 Options.
28169 * mthumb: ARM Options. (line 218)
28170 * mthumb-interwork: ARM Options. (line 25)
28171 * mti: TMS320C3x/C4x Options.
28173 * mtiny-stack: AVR Options. (line 50)
28174 * mtls-direct-seg-refs: i386 and x86-64 Options.
28176 * mtls-size: IA-64 Options. (line 97)
28177 * mtoc: RS/6000 and PowerPC Options.
28179 * mtomcat-stats: FRV Options. (line 201)
28180 * mtoplevel-symbols: MMIX Options. (line 40)
28181 * mtpcs-frame: ARM Options. (line 222)
28182 * mtpcs-leaf-frame: ARM Options. (line 228)
28183 * mtpf-trace: S/390 and zSeries Options.
28185 * mtrap-precision: DEC Alpha Options. (line 109)
28186 * mtune <1>: SPARC Options. (line 154)
28187 * mtune <2>: S/390 and zSeries Options.
28189 * mtune <3>: RS/6000 and PowerPC Options.
28191 * mtune <4>: MIPS Options. (line 43)
28192 * mtune <5>: i386 and x86-64 Options.
28194 * mtune <6>: DEC Alpha Options. (line 262)
28195 * mtune <7>: CRIS Options. (line 16)
28196 * mtune: ARM Options. (line 99)
28197 * mtune-arch: IA-64 Options. (line 101)
28198 * multi_module: Darwin Options. (line 174)
28199 * multilib-library-pic: FRV Options. (line 89)
28200 * multiply_defined: Darwin Options. (line 174)
28201 * multiply_defined_unused: Darwin Options. (line 174)
28202 * munaligned-doubles: SPARC Options. (line 59)
28203 * muninit-const-in-rodata: MIPS Options. (line 212)
28204 * munix: VAX Options. (line 9)
28205 * munix-asm: PDP-11 Options. (line 74)
28206 * mupdate: RS/6000 and PowerPC Options.
28208 * musermode: SH Options. (line 114)
28209 * mv850: V850 Options. (line 49)
28210 * mv850e: V850 Options. (line 69)
28211 * mv850e1: V850 Options. (line 64)
28212 * mv8plus: SPARC Options. (line 166)
28213 * mvis: SPARC Options. (line 173)
28214 * mvliw-branch: FRV Options. (line 164)
28215 * mvms-return-codes: DEC Alpha/VMS Options.
28217 * mvolatile-asm-stop: IA-64 Options. (line 32)
28218 * mvr4130-align: MIPS Options. (line 367)
28219 * mvxworks: RS/6000 and PowerPC Options.
28221 * mwarn-dynamicstack: S/390 and zSeries Options.
28223 * mwarn-framesize: S/390 and zSeries Options.
28225 * mwide-bitfields: MCore Options. (line 23)
28226 * mwindiss: RS/6000 and PowerPC Options.
28228 * mwords-little-endian: ARM Options. (line 76)
28229 * mxgot: MIPS Options. (line 103)
28230 * mxl-compat: RS/6000 and PowerPC Options.
28232 * myellowknife: RS/6000 and PowerPC Options.
28234 * mzarch: S/390 and zSeries Options.
28236 * mzda: V850 Options. (line 45)
28237 * mzero-extend: MMIX Options. (line 27)
28238 * no-integrated-cpp: C Dialect Options. (line 190)
28239 * no-red-zone: i386 and x86-64 Options.
28241 * no_dead_strip_inits_and_terms: Darwin Options. (line 174)
28242 * noall_load: Darwin Options. (line 174)
28243 * nocpp: MIPS Options. (line 283)
28244 * nodefaultlibs: Link Options. (line 62)
28245 * nofixprebinding: Darwin Options. (line 174)
28246 * nolibdld: HPPA Options. (line 186)
28247 * nomultidefs: Darwin Options. (line 174)
28248 * noprebind: Darwin Options. (line 174)
28249 * noseglinkedit: Darwin Options. (line 174)
28250 * nostartfiles: Link Options. (line 57)
28251 * nostdinc: Preprocessor Options.
28253 * nostdinc++ <1>: Preprocessor Options.
28255 * nostdinc++: C++ Dialect Options.
28257 * nostdlib: Link Options. (line 71)
28258 * o: Preprocessor Options.
28260 * O: Optimize Options. (line 32)
28261 * o: Overall Options. (line 167)
28262 * O0: Optimize Options. (line 106)
28263 * O1: Optimize Options. (line 32)
28264 * O2: Optimize Options. (line 67)
28265 * O3: Optimize Options. (line 101)
28266 * Os: Optimize Options. (line 109)
28267 * P: Preprocessor Options.
28269 * p: Debugging Options. (line 122)
28270 * pagezero_size: Darwin Options. (line 174)
28271 * param: Optimize Options. (line 1235)
28272 * pass-exit-codes: Overall Options. (line 126)
28273 * pedantic <1>: Warnings and Errors.
28275 * pedantic <2>: Alternate Keywords. (line 29)
28276 * pedantic <3>: C Extensions. (line 6)
28277 * pedantic <4>: Preprocessor Options.
28279 * pedantic <5>: Warning Options. (line 27)
28280 * pedantic: Standards. (line 13)
28281 * pedantic-errors <1>: Warnings and Errors.
28283 * pedantic-errors <2>: Non-bugs. (line 219)
28284 * pedantic-errors <3>: Preprocessor Options.
28286 * pedantic-errors <4>: Warning Options. (line 69)
28287 * pedantic-errors: Standards. (line 13)
28288 * pg: Debugging Options. (line 128)
28289 * pie: Link Options. (line 92)
28290 * pipe: Overall Options. (line 189)
28291 * prebind: Darwin Options. (line 174)
28292 * prebind_all_twolevel_modules: Darwin Options. (line 174)
28293 * preprocessor: Preprocessor Options.
28295 * print-file-name: Debugging Options. (line 677)
28296 * print-libgcc-file-name: Debugging Options. (line 698)
28297 * print-multi-directory: Debugging Options. (line 683)
28298 * print-multi-lib: Debugging Options. (line 688)
28299 * print-objc-runtime-info: Objective-C and Objective-C++ Dialect Options.
28301 * print-prog-name: Debugging Options. (line 695)
28302 * print-search-dirs: Debugging Options. (line 706)
28303 * private_bundle: Darwin Options. (line 174)
28304 * pthread <1>: RS/6000 and PowerPC Options.
28306 * pthread: IA-64 Options. (line 106)
28307 * pthreads: SPARC Options. (line 232)
28308 * Q: Debugging Options. (line 134)
28309 * Qn: System V Options. (line 18)
28310 * Qy: System V Options. (line 14)
28311 * read_only_relocs: Darwin Options. (line 174)
28312 * remap: Preprocessor Options.
28314 * s: Link Options. (line 98)
28315 * S <1>: Link Options. (line 20)
28316 * S: Overall Options. (line 150)
28317 * save-temps: Debugging Options. (line 639)
28318 * sectalign: Darwin Options. (line 174)
28319 * sectcreate: Darwin Options. (line 174)
28320 * sectobjectsymbols: Darwin Options. (line 174)
28321 * sectorder: Darwin Options. (line 174)
28322 * seg1addr: Darwin Options. (line 174)
28323 * seg_addr_table: Darwin Options. (line 174)
28324 * seg_addr_table_filename: Darwin Options. (line 174)
28325 * segaddr: Darwin Options. (line 174)
28326 * seglinkedit: Darwin Options. (line 174)
28327 * segprot: Darwin Options. (line 174)
28328 * segs_read_only_addr: Darwin Options. (line 174)
28329 * segs_read_write_addr: Darwin Options. (line 174)
28330 * shared: Link Options. (line 107)
28331 * shared-libgcc: Link Options. (line 115)
28332 * sim: CRIS Options. (line 108)
28333 * sim2: CRIS Options. (line 114)
28334 * single_module: Darwin Options. (line 174)
28335 * specs: Directory Options. (line 84)
28336 * static <1>: HPPA Options. (line 190)
28337 * static <2>: Darwin Options. (line 174)
28338 * static: Link Options. (line 102)
28339 * static-libgcc: Link Options. (line 115)
28340 * std <1>: Non-bugs. (line 107)
28341 * std <2>: Other Builtins. (line 22)
28342 * std <3>: C Dialect Options. (line 47)
28343 * std: Standards. (line 13)
28344 * std=: Preprocessor Options.
28346 * sub_library: Darwin Options. (line 174)
28347 * sub_umbrella: Darwin Options. (line 174)
28348 * symbolic: Link Options. (line 150)
28349 * target-help <1>: Preprocessor Options.
28351 * target-help: Overall Options. (line 220)
28352 * threads <1>: SPARC Options. (line 226)
28353 * threads: HPPA Options. (line 203)
28354 * time: Debugging Options. (line 653)
28355 * tls: FRV Options. (line 75)
28356 * TLS: FRV Options. (line 72)
28357 * traditional <1>: Incompatibilities. (line 6)
28358 * traditional: C Dialect Options. (line 202)
28359 * traditional-cpp <1>: Preprocessor Options.
28361 * traditional-cpp: C Dialect Options. (line 202)
28362 * trigraphs <1>: Preprocessor Options.
28364 * trigraphs: C Dialect Options. (line 186)
28365 * twolevel_namespace: Darwin Options. (line 174)
28366 * u: Link Options. (line 172)
28367 * U: Preprocessor Options.
28369 * umbrella: Darwin Options. (line 174)
28370 * undef: Preprocessor Options.
28372 * undefined: Darwin Options. (line 174)
28373 * unexported_symbols_list: Darwin Options. (line 174)
28374 * V: Target Options. (line 22)
28375 * v <1>: Preprocessor Options.
28377 * v: Overall Options. (line 178)
28378 * version <1>: Preprocessor Options.
28380 * version: Overall Options. (line 224)
28381 * W: Incompatibilities. (line 64)
28382 * w: Preprocessor Options.
28384 * W: Warning Options. (line 511)
28385 * w: Warning Options. (line 73)
28386 * Wa: Assembler Options. (line 9)
28387 * Wabi: C++ Dialect Options.
28389 * Waggregate-return: Warning Options. (line 765)
28390 * Wall <1>: Standard Libraries. (line 6)
28391 * Wall <2>: Preprocessor Options.
28393 * Wall: Warning Options. (line 495)
28394 * Wbad-function-cast: Warning Options. (line 719)
28395 * Wcast-align: Warning Options. (line 728)
28396 * Wcast-qual: Warning Options. (line 723)
28397 * Wchar-subscripts: Warning Options. (line 79)
28398 * Wcomment <1>: Preprocessor Options.
28400 * Wcomment: Warning Options. (line 84)
28401 * Wcomments: Preprocessor Options.
28403 * Wconversion <1>: Protoize Caveats. (line 31)
28404 * Wconversion: Warning Options. (line 745)
28405 * Wctor-dtor-privacy: C++ Dialect Options.
28407 * Wdeclaration-after-statement: Warning Options. (line 691)
28408 * Wdisabled-optimization: Warning Options. (line 937)
28409 * Wdiv-by-zero: Warning Options. (line 583)
28410 * weak_reference_mismatches: Darwin Options. (line 174)
28411 * Weffc++: C++ Dialect Options.
28413 * Wendif-labels <1>: Preprocessor Options.
28415 * Wendif-labels: Warning Options. (line 701)
28416 * Werror <1>: Preprocessor Options.
28418 * Werror: Warning Options. (line 952)
28419 * Werror-implicit-function-declaration: Warning Options. (line 198)
28420 * Wextra: Warning Options. (line 511)
28421 * Wfatal-errors: Warning Options. (line 89)
28422 * Wfloat-equal: Warning Options. (line 599)
28423 * Wformat <1>: Function Attributes.
28425 * Wformat: Warning Options. (line 94)
28426 * Wformat-nonliteral <1>: Function Attributes.
28428 * Wformat-nonliteral: Warning Options. (line 151)
28429 * Wformat-security: Warning Options. (line 156)
28430 * Wformat-y2k: Warning Options. (line 129)
28431 * Wformat=2: Warning Options. (line 167)
28432 * whatsloaded: Darwin Options. (line 174)
28433 * whyload: Darwin Options. (line 174)
28434 * Wimplicit: Warning Options. (line 204)
28435 * Wimplicit-function-declaration: Warning Options. (line 198)
28436 * Wimplicit-int: Warning Options. (line 193)
28437 * Wimport: Preprocessor Options.
28439 * Winit-self: Warning Options. (line 179)
28440 * Winline <1>: Inline. (line 35)
28441 * Winline: Warning Options. (line 894)
28442 * Winvalid-pch: Warning Options. (line 921)
28443 * Wl: Link Options. (line 168)
28444 * Wlarger-than: Warning Options. (line 710)
28445 * Wlong-long: Warning Options. (line 925)
28446 * Wmain: Warning Options. (line 208)
28447 * Wmissing-braces: Warning Options. (line 214)
28448 * Wmissing-declarations: Warning Options. (line 786)
28449 * Wmissing-field-initializers: Warning Options. (line 792)
28450 * Wmissing-format-attribute: Warning Options. (line 818)
28451 * Wmissing-include-dirs: Warning Options. (line 224)
28452 * Wmissing-noreturn: Warning Options. (line 810)
28453 * Wmissing-prototypes: Warning Options. (line 780)
28454 * Wmultichar: Warning Options. (line 828)
28455 * Wnested-externs: Warning Options. (line 869)
28456 * Wno-deprecated: C++ Dialect Options.
28458 * Wno-deprecated-declarations: Warning Options. (line 834)
28459 * Wno-div-by-zero: Warning Options. (line 583)
28460 * Wno-endif-labels: Warning Options. (line 701)
28461 * Wno-format-extra-args: Warning Options. (line 133)
28462 * Wno-format-zero-length: Warning Options. (line 147)
28463 * Wno-import: Warning Options. (line 76)
28464 * Wno-invalid-offsetof: Warning Options. (line 907)
28465 * Wno-long-long: Warning Options. (line 925)
28466 * Wno-multichar: Warning Options. (line 828)
28467 * Wno-non-template-friend: C++ Dialect Options.
28469 * Wno-pmf-conversions <1>: Bound member functions.
28471 * Wno-pmf-conversions: C++ Dialect Options.
28473 * Wno-pointer-sign: Warning Options. (line 946)
28474 * Wno-protocol: Objective-C and Objective-C++ Dialect Options.
28476 * Wno-variadic-macros: Warning Options. (line 931)
28477 * Wnon-virtual-dtor: C++ Dialect Options.
28479 * Wnonnull: Warning Options. (line 172)
28480 * Wold-style-cast: C++ Dialect Options.
28482 * Wold-style-definition: Warning Options. (line 776)
28483 * Woverloaded-virtual: C++ Dialect Options.
28485 * Wp: Preprocessor Options.
28487 * Wpacked: Warning Options. (line 840)
28488 * Wpadded: Warning Options. (line 857)
28489 * Wparentheses: Warning Options. (line 227)
28490 * Wpointer-arith <1>: Pointer Arith. (line 13)
28491 * Wpointer-arith: Warning Options. (line 713)
28492 * Wredundant-decls: Warning Options. (line 864)
28493 * Wreorder: C++ Dialect Options.
28495 * Wreturn-type: Warning Options. (line 322)
28496 * Wselector: Objective-C and Objective-C++ Dialect Options.
28498 * Wsequence-point: Warning Options. (line 273)
28499 * Wshadow: Warning Options. (line 705)
28500 * Wsign-compare: Warning Options. (line 758)
28501 * Wsign-promo: C++ Dialect Options.
28503 * Wstrict-aliasing: Warning Options. (line 481)
28504 * Wstrict-aliasing=2: Warning Options. (line 488)
28505 * Wstrict-prototypes: Warning Options. (line 770)
28506 * Wswitch: Warning Options. (line 341)
28507 * Wswitch-enum: Warning Options. (line 352)
28508 * Wswitch-switch: Warning Options. (line 349)
28509 * Wsystem-headers <1>: Preprocessor Options.
28511 * Wsystem-headers: Warning Options. (line 588)
28512 * Wtraditional <1>: Preprocessor Options.
28514 * Wtraditional: Warning Options. (line 614)
28515 * Wtrigraphs <1>: Preprocessor Options.
28517 * Wtrigraphs: Warning Options. (line 358)
28518 * Wundeclared-selector: Objective-C and Objective-C++ Dialect Options.
28520 * Wundef <1>: Preprocessor Options.
28522 * Wundef: Warning Options. (line 698)
28523 * Wuninitialized: Warning Options. (line 403)
28524 * Wunknown-pragmas: Warning Options. (line 474)
28525 * Wunreachable-code: Warning Options. (line 872)
28526 * Wunused: Warning Options. (line 396)
28527 * Wunused-function: Warning Options. (line 363)
28528 * Wunused-label: Warning Options. (line 368)
28529 * Wunused-macros: Preprocessor Options.
28531 * Wunused-parameter: Warning Options. (line 375)
28532 * Wunused-value: Warning Options. (line 390)
28533 * Wunused-variable: Warning Options. (line 382)
28534 * Wvariadic-macros: Warning Options. (line 931)
28535 * Wwrite-strings: Warning Options. (line 734)
28536 * x <1>: Preprocessor Options.
28538 * x: Overall Options. (line 101)
28539 * Xassembler: Assembler Options. (line 13)
28540 * Xlinker: Link Options. (line 156)
28541 * Ym: System V Options. (line 26)
28542 * YP: System V Options. (line 22)
28545 File: gcc.info, Node: Keyword Index, Prev: Option Index, Up: Top
28553 * ! in constraint: Multi-Alternative. (line 33)
28554 * # in constraint: Modifiers. (line 54)
28555 * #pragma: Pragmas. (line 6)
28556 * #pragma implementation: C++ Interface. (line 39)
28557 * #pragma implementation, implied: C++ Interface. (line 46)
28558 * #pragma interface: C++ Interface. (line 20)
28559 * #pragma, reason for not using: Function Attributes. (line 713)
28560 * $: Dollar Signs. (line 6)
28561 * % in constraint: Modifiers. (line 45)
28562 * %include: Spec Files. (line 27)
28563 * %include_noerr: Spec Files. (line 31)
28564 * %rename: Spec Files. (line 35)
28565 * & in constraint: Modifiers. (line 25)
28566 * ': Incompatibilities. (line 116)
28567 * * in constraint: Modifiers. (line 59)
28568 * + in constraint: Modifiers. (line 12)
28569 * -lgcc, use with -nodefaultlibs: Link Options. (line 79)
28570 * -lgcc, use with -nostdlib: Link Options. (line 79)
28571 * -nodefaultlibs and unresolved references: Link Options. (line 79)
28572 * -nostdlib and unresolved references: Link Options. (line 79)
28573 * .sdata/.sdata2 references (PowerPC): RS/6000 and PowerPC Options.
28575 * //: C++ Comments. (line 6)
28576 * 0 in constraint: Simple Constraints. (line 115)
28577 * < in constraint: Simple Constraints. (line 46)
28578 * = in constraint: Modifiers. (line 8)
28579 * > in constraint: Simple Constraints. (line 50)
28580 * ? in constraint: Multi-Alternative. (line 27)
28581 * ?: extensions: Conditionals. (line 6)
28582 * ?: side effect: Conditionals. (line 20)
28583 * _ in variables in macros: Typeof. (line 42)
28584 * __builtin_apply: Constructing Calls. (line 31)
28585 * __builtin_apply_args: Constructing Calls. (line 20)
28586 * __builtin_choose_expr: Other Builtins. (line 150)
28587 * __builtin_clz: Other Builtins. (line 362)
28588 * __builtin_clzl: Other Builtins. (line 380)
28589 * __builtin_clzll: Other Builtins. (line 400)
28590 * __builtin_constant_p: Other Builtins. (line 190)
28591 * __builtin_ctz: Other Builtins. (line 366)
28592 * __builtin_ctzl: Other Builtins. (line 384)
28593 * __builtin_ctzll: Other Builtins. (line 404)
28594 * __builtin_expect: Other Builtins. (line 236)
28595 * __builtin_ffs: Other Builtins. (line 358)
28596 * __builtin_ffsl: Other Builtins. (line 376)
28597 * __builtin_ffsll: Other Builtins. (line 396)
28598 * __builtin_frame_address: Return Address. (line 34)
28599 * __builtin_huge_val: Other Builtins. (line 300)
28600 * __builtin_huge_valf: Other Builtins. (line 305)
28601 * __builtin_huge_vall: Other Builtins. (line 308)
28602 * __builtin_inf: Other Builtins. (line 312)
28603 * __builtin_inff: Other Builtins. (line 316)
28604 * __builtin_infl: Other Builtins. (line 321)
28605 * __builtin_isgreater: Other Builtins. (line 6)
28606 * __builtin_isgreaterequal: Other Builtins. (line 6)
28607 * __builtin_isless: Other Builtins. (line 6)
28608 * __builtin_islessequal: Other Builtins. (line 6)
28609 * __builtin_islessgreater: Other Builtins. (line 6)
28610 * __builtin_isunordered: Other Builtins. (line 6)
28611 * __builtin_nan: Other Builtins. (line 325)
28612 * __builtin_nanf: Other Builtins. (line 340)
28613 * __builtin_nanl: Other Builtins. (line 343)
28614 * __builtin_nans: Other Builtins. (line 347)
28615 * __builtin_nansf: Other Builtins. (line 351)
28616 * __builtin_nansl: Other Builtins. (line 354)
28617 * __builtin_offsetof: Offsetof. (line 6)
28618 * __builtin_parity: Other Builtins. (line 373)
28619 * __builtin_parityl: Other Builtins. (line 392)
28620 * __builtin_parityll: Other Builtins. (line 412)
28621 * __builtin_popcount: Other Builtins. (line 370)
28622 * __builtin_popcountl: Other Builtins. (line 388)
28623 * __builtin_popcountll: Other Builtins. (line 408)
28624 * __builtin_powi: Other Builtins. (line 6)
28625 * __builtin_powif: Other Builtins. (line 6)
28626 * __builtin_powil: Other Builtins. (line 6)
28627 * __builtin_prefetch: Other Builtins. (line 261)
28628 * __builtin_return: Constructing Calls. (line 48)
28629 * __builtin_return_address: Return Address. (line 11)
28630 * __builtin_types_compatible_p: Other Builtins. (line 104)
28631 * __complex__ keyword: Complex. (line 6)
28632 * __declspec(dllexport): Function Attributes. (line 110)
28633 * __declspec(dllimport): Function Attributes. (line 142)
28634 * __extension__: Alternate Keywords. (line 29)
28635 * __func__ identifier: Function Names. (line 6)
28636 * __FUNCTION__ identifier: Function Names. (line 6)
28637 * __imag__ keyword: Complex. (line 27)
28638 * __PRETTY_FUNCTION__ identifier: Function Names. (line 6)
28639 * __real__ keyword: Complex. (line 27)
28640 * __STDC_HOSTED__: Standards. (line 6)
28641 * __thread: Thread-Local. (line 6)
28642 * _Complex keyword: Complex. (line 6)
28643 * _exit: Other Builtins. (line 6)
28644 * _Exit: Other Builtins. (line 6)
28645 * ABI: Compatibility. (line 6)
28646 * abort: Other Builtins. (line 6)
28647 * abs: Other Builtins. (line 6)
28648 * accessing volatiles: Volatiles. (line 6)
28649 * acos: Other Builtins. (line 6)
28650 * acosf: Other Builtins. (line 6)
28651 * acosh: Other Builtins. (line 6)
28652 * acoshf: Other Builtins. (line 6)
28653 * acoshl: Other Builtins. (line 6)
28654 * acosl: Other Builtins. (line 6)
28655 * Ada: G++ and GCC. (line 6)
28656 * address constraints: Simple Constraints. (line 142)
28657 * address of a label: Labels as Values. (line 6)
28658 * address_operand: Simple Constraints. (line 146)
28659 * alias attribute: Function Attributes. (line 31)
28660 * aliasing of parameters: Code Gen Options. (line 325)
28661 * aligned attribute <1>: Type Attributes. (line 30)
28662 * aligned attribute: Variable Attributes. (line 23)
28663 * alignment: Alignment. (line 6)
28664 * alloca: Other Builtins. (line 6)
28665 * alloca vs variable-length arrays: Variable Length. (line 27)
28666 * alternate keywords: Alternate Keywords. (line 6)
28667 * always_inline function attribute: Function Attributes. (line 44)
28668 * AMD x86-64 Options: i386 and x86-64 Options.
28670 * AMD1: Standards. (line 6)
28671 * ANSI C: Standards. (line 6)
28672 * ANSI C standard: Standards. (line 6)
28673 * ANSI C89: Standards. (line 6)
28674 * ANSI support: C Dialect Options. (line 10)
28675 * ANSI X3.159-1989: Standards. (line 6)
28676 * apostrophes: Incompatibilities. (line 116)
28677 * application binary interface: Compatibility. (line 6)
28678 * ARC Options: ARC Options. (line 6)
28679 * ARM [Annotated C++ Reference Manual]: Backwards Compatibility.
28681 * ARM options: ARM Options. (line 6)
28682 * arrays of length zero: Zero Length. (line 6)
28683 * arrays of variable length: Variable Length. (line 6)
28684 * arrays, non-lvalue: Subscripting. (line 6)
28685 * asin: Other Builtins. (line 6)
28686 * asinf: Other Builtins. (line 6)
28687 * asinh: Other Builtins. (line 6)
28688 * asinhf: Other Builtins. (line 6)
28689 * asinhl: Other Builtins. (line 6)
28690 * asinl: Other Builtins. (line 6)
28691 * asm constraints: Constraints. (line 6)
28692 * asm expressions: Extended Asm. (line 6)
28693 * assembler instructions: Extended Asm. (line 6)
28694 * assembler names for identifiers: Asm Labels. (line 6)
28695 * assembly code, invalid: Bug Criteria. (line 12)
28696 * atan: Other Builtins. (line 6)
28697 * atan2: Other Builtins. (line 6)
28698 * atan2f: Other Builtins. (line 6)
28699 * atan2l: Other Builtins. (line 6)
28700 * atanf: Other Builtins. (line 6)
28701 * atanh: Other Builtins. (line 6)
28702 * atanhf: Other Builtins. (line 6)
28703 * atanhl: Other Builtins. (line 6)
28704 * atanl: Other Builtins. (line 6)
28705 * attribute of types: Type Attributes. (line 6)
28706 * attribute of variables: Variable Attributes. (line 6)
28707 * attribute syntax: Attribute Syntax. (line 6)
28708 * autoincrement/decrement addressing: Simple Constraints. (line 28)
28709 * automatic inline for C++ member fns: Inline. (line 46)
28710 * AVR Options: AVR Options. (line 6)
28711 * Backwards Compatibility: Backwards Compatibility.
28713 * base class members: Name lookup. (line 6)
28714 * bcmp: Other Builtins. (line 6)
28715 * below100 attribute: Variable Attributes. (line 313)
28716 * binary compatibility: Compatibility. (line 6)
28717 * bound pointer to member function: Bound member functions.
28719 * bounds checking: Optimize Options. (line 319)
28720 * bug criteria: Bug Criteria. (line 6)
28721 * bugs: Bugs. (line 6)
28722 * bugs, known: Trouble. (line 6)
28723 * built-in functions <1>: Other Builtins. (line 6)
28724 * built-in functions: C Dialect Options. (line 128)
28725 * bzero: Other Builtins. (line 6)
28726 * C compilation options: Invoking GCC. (line 17)
28727 * C intermediate output, nonexistent: G++ and GCC. (line 35)
28728 * C language extensions: C Extensions. (line 6)
28729 * C language, traditional: C Dialect Options. (line 200)
28730 * C standard: Standards. (line 6)
28731 * C standards: Standards. (line 6)
28732 * c++: Invoking G++. (line 13)
28733 * C++: G++ and GCC. (line 30)
28734 * C++ comments: C++ Comments. (line 6)
28735 * C++ compilation options: Invoking GCC. (line 23)
28736 * C++ interface and implementation headers: C++ Interface. (line 6)
28737 * C++ language extensions: C++ Extensions. (line 6)
28738 * C++ member fns, automatically inline: Inline. (line 46)
28739 * C++ misunderstandings: C++ Misunderstandings.
28741 * C++ options, command line: C++ Dialect Options. (line 6)
28742 * C++ pragmas, effect on inlining: C++ Interface. (line 66)
28743 * C++ source file suffixes: Invoking G++. (line 6)
28744 * C++ static data, declaring and defining: Static Definitions.
28746 * C89: Standards. (line 6)
28747 * C90: Standards. (line 6)
28748 * C94: Standards. (line 6)
28749 * C95: Standards. (line 6)
28750 * C99: Standards. (line 6)
28751 * C9X: Standards. (line 6)
28752 * C_INCLUDE_PATH: Environment Variables.
28754 * cabs: Other Builtins. (line 6)
28755 * cabsf: Other Builtins. (line 6)
28756 * cabsl: Other Builtins. (line 6)
28757 * cacos: Other Builtins. (line 6)
28758 * cacosf: Other Builtins. (line 6)
28759 * cacosh: Other Builtins. (line 6)
28760 * cacoshf: Other Builtins. (line 6)
28761 * cacoshl: Other Builtins. (line 6)
28762 * cacosl: Other Builtins. (line 6)
28763 * calling functions through the function vector on the H8/300 processors: Function Attributes.
28765 * calloc: Other Builtins. (line 6)
28766 * carg: Other Builtins. (line 6)
28767 * cargf: Other Builtins. (line 6)
28768 * cargl: Other Builtins. (line 6)
28769 * case labels in initializers: Designated Inits. (line 6)
28770 * case ranges: Case Ranges. (line 6)
28771 * casin: Other Builtins. (line 6)
28772 * casinf: Other Builtins. (line 6)
28773 * casinh: Other Builtins. (line 6)
28774 * casinhf: Other Builtins. (line 6)
28775 * casinhl: Other Builtins. (line 6)
28776 * casinl: Other Builtins. (line 6)
28777 * cast to a union: Cast to Union. (line 6)
28778 * catan: Other Builtins. (line 6)
28779 * catanf: Other Builtins. (line 6)
28780 * catanh: Other Builtins. (line 6)
28781 * catanhf: Other Builtins. (line 6)
28782 * catanhl: Other Builtins. (line 6)
28783 * catanl: Other Builtins. (line 6)
28784 * cbrt: Other Builtins. (line 6)
28785 * cbrtf: Other Builtins. (line 6)
28786 * cbrtl: Other Builtins. (line 6)
28787 * ccos: Other Builtins. (line 6)
28788 * ccosf: Other Builtins. (line 6)
28789 * ccosh: Other Builtins. (line 6)
28790 * ccoshf: Other Builtins. (line 6)
28791 * ccoshl: Other Builtins. (line 6)
28792 * ccosl: Other Builtins. (line 6)
28793 * ceil: Other Builtins. (line 6)
28794 * ceilf: Other Builtins. (line 6)
28795 * ceill: Other Builtins. (line 6)
28796 * cexp: Other Builtins. (line 6)
28797 * cexpf: Other Builtins. (line 6)
28798 * cexpl: Other Builtins. (line 6)
28799 * character set, execution: Preprocessor Options.
28801 * character set, input: Preprocessor Options.
28803 * character set, wide execution: Preprocessor Options.
28805 * cimag: Other Builtins. (line 6)
28806 * cimagf: Other Builtins. (line 6)
28807 * cimagl: Other Builtins. (line 6)
28808 * cleanup attribute: Variable Attributes. (line 76)
28809 * COBOL: G++ and GCC. (line 23)
28810 * code generation conventions: Code Gen Options. (line 6)
28811 * code, mixed with declarations: Mixed Declarations. (line 6)
28812 * command options: Invoking GCC. (line 6)
28813 * comments, C++ style: C++ Comments. (line 6)
28814 * common attribute: Variable Attributes. (line 92)
28815 * comparison of signed and unsigned values, warning: Warning Options.
28817 * compiler bugs, reporting: Bug Reporting. (line 6)
28818 * compiler compared to C++ preprocessor: G++ and GCC. (line 35)
28819 * compiler options, C++: C++ Dialect Options. (line 6)
28820 * compiler options, Objective-C and Objective-C++: Objective-C and Objective-C++ Dialect Options.
28822 * compiler version, specifying: Target Options. (line 6)
28823 * COMPILER_PATH: Environment Variables.
28825 * complex conjugation: Complex. (line 34)
28826 * complex numbers: Complex. (line 6)
28827 * compound literals: Compound Literals. (line 6)
28828 * computed gotos: Labels as Values. (line 6)
28829 * conditional expressions, extensions: Conditionals. (line 6)
28830 * conflicting types: Disappointments. (line 21)
28831 * conj: Other Builtins. (line 6)
28832 * conjf: Other Builtins. (line 6)
28833 * conjl: Other Builtins. (line 6)
28834 * const applied to function: Function Attributes. (line 6)
28835 * const function attribute: Function Attributes. (line 55)
28836 * constants in constraints: Simple Constraints. (line 58)
28837 * constraint modifier characters: Modifiers. (line 6)
28838 * constraint, matching: Simple Constraints. (line 127)
28839 * constraints, asm: Constraints. (line 6)
28840 * constraints, machine specific: Machine Constraints. (line 6)
28841 * constructing calls: Constructing Calls. (line 6)
28842 * constructor expressions: Compound Literals. (line 6)
28843 * constructor function attribute: Function Attributes. (line 81)
28844 * contributors: Contributors. (line 6)
28845 * copysign: Other Builtins. (line 6)
28846 * copysignf: Other Builtins. (line 6)
28847 * copysignl: Other Builtins. (line 6)
28848 * core dump: Bug Criteria. (line 9)
28849 * cos: Other Builtins. (line 6)
28850 * cosf: Other Builtins. (line 6)
28851 * cosh: Other Builtins. (line 6)
28852 * coshf: Other Builtins. (line 6)
28853 * coshl: Other Builtins. (line 6)
28854 * cosl: Other Builtins. (line 6)
28855 * CPATH: Environment Variables.
28857 * CPLUS_INCLUDE_PATH: Environment Variables.
28859 * cpow: Other Builtins. (line 6)
28860 * cpowf: Other Builtins. (line 6)
28861 * cpowl: Other Builtins. (line 6)
28862 * cproj: Other Builtins. (line 6)
28863 * cprojf: Other Builtins. (line 6)
28864 * cprojl: Other Builtins. (line 6)
28865 * creal: Other Builtins. (line 6)
28866 * crealf: Other Builtins. (line 6)
28867 * creall: Other Builtins. (line 6)
28868 * CRIS Options: CRIS Options. (line 6)
28869 * cross compiling: Target Options. (line 6)
28870 * csin: Other Builtins. (line 6)
28871 * csinf: Other Builtins. (line 6)
28872 * csinh: Other Builtins. (line 6)
28873 * csinhf: Other Builtins. (line 6)
28874 * csinhl: Other Builtins. (line 6)
28875 * csinl: Other Builtins. (line 6)
28876 * csqrt: Other Builtins. (line 6)
28877 * csqrtf: Other Builtins. (line 6)
28878 * csqrtl: Other Builtins. (line 6)
28879 * ctan: Other Builtins. (line 6)
28880 * ctanf: Other Builtins. (line 6)
28881 * ctanh: Other Builtins. (line 6)
28882 * ctanhf: Other Builtins. (line 6)
28883 * ctanhl: Other Builtins. (line 6)
28884 * ctanl: Other Builtins. (line 6)
28885 * Darwin options: Darwin Options. (line 6)
28886 * dcgettext: Other Builtins. (line 6)
28887 * deallocating variable length arrays: Variable Length. (line 23)
28888 * debugging information options: Debugging Options. (line 6)
28889 * declaration scope: Incompatibilities. (line 80)
28890 * declarations inside expressions: Statement Exprs. (line 6)
28891 * declarations, mixed with code: Mixed Declarations. (line 6)
28892 * declaring attributes of functions: Function Attributes. (line 6)
28893 * declaring static data in C++: Static Definitions. (line 6)
28894 * defining static data in C++: Static Definitions. (line 6)
28895 * dependencies for make as output: Environment Variables.
28897 * dependencies, make: Preprocessor Options.
28899 * DEPENDENCIES_OUTPUT: Environment Variables.
28901 * dependent name lookup: Name lookup. (line 6)
28902 * deprecated attribute: Variable Attributes. (line 100)
28903 * deprecated attribute.: Function Attributes. (line 92)
28904 * designated initializers: Designated Inits. (line 6)
28905 * designator lists: Designated Inits. (line 94)
28906 * designators: Designated Inits. (line 61)
28907 * destructor function attribute: Function Attributes. (line 81)
28908 * dgettext: Other Builtins. (line 6)
28909 * diagnostic messages: Language Independent Options.
28911 * dialect options: C Dialect Options. (line 6)
28912 * digits in constraint: Simple Constraints. (line 115)
28913 * directory options: Directory Options. (line 6)
28914 * dollar signs in identifier names: Dollar Signs. (line 6)
28915 * double-word arithmetic: Long Long. (line 6)
28916 * downward funargs: Nested Functions. (line 6)
28917 * drem: Other Builtins. (line 6)
28918 * dremf: Other Builtins. (line 6)
28919 * dreml: Other Builtins. (line 6)
28920 * E in constraint: Simple Constraints. (line 77)
28921 * earlyclobber operand: Modifiers. (line 25)
28922 * eight bit data on the H8/300, H8/300H, and H8S: Function Attributes.
28924 * empty structures: Empty Structures. (line 6)
28925 * environment variables: Environment Variables.
28927 * erf: Other Builtins. (line 6)
28928 * erfc: Other Builtins. (line 6)
28929 * erfcf: Other Builtins. (line 6)
28930 * erfcl: Other Builtins. (line 6)
28931 * erff: Other Builtins. (line 6)
28932 * erfl: Other Builtins. (line 6)
28933 * error messages: Warnings and Errors. (line 6)
28934 * escaped newlines: Escaped Newlines. (line 6)
28935 * exclamation point: Multi-Alternative. (line 33)
28936 * exit: Other Builtins. (line 6)
28937 * exp: Other Builtins. (line 6)
28938 * exp10: Other Builtins. (line 6)
28939 * exp10f: Other Builtins. (line 6)
28940 * exp10l: Other Builtins. (line 6)
28941 * exp2: Other Builtins. (line 6)
28942 * exp2f: Other Builtins. (line 6)
28943 * exp2l: Other Builtins. (line 6)
28944 * expf: Other Builtins. (line 6)
28945 * expl: Other Builtins. (line 6)
28946 * explicit register variables: Explicit Reg Vars. (line 6)
28947 * expm1: Other Builtins. (line 6)
28948 * expm1f: Other Builtins. (line 6)
28949 * expm1l: Other Builtins. (line 6)
28950 * expressions containing statements: Statement Exprs. (line 6)
28951 * expressions, constructor: Compound Literals. (line 6)
28952 * extended asm: Extended Asm. (line 6)
28953 * extensible constraints: Simple Constraints. (line 151)
28954 * extensions, ?:: Conditionals. (line 6)
28955 * extensions, C language: C Extensions. (line 6)
28956 * extensions, C++ language: C++ Extensions. (line 6)
28957 * external declaration scope: Incompatibilities. (line 80)
28958 * F in constraint: Simple Constraints. (line 82)
28959 * fabs: Other Builtins. (line 6)
28960 * fabsf: Other Builtins. (line 6)
28961 * fabsl: Other Builtins. (line 6)
28962 * fatal signal: Bug Criteria. (line 9)
28963 * fdim: Other Builtins. (line 6)
28964 * fdimf: Other Builtins. (line 6)
28965 * fdiml: Other Builtins. (line 6)
28966 * FDL, GNU Free Documentation License: GNU Free Documentation License.
28968 * ffs: Other Builtins. (line 6)
28969 * file name suffix: Overall Options. (line 14)
28970 * file names: Link Options. (line 10)
28971 * flexible array members: Zero Length. (line 6)
28972 * float as function value type: Incompatibilities. (line 141)
28973 * floating point precision <1>: Disappointments. (line 68)
28974 * floating point precision: Optimize Options. (line 960)
28975 * floor: Other Builtins. (line 6)
28976 * floorf: Other Builtins. (line 6)
28977 * floorl: Other Builtins. (line 6)
28978 * fma: Other Builtins. (line 6)
28979 * fmaf: Other Builtins. (line 6)
28980 * fmal: Other Builtins. (line 6)
28981 * fmax: Other Builtins. (line 6)
28982 * fmaxf: Other Builtins. (line 6)
28983 * fmaxl: Other Builtins. (line 6)
28984 * fmin: Other Builtins. (line 6)
28985 * fminf: Other Builtins. (line 6)
28986 * fminl: Other Builtins. (line 6)
28987 * fmod: Other Builtins. (line 6)
28988 * fmodf: Other Builtins. (line 6)
28989 * fmodl: Other Builtins. (line 6)
28990 * format function attribute: Function Attributes. (line 222)
28991 * format_arg function attribute: Function Attributes. (line 275)
28992 * Fortran: G++ and GCC. (line 6)
28993 * forwarding calls: Constructing Calls. (line 6)
28994 * fprintf: Other Builtins. (line 6)
28995 * fprintf_unlocked: Other Builtins. (line 6)
28996 * fputs: Other Builtins. (line 6)
28997 * fputs_unlocked: Other Builtins. (line 6)
28998 * freestanding environment: Standards. (line 6)
28999 * freestanding implementation: Standards. (line 6)
29000 * frexp: Other Builtins. (line 6)
29001 * frexpf: Other Builtins. (line 6)
29002 * frexpl: Other Builtins. (line 6)
29003 * FRV Options: FRV Options. (line 6)
29004 * fscanf: Other Builtins. (line 6)
29005 * fscanf, and constant strings: Incompatibilities. (line 17)
29006 * function addressability on the M32R/D: Function Attributes. (line 384)
29007 * function attributes: Function Attributes. (line 6)
29008 * function pointers, arithmetic: Pointer Arith. (line 6)
29009 * function prototype declarations: Function Prototypes. (line 6)
29010 * function without a prologue/epilogue code: Function Attributes.
29012 * function, size of pointer to: Pointer Arith. (line 6)
29013 * functions called via pointer on the RS/6000 and PowerPC: Function Attributes.
29015 * functions in arbitrary sections: Function Attributes. (line 6)
29016 * functions that are passed arguments in registers on the 386: Function Attributes.
29018 * functions that behave like malloc: Function Attributes. (line 6)
29019 * functions that do not pop the argument stack on the 386: Function Attributes.
29021 * functions that do pop the argument stack on the 386: Function Attributes.
29023 * functions that have no side effects: Function Attributes. (line 6)
29024 * functions that never return: Function Attributes. (line 6)
29025 * functions that pop the argument stack on the 386: Function Attributes.
29027 * functions which do not handle memory bank switching on 68HC11/68HC12: Function Attributes.
29029 * functions which handle memory bank switching: Function Attributes.
29031 * functions with non-null pointer arguments: Function Attributes.
29033 * functions with printf, scanf, strftime or strfmon style arguments: Function Attributes.
29035 * g in constraint: Simple Constraints. (line 108)
29036 * G in constraint: Simple Constraints. (line 86)
29037 * g++: Invoking G++. (line 13)
29038 * G++: G++ and GCC. (line 30)
29039 * gamma: Other Builtins. (line 6)
29040 * gammaf: Other Builtins. (line 6)
29041 * gammal: Other Builtins. (line 6)
29042 * GCC: G++ and GCC. (line 6)
29043 * GCC command options: Invoking GCC. (line 6)
29044 * GCC_EXEC_PREFIX: Environment Variables.
29046 * gcc_struct: Type Attributes. (line 288)
29047 * gcc_struct attribute: Variable Attributes. (line 296)
29048 * gettext: Other Builtins. (line 6)
29049 * global offset table: Code Gen Options. (line 170)
29050 * global register after longjmp: Global Reg Vars. (line 66)
29051 * global register variables: Global Reg Vars. (line 6)
29052 * GNAT: G++ and GCC. (line 30)
29053 * GNU C Compiler: G++ and GCC. (line 6)
29054 * GNU Compiler Collection: G++ and GCC. (line 6)
29055 * goto with computed label: Labels as Values. (line 6)
29056 * gp-relative references (MIPS): MIPS Options. (line 195)
29057 * gprof: Debugging Options. (line 127)
29058 * grouping options: Invoking GCC. (line 26)
29059 * H in constraint: Simple Constraints. (line 86)
29060 * hardware models and configurations, specifying: Submodel Options.
29062 * hex floats: Hex Floats. (line 6)
29063 * hosted environment <1>: C Dialect Options. (line 162)
29064 * hosted environment: Standards. (line 6)
29065 * hosted implementation: Standards. (line 6)
29066 * HPPA Options: HPPA Options. (line 6)
29067 * hypot: Other Builtins. (line 6)
29068 * hypotf: Other Builtins. (line 6)
29069 * hypotl: Other Builtins. (line 6)
29070 * I in constraint: Simple Constraints. (line 69)
29071 * i in constraint: Simple Constraints. (line 58)
29072 * i386 Options: i386 and x86-64 Options.
29074 * IA-64 Options: IA-64 Options. (line 6)
29075 * IBM RS/6000 and PowerPC Options: RS/6000 and PowerPC Options.
29077 * identifier names, dollar signs in: Dollar Signs. (line 6)
29078 * identifiers, names in assembler code: Asm Labels. (line 6)
29079 * ilogb: Other Builtins. (line 6)
29080 * ilogbf: Other Builtins. (line 6)
29081 * ilogbl: Other Builtins. (line 6)
29082 * imaxabs: Other Builtins. (line 6)
29083 * implementation-defined behavior, C language: C Implementation.
29085 * implied #pragma implementation: C++ Interface. (line 46)
29086 * incompatibilities of GCC: Incompatibilities. (line 6)
29087 * increment operators: Bug Criteria. (line 17)
29088 * index: Other Builtins. (line 6)
29089 * indirect calls on ARM: Function Attributes. (line 353)
29090 * init_priority attribute: C++ Attributes. (line 9)
29091 * initializations in expressions: Compound Literals. (line 6)
29092 * initializers with labeled elements: Designated Inits. (line 6)
29093 * initializers, non-constant: Initializers. (line 6)
29094 * inline automatic for C++ member fns: Inline. (line 46)
29095 * inline functions: Inline. (line 6)
29096 * inline functions, omission of: Inline. (line 51)
29097 * inlining and C++ pragmas: C++ Interface. (line 66)
29098 * installation trouble: Trouble. (line 6)
29099 * integrating function code: Inline. (line 6)
29100 * Intel 386 Options: i386 and x86-64 Options.
29102 * interface and implementation headers, C++: C++ Interface. (line 6)
29103 * intermediate C version, nonexistent: G++ and GCC. (line 35)
29104 * interrupt handler functions: Function Attributes. (line 325)
29105 * interrupt handler functions on the m68k, H8/300 and SH processors: Function Attributes.
29107 * introduction: Top. (line 6)
29108 * invalid assembly code: Bug Criteria. (line 12)
29109 * invalid input: Bug Criteria. (line 42)
29110 * invoking g++: Invoking G++. (line 23)
29111 * isalnum: Other Builtins. (line 6)
29112 * isalpha: Other Builtins. (line 6)
29113 * isascii: Other Builtins. (line 6)
29114 * isblank: Other Builtins. (line 6)
29115 * iscntrl: Other Builtins. (line 6)
29116 * isdigit: Other Builtins. (line 6)
29117 * isgraph: Other Builtins. (line 6)
29118 * islower: Other Builtins. (line 6)
29119 * ISO 9899: Standards. (line 6)
29120 * ISO C: Standards. (line 6)
29121 * ISO C standard: Standards. (line 6)
29122 * ISO C90: Standards. (line 6)
29123 * ISO C94: Standards. (line 6)
29124 * ISO C95: Standards. (line 6)
29125 * ISO C99: Standards. (line 6)
29126 * ISO C9X: Standards. (line 6)
29127 * ISO support: C Dialect Options. (line 10)
29128 * ISO/IEC 9899: Standards. (line 6)
29129 * isprint: Other Builtins. (line 6)
29130 * ispunct: Other Builtins. (line 6)
29131 * isspace: Other Builtins. (line 6)
29132 * isupper: Other Builtins. (line 6)
29133 * iswalnum: Other Builtins. (line 6)
29134 * iswalpha: Other Builtins. (line 6)
29135 * iswblank: Other Builtins. (line 6)
29136 * iswcntrl: Other Builtins. (line 6)
29137 * iswdigit: Other Builtins. (line 6)
29138 * iswgraph: Other Builtins. (line 6)
29139 * iswlower: Other Builtins. (line 6)
29140 * iswprint: Other Builtins. (line 6)
29141 * iswpunct: Other Builtins. (line 6)
29142 * iswspace: Other Builtins. (line 6)
29143 * iswupper: Other Builtins. (line 6)
29144 * iswxdigit: Other Builtins. (line 6)
29145 * isxdigit: Other Builtins. (line 6)
29146 * j0: Other Builtins. (line 6)
29147 * j0f: Other Builtins. (line 6)
29148 * j0l: Other Builtins. (line 6)
29149 * j1: Other Builtins. (line 6)
29150 * j1f: Other Builtins. (line 6)
29151 * j1l: Other Builtins. (line 6)
29152 * Java: G++ and GCC. (line 6)
29153 * java_interface attribute: C++ Attributes. (line 29)
29154 * jn: Other Builtins. (line 6)
29155 * jnf: Other Builtins. (line 6)
29156 * jnl: Other Builtins. (line 6)
29157 * keywords, alternate: Alternate Keywords. (line 6)
29158 * known causes of trouble: Trouble. (line 6)
29159 * labeled elements in initializers: Designated Inits. (line 6)
29160 * labels as values: Labels as Values. (line 6)
29161 * labs: Other Builtins. (line 6)
29162 * LANG: Environment Variables.
29164 * language dialect options: C Dialect Options. (line 6)
29165 * LC_ALL: Environment Variables.
29167 * LC_CTYPE: Environment Variables.
29169 * LC_MESSAGES: Environment Variables.
29171 * ldexp: Other Builtins. (line 6)
29172 * ldexpf: Other Builtins. (line 6)
29173 * ldexpl: Other Builtins. (line 6)
29174 * length-zero arrays: Zero Length. (line 6)
29175 * lgamma: Other Builtins. (line 6)
29176 * lgammaf: Other Builtins. (line 6)
29177 * lgammal: Other Builtins. (line 6)
29178 * Libraries: Link Options. (line 24)
29179 * LIBRARY_PATH: Environment Variables.
29181 * link options: Link Options. (line 6)
29182 * LL integer suffix: Long Long. (line 6)
29183 * llabs: Other Builtins. (line 6)
29184 * llrint: Other Builtins. (line 6)
29185 * llrintf: Other Builtins. (line 6)
29186 * llrintl: Other Builtins. (line 6)
29187 * llround: Other Builtins. (line 6)
29188 * llroundf: Other Builtins. (line 6)
29189 * llroundl: Other Builtins. (line 6)
29190 * load address instruction: Simple Constraints. (line 142)
29191 * local labels: Local Labels. (line 6)
29192 * local variables in macros: Typeof. (line 42)
29193 * local variables, specifying registers: Local Reg Vars. (line 6)
29194 * locale: Environment Variables.
29196 * locale definition: Environment Variables.
29198 * log: Other Builtins. (line 6)
29199 * log10: Other Builtins. (line 6)
29200 * log10f: Other Builtins. (line 6)
29201 * log10l: Other Builtins. (line 6)
29202 * log1p: Other Builtins. (line 6)
29203 * log1pf: Other Builtins. (line 6)
29204 * log1pl: Other Builtins. (line 6)
29205 * log2: Other Builtins. (line 6)
29206 * log2f: Other Builtins. (line 6)
29207 * log2l: Other Builtins. (line 6)
29208 * logb: Other Builtins. (line 6)
29209 * logbf: Other Builtins. (line 6)
29210 * logbl: Other Builtins. (line 6)
29211 * logf: Other Builtins. (line 6)
29212 * logl: Other Builtins. (line 6)
29213 * long long data types: Long Long. (line 6)
29214 * longjmp: Global Reg Vars. (line 66)
29215 * longjmp incompatibilities: Incompatibilities. (line 39)
29216 * longjmp warnings: Warning Options. (line 457)
29217 * lrint: Other Builtins. (line 6)
29218 * lrintf: Other Builtins. (line 6)
29219 * lrintl: Other Builtins. (line 6)
29220 * lround: Other Builtins. (line 6)
29221 * lroundf: Other Builtins. (line 6)
29222 * lroundl: Other Builtins. (line 6)
29223 * m in constraint: Simple Constraints. (line 17)
29224 * M32R/D options: M32R/D Options. (line 6)
29225 * M680x0 options: M680x0 Options. (line 6)
29226 * M68hc1x options: M68hc1x Options. (line 6)
29227 * machine dependent options: Submodel Options. (line 6)
29228 * machine specific constraints: Machine Constraints. (line 6)
29229 * macro with variable arguments: Variadic Macros. (line 6)
29230 * macros containing asm: Extended Asm. (line 239)
29231 * macros, inline alternative: Inline. (line 6)
29232 * macros, local labels: Local Labels. (line 6)
29233 * macros, local variables in: Typeof. (line 42)
29234 * macros, statements in expressions: Statement Exprs. (line 6)
29235 * macros, types of arguments: Typeof. (line 6)
29236 * make: Preprocessor Options.
29238 * malloc: Other Builtins. (line 6)
29239 * malloc attribute: Function Attributes. (line 374)
29240 * matching constraint: Simple Constraints. (line 127)
29241 * MCore options: MCore Options. (line 6)
29242 * member fns, automatically inline: Inline. (line 46)
29243 * memcmp: Other Builtins. (line 6)
29244 * memcpy: Other Builtins. (line 6)
29245 * memory references in constraints: Simple Constraints. (line 17)
29246 * mempcpy: Other Builtins. (line 6)
29247 * memset: Other Builtins. (line 6)
29248 * Mercury: G++ and GCC. (line 23)
29249 * message formatting: Language Independent Options.
29251 * messages, warning: Warning Options. (line 6)
29252 * messages, warning and error: Warnings and Errors. (line 6)
29253 * middle-operands, omitted: Conditionals. (line 6)
29254 * MIPS options: MIPS Options. (line 6)
29255 * misunderstandings in C++: C++ Misunderstandings.
29257 * mixed declarations and code: Mixed Declarations. (line 6)
29258 * mktemp, and constant strings: Incompatibilities. (line 13)
29259 * MMIX Options: MMIX Options. (line 6)
29260 * MN10300 options: MN10300 Options. (line 6)
29261 * mode attribute: Variable Attributes. (line 118)
29262 * modf: Other Builtins. (line 6)
29263 * modff: Other Builtins. (line 6)
29264 * modfl: Other Builtins. (line 6)
29265 * modifiers in constraints: Modifiers. (line 6)
29266 * ms_struct: Type Attributes. (line 288)
29267 * ms_struct attribute: Variable Attributes. (line 296)
29268 * mudflap: Optimize Options. (line 319)
29269 * multiple alternative constraints: Multi-Alternative. (line 6)
29270 * multiprecision arithmetic: Long Long. (line 6)
29271 * n in constraint: Simple Constraints. (line 63)
29272 * names used in assembler code: Asm Labels. (line 6)
29273 * naming convention, implementation headers: C++ Interface. (line 46)
29274 * nearbyint: Other Builtins. (line 6)
29275 * nearbyintf: Other Builtins. (line 6)
29276 * nearbyintl: Other Builtins. (line 6)
29277 * nested functions: Nested Functions. (line 6)
29278 * newlines (escaped): Escaped Newlines. (line 6)
29279 * nextafter: Other Builtins. (line 6)
29280 * nextafterf: Other Builtins. (line 6)
29281 * nextafterl: Other Builtins. (line 6)
29282 * nexttoward: Other Builtins. (line 6)
29283 * nexttowardf: Other Builtins. (line 6)
29284 * nexttowardl: Other Builtins. (line 6)
29285 * no_instrument_function function attribute: Function Attributes.
29287 * nocommon attribute: Variable Attributes. (line 92)
29288 * noinline function attribute: Function Attributes. (line 429)
29289 * non-constant initializers: Initializers. (line 6)
29290 * non-static inline function: Inline. (line 63)
29291 * nonnull function attribute: Function Attributes. (line 433)
29292 * noreturn function attribute: Function Attributes. (line 456)
29293 * nothrow function attribute: Function Attributes. (line 498)
29294 * NS32K options: NS32K Options. (line 6)
29295 * o in constraint: Simple Constraints. (line 21)
29296 * OBJC_INCLUDE_PATH: Environment Variables.
29298 * Objective-C <1>: Standards. (line 110)
29299 * Objective-C: G++ and GCC. (line 6)
29300 * Objective-C and Objective-C++ options, command line: Objective-C and Objective-C++ Dialect Options.
29302 * Objective-C++ <1>: Standards. (line 110)
29303 * Objective-C++: G++ and GCC. (line 6)
29304 * offsettable address: Simple Constraints. (line 21)
29305 * old-style function definitions: Function Prototypes. (line 6)
29306 * omitted middle-operands: Conditionals. (line 6)
29307 * open coding: Inline. (line 6)
29308 * operand constraints, asm: Constraints. (line 6)
29309 * optimize options: Optimize Options. (line 6)
29310 * options to control diagnostics formatting: Language Independent Options.
29312 * options to control warnings: Warning Options. (line 6)
29313 * options, C++: C++ Dialect Options. (line 6)
29314 * options, code generation: Code Gen Options. (line 6)
29315 * options, debugging: Debugging Options. (line 6)
29316 * options, dialect: C Dialect Options. (line 6)
29317 * options, directory search: Directory Options. (line 6)
29318 * options, GCC command: Invoking GCC. (line 6)
29319 * options, grouping: Invoking GCC. (line 26)
29320 * options, linking: Link Options. (line 6)
29321 * options, Objective-C and Objective-C++: Objective-C and Objective-C++ Dialect Options.
29323 * options, optimization: Optimize Options. (line 6)
29324 * options, order: Invoking GCC. (line 30)
29325 * options, preprocessor: Preprocessor Options.
29327 * order of evaluation, side effects: Non-bugs. (line 199)
29328 * order of options: Invoking GCC. (line 30)
29329 * other register constraints: Simple Constraints. (line 151)
29330 * output file option: Overall Options. (line 166)
29331 * overloaded virtual fn, warning: C++ Dialect Options. (line 372)
29332 * p in constraint: Simple Constraints. (line 142)
29333 * packed attribute: Variable Attributes. (line 129)
29334 * parameter forward declaration: Variable Length. (line 60)
29335 * parameters, aliased: Code Gen Options. (line 325)
29336 * Pascal: G++ and GCC. (line 23)
29337 * PDP-11 Options: PDP-11 Options. (line 6)
29338 * PIC: Code Gen Options. (line 170)
29339 * pmf: Bound member functions.
29341 * pointer arguments: Function Attributes. (line 60)
29342 * pointer to member function: Bound member functions.
29344 * portions of temporary objects, pointers to: Temporaries. (line 6)
29345 * pow: Other Builtins. (line 6)
29346 * pow10: Other Builtins. (line 6)
29347 * pow10f: Other Builtins. (line 6)
29348 * pow10l: Other Builtins. (line 6)
29349 * PowerPC options: PowerPC Options. (line 6)
29350 * powf: Other Builtins. (line 6)
29351 * powl: Other Builtins. (line 6)
29352 * pragma, align: Solaris Pragmas. (line 11)
29353 * pragma, extern_prefix: Symbol-Renaming Pragmas.
29355 * pragma, fini: Solaris Pragmas. (line 19)
29356 * pragma, init: Solaris Pragmas. (line 24)
29357 * pragma, long_calls: ARM Pragmas. (line 11)
29358 * pragma, long_calls_off: ARM Pragmas. (line 17)
29359 * pragma, longcall: RS/6000 and PowerPC Pragmas.
29361 * pragma, mark: Darwin Pragmas. (line 11)
29362 * pragma, no_long_calls: ARM Pragmas. (line 14)
29363 * pragma, options align: Darwin Pragmas. (line 14)
29364 * pragma, reason for not using: Function Attributes. (line 713)
29365 * pragma, redefine_extname: Symbol-Renaming Pragmas.
29367 * pragma, segment: Darwin Pragmas. (line 21)
29368 * pragma, unused: Darwin Pragmas. (line 24)
29369 * pragma, weak: Weak Pragmas. (line 10)
29370 * pragmas: Pragmas. (line 6)
29371 * pragmas in C++, effect on inlining: C++ Interface. (line 66)
29372 * pragmas, interface and implementation: C++ Interface. (line 6)
29373 * pragmas, warning of unknown: Warning Options. (line 474)
29374 * precompiled headers: Precompiled Headers. (line 6)
29375 * preprocessing numbers: Incompatibilities. (line 173)
29376 * preprocessing tokens: Incompatibilities. (line 173)
29377 * preprocessor options: Preprocessor Options.
29379 * printf: Other Builtins. (line 6)
29380 * printf_unlocked: Other Builtins. (line 6)
29381 * prof: Debugging Options. (line 121)
29382 * promotion of formal parameters: Function Prototypes. (line 6)
29383 * pure function attribute: Function Attributes. (line 506)
29384 * push address instruction: Simple Constraints. (line 142)
29385 * putchar: Other Builtins. (line 6)
29386 * puts: Other Builtins. (line 6)
29387 * qsort, and global register variables: Global Reg Vars. (line 42)
29388 * question mark: Multi-Alternative. (line 27)
29389 * r in constraint: Simple Constraints. (line 54)
29390 * ranges in case statements: Case Ranges. (line 6)
29391 * read-only strings: Incompatibilities. (line 9)
29392 * register variable after longjmp: Global Reg Vars. (line 66)
29393 * registers: Extended Asm. (line 6)
29394 * registers for local variables: Local Reg Vars. (line 6)
29395 * registers in constraints: Simple Constraints. (line 54)
29396 * registers, global allocation: Explicit Reg Vars. (line 6)
29397 * registers, global variables in: Global Reg Vars. (line 6)
29398 * regparm attribute: Function Attributes. (line 528)
29399 * relocation truncated to fit (MIPS): MIPS Options. (line 111)
29400 * remainder: Other Builtins. (line 6)
29401 * remainderf: Other Builtins. (line 6)
29402 * remainderl: Other Builtins. (line 6)
29403 * remquo: Other Builtins. (line 6)
29404 * remquof: Other Builtins. (line 6)
29405 * remquol: Other Builtins. (line 6)
29406 * reordering, warning: C++ Dialect Options. (line 300)
29407 * reporting bugs: Bugs. (line 6)
29408 * rest argument (in macro): Variadic Macros. (line 6)
29409 * restricted pointers: Restricted Pointers. (line 6)
29410 * restricted references: Restricted Pointers. (line 6)
29411 * restricted this pointer: Restricted Pointers. (line 6)
29412 * rindex: Other Builtins. (line 6)
29413 * rint: Other Builtins. (line 6)
29414 * rintf: Other Builtins. (line 6)
29415 * rintl: Other Builtins. (line 6)
29416 * round: Other Builtins. (line 6)
29417 * roundf: Other Builtins. (line 6)
29418 * roundl: Other Builtins. (line 6)
29419 * RS/6000 and PowerPC Options: RS/6000 and PowerPC Options.
29421 * RTTI: Vague Linkage. (line 43)
29422 * run-time options: Code Gen Options. (line 6)
29423 * s in constraint: Simple Constraints. (line 90)
29424 * S/390 and zSeries Options: S/390 and zSeries Options.
29426 * save all registers on the H8/300, H8/300H, and H8S: Function Attributes.
29428 * scalb: Other Builtins. (line 6)
29429 * scalbf: Other Builtins. (line 6)
29430 * scalbl: Other Builtins. (line 6)
29431 * scalbln: Other Builtins. (line 6)
29432 * scalblnf: Other Builtins. (line 6)
29433 * scalbn: Other Builtins. (line 6)
29434 * scalbnf: Other Builtins. (line 6)
29435 * scanf, and constant strings: Incompatibilities. (line 17)
29436 * scanfnl: Other Builtins. (line 6)
29437 * scope of a variable length array: Variable Length. (line 23)
29438 * scope of declaration: Disappointments. (line 21)
29439 * scope of external declarations: Incompatibilities. (line 80)
29440 * search path: Directory Options. (line 6)
29441 * section function attribute: Function Attributes. (line 550)
29442 * section variable attribute: Variable Attributes. (line 144)
29443 * sentinel function attribute: Function Attributes. (line 566)
29444 * setjmp: Global Reg Vars. (line 66)
29445 * setjmp incompatibilities: Incompatibilities. (line 39)
29446 * shared strings: Incompatibilities. (line 9)
29447 * shared variable attribute: Variable Attributes. (line 189)
29448 * side effect in ?:: Conditionals. (line 20)
29449 * side effects, macro argument: Statement Exprs. (line 35)
29450 * side effects, order of evaluation: Non-bugs. (line 199)
29451 * signal handler functions on the AVR processors: Function Attributes.
29453 * signbit: Other Builtins. (line 6)
29454 * signbitf: Other Builtins. (line 6)
29455 * signbitl: Other Builtins. (line 6)
29456 * signed and unsigned values, comparison warning: Warning Options.
29458 * significand: Other Builtins. (line 6)
29459 * significandf: Other Builtins. (line 6)
29460 * significandl: Other Builtins. (line 6)
29461 * simple constraints: Simple Constraints. (line 6)
29462 * sin: Other Builtins. (line 6)
29463 * sincos: Other Builtins. (line 6)
29464 * sincosf: Other Builtins. (line 6)
29465 * sincosl: Other Builtins. (line 6)
29466 * sinf: Other Builtins. (line 6)
29467 * sinh: Other Builtins. (line 6)
29468 * sinhf: Other Builtins. (line 6)
29469 * sinhl: Other Builtins. (line 6)
29470 * sinl: Other Builtins. (line 6)
29471 * sizeof: Typeof. (line 6)
29472 * smaller data references: M32R/D Options. (line 57)
29473 * smaller data references (MIPS): MIPS Options. (line 195)
29474 * smaller data references (PowerPC): RS/6000 and PowerPC Options.
29476 * snprintf: Other Builtins. (line 6)
29477 * SPARC options: SPARC Options. (line 6)
29478 * Spec Files: Spec Files. (line 6)
29479 * specified registers: Explicit Reg Vars. (line 6)
29480 * specifying compiler version and target machine: Target Options.
29482 * specifying hardware config: Submodel Options. (line 6)
29483 * specifying machine version: Target Options. (line 6)
29484 * specifying registers for local variables: Local Reg Vars. (line 6)
29485 * speed of compilation: Precompiled Headers. (line 6)
29486 * sprintf: Other Builtins. (line 6)
29487 * sqrt: Other Builtins. (line 6)
29488 * sqrtf: Other Builtins. (line 6)
29489 * sqrtl: Other Builtins. (line 6)
29490 * sscanf: Other Builtins. (line 6)
29491 * sscanf, and constant strings: Incompatibilities. (line 17)
29492 * statements inside expressions: Statement Exprs. (line 6)
29493 * static data in C++, declaring and defining: Static Definitions.
29495 * stpcpy: Other Builtins. (line 6)
29496 * strcat: Other Builtins. (line 6)
29497 * strchr: Other Builtins. (line 6)
29498 * strcmp: Other Builtins. (line 6)
29499 * strcpy: Other Builtins. (line 6)
29500 * strcspn: Other Builtins. (line 6)
29501 * strdup: Other Builtins. (line 6)
29502 * strfmon: Other Builtins. (line 6)
29503 * strftime: Other Builtins. (line 6)
29504 * string constants: Incompatibilities. (line 9)
29505 * strlen: Other Builtins. (line 6)
29506 * strncat: Other Builtins. (line 6)
29507 * strncmp: Other Builtins. (line 6)
29508 * strncpy: Other Builtins. (line 6)
29509 * strpbrk: Other Builtins. (line 6)
29510 * strrchr: Other Builtins. (line 6)
29511 * strspn: Other Builtins. (line 6)
29512 * strstr: Other Builtins. (line 6)
29513 * struct: Unnamed Fields. (line 6)
29514 * structures: Incompatibilities. (line 146)
29515 * structures, constructor expression: Compound Literals. (line 6)
29516 * submodel options: Submodel Options. (line 6)
29517 * subscripting: Subscripting. (line 6)
29518 * subscripting and function values: Subscripting. (line 6)
29519 * suffixes for C++ source: Invoking G++. (line 6)
29520 * SUNPRO_DEPENDENCIES: Environment Variables.
29522 * suppressing warnings: Warning Options. (line 6)
29523 * surprises in C++: C++ Misunderstandings.
29525 * syntax checking: Warning Options. (line 22)
29526 * system headers, warnings from: Warning Options. (line 588)
29527 * tan: Other Builtins. (line 6)
29528 * tanf: Other Builtins. (line 6)
29529 * tanh: Other Builtins. (line 6)
29530 * tanhf: Other Builtins. (line 6)
29531 * tanhl: Other Builtins. (line 6)
29532 * tanl: Other Builtins. (line 6)
29533 * target machine, specifying: Target Options. (line 6)
29534 * target options: Target Options. (line 6)
29535 * TC1: Standards. (line 6)
29536 * TC2: Standards. (line 6)
29537 * Technical Corrigenda: Standards. (line 6)
29538 * Technical Corrigendum 1: Standards. (line 6)
29539 * Technical Corrigendum 2: Standards. (line 6)
29540 * template instantiation: Template Instantiation.
29542 * temporaries, lifetime of: Temporaries. (line 6)
29543 * tgamma: Other Builtins. (line 6)
29544 * tgammaf: Other Builtins. (line 6)
29545 * tgammal: Other Builtins. (line 6)
29546 * Thread-Local Storage: Thread-Local. (line 6)
29547 * thunks: Nested Functions. (line 6)
29548 * tiny data section on the H8/300H and H8S: Function Attributes.
29550 * TLS: Thread-Local. (line 6)
29551 * tls_model attribute: Variable Attributes. (line 213)
29552 * TMPDIR: Environment Variables.
29554 * TMS320C3x/C4x Options: TMS320C3x/C4x Options.
29556 * toascii: Other Builtins. (line 6)
29557 * tolower: Other Builtins. (line 6)
29558 * toupper: Other Builtins. (line 6)
29559 * towlower: Other Builtins. (line 6)
29560 * towupper: Other Builtins. (line 6)
29561 * traditional C language: C Dialect Options. (line 200)
29562 * treelang <1>: Standards. (line 123)
29563 * treelang: G++ and GCC. (line 6)
29564 * trunc: Other Builtins. (line 6)
29565 * truncf: Other Builtins. (line 6)
29566 * truncl: Other Builtins. (line 6)
29567 * two-stage name lookup: Name lookup. (line 6)
29568 * type alignment: Alignment. (line 6)
29569 * type attributes: Type Attributes. (line 6)
29570 * type_info: Vague Linkage. (line 43)
29571 * typedef names as function parameters: Incompatibilities. (line 97)
29572 * typeof: Typeof. (line 6)
29573 * ULL integer suffix: Long Long. (line 6)
29574 * Ultrix calling convention: Interoperation. (line 150)
29575 * undefined behavior: Bug Criteria. (line 17)
29576 * undefined function value: Bug Criteria. (line 17)
29577 * underscores in variables in macros: Typeof. (line 42)
29578 * union: Unnamed Fields. (line 6)
29579 * union, casting to a: Cast to Union. (line 6)
29580 * unions: Incompatibilities. (line 146)
29581 * unknown pragmas, warning: Warning Options. (line 474)
29582 * unresolved references and -nodefaultlibs: Link Options. (line 79)
29583 * unresolved references and -nostdlib: Link Options. (line 79)
29584 * unused attribute.: Function Attributes. (line 631)
29585 * used attribute.: Function Attributes. (line 636)
29586 * V in constraint: Simple Constraints. (line 41)
29587 * V850 Options: V850 Options. (line 6)
29588 * vague linkage: Vague Linkage. (line 6)
29589 * value after longjmp: Global Reg Vars. (line 66)
29590 * variable addressability on the IA-64: Function Attributes. (line 384)
29591 * variable addressability on the M32R/D: Variable Attributes. (line 277)
29592 * variable alignment: Alignment. (line 6)
29593 * variable attributes: Variable Attributes. (line 6)
29594 * variable number of arguments: Variadic Macros. (line 6)
29595 * variable-length array scope: Variable Length. (line 23)
29596 * variable-length arrays: Variable Length. (line 6)
29597 * variables in specified registers: Explicit Reg Vars. (line 6)
29598 * variables, local, in macros: Typeof. (line 42)
29599 * variadic macros: Variadic Macros. (line 6)
29600 * VAX calling convention: Interoperation. (line 150)
29601 * VAX options: VAX Options. (line 6)
29602 * vfprintf: Other Builtins. (line 6)
29603 * vfscanf: Other Builtins. (line 6)
29604 * visibility attribute: Function Attributes. (line 642)
29605 * VLAs: Variable Length. (line 6)
29606 * void pointers, arithmetic: Pointer Arith. (line 6)
29607 * void, size of pointer to: Pointer Arith. (line 6)
29608 * volatile access: Volatiles. (line 6)
29609 * volatile applied to function: Function Attributes. (line 6)
29610 * volatile read: Volatiles. (line 6)
29611 * volatile write: Volatiles. (line 6)
29612 * vprintf: Other Builtins. (line 6)
29613 * vscanf: Other Builtins. (line 6)
29614 * vsnprintf: Other Builtins. (line 6)
29615 * vsprintf: Other Builtins. (line 6)
29616 * vsscanf: Other Builtins. (line 6)
29617 * vtable: Vague Linkage. (line 28)
29618 * warn_unused_result attribute: Function Attributes. (line 684)
29619 * warning for comparison of signed and unsigned values: Warning Options.
29621 * warning for overloaded virtual fn: C++ Dialect Options. (line 372)
29622 * warning for reordering of member initializers: C++ Dialect Options.
29624 * warning for unknown pragmas: Warning Options. (line 474)
29625 * warning messages: Warning Options. (line 6)
29626 * warnings from system headers: Warning Options. (line 588)
29627 * warnings vs errors: Warnings and Errors. (line 6)
29628 * weak attribute: Function Attributes. (line 701)
29629 * whitespace: Incompatibilities. (line 112)
29630 * X in constraint: Simple Constraints. (line 112)
29631 * X3.159-1989: Standards. (line 6)
29632 * x86-64 options: x86-64 Options. (line 6)
29633 * x86-64 Options: i386 and x86-64 Options.
29635 * Xstormy16 Options: Xstormy16 Options. (line 6)
29636 * Xtensa Options: Xtensa Options. (line 6)
29637 * y0: Other Builtins. (line 6)
29638 * y0f: Other Builtins. (line 6)
29639 * y0l: Other Builtins. (line 6)
29640 * y1: Other Builtins. (line 6)
29641 * y1f: Other Builtins. (line 6)
29642 * y1l: Other Builtins. (line 6)
29643 * yn: Other Builtins. (line 6)
29644 * ynf: Other Builtins. (line 6)
29645 * ynl: Other Builtins. (line 6)
29646 * zero-length arrays: Zero Length. (line 6)
29647 * zero-size structures: Empty Structures. (line 6)
29648 * zSeries options: zSeries Options. (line 6)
29654 Node: G++ and GCC
\7f3740
29655 Node: Standards
\7f5805
29656 Node: Invoking GCC
\7f12932
29657 Node: Option Summary
\7f16702
29658 Node: Overall Options
\7f42658
29659 Node: Invoking G++
\7f50960
29660 Node: C Dialect Options
\7f52582
29661 Node: C++ Dialect Options
\7f63592
29662 Node: Objective-C and Objective-C++ Dialect Options
\7f80803
29663 Node: Language Independent Options
\7f90253
29664 Node: Warning Options
\7f92064
29665 Node: Debugging Options
\7f133461
29666 Node: Optimize Options
\7f162726
29667 Node: Preprocessor Options
\7f231352
29668 Ref: Wtrigraphs
\7f235316
29669 Ref: dashMF
\7f240073
29670 Ref: fdollars-in-identifiers
\7f248969
29671 Node: Assembler Options
\7f256830
29672 Node: Link Options
\7f257535
29673 Ref: Link Options-Footnote-1
\7f265787
29674 Node: Directory Options
\7f266121
29675 Node: Spec Files
\7f271488
29676 Node: Target Options
\7f290776
29677 Node: Submodel Options
\7f292082
29678 Node: ARC Options
\7f293810
29679 Node: ARM Options
\7f295000
29680 Node: AVR Options
\7f306208
29681 Node: CRIS Options
\7f308337
29682 Node: Darwin Options
\7f312554
29683 Node: DEC Alpha Options
\7f318867
29684 Node: DEC Alpha/VMS Options
\7f330345
29685 Node: FRV Options
\7f330730
29686 Node: H8/300 Options
\7f337114
29687 Node: HPPA Options
\7f338173
29688 Node: i386 and x86-64 Options
\7f347552
29689 Node: IA-64 Options
\7f365305
29690 Node: M32R/D Options
\7f369303
29691 Node: M680x0 Options
\7f372891
29692 Node: M68hc1x Options
\7f380124
29693 Node: MCore Options
\7f381692
29694 Node: MIPS Options
\7f382713
29695 Node: MMIX Options
\7f396775
29696 Node: MN10300 Options
\7f399257
29697 Node: NS32K Options
\7f400317
29698 Node: PDP-11 Options
\7f404862
29699 Node: PowerPC Options
\7f406699
29700 Node: RS/6000 and PowerPC Options
\7f406933
29701 Node: S/390 and zSeries Options
\7f432763
29702 Node: SH Options
\7f439811
29703 Node: SPARC Options
\7f443073
29704 Node: System V Options
\7f453704
29705 Node: TMS320C3x/C4x Options
\7f454538
29706 Node: V850 Options
\7f460063
29707 Node: VAX Options
\7f463208
29708 Node: x86-64 Options
\7f463755
29709 Node: Xstormy16 Options
\7f463969
29710 Node: Xtensa Options
\7f464258
29711 Node: zSeries Options
\7f468098
29712 Node: Code Gen Options
\7f468294
29713 Node: Environment Variables
\7f487553
29714 Node: Precompiled Headers
\7f495225
29715 Node: Running Protoize
\7f501776
29716 Node: C Implementation
\7f508113
29717 Node: Translation implementation
\7f509776
29718 Node: Environment implementation
\7f510350
29719 Node: Identifiers implementation
\7f510900
29720 Node: Characters implementation
\7f511954
29721 Node: Integers implementation
\7f514760
29722 Node: Floating point implementation
\7f516585
29723 Node: Arrays and pointers implementation
\7f519514
29724 Ref: Arrays and pointers implementation-Footnote-1
\7f520949
29725 Node: Hints implementation
\7f521073
29726 Node: Structures unions enumerations and bit-fields implementation
\7f522539
29727 Node: Qualifiers implementation
\7f524502
29728 Node: Declarators implementation
\7f524885
29729 Node: Statements implementation
\7f525227
29730 Node: Preprocessing directives implementation
\7f525554
29731 Node: Library functions implementation
\7f527659
29732 Node: Architecture implementation
\7f528299
29733 Node: Locale-specific behavior implementation
\7f529002
29734 Node: C Extensions
\7f529307
29735 Node: Statement Exprs
\7f533486
29736 Node: Local Labels
\7f537999
29737 Node: Labels as Values
\7f540978
29738 Ref: Labels as Values-Footnote-1
\7f543032
29739 Node: Nested Functions
\7f543215
29740 Node: Constructing Calls
\7f547109
29741 Node: Typeof
\7f549445
29742 Node: Conditionals
\7f552611
29743 Node: Long Long
\7f553502
29744 Node: Complex
\7f555003
29745 Node: Hex Floats
\7f557569
29746 Node: Zero Length
\7f558604
29747 Node: Empty Structures
\7f561881
29748 Node: Variable Length
\7f562297
29749 Node: Variadic Macros
\7f565064
29750 Node: Escaped Newlines
\7f567446
29751 Node: Subscripting
\7f568285
29752 Node: Pointer Arith
\7f569008
29753 Node: Initializers
\7f569576
29754 Node: Compound Literals
\7f570072
29755 Node: Designated Inits
\7f572234
29756 Node: Case Ranges
\7f575889
29757 Node: Cast to Union
\7f576572
29758 Node: Mixed Declarations
\7f577668
29759 Node: Function Attributes
\7f578174
29760 Node: Attribute Syntax
\7f611743
29761 Node: Function Prototypes
\7f622827
29762 Node: C++ Comments
\7f624608
29763 Node: Dollar Signs
\7f625127
29764 Node: Character Escapes
\7f625592
29765 Node: Alignment
\7f625886
29766 Node: Variable Attributes
\7f627203
29767 Node: Type Attributes
\7f640650
29768 Node: Inline
\7f654068
29769 Node: Extended Asm
\7f658772
29770 Ref: Example of asm with clobbered asm reg
\7f664858
29771 Node: Constraints
\7f678954
29772 Node: Simple Constraints
\7f679804
29773 Node: Multi-Alternative
\7f686332
29774 Node: Modifiers
\7f688049
29775 Node: Machine Constraints
\7f690737
29776 Node: Asm Labels
\7f712895
29777 Node: Explicit Reg Vars
\7f714571
29778 Node: Global Reg Vars
\7f716179
29779 Node: Local Reg Vars
\7f720729
29780 Node: Alternate Keywords
\7f723170
29781 Node: Incomplete Enums
\7f724598
29782 Node: Function Names
\7f725355
29783 Node: Return Address
\7f727545
29784 Node: Vector Extensions
\7f730342
29785 Node: Offsetof
\7f733844
29786 Node: Other Builtins
\7f734629
29787 Node: Target Builtins
\7f755734
29788 Node: Alpha Built-in Functions
\7f756403
29789 Node: ARM Built-in Functions
\7f759395
29790 Node: FR-V Built-in Functions
\7f766098
29791 Node: Argument Types
\7f766923
29792 Node: Directly-mapped Integer Functions
\7f768679
29793 Node: Directly-mapped Media Functions
\7f769761
29794 Node: Other Built-in Functions
\7f776793
29795 Node: X86 Built-in Functions
\7f777989
29796 Node: MIPS Paired-Single Support
\7f788381
29797 Node: Paired-Single Arithmetic
\7f789986
29798 Node: Paired-Single Built-in Functions
\7f790926
29799 Node: MIPS-3D Built-in Functions
\7f793590
29800 Node: PowerPC AltiVec Built-in Functions
\7f798959
29801 Node: SPARC VIS Built-in Functions
\7f900263
29802 Node: Target Format Checks
\7f901922
29803 Node: Solaris Format Checks
\7f902329
29804 Node: Pragmas
\7f902726
29805 Node: ARM Pragmas
\7f903293
29806 Node: RS/6000 and PowerPC Pragmas
\7f903911
29807 Node: Darwin Pragmas
\7f904652
29808 Node: Solaris Pragmas
\7f905719
29809 Node: Symbol-Renaming Pragmas
\7f906880
29810 Node: Structure-Packing Pragmas
\7f909502
29811 Node: Weak Pragmas
\7f910731
29812 Node: Unnamed Fields
\7f911506
29813 Node: Thread-Local
\7f913016
29814 Node: C99 Thread-Local Edits
\7f915100
29815 Node: C++98 Thread-Local Edits
\7f917112
29816 Node: C++ Extensions
\7f920557
29817 Node: Volatiles
\7f922129
29818 Node: Restricted Pointers
\7f925475
29819 Node: Vague Linkage
\7f927069
29820 Node: C++ Interface
\7f930725
29821 Ref: C++ Interface-Footnote-1
\7f935022
29822 Node: Template Instantiation
\7f935159
29823 Node: Bound member functions
\7f942171
29824 Node: C++ Attributes
\7f943714
29825 Node: Strong Using
\7f945354
29826 Node: Java Exceptions
\7f946603
29827 Node: Deprecated Features
\7f947999
29828 Node: Backwards Compatibility
\7f950978
29829 Node: Objective-C
\7f952333
29830 Node: Executing code before main
\7f952914
29831 Node: What you can and what you cannot do in +load
\7f955520
29832 Node: Type encoding
\7f957687
29833 Node: Garbage Collection
\7f960930
29834 Node: Constant string objects
\7f963554
29835 Node: compatibility_alias
\7f966062
29836 Node: Compatibility
\7f966940
29837 Node: Gcov
\7f973507
29838 Node: Gcov Intro
\7f973977
29839 Node: Invoking Gcov
\7f976693
29840 Node: Gcov and Optimization
\7f988544
29841 Node: Gcov Data Files
\7f991197
29842 Node: Trouble
\7f992311
29843 Node: Actual Bugs
\7f993851
29844 Node: Cross-Compiler Problems
\7f994591
29845 Node: Interoperation
\7f995005
29846 Node: Incompatibilities
\7f1002603
29847 Node: Fixed Headers
\7f1010753
29848 Node: Standard Libraries
\7f1012416
29849 Node: Disappointments
\7f1013788
29850 Node: C++ Misunderstandings
\7f1018146
29851 Node: Static Definitions
\7f1018965
29852 Node: Name lookup
\7f1020018
29853 Ref: Name lookup-Footnote-1
\7f1024796
29854 Node: Temporaries
\7f1024983
29855 Node: Copy Assignment
\7f1026959
29856 Node: Protoize Caveats
\7f1028766
29857 Node: Non-bugs
\7f1032728
29858 Node: Warnings and Errors
\7f1043351
29859 Node: Bugs
\7f1045115
29860 Node: Bug Criteria
\7f1045679
29861 Node: Bug Reporting
\7f1047889
29862 Node: Service
\7f1048281
29863 Node: Contributing
\7f1049100
29864 Node: Funding
\7f1049840
29865 Node: GNU Project
\7f1052329
29866 Node: Copying
\7f1052975
29867 Node: GNU Free Documentation License
\7f1072125
29868 Node: Contributors
\7f1094521
29869 Node: Option Index
\7f1124568
29870 Node: Keyword Index
\7f1249198