Various egcs-1.0.1 related changes.
[official-gcc.git] / gcc / gcc.1
blob10422c2ea033a02ef83e122eb701263d291a546d
1 .\" Copyright (c) 1991, 1992, 1993, 1994 Free Software Foundation    -*-Text-*-
2 .\" See section COPYING for conditions for redistribution
3 .\"
4 .\" Set up \*(lq, \*(rq if -man hasn't already set it up.
5 .if @@\*(lq@ \{\
6 .       ds lq "
7 .       if t .ds lq ``
8 .       if !@@\(lq@ .ds lq "\(lq
9 .\}
10 .if @@\*(rq@ \{\
11 .       ds rq "
12 .       if t .ds rq ''
13 .       if !@@\(rq@ .ds rq "\(rq
14 .\}
15 .de Id
16 .ds Rv \\$3
17 .ds Dt \\$4
19 .de Sp
20 .if n .sp
21 .if t .sp 0.4
23 .Id $Id: gcc.1,v 1.1.1.1.2.1 1997/12/03 08:07:52 law Exp $
24 .TH GCC 1 "\*(Dt" "GNU Tools" "GNU Tools"
25 .SH NAME
26 gcc, g++ \- GNU project C and C++ Compiler (egcs-1.0.1)
27 .SH SYNOPSIS
28 .B gcc
29 .RI "[ " option " | " filename " ].\|.\|."
30 .br
31 .B g++
32 .RI "[ " option " | " filename " ].\|.\|."
33 .SH WARNING
34 The information in this man page is an extract from the full
35 documentation of the GNU C compiler, and is limited to the meaning of
36 the options.
37 .PP
38 This man page is not kept up to date except when volunteers want to
39 maintain it.  If you find a discrepancy between the man page and the
40 software, please check the Info file, which is the authoritative
41 documentation.
42 .PP
43 If we find that the things in this man page that are out of date cause
44 significant confusion or complaints, we will stop distributing the man
45 page.  The alternative, updating the man page when we update the Info
46 file, is impossible because the rest of the work of maintaining GNU CC
47 leaves us no time for that.  The GNU project regards man pages as
48 obsolete and should not let them take time away from other things.
49 .PP
50 For complete and current documentation, refer to the Info file `\|\c
51 .B gcc\c
52 \&\|' or the manual
54 Using and Porting GNU CC (for version 2.0)\c
55 \&.  Both are made from the Texinfo source file
56 .BR gcc.texinfo .
57 .SH DESCRIPTION
58 The C and C++ compilers are integrated.  Both process input files
59 through one or more of four stages: preprocessing, compilation,
60 assembly, and linking.  Source filename suffixes identify the source
61 language, but which name you use for the compiler governs default
62 assumptions:
63 .TP
64 .B gcc
65 assumes preprocessed (\c
66 .B .i\c
67 \&) files are C and assumes C style linking.
68 .TP
69 .B g++
70 assumes preprocessed (\c
71 .B .i\c
72 \&) files are C++ and assumes C++ style linking.
73 .PP
74 Suffixes of source file names indicate the language and kind of
75 processing to be done:
76 .Sp
77 .nf
78 .ta \w'\fB.cxx\fP  'u
79 \&\fB.c\fP      C source; preprocess, compile, assemble
80 \&\fB.C\fP      C++ source; preprocess, compile, assemble
81 \&\fB.cc\fP     C++ source; preprocess, compile, assemble
82 \&\fB.cxx\fP    C++ source; preprocess, compile, assemble
83 \&\fB.m\fP      Objective-C source; preprocess, compile, assemble
84 \&\fB.i\fP      preprocessed C; compile, assemble
85 \&\fB.ii\fP     preprocessed C++; compile, assemble
86 \&\fB.s\fP      Assembler source; assemble
87 \&\fB.S\fP      Assembler source; preprocess, assemble
88 \&\fB.h\fP      Preprocessor file; not usually named on command line
89 .Sp
90 .fi
91 Files with other suffixes are passed to the linker.  Common cases include:
92 .Sp
93 .nf
94 \&\fB.o\fP      Object file
95 \&\fB.a\fP      Archive file
96 .br
97 .fi
98 .Sp
99 Linking is always the last stage unless you use one of the
100 .BR \-c ,
101 .BR \-S ,
103 .B \-E
104 options to avoid it (or unless compilation errors stop the whole
105 process).  For the link stage, all
106 .B .o
107 files corresponding to source files,
108 .B \-l
109 libraries, unrecognized filenames (including named
110 .B .o
111 object files and
112 .B .a
113 archives)
114 are passed to the linker in command-line order.
115 .SH OPTIONS
116 Options must be separate: `\|\c
117 .B \-dr\c
118 \&\|' is quite different from `\|\c
119 .B \-d \-r
120 \&\|'.
122 Most `\|\c
123 .B \-f\c
124 \&\|' and `\|\c
125 .B \-W\c
126 \&\|' options have two contrary forms:
127 .BI \-f name
129 .BI \-fno\- name\c
130 \& (or
131 .BI \-W name
133 .BI \-Wno\- name\c
134 \&).  Only the non-default forms are shown here.
136 Here is a summary of all the options, grouped by type.  Explanations are
137 in the following sections.
138 .hy 0
141 .B Overall Options
146 .RI "\-o " file
147 \-pipe
149 .RI "\-x " language
151 .B Language Options
152 \-ansi
153 \-fall\-virtual
154 \-fcond\-mismatch
155 \-fdollars\-in\-identifiers
156 \-fenum\-int\-equiv
157 \-fexternal\-templates
158 \-fno\-asm
159 \-fno\-builtin
160 \-fhosted
161 \-fno\-hosted
162 \-ffreestanding
163 \-fno\-freestanding
164 \-fno\-strict\-prototype
165 \-fsigned\-bitfields
166 \-fsigned\-char
167 \-fthis\-is\-variable
168 \-funsigned\-bitfields
169 \-funsigned\-char
170 \-fwritable\-strings
171 \-traditional
172 \-traditional\-cpp
173 \-trigraphs
175 .B Warning Options
176 \-fsyntax\-only
177 \-pedantic
178 \-pedantic\-errors
181 \-Wall
182 \-Waggregate\-return
183 \-Wcast\-align
184 \-Wcast\-qual
185 \-Wchar\-subscript
186 \-Wcomment
187 \-Wconversion
188 \-Wenum\-clash
189 \-Werror
190 \-Wformat
191 .RI \-Wid\-clash\- len
192 \-Wimplicit
193 \-Winline
194 \-Wmain
195 \-Wmissing\-prototypes
196 \-Wmissing\-declarations
197 \-Wnested\-externs
198 \-Wno\-import
199 \-Wparentheses
200 \-Wpointer\-arith
201 \-Wredundant\-decls
202 \-Wreturn\-type
203 \-Wshadow
204 \-Wstrict\-prototypes
205 \-Wswitch
206 \-Wtemplate\-debugging
207 \-Wtraditional
208 \-Wtrigraphs
209 \-Wuninitialized
210 \-Wunused
211 \-Wwrite\-strings
213 .B Debugging Options
215 .RI \-d letters
216 \-fpretend\-float
218 .RI \-g level
219 \-gcoff
220 \-gxcoff
221 \-gxcoff+
222 \-gdwarf
223 \-gdwarf+
224 \-gstabs
225 \-gstabs+
226 \-ggdb
228 \-pg
229 \-save\-temps
230 .RI \-print\-file\-name= library
231 \-print\-libgcc\-file\-name
232 .RI \-print\-prog\-name= program
234 .B Optimization Options
235 \-fcaller\-saves
236 \-fcse\-follow\-jumps
237 \-fcse\-skip\-blocks
238 \-fdelayed\-branch
239 \-felide\-constructors
240 \-fexpensive\-optimizations
241 \-ffast\-math
242 \-ffloat\-store
243 \-fforce\-addr
244 \-fforce\-mem
245 \-finline\-functions
246 \-fkeep\-inline\-functions
247 \-fmemoize\-lookups
248 \-fno\-default\-inline
249 \-fno\-defer\-pop
250 \-fno\-function\-cse
251 \-fno\-inline
252 \-fno\-peephole
253 \-fomit\-frame\-pointer
254 \-frerun\-cse\-after\-loop
255 \-fschedule\-insns
256 \-fschedule\-insns2
257 \-fstrength\-reduce
258 \-fthread\-jumps
259 \-funroll\-all\-loops
260 \-funroll\-loops
262 \-O2
264 .B Preprocessor Options
265 .RI \-A assertion
267 \-dD
268 \-dM
269 \-dN
270 .RI \-D macro [\|= defn \|]
273 .RI "\-idirafter " dir
274 .RI "\-include " file
275 .RI "\-imacros " file
276 .RI "\-iprefix " file
277 .RI "\-iwithprefix " dir
279 \-MD
280 \-MM
281 \-MMD
282 \-nostdinc
284 .RI \-U macro
285 \-undef
287 .B Assembler Option
288 .RI \-Wa, option
290 .B Linker Options
291 .RI \-l library
292 \-nostartfiles
293 \-nostdlib
294 \-static
295 \-shared
296 \-symbolic
297 .RI "\-Xlinker\ " option
298 .RI \-Wl, option
299 .RI "\-u " symbol
301 .B Directory Options
302 .RI \-B prefix
303 .RI \-I dir
304 \-I\-
305 .RI \-L dir
307 .B Target Options
308 .RI "\-b  " machine
309 .RI "\-V " version
311 .B Configuration Dependent Options
312 .I M680x0\ Options
314 \-m68000
315 \-m68020
316 \-m68020\-40
317 \-m68030
318 \-m68040
319 \-m68881
320 \-mbitfield
321 \-mc68000
322 \-mc68020
323 \-mfpa
324 \-mnobitfield
325 \-mrtd
326 \-mshort
327 \-msoft\-float
329 .I VAX Options
331 \-mg
332 \-mgnu
333 \-munix
335 .I SPARC Options
337 \-mepilogue
338 \-mfpu
339 \-mhard\-float
340 \-mno\-fpu
341 \-mno\-epilogue
342 \-msoft\-float
343 \-msparclite
344 \-mv8
345 \-msupersparc
346 \-mcypress
348 .I Convex Options
350 \-margcount
351 \-mc1
352 \-mc2
353 \-mnoargcount
355 .I AMD29K Options
357 \-m29000
358 \-m29050
359 \-mbw
360 \-mdw
361 \-mkernel\-registers
362 \-mlarge
363 \-mnbw
364 \-mnodw
365 \-msmall
366 \-mstack\-check
367 \-muser\-registers
369 .I M88K Options
371 \-m88000
372 \-m88100
373 \-m88110
374 \-mbig\-pic
375 \-mcheck\-zero\-division
376 \-mhandle\-large\-shift
377 \-midentify\-revision
378 \-mno\-check\-zero\-division
379 \-mno\-ocs\-debug\-info
380 \-mno\-ocs\-frame\-position
381 \-mno\-optimize\-arg\-area
382 \-mno\-serialize\-volatile
383 \-mno\-underscores
384 \-mocs\-debug\-info
385 \-mocs\-frame\-position
386 \-moptimize\-arg\-area
387 \-mserialize\-volatile
388 .RI \-mshort\-data\- num
389 \-msvr3
390 \-msvr4
391 \-mtrap\-large\-shift
392 \-muse\-div\-instruction
393 \-mversion\-03.00
394 \-mwarn\-passed\-structs
396 .I RS6000 Options
398 \-mfp\-in\-toc
399 \-mno\-fop\-in\-toc
401 .I RT Options
403 \-mcall\-lib\-mul
404 \-mfp\-arg\-in\-fpregs
405 \-mfp\-arg\-in\-gregs
406 \-mfull\-fp\-blocks
407 \-mhc\-struct\-return
408 \-min\-line\-mul
409 \-mminimum\-fp\-blocks
410 \-mnohc\-struct\-return
412 .I MIPS Options
414 \-mcpu=\fIcpu type\fP
415 \-mips2
416 \-mips3
417 \-mint64
418 \-mlong64
419 \-mlonglong128
420 \-mmips\-as
421 \-mgas
422 \-mrnames
423 \-mno\-rnames
424 \-mgpopt
425 \-mno\-gpopt
426 \-mstats
427 \-mno\-stats
428 \-mmemcpy
429 \-mno\-memcpy
430 \-mno\-mips\-tfile
431 \-mmips\-tfile
432 \-msoft\-float
433 \-mhard\-float
434 \-mabicalls
435 \-mno\-abicalls
436 \-mhalf\-pic
437 \-mno\-half\-pic
438 \-G \fInum\fP
439 \-nocpp
441 .I i386 Options
443 \-m486
444 \-mno\-486
445 \-msoft\-float
446 \-mno\-fp\-ret\-in\-387
448 .I HPPA Options
450 \-mpa\-risc\-1\-0
451 \-mpa\-risc\-1\-1
452 \-mkernel
453 \-mshared\-libs
454 \-mno\-shared\-libs
455 \-mlong\-calls
456 \-mdisable\-fpregs
457 \-mdisable\-indexing
458 \-mtrailing\-colon
460 .I i960 Options
462 \-m\fIcpu-type\fP
463 \-mnumerics
464 \-msoft\-float
465 \-mleaf\-procedures
466 \-mno\-leaf\-procedures
467 \-mtail\-call
468 \-mno\-tail\-call
469 \-mcomplex\-addr
470 \-mno\-complex\-addr
471 \-mcode\-align
472 \-mno\-code\-align
473 \-mic\-compat
474 \-mic2.0\-compat
475 \-mic3.0\-compat
476 \-masm\-compat
477 \-mintel\-asm
478 \-mstrict\-align
479 \-mno\-strict\-align
480 \-mold\-align
481 \-mno\-old\-align
483 .I DEC Alpha Options
485 \-mfp\-regs
486 \-mno\-fp\-regs
487 \-mno\-soft\-float
488 \-msoft\-float
490 .I System V Options
493 \-Qy
494 \-Qn
495 .RI \-YP, paths
496 .RI \-Ym, dir
498 .B Code Generation Options
499 .RI \-fcall\-saved\- reg
500 .RI \-fcall\-used\- reg
501 .RI \-ffixed\- reg
502 \-finhibit\-size\-directive
503 \-fnonnull\-objects
504 \-fno\-common
505 \-fno\-ident
506 \-fno\-gnu\-linker
507 \-fpcc\-struct\-return
508 \-fpic
509 \-fPIC
510 \-freg\-struct\-return
511 \-fshared\-data
512 \-fshort\-enums
513 \-fshort\-double
514 \-fvolatile
515 \-fvolatile\-global
516 \-fverbose\-asm
517 .ad b
518 .hy 1
519 .SH OVERALL OPTIONS
521 .BI "\-x " "language"
522 Specify explicitly the
523 .I language\c
524 \& for the following input files (rather than choosing a default based
525 on the file name suffix) .  This option applies to all following input
526 files until the next `\|\c
527 .B \-x\c
528 \&\|' option.  Possible values of \c
529 .I language\c
530 \& are
531 `\|\c
532 .B c\c
533 \&\|', `\|\c
534 .B objective\-c\c
535 \&\|', `\|\c
536 .B c\-header\c
537 \&\|', `\|\c
538 .B c++\c
539 \&\|',
540 `\|\c
541 .B cpp\-output\c
542 \&\|', `\|\c
543 .B assembler\c
544 \&\|', and `\|\c
545 .B assembler\-with\-cpp\c
546 \&\|'.
548 .B \-x none
549 Turn off any specification of a language, so that subsequent files are
550 handled according to their file name suffixes (as they are if `\|\c
551 .B \-x\c
552 \&\|'
553 has not been used at all).
555 If you want only some of the four stages (preprocess, compile,
556 assemble, link), you can use
557 `\|\c
558 .B \-x\c
559 \&\|' (or filename suffixes) to tell \c
560 .B gcc\c
561 \& where to start, and
562 one of the options `\|\c
563 .B \-c\c
564 \&\|', `\|\c
565 .B \-S\c
566 \&\|', or `\|\c
567 .B \-E\c
568 \&\|' to say where
569 .B gcc\c
570 \& is to stop.  Note that some combinations (for example,
571 `\|\c
572 .B \-x cpp\-output \-E\c
573 \&\|') instruct \c
574 .B gcc\c
575 \& to do nothing at all.
577 .B \-c
578 Compile or assemble the source files, but do not link.  The compiler
579 output is an object file corresponding to each source file.
581 By default, GCC makes the object file name for a source file by replacing
582 the suffix `\|\c
583 .B .c\c
584 \&\|', `\|\c
585 .B .i\c
586 \&\|', `\|\c
587 .B .s\c
588 \&\|', etc., with `\|\c
589 .B .o\c
590 \&\|'.  Use
591 .B \-o\c
592 \& to select another name.
594 GCC ignores any unrecognized input files (those that do not require
595 compilation or assembly) with the
596 .B \-c
597 option.
599 .B \-S
600 Stop after the stage of compilation proper; do not assemble.  The output
601 is an assembler code file for each non-assembler input
602 file specified.
604 By default, GCC makes the assembler file name for a source file by
605 replacing the suffix `\|\c
606 .B .c\c
607 \&\|', `\|\c
608 .B .i\c
609 \&\|', etc., with `\|\c
610 .B .s\c
611 \&\|'.  Use
612 .B \-o\c
613 \& to select another name.
615 GCC ignores any input files that don't require compilation.
617 .B \-E
618 Stop after the preprocessing stage; do not run the compiler proper.  The
619 output is preprocessed source code, which is sent to the
620 standard output.
622 GCC ignores input files which don't require preprocessing.
624 .BI "\-o " file
625 Place output in file \c
626 .I file\c
627 \&.  This applies regardless to whatever
628 sort of output GCC is producing, whether it be an executable file,
629 an object file, an assembler file or preprocessed C code.
631 Since only one output file can be specified, it does not make sense to
632 use `\|\c
633 .B \-o\c
634 \&\|' when compiling more than one input file, unless you are
635 producing an executable file as output.
637 If you do not specify `\|\c
638 .B \-o\c
639 \&\|', the default is to put an executable file
640 in `\|\c
641 .B a.out\c
642 \&\|', the object file for `\|\c
643 .I source\c
644 .B \&.\c
645 .I suffix\c
646 \&\c
647 \&\|' in
648 `\|\c
649 .I source\c
650 .B \&.o\c
651 \&\|', its assembler file in `\|\c
652 .I source\c
653 .B \&.s\c
654 \&\|', and
655 all preprocessed C source on standard output.
657 .B \-v
658 Print (on standard error output) the commands executed to run the stages
659 of compilation.  Also print the version number of the compiler driver
660 program and of the preprocessor and the compiler proper.
662 .B \-pipe
663 Use pipes rather than temporary files for communication between the
664 various stages of compilation.  This fails to work on some systems where
665 the assembler cannot read from a pipe; but the GNU assembler has
666 no trouble.
668 .SH LANGUAGE OPTIONS
669 The following options control the dialect of C that the compiler
670 accepts:
672 .B \-ansi
673 Support all ANSI standard C programs.
675 This turns off certain features of GNU C that are incompatible with
676 ANSI C, such as the \c
677 .B asm\c
678 \&, \c
679 .B inline\c
680 \& and \c
681 .B typeof
682 keywords, and predefined macros such as \c
683 .B unix\c
684 \& and \c
685 .B vax
686 that identify the type of system you are using.  It also enables the
687 undesirable and rarely used ANSI trigraph feature, and disallows `\|\c
688 .B $\c
689 \&\|' as part of identifiers.
691 The alternate keywords \c
692 .B _\|_asm_\|_\c
693 \&, \c
694 .B _\|_extension_\|_\c
696 .B _\|_inline_\|_\c
697 \& and \c
698 .B _\|_typeof_\|_\c
699 \& continue to work despite
700 `\|\c
701 .B \-ansi\c
702 \&\|'.  You would not want to use them in an ANSI C program, of
703 course, but it is useful to put them in header files that might be included
704 in compilations done with `\|\c
705 .B \-ansi\c
706 \&\|'.  Alternate predefined macros
707 such as \c
708 .B _\|_unix_\|_\c
709 \& and \c
710 .B _\|_vax_\|_\c
711 \& are also available, with or
712 without `\|\c
713 .B \-ansi\c
714 \&\|'.
716 The `\|\c
717 .B \-ansi\c
718 \&\|' option does not cause non-ANSI programs to be
719 rejected gratuitously.  For that, `\|\c
720 .B \-pedantic\c
721 \&\|' is required in
722 addition to `\|\c
723 .B \-ansi\c
724 \&\|'.
726 The preprocessor predefines a macro \c
727 .B _\|_STRICT_ANSI_\|_\c
728 \& when you use the `\|\c
729 .B \-ansi\c
730 \&\|'
731 option.  Some header files may notice this macro and refrain
732 from declaring certain functions or defining certain macros that the
733 ANSI standard doesn't call for; this is to avoid interfering with any
734 programs that might use these names for other things.
736 .B \-fno\-asm
737 Do not recognize \c
738 .B asm\c
739 \&, \c
740 .B inline\c
741 \& or \c
742 .B typeof\c
743 \& as a
744 keyword.  These words may then be used as identifiers.  You can
745 use \c
746 .B _\|_asm_\|_\c
747 \&, \c
748 .B _\|_inline_\|_\c
749 \& and \c
750 .B _\|_typeof_\|_\c
751 \& instead.
752 `\|\c
753 .B \-ansi\c
754 \&\|' implies `\|\c
755 .B \-fno\-asm\c
756 \&\|'.
758 .B \-fno\-builtin
759 Don't recognize built-in functions that do not begin with two leading
760 underscores.  Currently, the functions affected include \c
761 .B _exit\c
763 .B abort\c
764 \&, \c
765 .B abs\c
766 \&, \c
767 .B alloca\c
768 \&, \c
769 .B cos\c
770 \&, \c
771 .B exit\c
773 .B fabs\c
774 \&, \c
775 .B labs\c
776 \&, \c
777 .B memcmp\c
778 \&, \c
779 .B memcpy\c
780 \&, \c
781 .B sin\c
783 .B sqrt\c
784 \&, \c
785 .B strcmp\c
786 \&, \c
787 .B strcpy\c
788 \&, and \c
789 .B strlen\c
792 The `\|\c
793 .B \-ansi\c
794 \&\|' option prevents \c
795 .B alloca\c
796 \& and \c
797 .B _exit\c
798 \& from
799 being builtin functions.
801 .B \-fhosted
802 Compile for a hosted environment; this implies the `\|\c
803 .B \-fbuiltin\c
804 \&\|' option, and implies that suspicious declarations of
805 .B main\c
806 \& should be warned about.
808 .B \-ffreestanding
809 Compile for a freestanding environment; this implies the `\|\c
810 .B \-fno-builtin\c
811 \&\|' option, and implies that
812 .B main\c
813 \& has no special requirements.
815 .B \-fno\-strict\-prototype
816 Treat a function declaration with no arguments, such as `\|\c
817 .B int foo
818 ();\c
819 \&\|', as C would treat it\(em\&as saying nothing about the number of
820 arguments or their types (C++ only).  Normally, such a declaration in
821 C++ means that the function \c
822 .B foo\c
823 \& takes no arguments.
825 .B \-trigraphs
826 Support ANSI C trigraphs.  The `\|\c
827 .B \-ansi\c
828 \&\|' option implies `\|\c
829 .B \-trigraphs\c
830 \&\|'.
832 .B \-traditional
833 Attempt to support some aspects of traditional C compilers.
834 For details, see the GNU C Manual; the duplicate list here
835 has been deleted so that we won't get complaints when it
836 is out of date.
838 But one note about C++ programs only (not C).  `\|\c
839 .B \-traditional\c
840 \&\|' has one additional effect for C++: assignment to
841 .B this
842 is permitted.  This is the same as the effect of `\|\c
843 .B \-fthis\-is\-variable\c
844 \&\|'.
846 .B \-traditional\-cpp
847 Attempt to support some aspects of traditional C preprocessors.
848 This includes the items that specifically mention the preprocessor above,
849 but none of the other effects of `\|\c
850 .B \-traditional\c
851 \&\|'.
853 .B \-fdollars\-in\-identifiers
854 Permit the use of `\|\c
855 .B $\c
856 \&\|' in identifiers (C++ only).  You can also use
857 `\|\c
858 .B \-fno\-dollars\-in\-identifiers\c
859 \&\|' to explicitly prohibit use of
860 `\|\c
861 .B $\c
862 \&\|'.  (GNU C++ allows `\|\c
863 .B $\c
864 \&\|' by default on some target systems
865 but not others.)
867 .B \-fenum\-int\-equiv
868 Permit implicit conversion of \c
869 .B int\c
870 \& to enumeration types (C++
871 only).  Normally GNU C++ allows conversion of \c
872 .B enum\c
873 \& to \c
874 .B int\c
876 but not the other way around.
878 .B \-fexternal\-templates
879 Produce smaller code for template declarations, by generating only a
880 single copy of each template function where it is defined (C++ only).
881 To use this option successfully, you must also mark all files that
882 use templates with either `\|\c
883 .B #pragma implementation\c
884 \&\|' (the definition) or
885 `\|\c
886 .B #pragma interface\c
887 \&\|' (declarations).
889 When your code is compiled with `\|\c
890 .B \-fexternal\-templates\c
891 \&\|', all
892 template instantiations are external.  You must arrange for all
893 necessary instantiations to appear in the implementation file; you can
894 do this with a \c
895 .B typedef\c
896 \& that references each instantiation needed.
897 Conversely, when you compile using the default option
898 `\|\c
899 .B \-fno\-external\-templates\c
900 \&\|', all template instantiations are
901 explicitly internal.
903 .B \-fall\-virtual
904 Treat all possible member functions as virtual, implicitly.  All
905 member functions (except for constructor functions and
906 .B new
908 .B delete
909 member operators) are treated as virtual functions of the class where
910 they appear.
912 This does not mean that all calls to these member functions will be
913 made through the internal table of virtual functions.  Under some
914 circumstances, the compiler can determine that a call to a given
915 virtual function can be made directly; in these cases the calls are
916 direct in any case.
918 .B \-fcond\-mismatch
919 Allow conditional expressions with mismatched types in the second and
920 third arguments.  The value of such an expression is void.
922 .B \-fthis\-is\-variable
923 Permit assignment to \c
924 .B this\c
925 \& (C++ only).  The incorporation of
926 user-defined free store management into C++ has made assignment to
927 `\|\c
928 .B this\c
929 \&\|' an anachronism.  Therefore, by default it is invalid to
930 assign to \c
931 .B this\c
932 \& within a class member function.  However, for
933 backwards compatibility, you can make it valid with
934 `\|\c
935 .B \-fthis-is-variable\c
936 \&\|'.
938 .B \-funsigned\-char
939 Let the type \c
940 .B char\c
941 \& be unsigned, like \c
942 .B unsigned char\c
945 Each kind of machine has a default for what \c
946 .B char\c
947 \& should
948 be.  It is either like \c
949 .B unsigned char\c
950 \& by default or like
951 .B signed char\c
952 \& by default.
954 Ideally, a portable program should always use \c
955 .B signed char\c
956 \& or
957 .B unsigned char\c
958 \& when it depends on the signedness of an object.
959 But many programs have been written to use plain \c
960 .B char\c
961 \& and
962 expect it to be signed, or expect it to be unsigned, depending on the
963 machines they were written for.  This option, and its inverse, let you
964 make such a program work with the opposite default.
966 The type \c
967 .B char\c
968 \& is always a distinct type from each of
969 .B signed char\c
970 \& and \c
971 .B unsigned char\c
972 \&, even though its behavior
973 is always just like one of those two.
975 .B \-fsigned\-char
976 Let the type \c
977 .B char\c
978 \& be signed, like \c
979 .B signed char\c
982 Note that this is equivalent to `\|\c
983 .B \-fno\-unsigned\-char\c
984 \&\|', which is
985 the negative form of `\|\c
986 .B \-funsigned\-char\c
987 \&\|'.  Likewise,
988 `\|\c
989 .B \-fno\-signed\-char\c
990 \&\|' is equivalent to `\|\c
991 .B \-funsigned\-char\c
992 \&\|'.
994 .B \-fsigned\-bitfields
996 .B \-funsigned\-bitfields
998 .B \-fno\-signed\-bitfields
1000 .B \-fno\-unsigned\-bitfields
1001 These options control whether a bitfield is
1002 signed or unsigned, when declared with no explicit `\|\c
1003 .B signed\c
1004 \&\|' or `\|\c
1005 .B unsigned\c
1006 \&\|' qualifier.  By default, such a bitfield is
1007 signed, because this is consistent: the basic integer types such as
1008 .B int\c
1009 \& are signed types.
1011 However, when you specify `\|\c
1012 .B \-traditional\c
1013 \&\|', bitfields are all unsigned
1014 no matter what.
1016 .B \-fwritable\-strings
1017 Store string constants in the writable data segment and don't uniquize
1018 them.  This is for compatibility with old programs which assume they
1019 can write into string constants.  `\|\c
1020 .B \-traditional\c
1021 \&\|' also has this
1022 effect.
1024 Writing into string constants is a very bad idea; \*(lqconstants\*(rq should
1025 be constant.
1026 .SH PREPROCESSOR OPTIONS
1027 These options control the C preprocessor, which is run on each C source
1028 file before actual compilation.
1030 If you use the `\|\c
1031 .B \-E\c
1032 \&\|' option, GCC does nothing except preprocessing.
1033 Some of these options make sense only together with `\|\c
1034 .B \-E\c
1035 \&\|' because
1036 they cause the preprocessor output to be unsuitable for actual
1037 compilation.
1039 .BI "\-include " "file"
1040 Process \c
1041 .I file\c
1042 \& as input before processing the regular input file.
1043 In effect, the contents of \c
1044 .I file\c
1045 \& are compiled first.  Any `\|\c
1046 .B \-D\c
1047 \&\|'
1048 and `\|\c
1049 .B \-U\c
1050 \&\|' options on the command line are always processed before
1051 `\|\c
1052 .B \-include \c
1053 .I file\c
1054 \&\c
1055 \&\|', regardless of the order in which they are
1056 written.  All the `\|\c
1057 .B \-include\c
1058 \&\|' and `\|\c
1059 .B \-imacros\c
1060 \&\|' options are
1061 processed in the order in which they are written.
1063 .BI "\-imacros " file
1064 Process \c
1065 .I file\c
1066 \& as input, discarding the resulting output, before
1067 processing the regular input file.  Because the output generated from
1068 .I file\c
1069 \& is discarded, the only effect of `\|\c
1070 .B \-imacros \c
1071 .I file\c
1072 \&\c
1073 \&\|' is to
1074 make the macros defined in \c
1075 .I file\c
1076 \& available for use in the main
1077 input.  The preprocessor evaluates any `\|\c
1078 .B \-D\c
1079 \&\|' and `\|\c
1080 .B \-U\c
1081 \&\|' options
1082 on the command line before processing `\|\c
1083 .B \-imacros\c
1084 .I file\c
1085 \&\|', regardless of the order in
1086 which they are written.  All the `\|\c
1087 .B \-include\c
1088 \&\|' and `\|\c
1089 .B \-imacros\c
1090 \&\|'
1091 options are processed in the order in which they are written.
1093 .BI "\-idirafter " "dir"
1094 Add the directory \c
1095 .I dir\c
1096 \& to the second include path.  The directories
1097 on the second include path are searched when a header file is not found
1098 in any of the directories in the main include path (the one that
1099 `\|\c
1100 .B \-I\c
1101 \&\|' adds to).
1103 .BI "\-iprefix " "prefix"
1104 Specify \c
1105 .I prefix\c
1106 \& as the prefix for subsequent `\|\c
1107 .B \-iwithprefix\c
1108 \&\|'
1109 options.
1111 .BI "\-iwithprefix " "dir"
1112 Add a directory to the second include path.  The directory's name is
1113 made by concatenating \c
1114 .I prefix\c
1115 \& and \c
1116 .I dir\c
1117 \&, where \c
1118 .I prefix
1119 was specified previously with `\|\c
1120 .B \-iprefix\c
1121 \&\|'.
1123 .B \-nostdinc
1124 Do not search the standard system directories for header files.  Only
1125 the directories you have specified with `\|\c
1126 .B \-I\c
1127 \&\|' options (and the
1128 current directory, if appropriate) are searched.
1130 By using both `\|\c
1131 .B \-nostdinc\c
1132 \&\|' and `\|\c
1133 .B \-I\-\c
1134 \&\|', you can limit the include-file search file to only those
1135 directories you specify explicitly.
1137 .B \-nostdinc++
1138 Do not search for header files in the C++\-specific standard directories,
1139 but do still search the other standard directories.
1140 (This option is used when building `\|\c
1141 .B libg++\c
1142 \&\|'.)
1144 .B \-undef
1145 Do not predefine any nonstandard macros.  (Including architecture flags).
1147 .B \-E
1148 Run only the C preprocessor.  Preprocess all the C source files
1149 specified and output the results to standard output or to the
1150 specified output file.
1152 .B \-C
1153 Tell the preprocessor not to discard comments.  Used with the
1154 `\|\c
1155 .B \-E\c
1156 \&\|' option.
1158 .B \-P
1159 Tell the preprocessor not to generate `\|\c
1160 .B #line\c
1161 \&\|' commands.
1162 Used with the `\|\c
1163 .B \-E\c
1164 \&\|' option.
1166 .B \-M\  [ \-MG ]
1167 Tell the preprocessor to output a rule suitable for \c
1168 .B make
1169 describing the dependencies of each object file.  For each source file,
1170 the preprocessor outputs one \c
1171 .B make\c
1172 \&-rule whose target is the object
1173 file name for that source file and whose dependencies are all the files
1174 `\|\c
1175 .B #include\c
1176 \&\|'d in it.  This rule may be a single line or may be
1177 continued with `\|\c
1178 .B \e\c
1179 \&\|'-newline if it is long.  The list of rules is
1180 printed on standard output instead of the preprocessed C program.
1182 `\|\c
1183 .B \-M\c
1184 \&\|' implies `\|\c
1185 .B \-E\c
1186 \&\|'.
1188 `\|\c
1189 .B \-MG\c
1190 \&\|' says to treat missing header files as generated files and assume \c
1191 they live in the same directory as the source file.  It must be specified \c
1192 in addition to `\|\c
1193 .B \-M\c
1194 \&\|'.
1196 .B \-MM\  [ \-MG ]
1197 Like `\|\c
1198 .B \-M\c
1199 \&\|' but the output mentions only the user header files
1200 included with `\|\c
1201 .B #include "\c
1202 .I file\c
1203 \&"\c
1204 \&\|'.  System header files
1205 included with `\|\c
1206 .B #include <\c
1207 .I file\c
1208 \&>\c
1209 \&\|' are omitted.
1211 .B \-MD
1212 Like `\|\c
1213 .B \-M\c
1214 \&\|' but the dependency information is written to files with
1215 names made by replacing `\|\c
1216 .B .o\c
1217 \&\|' with `\|\c
1218 .B .d\c
1219 \&\|' at the end of the
1220 output file names.  This is in addition to compiling the file as
1221 specified\(em\&`\|\c
1222 .B \-MD\c
1223 \&\|' does not inhibit ordinary compilation the way
1224 `\|\c
1225 .B \-M\c
1226 \&\|' does.
1228 The Mach utility `\|\c
1229 .B md\c
1230 \&\|' can be used to merge the `\|\c
1231 .B .d\c
1232 \&\|' files
1233 into a single dependency file suitable for using with the `\|\c
1234 .B make\c
1235 \&\|'
1236 command.
1238 .B \-MMD
1239 Like `\|\c
1240 .B \-MD\c
1241 \&\|' except mention only user header files, not system
1242 header files.
1244 .B \-H
1245 Print the name of each header file used, in addition to other normal
1246 activities.
1248 .BI "\-A" "question" ( answer )
1249 Assert the answer
1250 .I answer
1252 .I question\c
1253 \&, in case it is tested
1254 with a preprocessor conditional such as `\|\c
1255 .BI "#if #" question ( answer )\c
1256 \&\|'.  `\|\c
1257 .B \-A\-\c
1258 \&\|' disables the standard
1259 assertions that normally describe the target machine.
1261 .BI "\-A" "question"\c
1262 \&(\c
1263 .I answer\c
1265 Assert the answer \c
1266 .I answer\c
1267 \& for \c
1268 .I question\c
1269 \&, in case it is tested
1270 with a preprocessor conditional such as `\|\c
1271 .B #if
1273 .I question\c
1274 \&(\c
1275 .I answer\c
1276 \&)\c
1277 \&\|'.  `\|\c
1278 .B \-A-\c
1279 \&\|' disables the standard
1280 assertions that normally describe the target machine.
1282 .BI \-D macro
1283 Define macro \c
1284 .I macro\c
1285 \& with the string `\|\c
1286 .B 1\c
1287 \&\|' as its definition.
1289 .BI \-D macro = defn
1290 Define macro \c
1291 .I macro\c
1292 \& as \c
1293 .I defn\c
1294 \&.    All instances of `\|\c
1295 .B \-D\c
1296 \&\|' on
1297 the command line are processed before any `\|\c
1298 .B \-U\c
1299 \&\|' options.
1301 .BI \-U macro
1302 Undefine macro \c
1303 .I macro\c
1304 \&.  `\|\c
1305 .B \-U\c
1306 \&\|' options are evaluated after all `\|\c
1307 .B \-D\c
1308 \&\|' options, but before any `\|\c
1309 .B \-include\c
1310 \&\|' and `\|\c
1311 .B \-imacros\c
1312 \&\|' options.
1314 .B \-dM
1315 Tell the preprocessor to output only a list of the macro definitions
1316 that are in effect at the end of preprocessing.  Used with the `\|\c
1317 .B \-E\c
1318 \&\|'
1319 option.
1321 .B \-dD
1322 Tell the preprocessor to pass all macro definitions into the output, in
1323 their proper sequence in the rest of the output.
1325 .B \-dN
1326 Like `\|\c
1327 .B \-dD\c
1328 \&\|' except that the macro arguments and contents are omitted.
1329 Only `\|\c
1330 .B #define \c
1331 .I name\c
1332 \&\c
1333 \&\|' is included in the output.
1334 .SH ASSEMBLER OPTION
1336 .BI "\-Wa," "option"
1337 Pass \c
1338 .I option\c
1339 \& as an option to the assembler.  If \c
1340 .I option
1341 contains commas, it is split into multiple options at the commas.
1342 .SH LINKER OPTIONS
1343 These options come into play when the compiler links object files into
1344 an executable output file.  They are meaningless if the compiler is
1345 not doing a link step.
1347 .I object-file-name
1348 A file name that does not end in a special recognized suffix is
1349 considered to name an object file or library.  (Object files are
1350 distinguished from libraries by the linker according to the file
1351 contents.)  If GCC does a link step, these object files are used as input
1352 to the linker.
1354 .BI \-l library
1355 Use the library named \c
1356 .I library\c
1357 \& when linking.
1359 The linker searches a standard list of directories for the library,
1360 which is actually a file named `\|\c
1361 .B lib\c
1362 .I library\c
1363 \&.a\c
1364 \&\|'.  The linker
1365 then uses this file as if it had been specified precisely by name.
1367 The directories searched include several standard system directories
1368 plus any that you specify with `\|\c
1369 .B \-L\c
1370 \&\|'.
1372 Normally the files found this way are library files\(em\&archive files
1373 whose members are object files.  The linker handles an archive file by
1374 scanning through it for members which define symbols that have so far
1375 been referenced but not defined.  However, if the linker finds an
1376 ordinary object file rather than a library, the object file is linked
1377 in the usual fashion.  The only difference between using an `\|\c
1378 .B \-l\c
1379 \&\|' option and specifying a file
1380 name is that `\|\c
1381 .B \-l\c
1382 \&\|' surrounds
1383 .I library
1384 with `\|\c
1385 .B lib\c
1386 \&\|' and `\|\c
1387 .B .a\c
1388 \&\|' and searches several directories.
1390 .B \-lobjc
1391 You need this special case of the
1392 .B \-l
1393 option in order to link an Objective C program.
1395 .B \-nostartfiles
1396 Do not use the standard system startup files when linking.
1397 The standard libraries are used normally.
1399 .B \-nostdlib
1400 Don't use the standard system libraries and startup files when linking.
1401 Only the files you specify will be passed to the linker.
1403 .B \-static
1404 On systems that support dynamic linking, this prevents linking with the shared
1405 libraries.  On other systems, this option has no effect.
1407 .B \-shared
1408 Produce a shared object which can then be linked with other objects to
1409 form an executable.  Only a few systems support this option.
1411 .B \-symbolic
1412 Bind references to global symbols when building a shared object.  Warn
1413 about any unresolved references (unless overridden by the link editor
1414 option `\|\c
1416 \-Xlinker \-z \-Xlinker defs\c
1417 \&\|').  Only a few systems support
1418 this option.
1420 .BI "\-Xlinker " "option"
1421 Pass \c
1422 .I option
1423 as an option to the linker.  You can use this to
1424 supply system-specific linker options which GNU CC does not know how to
1425 recognize.
1427 If you want to pass an option that takes an argument, you must use
1428 `\|\c
1429 .B \-Xlinker\c
1430 \&\|' twice, once for the option and once for the argument.
1431 For example, to pass `\|\c
1433 \-assert definitions\c
1434 \&\|', you must write
1435 `\|\c
1437 \-Xlinker \-assert \-Xlinker definitions\c
1438 \&\|'.  It does not work to write
1439 `\|\c
1441 \-Xlinker "\-assert definitions"\c
1442 \&\|', because this passes the entire
1443 string as a single argument, which is not what the linker expects.
1445 .BI "\-Wl," "option"
1446 Pass \c
1447 .I option\c
1448 \& as an option to the linker.  If \c
1449 .I option\c
1450 \& contains
1451 commas, it is split into multiple options at the commas.
1453 .BI "\-u " "symbol"
1454 Pretend the symbol
1455 .I symbol
1456 is undefined, to force linking of
1457 library modules to define it.  You can use `\|\c
1458 .B \-u\c
1459 \&\|' multiple times with
1460 different symbols to force loading of additional library modules.
1461 .SH DIRECTORY OPTIONS
1462 These options specify directories to search for header files, for
1463 libraries and for parts of the compiler:
1465 .BI "\-I" "dir"
1466 Append directory \c
1467 .I dir\c
1468 \& to the list of directories searched for include files.
1470 .B \-I\-
1471 Any directories you specify with `\|\c
1472 .B \-I\c
1473 \&\|' options before the `\|\c
1474 .B \-I\-\c
1475 \&\|'
1476 option are searched only for the case of `\|\c
1478 #include "\c
1479 .I file\c
1481 \&"\c
1482 \&\|';
1483 they are not searched for `\|\c
1484 .B #include <\c
1485 .I file\c
1486 \&>\c
1487 \&\|'.
1489 If additional directories are specified with `\|\c
1490 .B \-I\c
1491 \&\|' options after
1492 the `\|\c
1493 .B \-I\-\c
1494 \&\|', these directories are searched for all `\|\c
1495 .B #include\c
1496 \&\|'
1497 directives.  (Ordinarily \c
1498 .I all\c
1499 \& `\|\c
1500 .B \-I\c
1501 \&\|' directories are used
1502 this way.)
1504 In addition, the `\|\c
1505 .B \-I\-\c
1506 \&\|' option inhibits the use of the current
1507 directory (where the current input file came from) as the first search
1508 directory for `\|\c
1510 #include "\c
1511 .I file\c
1513 \&"\c
1514 \&\|'.  There is no way to
1515 override this effect of `\|\c
1516 .B \-I\-\c
1517 \&\|'.  With `\|\c
1518 .B \-I.\c
1519 \&\|' you can specify
1520 searching the directory which was current when the compiler was
1521 invoked.  That is not exactly the same as what the preprocessor does
1522 by default, but it is often satisfactory.
1524 `\|\c
1525 .B \-I\-\c
1526 \&\|' does not inhibit the use of the standard system directories
1527 for header files.  Thus, `\|\c
1528 .B \-I\-\c
1529 \&\|' and `\|\c
1530 .B \-nostdinc\c
1531 \&\|' are
1532 independent.
1534 .BI "\-L" "dir"
1535 Add directory \c
1536 .I dir\c
1537 \& to the list of directories to be searched
1538 for `\|\c
1539 .B \-l\c
1540 \&\|'.
1542 .BI "\-B" "prefix"
1543 This option specifies where to find the executables, libraries and
1544 data files of the compiler itself.
1546 The compiler driver program runs one or more of the subprograms
1547 `\|\c
1548 .B cpp\c
1549 \&\|', `\|\c
1550 .B cc1\c
1551 \&\|' (or, for C++, `\|\c
1552 .B cc1plus\c
1553 \&\|'), `\|\c
1554 .B as\c
1555 \&\|' and `\|\c
1556 .B ld\c
1557 \&\|'.  It tries
1558 .I prefix\c
1559 \& as a prefix for each program it tries to run, both with and
1560 without `\|\c
1561 .I machine\c
1562 .B /\c
1563 .I version\c
1564 .B /\c
1565 \&\|'.
1567 For each subprogram to be run, the compiler driver first tries the
1568 `\|\c
1569 .B \-B\c
1570 \&\|' prefix, if any.  If that name is not found, or if `\|\c
1571 .B \-B\c
1572 \&\|'
1573 was not specified, the driver tries two standard prefixes, which are
1574 `\|\c
1575 .B /usr/lib/gcc/\c
1576 \&\|' and `\|\c
1577 .B /usr/local/lib/gcc-lib/\c
1578 \&\|'.  If neither of
1579 those results in a file name that is found, the compiler driver
1580 searches for the unmodified program
1581 name, using the directories specified in your
1582 `\|\c
1583 .B PATH\c
1584 \&\|' environment variable.
1586 The run-time support file `\|\c
1587 .B libgcc.a\c
1588 \&\|' is also searched for using the
1589 `\|\c
1590 .B \-B\c
1591 \&\|' prefix, if needed.  If it is not found there, the two
1592 standard prefixes above are tried, and that is all.  The file is left
1593 out of the link if it is not found by those means.  Most of the time,
1594 on most machines, `\|\c
1595 .B libgcc.a\c
1596 \&\|' is not actually necessary.
1598 You can get a similar result from the environment variable
1599 .B GCC_EXEC_PREFIX\c
1600 \&; if it is defined, its value is used as a prefix
1601 in the same way.  If both the `\|\c
1602 .B \-B\c
1603 \&\|' option and the
1604 .B GCC_EXEC_PREFIX\c
1605 \& variable are present, the `\|\c
1606 .B \-B\c
1607 \&\|' option is
1608 used first and the environment variable value second.
1609 .SH WARNING OPTIONS
1610 Warnings are diagnostic messages that report constructions which
1611 are not inherently erroneous but which are risky or suggest there
1612 may have been an error.
1614 These options control the amount and kinds of warnings produced by GNU
1617 .B \-fsyntax\-only
1618 Check the code for syntax errors, but don't emit any output.
1620 .B \-w
1621 Inhibit all warning messages.
1623 .B \-Wno\-import
1624 Inhibit warning messages about the use of
1625 .BR #import .
1627 .B \-pedantic
1628 Issue all the warnings demanded by strict ANSI standard C; reject
1629 all programs that use forbidden extensions.
1631 Valid ANSI standard C programs should compile properly with or without
1632 this option (though a rare few will require `\|\c
1633 .B \-ansi\c
1634 \&\|').  However,
1635 without this option, certain GNU extensions and traditional C features
1636 are supported as well.  With this option, they are rejected.  There is
1637 no reason to \c
1638 .I use\c
1639 \& this option; it exists only to satisfy pedants.
1641 `\|\c
1642 .B \-pedantic\c
1643 \&\|' does not cause warning messages for use of the
1644 alternate keywords whose names begin and end with `\|\c
1645 .B _\|_\c
1646 \&\|'.  Pedantic
1647 warnings are also disabled in the expression that follows
1648 .B _\|_extension_\|_\c
1649 \&.  However, only system header files should use
1650 these escape routes; application programs should avoid them.
1652 .B \-pedantic\-errors
1653 Like `\|\c
1654 .B \-pedantic\c
1655 \&\|', except that errors are produced rather than
1656 warnings.
1658 .B \-W
1659 Print extra warning messages for these events:
1661 \ \ \ \(bu
1662 A nonvolatile automatic variable might be changed by a call to
1663 .B longjmp\c
1664 \&.  These warnings are possible only in
1665 optimizing compilation.
1667 The compiler sees only the calls to \c
1668 .B setjmp\c
1669 \&.  It cannot know
1670 where \c
1671 .B longjmp\c
1672 \& will be called; in fact, a signal handler could
1673 call it at any point in the code.  As a result, you may get a warning
1674 even when there is in fact no problem because \c
1675 .B longjmp\c
1676 \& cannot
1677 in fact be called at the place which would cause a problem.
1679 \ \ \ \(bu
1680 A function can return either with or without a value.  (Falling
1681 off the end of the function body is considered returning without
1682 a value.)  For example, this function would evoke such a
1683 warning:
1686 foo (a)
1688   if (a > 0)
1689     return a;
1693 Spurious warnings can occur because GNU CC does not realize that
1694 certain functions (including \c
1695 .B abort\c
1696 \& and \c
1697 .B longjmp\c
1699 will never return.
1701 \ \ \ \(bu
1702 An expression-statement or the left-hand side of a comma expression
1703 contains no side effects. 
1704 To suppress the warning, cast the unused expression to void.
1705 For example, an expression such as `\|\c
1706 .B x[i,j]\c
1707 \&\|' will cause a warning,
1708 but `\|\c
1709 .B x[(void)i,j]\c
1710 \&\|' will not.
1712 \ \ \ \(bu
1713 An unsigned value is compared against zero with `\|\c
1714 .B >\c
1715 \&\|' or `\|\c
1716 .B <=\c
1717 \&\|'.
1720 .B \-Wimplicit
1721 Warn whenever a function or parameter is implicitly declared.
1723 .B \-Wmain
1724 Warn if the
1725 .B main
1726 function is declared or defined with a suspicious type.
1727 Typically, it is a function with external linkage, returning
1728 .B int\c
1729 \&, and
1730 taking zero or two arguments.
1733 .B \-Wreturn\-type
1734 Warn whenever a function is defined with a return-type that defaults
1735 to \c
1736 .B int\c
1737 \&.  Also warn about any \c
1738 .B return\c
1739 \& statement with no
1740 return-value in a function whose return-type is not \c
1741 .B void\c
1744 .B \-Wunused
1745 Warn whenever a local variable is unused aside from its declaration,
1746 whenever a function is declared static but never defined, and whenever
1747 a statement computes a result that is explicitly not used.
1749 .B \-Wswitch
1750 Warn whenever a \c
1751 .B switch\c
1752 \& statement has an index of enumeral type
1753 and lacks a \c
1754 .B case\c
1755 \& for one or more of the named codes of that
1756 enumeration.  (The presence of a \c
1757 .B default\c
1758 \& label prevents this
1759 warning.)  \c
1760 .B case\c
1761 \& labels outside the enumeration range also
1762 provoke warnings when this option is used.
1764 .B \-Wcomment
1765 Warn whenever a comment-start sequence `\|\c
1766 .B /\(**\c
1767 \&\|' appears in a comment.
1769 .B \-Wtrigraphs
1770 Warn if any trigraphs are encountered (assuming they are enabled).
1772 .B \-Wformat
1773 Check calls to \c
1774 .B printf\c
1775 \& and \c
1776 .B scanf\c
1777 \&, etc., to make sure that
1778 the arguments supplied have types appropriate to the format string
1779 specified.
1781 .B \-Wchar\-subscripts
1782 Warn if an array subscript has type
1783 .BR char .
1784 This is a common cause of error, as programmers often forget that this
1785 type is signed on some machines.
1787 .B \-Wuninitialized
1788 An automatic variable is used without first being initialized.
1790 These warnings are possible only in optimizing compilation,
1791 because they require data flow information that is computed only
1792 when optimizing.  If you don't specify `\|\c
1793 .B \-O\c
1794 \&\|', you simply won't
1795 get these warnings.
1797 These warnings occur only for variables that are candidates for
1798 register allocation.  Therefore, they do not occur for a variable that
1799 is declared \c
1800 .B volatile\c
1801 \&, or whose address is taken, or whose size
1802 is other than 1, 2, 4 or 8 bytes.  Also, they do not occur for
1803 structures, unions or arrays, even when they are in registers.
1805 Note that there may be no warning about a variable that is used only
1806 to compute a value that itself is never used, because such
1807 computations may be deleted by data flow analysis before the warnings
1808 are printed.
1810 These warnings are made optional because GNU CC is not smart
1811 enough to see all the reasons why the code might be correct
1812 despite appearing to have an error.  Here is one example of how
1813 this can happen:
1817   int x;
1818   switch (y)
1819     {
1820     case 1: x = 1;
1821       break;
1822     case 2: x = 4;
1823       break;
1824     case 3: x = 5;
1825     }
1826   foo (x);
1830 If the value of \c
1831 .B y\c
1832 \& is always 1, 2 or 3, then \c
1833 .B x\c
1834 \& is
1835 always initialized, but GNU CC doesn't know this.  Here is
1836 another common case:
1840   int save_y;
1841   if (change_y) save_y = y, y = new_y;
1842   .\|.\|.
1843   if (change_y) y = save_y;
1847 This has no bug because \c
1848 .B save_y\c
1849 \& is used only if it is set.
1851 Some spurious warnings can be avoided if you declare as
1852 .B volatile\c
1853 \& all the functions you use that never return.
1855 .B \-Wparentheses
1856 Warn if parentheses are omitted in certain contexts.
1858 .B \-Wtemplate\-debugging
1859 When using templates in a C++ program, warn if debugging is not yet
1860 fully available (C++ only).
1862 .B \-Wall
1863 All of the above `\|\c
1864 .B \-W\c
1865 \&\|' options combined.  These are all the
1866 options which pertain to usage that we recommend avoiding and that we
1867 believe is easy to avoid, even in conjunction with macros.
1869 The remaining `\|\c
1870 .B \-W.\|.\|.\c
1871 \&\|' options are not implied by `\|\c
1872 .B \-Wall\c
1873 \&\|'
1874 because they warn about constructions that we consider reasonable to
1875 use, on occasion, in clean programs.
1877 .B \-Wtraditional
1878 Warn about certain constructs that behave differently in traditional and
1879 ANSI C.
1881 \ \ \ \(bu
1882 Macro arguments occurring within string constants in the macro body.
1883 These would substitute the argument in traditional C, but are part of
1884 the constant in ANSI C.
1886 \ \ \ \(bu
1887 A function declared external in one block and then used after the end of
1888 the block.
1890 \ \ \ \(bu
1891 A \c
1892 .B switch\c
1893 \& statement has an operand of type \c
1894 .B long\c
1898 .B \-Wshadow
1899 Warn whenever a local variable shadows another local variable.
1901 .BI "\-Wid\-clash\-" "len"
1902 Warn whenever two distinct identifiers match in the first \c
1903 .I len
1904 characters.  This may help you prepare a program that will compile
1905 with certain obsolete, brain-damaged compilers.
1907 .B \-Wpointer\-arith
1908 Warn about anything that depends on the \*(lqsize of\*(rq a function type or
1909 of \c
1910 .B void\c
1911 \&.  GNU C assigns these types a size of 1, for
1912 convenience in calculations with \c
1913 .B void \(**\c
1914 \& pointers and pointers
1915 to functions.
1917 .B \-Wcast\-qual
1918 Warn whenever a pointer is cast so as to remove a type qualifier from
1919 the target type.  For example, warn if a \c
1920 .B const char \(**\c
1921 \& is cast
1922 to an ordinary \c
1923 .B char \(**\c
1926 .B \-Wcast\-align
1927 Warn whenever a pointer is cast such that the required alignment of the
1928 target is increased.  For example, warn if a \c
1929 .B char \(**\c
1930 \& is cast to
1931 an \c
1932 .B int \(**\c
1933 \& on machines where integers can only be accessed at
1934 two- or four-byte boundaries.
1936 .B \-Wwrite\-strings
1937 Give string constants the type \c
1938 .B const char[\c
1939 .I length\c
1940 .B ]\c
1941 \& so that
1942 copying the address of one into a non-\c
1943 .B const\c
1944 \& \c
1945 .B char \(**
1946 pointer will get a warning.  These warnings will help you find at
1947 compile time code that can try to write into a string constant, but
1948 only if you have been very careful about using \c
1949 .B const\c
1950 \& in
1951 declarations and prototypes.  Otherwise, it will just be a nuisance;
1952 this is why we did not make `\|\c
1953 .B \-Wall\c
1954 \&\|' request these warnings.
1956 .B \-Wconversion
1957 Warn if a prototype causes a type conversion that is different from what
1958 would happen to the same argument in the absence of a prototype.  This
1959 includes conversions of fixed point to floating and vice versa, and
1960 conversions changing the width or signedness of a fixed point argument
1961 except when the same as the default promotion.
1963 .B \-Waggregate\-return
1964 Warn if any functions that return structures or unions are defined or
1965 called.  (In languages where you can return an array, this also elicits
1966 a warning.)
1968 .B \-Wstrict\-prototypes
1969 Warn if a function is declared or defined without specifying the
1970 argument types.  (An old-style function definition is permitted without
1971 a warning if preceded by a declaration which specifies the argument
1972 types.)
1974 .B \-Wmissing\-prototypes
1975 Warn if a global function is defined without a previous prototype
1976 declaration.  This warning is issued even if the definition itself
1977 provides a prototype.  The aim is to detect global functions that fail
1978 to be declared in header files.
1980 .B \-Wmissing\-declarations
1981 Warn if a global function is defined without a previous declaration.
1982 Do so even if the definition itself provides a prototype.
1983 Use this option to detect global functions that are not declared in
1984 header files.
1986 .B \-Wredundant-decls
1987 Warn if anything is declared more than once in the same scope, even in
1988 cases where multiple declaration is valid and changes nothing.
1990 .B \-Wnested-externs
1991 Warn if an \c
1992 .B extern\c
1993 \& declaration is encountered within an function.
1995 .B \-Wenum\-clash
1996 Warn about conversion between different enumeration types (C++ only).
1998 .B \-Woverloaded\-virtual
1999 (C++ only.)
2000 In a derived class, the definitions of virtual functions must match
2001 the type signature of a virtual function declared in the base class.
2002 Use this option to request warnings when a derived class declares a
2003 function that may be an erroneous attempt to define a virtual
2004 function: that is, warn when a function with the same name as a
2005 virtual function in the base class, but with a type signature that
2006 doesn't match any virtual functions from the base class.
2008 .B \-Winline
2009 Warn if a function can not be inlined, and either it was declared as inline,
2010 or else the
2011 .B \-finline\-functions
2012 option was given.
2014 .B \-Werror
2015 Treat warnings as errors; abort compilation after any warning.
2016 .SH DEBUGGING OPTIONS
2017 GNU CC has various special options that are used for debugging
2018 either your program or GCC:
2020 .B \-g
2021 Produce debugging information in the operating system's native format
2022 (stabs, COFF, XCOFF, or DWARF).  GDB can work with this debugging
2023 information.
2025 On most systems that use stabs format, `\|\c
2026 .B \-g\c
2027 \&\|' enables use of extra
2028 debugging information that only GDB can use; this extra information
2029 makes debugging work better in GDB but will probably make other debuggers
2030 crash or
2031 refuse to read the program.  If you want to control for certain whether
2032 to generate the extra information, use `\|\c
2033 .B \-gstabs+\c
2034 \&\|', `\|\c
2035 .B \-gstabs\c
2036 \&\|',
2037 `\|\c
2038 .B \-gxcoff+\c
2039 \&\|', `\|\c
2040 .B \-gxcoff\c
2041 \&\|', `\|\c
2042 .B \-gdwarf+\c
2043 \&\|', or `\|\c
2044 .B \-gdwarf\c
2045 \&\|'
2046 (see below).
2048 Unlike most other C compilers, GNU CC allows you to use `\|\c
2049 .B \-g\c
2050 \&\|' with
2051 `\|\c
2052 .B \-O\c
2053 \&\|'.  The shortcuts taken by optimized code may occasionally
2054 produce surprising results: some variables you declared may not exist
2055 at all; flow of control may briefly move where you did not expect it;
2056 some statements may not be executed because they compute constant
2057 results or their values were already at hand; some statements may
2058 execute in different places because they were moved out of loops.
2060 Nevertheless it proves possible to debug optimized output.  This makes
2061 it reasonable to use the optimizer for programs that might have bugs.
2063 The following options are useful when GNU CC is generated with the
2064 capability for more than one debugging format.
2066 .B \-ggdb
2067 Produce debugging information in the native format (if that is supported),
2068 including GDB extensions if at all possible.
2070 .B \-gstabs
2071 Produce debugging information in stabs format (if that is supported),
2072 without GDB extensions.  This is the format used by DBX on most BSD
2073 systems.
2075 .B \-gstabs+
2076 Produce debugging information in stabs format (if that is supported),
2077 using GNU extensions understood only by the GNU debugger (GDB).  The
2078 use of these extensions is likely to make other debuggers crash or
2079 refuse to read the program.
2081 .B \-gcoff
2082 Produce debugging information in COFF format (if that is supported).
2083 This is the format used by SDB on most System V systems prior to
2084 System V Release 4.
2086 .B \-gxcoff
2087 Produce debugging information in XCOFF format (if that is supported).
2088 This is the format used by the DBX debugger on IBM RS/6000 systems.
2090 .B \-gxcoff+
2091 Produce debugging information in XCOFF format (if that is supported),
2092 using GNU extensions understood only by the GNU debugger (GDB).  The
2093 use of these extensions is likely to make other debuggers crash or
2094 refuse to read the program.
2096 .B \-gdwarf
2097 Produce debugging information in DWARF format (if that is supported).
2098 This is the format used by SDB on most System V Release 4 systems.
2100 .B \-gdwarf+
2101 Produce debugging information in DWARF format (if that is supported),
2102 using GNU extensions understood only by the GNU debugger (GDB).  The
2103 use of these extensions is likely to make other debuggers crash or
2104 refuse to read the program.
2106 .BI "\-g" "level"
2108 .BI "\-ggdb" "level"
2110 .BI "\-gstabs" "level"
2112 .BI "\-gcoff" "level"
2113 .BI "\-gxcoff" "level"
2115 .BI "\-gdwarf" "level"
2116 Request debugging information and also use \c
2117 .I level\c
2118 \& to specify how
2119 much information.  The default level is 2.
2121 Level 1 produces minimal information, enough for making backtraces in
2122 parts of the program that you don't plan to debug.  This includes
2123 descriptions of functions and external variables, but no information
2124 about local variables and no line numbers.
2126 Level 3 includes extra information, such as all the macro definitions
2127 present in the program.  Some debuggers support macro expansion when
2128 you use `\|\c
2129 .B \-g3\c
2130 \&\|'.
2132 .B \-p
2133 Generate extra code to write profile information suitable for the
2134 analysis program \c
2135 .B prof\c
2138 .B \-pg
2139 Generate extra code to write profile information suitable for the
2140 analysis program \c
2141 .B gprof\c
2144 .B \-a
2145 Generate extra code to write profile information for basic blocks,
2146 which will record the number of times each basic block is executed.
2147 This data could be analyzed by a program like \c
2148 .B tcov\c
2149 \&.  Note,
2150 however, that the format of the data is not what \c
2151 .B tcov\c
2152 \& expects.
2153 Eventually GNU \c
2154 .B gprof\c
2155 \& should be extended to process this data.
2157 .B \-ax
2158 Generate extra code to read basic block profiling parameters from 
2159 file `bb.in' and write profiling results to file `bb.out'.
2160 `bb.in' contains a list of functions. Whenever a function on the list
2161 is entered, profiling is turned on. When the outmost function is left,
2162 profiling is turned off. If a function name is prefixed with `-'
2163 the function is excluded from profiling. If a function name is not
2164 unique it can be disambiguated by writing
2165 `/path/filename.d:functionname'. `bb.out' will list some available
2166 filenames.
2167 Four function names have a special meaning:
2168 `__bb_jumps__' will cause jump frequencies to be written to `bb.out'.
2169 `__bb_trace__' will cause the sequence of basic blocks to be piped 
2170 into `gzip' and written to file `bbtrace.gz'.
2171 `__bb_hidecall__' will cause call instructions to be excluded from
2172 the trace.
2173 `__bb_showret__' will cause return instructions to be included in
2174 the trace.
2176 .BI "\-d" "letters"
2177 Says to make debugging dumps during compilation at times specified by
2178 .I letters\c
2179 \&.  This is used for debugging the compiler.  The file names
2180 for most of the dumps are made by appending a word to the source file
2181 name (e.g.  `\|\c
2182 .B foo.c.rtl\c
2183 \&\|' or `\|\c
2184 .B foo.c.jump\c
2185 \&\|').
2187 .B \-dM
2188 Dump all macro definitions, at the end of preprocessing, and write no
2189 output.
2191 .B \-dN
2192 Dump all macro names, at the end of preprocessing.
2194 .B \-dD
2195 Dump all macro definitions, at the end of preprocessing, in addition to
2196 normal output.
2198 .B \-dy
2199 Dump debugging information during parsing, to standard error.
2201 .B \-dr
2202 Dump after RTL generation, to `\|\c
2203 .I file\c
2204 .B \&.rtl\c
2205 \&\|'.
2207 .B \-dx
2208 Just generate RTL for a function instead of compiling it.  Usually used
2209 with `\|\c
2210 .B r\c
2211 \&\|'.
2213 .B \-dj
2214 Dump after first jump optimization, to `\|\c
2215 .I file\c
2216 .B \&.jump\c
2217 \&\|'.
2219 .B \-ds
2220 Dump after CSE (including the jump optimization that sometimes
2221 follows CSE), to `\|\c
2222 .I file\c
2223 .B \&.cse\c
2224 \&\|'.
2226 .B \-dL
2227 Dump after loop optimization, to `\|\c
2228 .I file\c
2229 .B \&.loop\c
2230 \&\|'.
2232 .B \-dt
2233 Dump after the second CSE pass (including the jump optimization that
2234 sometimes follows CSE), to `\|\c
2235 .I file\c
2236 .B \&.cse2\c
2237 \&\|'.
2239 .B \-df
2240 Dump after flow analysis, to `\|\c
2241 .I file\c
2242 .B \&.flow\c
2243 \&\|'.
2245 .B \-dc
2246 Dump after instruction combination, to `\|\c
2247 .I file\c
2248 .B \&.combine\c
2249 \&\|'.
2251 .B \-dS
2252 Dump after the first instruction scheduling pass, to
2253 `\|\c
2254 .I file\c
2255 .B \&.sched\c
2256 \&\|'.
2258 .B \-dl
2259 Dump after local register allocation, to `\|\c
2260 .I file\c
2261 .B \&.lreg\c
2262 \&\|'.
2264 .B \-dg
2265 Dump after global register allocation, to `\|\c
2266 .I file\c
2267 .B \&.greg\c
2268 \&\|'.
2270 .B \-dR
2271 Dump after the second instruction scheduling pass, to
2272 `\|\c
2273 .I file\c
2274 .B \&.sched2\c
2275 \&\|'.
2277 .B \-dJ
2278 Dump after last jump optimization, to `\|\c
2279 .I file\c
2280 .B \&.jump2\c
2281 \&\|'.
2283 .B \-dd
2284 Dump after delayed branch scheduling, to `\|\c
2285 .I file\c
2286 .B \&.dbr\c
2287 \&\|'.
2289 .B \-dk
2290 Dump after conversion from registers to stack, to `\|\c
2291 .I file\c
2292 .B \&.stack\c
2293 \&\|'.
2295 .B \-da
2296 Produce all the dumps listed above.
2298 .B \-dm
2299 Print statistics on memory usage, at the end of the run, to
2300 standard error.
2302 .B \-dp
2303 Annotate the assembler output with a comment indicating which
2304 pattern and alternative was used.
2306 .B \-fpretend\-float
2307 When running a cross-compiler, pretend that the target machine uses the
2308 same floating point format as the host machine.  This causes incorrect
2309 output of the actual floating constants, but the actual instruction
2310 sequence will probably be the same as GNU CC would make when running on
2311 the target machine.
2313 .B \-save\-temps
2314 Store the usual \*(lqtemporary\*(rq intermediate files permanently; place them
2315 in the current directory and name them based on the source file.  Thus,
2316 compiling `\|\c
2317 .B foo.c\c
2318 \&\|' with `\|\c
2319 .B \-c \-save\-temps\c
2320 \&\|' would produce files
2321 `\|\c
2322 .B foo.cpp\c
2323 \&\|' and `\|\c
2324 .B foo.s\c
2325 \&\|', as well as `\|\c
2326 .B foo.o\c
2327 \&\|'.
2329 .BI "\-print\-file\-name=" "library"
2330 Print the full absolute name of the library file \|\c
2332 .I library
2334 \&\| that
2335 would be used when linking\(em\&and do not do anything else.  With this
2336 option, GNU CC does not compile or link anything; it just prints the
2337 file name.
2339 .B \-print\-libgcc\-file\-name
2340 Same as `\|\c
2341 .B \-print\-file\-name=libgcc.a\c
2342 \&\|'.
2344 .BI "\-print\-prog\-name=" "program"
2345 Like `\|\c
2346 .B \-print\-file\-name\c
2347 \&\|', but searches for a program such as `\|\c
2348 cpp\c
2349 \&\|'.
2350 .SH OPTIMIZATION OPTIONS
2351 These options control various sorts of optimizations:
2353 .B \-O
2355 .B \-O1
2356 Optimize.  Optimizing compilation takes somewhat more time, and a lot
2357 more memory for a large function.
2359 Without `\|\c
2360 .B \-O\c
2361 \&\|', the compiler's goal is to reduce the cost of
2362 compilation and to make debugging produce the expected results.
2363 Statements are independent: if you stop the program with a breakpoint
2364 between statements, you can then assign a new value to any variable or
2365 change the program counter to any other statement in the function and
2366 get exactly the results you would expect from the source code.
2368 Without `\|\c
2369 .B \-O\c
2370 \&\|', only variables declared \c
2371 .B register\c
2372 \& are
2373 allocated in registers.  The resulting compiled code is a little worse
2374 than produced by PCC without `\|\c
2375 .B \-O\c
2376 \&\|'.
2378 With `\|\c
2379 .B \-O\c
2380 \&\|', the compiler tries to reduce code size and execution
2381 time.
2383 When you specify `\|\c
2384 .B \-O\c
2385 \&\|', the two options `\|\c
2386 .B \-fthread\-jumps\c
2387 \&\|' and `\|\c
2388 .B \-fdefer\-pop\c
2389 \&\|' are turned on.  On machines that have delay slots, the `\|\c
2390 .B \-fdelayed\-branch\c
2391 \&\|' option is turned on.  For those machines that can support debugging even
2392 without a frame pointer, the `\|\c
2393 .B \-fomit\-frame\-pointer\c
2394 \&\|' option is turned on.  On some machines other flags may also be turned on.
2396 .B \-O2
2397 Optimize even more.  Nearly all supported optimizations that do not
2398 involve a space-speed tradeoff are performed.  Loop unrolling and function
2399 inlining are not done, for example.  As compared to
2400 .B \-O\c
2402 this option increases both compilation time and the performance of the
2403 generated code.
2405 .B \-O3
2406 Optimize yet more. This turns on everything
2407 .B \-O2
2408 does, along with also turning on
2409 .B \-finline\-functions.
2411 .B \-O0
2412 Do not optimize.
2414 If you use multiple
2415 .B \-O
2416 options, with or without level numbers, the last such option is the
2417 one that is effective.
2419 Options of the form `\|\c
2420 .B \-f\c
2421 .I flag\c
2422 \&\c
2423 \&\|' specify machine-independent
2424 flags.  Most flags have both positive and negative forms; the negative
2425 form of `\|\c
2426 .B \-ffoo\c
2427 \&\|' would be `\|\c
2428 .B \-fno\-foo\c
2429 \&\|'.  The following list shows
2430 only one form\(em\&the one which is not the default.
2431 You can figure out the other form by either removing `\|\c
2432 .B no\-\c
2433 \&\|' or
2434 adding it.
2436 .B \-ffloat\-store
2437 Do not store floating point variables in registers.  This
2438 prevents undesirable excess precision on machines such as the
2439 68000 where the floating registers (of the 68881) keep more
2440 precision than a \c
2441 .B double\c
2442 \& is supposed to have.
2444 For most programs, the excess precision does only good, but a few
2445 programs rely on the precise definition of IEEE floating point.
2446 Use `\|\c
2447 .B \-ffloat\-store\c
2448 \&\|' for such programs.
2450 .B \-fmemoize\-lookups
2452 .B \-fsave\-memoized
2453 Use heuristics to compile faster (C++ only).  These heuristics are not
2454 enabled by default, since they are only effective for certain input
2455 files.  Other input files compile more slowly.
2457 The first time the compiler must build a call to a member function (or
2458 reference to a data member), it must (1) determine whether the class
2459 implements member functions of that name; (2) resolve which member
2460 function to call (which involves figuring out what sorts of type
2461 conversions need to be made); and (3) check the visibility of the member
2462 function to the caller.  All of this adds up to slower compilation.
2463 Normally, the second time a call is made to that member function (or
2464 reference to that data member), it must go through the same lengthy
2465 process again.  This means that code like this
2467 \&  cout << "This " << p << " has " << n << " legs.\en";
2469 makes six passes through all three steps.  By using a software cache,
2470 a \*(lqhit\*(rq significantly reduces this cost.  Unfortunately, using the
2471 cache introduces another layer of mechanisms which must be implemented,
2472 and so incurs its own overhead.  `\|\c
2473 .B \-fmemoize\-lookups\c
2474 \&\|' enables
2475 the software cache.
2477 Because access privileges (visibility) to members and member functions
2478 may differ from one function context to the next,
2479 .B g++
2480 may need to flush the cache.  With the `\|\c
2481 .B \-fmemoize\-lookups\c
2482 \&\|' flag, the cache is flushed after every
2483 function that is compiled.  The `\|\c
2484 \-fsave\-memoized\c
2485 \&\|' flag enables the same software cache, but when the compiler
2486 determines that the context of the last function compiled would yield
2487 the same access privileges of the next function to compile, it
2488 preserves the cache.
2489 This is most helpful when defining many member functions for the same
2490 class: with the exception of member functions which are friends of
2491 other classes, each member function has exactly the same access
2492 privileges as every other, and the cache need not be flushed.
2494 .B \-fno\-default\-inline
2495 Don't make member functions inline by default merely because they are
2496 defined inside the class scope (C++ only).
2498 .B \-fno\-defer\-pop
2499 Always pop the arguments to each function call as soon as that
2500 function returns.  For machines which must pop arguments after a
2501 function call, the compiler normally lets arguments accumulate on the
2502 stack for several function calls and pops them all at once.
2504 .B \-fforce\-mem
2505 Force memory operands to be copied into registers before doing
2506 arithmetic on them.  This may produce better code by making all
2507 memory references potential common subexpressions.  When they are
2508 not common subexpressions, instruction combination should
2509 eliminate the separate register-load.  I am interested in hearing
2510 about the difference this makes.
2512 .B \-fforce\-addr
2513 Force memory address constants to be copied into registers before
2514 doing arithmetic on them.  This may produce better code just as
2515 `\|\c
2516 .B \-fforce\-mem\c
2517 \&\|' may.  I am interested in hearing about the
2518 difference this makes.
2520 .B \-fomit\-frame\-pointer
2521 Don't keep the frame pointer in a register for functions that
2522 don't need one.  This avoids the instructions to save, set up and
2523 restore frame pointers; it also makes an extra register available
2524 in many functions.  \c
2525 .I It also makes debugging impossible on most machines\c
2528 On some machines, such as the Vax, this flag has no effect, because
2529 the standard calling sequence automatically handles the frame pointer
2530 and nothing is saved by pretending it doesn't exist.  The
2531 machine-description macro \c
2532 .B FRAME_POINTER_REQUIRED\c
2533 \& controls
2534 whether a target machine supports this flag.
2536 .B \-finline\-functions
2537 Integrate all simple functions into their callers.  The compiler
2538 heuristically decides which functions are simple enough to be worth
2539 integrating in this way.
2541 If all calls to a given function are integrated, and the function is
2542 declared \c
2543 .B static\c
2544 \&, then GCC normally does not output the function as
2545 assembler code in its own right.
2547 .B \-fcaller\-saves
2548 Enable values to be allocated in registers that will be clobbered by
2549 function calls, by emitting extra instructions to save and restore the
2550 registers around such calls.  Such allocation is done only when it
2551 seems to result in better code than would otherwise be produced.
2553 This option is enabled by default on certain machines, usually those
2554 which have no call-preserved registers to use instead.
2556 .B \-fkeep\-inline\-functions
2557 Even if all calls to a given function are integrated, and the function
2558 is declared \c
2559 .B static\c
2560 \&, nevertheless output a separate run-time
2561 callable version of the function.
2563 .B \-fno\-function\-cse
2564 Do not put function addresses in registers; make each instruction that
2565 calls a constant function contain the function's address explicitly.
2567 This option results in less efficient code, but some strange hacks
2568 that alter the assembler output may be confused by the optimizations
2569 performed when this option is not used.
2571 .B \-fno\-peephole
2572 Disable any machine-specific peephole optimizations.
2574 .B \-ffast-math
2575 This option allows GCC to violate some ANSI or IEEE rules/specifications
2576 in the interest of optimizing code for speed.  For example, it allows
2577 the compiler to assume arguments to the \c
2578 .B sqrt\c
2579 \& function are
2580 non-negative numbers.
2582 This option should never be turned on by any `\|\c
2583 .B \-O\c
2584 \&\|' option since
2585 it can result in incorrect output for programs which depend on
2586 an exact implementation of IEEE or ANSI rules/specifications for
2587 math functions.
2589 The following options control specific optimizations.  The `\|\c
2590 .B \-O2\c
2591 \&\|'
2592 option turns on all of these optimizations except `\|\c
2593 .B \-funroll\-loops\c
2594 \&\|'
2595 and `\|\c
2596 .B \-funroll\-all\-loops\c
2597 \&\|'.
2599 The `\|\c
2600 .B \-O\c
2601 \&\|' option usually turns on
2602 the `\|\c
2603 .B \-fthread\-jumps\c
2604 \&\|' and `\|\c
2605 .B \-fdelayed\-branch\c
2606 \&\|' options, but
2607 specific machines may change the default optimizations.
2609 You can use the following flags in the rare cases when \*(lqfine-tuning\*(rq
2610 of optimizations to be performed is desired.
2612 .B \-fstrength\-reduce
2613 Perform the optimizations of loop strength reduction and
2614 elimination of iteration variables.
2616 .B \-fthread\-jumps
2617 Perform optimizations where we check to see if a jump branches to a
2618 location where another comparison subsumed by the first is found.  If
2619 so, the first branch is redirected to either the destination of the
2620 second branch or a point immediately following it, depending on whether
2621 the condition is known to be true or false.
2623 .B \-funroll\-loops
2624 Perform the optimization of loop unrolling.  This is only done for loops
2625 whose number of iterations can be determined at compile time or run time.
2627 .B \-funroll\-all\-loops
2628 Perform the optimization of loop unrolling.  This is done for all loops.
2629 This usually makes programs run more slowly.
2631 .B \-fcse\-follow\-jumps
2632 In common subexpression elimination, scan through jump instructions
2633 when the target of the jump is not reached by any other path.  For
2634 example, when CSE encounters an \c
2635 .B if\c
2636 \& statement with an
2637 .B else\c
2638 \& clause, CSE will follow the jump when the condition
2639 tested is false.
2641 .B \-fcse\-skip\-blocks
2642 This is similar to `\|\c
2643 .B \-fcse\-follow\-jumps\c
2644 \&\|', but causes CSE to
2645 follow jumps which conditionally skip over blocks.  When CSE
2646 encounters a simple \c
2647 .B if\c
2648 \& statement with no else clause,
2649 `\|\c
2650 .B \-fcse\-skip\-blocks\c
2651 \&\|' causes CSE to follow the jump around the
2652 body of the \c
2653 .B if\c
2656 .B \-frerun\-cse\-after\-loop
2657 Re-run common subexpression elimination after loop optimizations has been
2658 performed.
2660 .B \-felide\-constructors
2661 Elide constructors when this seems plausible (C++ only).  With this
2662 flag, GNU C++ initializes \c
2663 .B y\c
2664 \& directly from the call to \c
2665 .B foo
2666 without going through a temporary in the following code:
2668 A foo ();
2669 A y = foo ();
2671 Without this option, GNU C++ first initializes \c
2672 .B y\c
2673 \& by calling the
2674 appropriate constructor for type \c
2675 .B A\c
2676 \&; then assigns the result of
2677 .B foo\c
2678 \& to a temporary; and, finally, replaces the initial value of
2679 `\|\c
2680 .B y\c
2681 \&\|' with the temporary.
2683 The default behavior (`\|\c
2684 .B \-fno\-elide\-constructors\c
2685 \&\|') is specified by
2686 the draft ANSI C++ standard.  If your program's constructors have side
2687 effects, using `\|\c
2688 .B \-felide-constructors\c
2689 \&\|' can make your program act
2690 differently, since some constructor calls may be omitted.
2692 .B \-fexpensive\-optimizations
2693 Perform a number of minor optimizations that are relatively expensive.
2695 .B \-fdelayed\-branch
2696 If supported for the target machine, attempt to reorder instructions
2697 to exploit instruction slots available after delayed branch
2698 instructions.
2700 .B \-fschedule\-insns
2701 If supported for the target machine, attempt to reorder instructions to
2702 eliminate execution stalls due to required data being unavailable.  This
2703 helps machines that have slow floating point or memory load instructions
2704 by allowing other instructions to be issued until the result of the load
2705 or floating point instruction is required.
2707 .B \-fschedule\-insns2
2708 Similar to `\|\c
2709 .B \-fschedule\-insns\c
2710 \&\|', but requests an additional pass of
2711 instruction scheduling after register allocation has been done.  This is
2712 especially useful on machines with a relatively small number of
2713 registers and where memory load instructions take more than one cycle.
2714 .SH TARGET OPTIONS
2715 By default, GNU CC compiles code for the same type of machine that you
2716 are using.  However, it can also be installed as a cross-compiler, to
2717 compile for some other type of machine.  In fact, several different
2718 configurations of GNU CC, for different target machines, can be
2719 installed side by side.  Then you specify which one to use with the
2720 `\|\c
2721 .B \-b\c
2722 \&\|' option.
2724 In addition, older and newer versions of GNU CC can be installed side
2725 by side.  One of them (probably the newest) will be the default, but
2726 you may sometimes wish to use another.
2728 .BI "\-b " "machine"
2729 The argument \c
2730 .I machine\c
2731 \& specifies the target machine for compilation.
2732 This is useful when you have installed GNU CC as a cross-compiler.
2734 The value to use for \c
2735 .I machine\c
2736 \& is the same as was specified as the
2737 machine type when configuring GNU CC as a cross-compiler.  For
2738 example, if a cross-compiler was configured with `\|\c
2739 .B configure
2740 i386v\c
2741 \&\|', meaning to compile for an 80386 running System V, then you
2742 would specify `\|\c
2743 .B \-b i386v\c
2744 \&\|' to run that cross compiler.
2746 When you do not specify `\|\c
2747 .B \-b\c
2748 \&\|', it normally means to compile for
2749 the same type of machine that you are using.
2751 .BI "\-V " "version"
2752 The argument \c
2753 .I version\c
2754 \& specifies which version of GNU CC to run.
2755 This is useful when multiple versions are installed.  For example,
2756 .I version\c
2757 \& might be `\|\c
2758 .B 2.0\c
2759 \&\|', meaning to run GNU CC version 2.0.
2761 The default version, when you do not specify `\|\c
2762 .B \-V\c
2763 \&\|', is controlled
2764 by the way GNU CC is installed.  Normally, it will be a version that
2765 is recommended for general use.
2766 .SH MACHINE DEPENDENT OPTIONS
2767 Each of the target machine types can have its own special options,
2768 starting with `\|\c
2769 .B \-m\c
2770 \&\|', to choose among various hardware models or
2771 configurations\(em\&for example, 68010 vs 68020, floating coprocessor or
2772 none.  A single installed version of the compiler can compile for any
2773 model or configuration, according to the options specified.
2775 Some configurations of the compiler also support additional special
2776 options, usually for command-line compatibility with other compilers on
2777 the same platform.
2779 These are the `\|\c
2780 .B \-m\c
2781 \&\|' options defined for the 68000 series:
2783 .B \-m68000
2785 .B \-mc68000
2786 Generate output for a 68000.  This is the default when the compiler is
2787 configured for 68000-based systems.
2789 .B \-m68020
2791 .B \-mc68020
2792 Generate output for a 68020 (rather than a 68000).  This is the
2793 default when the compiler is configured for 68020-based systems.
2795 .B \-m68881
2796 Generate output containing 68881 instructions for floating point.
2797 This is the default for most 68020-based systems unless
2798 .B \-nfp
2799 was specified when the compiler was configured.
2801 .B \-m68030
2802 Generate output for a 68030.  This is the default when the compiler is
2803 configured for 68030-based systems.
2805 .B \-m68040
2806 Generate output for a 68040.  This is the default when the compiler is
2807 configured for 68040-based systems.
2809 .B \-m68020\-40
2810 Generate output for a 68040, without using any of the new instructions.
2811 This results in code which can run relatively efficiently on either a
2812 68020/68881 or a 68030 or a 68040.
2814 .B \-mfpa
2815 Generate output containing Sun FPA instructions for floating point.
2817 .B \-msoft\-float
2818 Generate output containing library calls for floating point.
2820 WARNING:
2821 the requisite libraries are not part of GNU CC.  Normally the
2822 facilities of the machine's usual C compiler are used, but this can't
2823 be done directly in cross-compilation.  You must make your own
2824 arrangements to provide suitable library functions for cross-compilation.
2826 .B \-mshort
2827 Consider type \c
2828 .B int\c
2829 \& to be 16 bits wide, like \c
2830 .B short int\c
2833 .B \-mnobitfield
2834 Do not use the bit-field instructions.  `\|\c
2835 .B \-m68000\c
2836 \&\|' implies
2837 `\|\c
2838 .B \-mnobitfield\c
2839 \&\|'.
2841 .B \-mbitfield
2842 Do use the bit-field instructions.  `\|\c
2843 .B \-m68020\c
2844 \&\|' implies
2845 `\|\c
2846 .B \-mbitfield\c
2847 \&\|'.  This is the default if you use the unmodified
2848 sources.
2850 .B \-mrtd
2851 Use a different function-calling convention, in which functions
2852 that take a fixed number of arguments return with the \c
2853 .B rtd
2854 instruction, which pops their arguments while returning.  This
2855 saves one instruction in the caller since there is no need to pop
2856 the arguments there.
2858 This calling convention is incompatible with the one normally
2859 used on Unix, so you cannot use it if you need to call libraries
2860 compiled with the Unix compiler.
2862 Also, you must provide function prototypes for all functions that
2863 take variable numbers of arguments (including \c
2864 .B printf\c
2865 \&);
2866 otherwise incorrect code will be generated for calls to those
2867 functions.
2869 In addition, seriously incorrect code will result if you call a
2870 function with too many arguments.  (Normally, extra arguments are
2871 harmlessly ignored.)
2873 The \c
2874 .B rtd\c
2875 \& instruction is supported by the 68010 and 68020
2876 processors, but not by the 68000.
2878 These `\|\c
2879 .B \-m\c
2880 \&\|' options are defined for the Vax:
2882 .B \-munix
2883 Do not output certain jump instructions (\c
2884 .B aobleq\c
2885 \& and so on)
2886 that the Unix assembler for the Vax cannot handle across long
2887 ranges.
2889 .B \-mgnu
2890 Do output those jump instructions, on the assumption that you
2891 will assemble with the GNU assembler.
2893 .B \-mg
2894 Output code for g-format floating point numbers instead of d-format.
2896 These `\|\c
2897 .B \-m\c
2898 \&\|' switches are supported on the SPARC:
2900 .B \-mfpu
2902 .B \-mhard\-float
2903 Generate output containing floating point instructions.  This is the
2904 default.
2906 .B \-mno\-fpu
2908 .B \-msoft\-float
2909 Generate output containing library calls for floating point.
2910 .I Warning:
2911 there is no GNU floating-point library for SPARC.
2912 Normally the facilities of the machine's usual C compiler are used, but
2913 this cannot be done directly in cross-compilation.  You must make your
2914 own arrangements to provide suitable library functions for
2915 cross-compilation.
2917 .B \-msoft\-float
2918 changes the calling convention in the output file;
2919 therefore, it is only useful if you compile
2920 .I all
2921 of a program with this option.
2923 .B \-mno\-epilogue
2925 .B \-mepilogue
2926 With
2927 .B \-mepilogue
2928 (the default), the compiler always emits code for
2929 function exit at the end of each function.  Any function exit in
2930 the middle of the function (such as a return statement in C) will
2931 generate a jump to the exit code at the end of the function.
2933 With
2934 .BR \-mno\-epilogue ,
2935 the compiler tries to emit exit code inline at every function exit.
2937 .B \-mno\-v8
2939 .B \-mv8
2941 .B \-msparclite
2942 These three options select variations on the SPARC architecture.
2944 By default (unless specifically configured for the Fujitsu SPARClite),
2945 GCC generates code for the v7 variant of the SPARC architecture.
2947 .B \-mv8
2948 will give you SPARC v8 code.  The only difference from v7
2949 code is that the compiler emits the integer multiply and integer
2950 divide instructions which exist in SPARC v8 but not in SPARC v7.
2952 .B \-msparclite
2953 will give you SPARClite code.  This adds the integer
2954 multiply, integer divide step and scan (ffs) instructions which
2955 exist in SPARClite but not in SPARC v7.
2957 .B \-mcypress
2959 .B \-msupersparc
2960 These two options select the processor for which the code is optimised.
2962 With
2963 .B \-mcypress
2964 (the default), the compiler optimises code for the Cypress CY7C602 chip, as
2965 used in the SparcStation/SparcServer 3xx series. This is also appropriate for
2966 the older SparcStation 1, 2, IPX etc.
2968 With
2969 .B \-msupersparc
2970 the compiler optimises code for the SuperSparc cpu, as used in the SparcStation
2971 10, 1000 and 2000 series. This flag also enables use of the full SPARC v8
2972 instruction set.
2974 These `\|\c
2975 .B \-m\c
2976 \&\|' options are defined for the Convex:
2978 .B \-mc1
2979 Generate output for a C1.  This is the default when the compiler is
2980 configured for a C1.
2982 .B \-mc2
2983 Generate output for a C2.  This is the default when the compiler is
2984 configured for a C2.
2986 .B \-margcount
2987 Generate code which puts an argument count in the word preceding each
2988 argument list.  Some nonportable Convex and Vax programs need this word.
2989 (Debuggers don't, except for functions with variable-length argument
2990 lists; this info is in the symbol table.)
2992 .B \-mnoargcount
2993 Omit the argument count word.  This is the default if you use the
2994 unmodified sources.
2996 These `\|\c
2997 .B \-m\c
2998 \&\|' options are defined for the AMD Am29000:
3000 .B \-mdw
3001 Generate code that assumes the DW bit is set, i.e., that byte and
3002 halfword operations are directly supported by the hardware.  This is the
3003 default.
3005 .B \-mnodw
3006 Generate code that assumes the DW bit is not set.
3008 .B \-mbw
3009 Generate code that assumes the system supports byte and halfword write
3010 operations.  This is the default.
3012 .B \-mnbw
3013 Generate code that assumes the systems does not support byte and
3014 halfword write operations.  This implies `\|\c
3015 .B \-mnodw\c
3016 \&\|'.
3018 .B \-msmall
3019 Use a small memory model that assumes that all function addresses are
3020 either within a single 256 KB segment or at an absolute address of less
3021 than 256K.  This allows the \c
3022 .B call\c
3023 \& instruction to be used instead
3024 of a \c
3025 .B const\c
3026 \&, \c
3027 .B consth\c
3028 \&, \c
3029 .B calli\c
3030 \& sequence.
3032 .B \-mlarge
3033 Do not assume that the \c
3034 .B call\c
3035 \& instruction can be used; this is the
3036 default.
3038 .B \-m29050
3039 Generate code for the Am29050.
3041 .B \-m29000
3042 Generate code for the Am29000.  This is the default.
3044 .B \-mkernel\-registers
3045 Generate references to registers \c
3046 .B gr64-gr95\c
3047 \& instead of
3048 .B gr96-gr127\c
3049 \&.  This option can be used when compiling kernel code
3050 that wants a set of global registers disjoint from that used by
3051 user-mode code.
3053 Note that when this option is used, register names in `\|\c
3054 .B \-f\c
3055 \&\|' flags
3056 must use the normal, user-mode, names.
3058 .B \-muser\-registers
3059 Use the normal set of global registers, \c
3060 .B gr96-gr127\c
3061 \&.  This is the
3062 default.
3064 .B \-mstack\-check
3065 Insert a call to \c
3066 .B _\|_msp_check\c
3067 \& after each stack adjustment.  This
3068 is often used for kernel code.
3070 These `\|\c
3071 .B \-m\c
3072 \&\|' options are defined for Motorola 88K architectures:
3074 .B \-m88000
3075 Generate code that works well on both the m88100 and the
3076 m88110.
3078 .B \-m88100
3079 Generate code that works best for the m88100, but that also
3080 runs on the m88110.
3082 .B \-m88110
3083 Generate code that works best for the m88110, and may not run
3084 on the m88100.
3086 .B \-midentify\-revision
3087 Include an \c
3088 .B ident\c
3089 \& directive in the assembler output recording the
3090 source file name, compiler name and version, timestamp, and compilation
3091 flags used.
3093 .B \-mno\-underscores
3094 In assembler output, emit symbol names without adding an underscore
3095 character at the beginning of each name.  The default is to use an
3096 underscore as prefix on each name.
3098 .B \-mno\-check\-zero\-division
3100 .B \-mcheck\-zero\-division
3101 Early models of the 88K architecture had problems with division by zero;
3102 in particular, many of them didn't trap.  Use these options to avoid
3103 including (or to include explicitly) additional code to detect division
3104 by zero and signal an exception.  All GCC configurations for the 88K use
3105 `\|\c
3106 .B \-mcheck\-zero\-division\c
3107 \&\|' by default.
3109 .B \-mocs\-debug\-info
3111 .B \-mno\-ocs\-debug\-info
3112 Include (or omit) additional debugging information (about
3113 registers used in each stack frame) as specified in the 88Open Object
3114 Compatibility Standard, \*(lqOCS\*(rq.  This extra information is not needed
3115 by GDB.  The default for DG/UX, SVr4, and Delta 88 SVr3.2 is to
3116 include this information; other 88k configurations omit this information
3117 by default.
3119 .B \-mocs\-frame\-position
3121 .B \-mno\-ocs\-frame\-position
3122 Force (or do not require) register values to be stored in a particular
3123 place in stack frames, as specified in OCS.  The DG/UX, Delta88 SVr3.2,
3124 and BCS configurations use `\|\c
3125 .B \-mocs\-frame\-position\c
3126 \&\|'; other 88k
3127 configurations have the default `\|\c
3128 .B \-mno\-ocs\-frame\-position\c
3129 \&\|'.
3131 .B \-moptimize\-arg\-area
3133 .B \-mno\-optimize\-arg\-area
3134 Control how to store function arguments in stack frames.
3135 `\|\c
3136 .B \-moptimize\-arg\-area\c
3137 \&\|' saves space, but may break some
3138 debuggers (not GDB).  `\|\c
3139 .B \-mno\-optimize\-arg\-area\c
3140 \&\|' conforms better to
3141 standards.   By default GCC does not optimize the argument area.
3143 .BI "\-mshort\-data\-" "num"
3144 .I num
3145 Generate smaller data references by making them relative to \c
3146 .B r0\c
3148 which allows loading a value using a single instruction (rather than the
3149 usual two).  You control which data references are affected by
3150 specifying \c
3151 .I num\c
3152 \& with this option.  For example, if you specify
3153 `\|\c
3154 .B \-mshort\-data\-512\c
3155 \&\|', then the data references affected are those
3156 involving displacements of less than 512 bytes.
3157 `\|\c
3158 .B \-mshort\-data\-\c
3159 .I num\c
3160 \&\c
3161 \&\|' is not effective for \c
3162 .I num\c
3163 \& greater
3164 than 64K.
3166 .B \-mserialize-volatile
3168 .B \-mno-serialize-volatile
3169 Do, or do not, generate code to guarantee sequential consistency of
3170 volatile memory references.
3172 GNU CC always guarantees consistency by default, for the preferred
3173 processor submodel.  How this is done depends on the submodel.
3175 The m88100 processor does not reorder memory references and so always
3176 provides sequential consistency.  If you use `\|\c
3177 .B \-m88100\c
3178 \&\|', GNU CC does
3179 not generate any special instructions for sequential consistency.
3181 The order of memory references made by the m88110 processor does not
3182 always match the order of the instructions requesting those references.
3183 In particular, a load instruction may execute before a preceding store
3184 instruction.  Such reordering violates sequential consistency of
3185 volatile memory references, when there are multiple processors.  When
3186 you use `\|\c
3187 .B \-m88000\c
3188 \&\|' or `\|\c
3189 .B \-m88110\c
3190 \&\|', GNU CC generates special
3191 instructions when appropriate, to force execution in the proper order.
3193 The extra code generated to guarantee consistency may affect the
3194 performance of your application.  If you know that you can safely forgo
3195 this guarantee, you may use the option `\|\c
3196 .B \-mno-serialize-volatile\c
3197 \&\|'.
3199 If you use the `\|\c
3200 .B \-m88100\c
3201 \&\|' option but require sequential consistency
3202 when running on the m88110 processor, you should use
3203 `\|\c
3204 .B \-mserialize-volatile\c
3205 \&\|'.
3207 .B \-msvr4
3209 .B \-msvr3
3210 Turn on (`\|\c
3211 .B \-msvr4\c
3212 \&\|') or off (`\|\c
3213 .B \-msvr3\c
3214 \&\|') compiler extensions
3215 related to System V release 4 (SVr4).  This controls the following:
3217 \ \ \ \(bu
3218 Which variant of the assembler syntax to emit (which you can select
3219 independently using `\|\c
3220 .B \-mversion\-03.00\c
3221 \&\|').
3223 \ \ \ \(bu
3224 `\|\c
3225 .B \-msvr4\c
3226 \&\|' makes the C preprocessor recognize `\|\c
3227 .B #pragma weak\c
3228 \&\|'
3230 \ \ \ \(bu
3231 `\|\c
3232 .B \-msvr4\c
3233 \&\|' makes GCC issue additional declaration directives used in
3234 SVr4.
3236 `\|\c
3237 .B \-msvr3\c
3238 \&\|' is the default for all m88K configurations except
3239 the SVr4 configuration.
3241 .B \-mtrap\-large\-shift
3243 .B \-mhandle\-large\-shift
3244 Include code to detect bit-shifts of more than 31 bits; respectively,
3245 trap such shifts or emit code to handle them properly.  By default GCC
3246 makes no special provision for large bit shifts.
3248 .B \-muse\-div\-instruction
3249 Very early models of the 88K architecture didn't have a divide
3250 instruction, so GCC avoids that instruction by default.  Use this option
3251 to specify that it's safe to use the divide instruction.
3253 .B \-mversion\-03.00
3254 In the DG/UX configuration, there are two flavors of SVr4.  This option
3255 modifies
3256 .B \-msvr4
3257 to select whether the hybrid-COFF or real-ELF
3258 flavor is used.  All other configurations ignore this option.
3260 .B \-mwarn\-passed\-structs
3261 Warn when a function passes a struct as an argument or result.
3262 Structure-passing conventions have changed during the evolution of the C
3263 language, and are often the source of portability problems.  By default,
3264 GCC issues no such warning.
3266 These options are defined for the IBM RS6000:
3268 .B \-mfp\-in\-toc
3270 .B \-mno\-fp\-in\-toc
3271 Control whether or not floating-point constants go in the Table of
3272 Contents (TOC), a table of all global variable and function addresses.  By
3273 default GCC puts floating-point constants there; if the TOC overflows,
3274 `\|\c
3275 .B \-mno\-fp\-in\-toc\c
3276 \&\|' will reduce the size of the TOC, which may avoid
3277 the overflow.
3279 These `\|\c
3280 .B \-m\c
3281 \&\|' options are defined for the IBM RT PC:
3283 .B \-min\-line\-mul
3284 Use an in-line code sequence for integer multiplies.  This is the
3285 default.
3287 .B \-mcall\-lib\-mul
3288 Call \c
3289 .B lmul$$\c
3290 \& for integer multiples.
3292 .B \-mfull\-fp\-blocks
3293 Generate full-size floating point data blocks, including the minimum
3294 amount of scratch space recommended by IBM.  This is the default.
3296 .B \-mminimum\-fp\-blocks
3297 Do not include extra scratch space in floating point data blocks.  This
3298 results in smaller code, but slower execution, since scratch space must
3299 be allocated dynamically.
3301 .B \-mfp\-arg\-in\-fpregs
3302 Use a calling sequence incompatible with the IBM calling convention in
3303 which floating point arguments are passed in floating point registers.
3304 Note that \c
3305 .B varargs.h\c
3306 \& and \c
3307 .B stdargs.h\c
3308 \& will not work with
3309 floating point operands if this option is specified.
3311 .B \-mfp\-arg\-in\-gregs
3312 Use the normal calling convention for floating point arguments.  This is
3313 the default.
3315 .B \-mhc\-struct\-return
3316 Return structures of more than one word in memory, rather than in a
3317 register.  This provides compatibility with the MetaWare HighC (hc)
3318 compiler.  Use `\|\c
3319 .B \-fpcc\-struct\-return\c
3320 \&\|' for compatibility with the
3321 Portable C Compiler (pcc).
3323 .B \-mnohc\-struct\-return
3324 Return some structures of more than one word in registers, when
3325 convenient.  This is the default.  For compatibility with the
3326 IBM-supplied compilers, use either `\|\c
3327 .B \-fpcc\-struct\-return\c
3328 \&\|' or
3329 `\|\c
3330 .B \-mhc\-struct\-return\c
3331 \&\|'.
3333 These `\|\c
3334 .B \-m\c
3335 \&\|' options are defined for the MIPS family of computers:
3337 .BI "\-mcpu=" "cpu-type"
3338 Assume the defaults for the machine type
3339 .I cpu-type
3340 when
3341 scheduling instructions.  The default
3342 .I cpu-type
3344 .BR default ,
3345 which picks the longest cycles times for any of the machines, in order
3346 that the code run at reasonable rates on all MIPS cpu's.  Other
3347 choices for
3348 .I cpu-type
3350 .BR r2000 ,
3351 .BR r3000 ,
3352 .BR r4000 ,
3354 .BR r6000 .
3355 While picking a specific
3356 .I cpu-type
3357 will schedule things appropriately for that particular chip, the
3358 compiler will not generate any code that does not meet level 1 of the
3359 MIPS ISA (instruction set architecture) without the
3360 .B \-mips2
3362 .B \-mips3
3363 switches being used.
3365 .B \-mips2
3366 Issue instructions from level 2 of the MIPS ISA (branch likely, square
3367 root instructions).  The
3368 .B \-mcpu=r4000
3370 .B \-mcpu=r6000
3371 switch must be used in conjunction with
3372 .BR \-mips2 .
3374 .B \-mips3
3375 Issue instructions from level 3 of the MIPS ISA (64 bit instructions).
3377 .B \-mcpu=r4000
3378 switch must be used in conjunction with
3379 .BR \-mips2 .
3381 .B \-mint64
3383 .B \-mlong64
3385 .B \-mlonglong128
3386 These options don't work at present.
3388 .B \-mmips\-as
3389 Generate code for the MIPS assembler, and invoke
3390 .B mips\-tfile
3391 to add normal debug information.  This is the default for all
3392 platforms except for the OSF/1 reference platform, using the OSF/rose
3393 object format.  If any of the
3394 .BR \-ggdb ,
3395 .BR \-gstabs ,
3397 .B \-gstabs+
3398 switches are used, the
3399 .B mips\-tfile
3400 program will encapsulate the stabs within MIPS ECOFF.
3402 .B \-mgas
3403 Generate code for the GNU assembler.  This is the default on the OSF/1
3404 reference platform, using the OSF/rose object format.
3406 .B \-mrnames
3408 .B \-mno\-rnames
3410 .B \-mrnames
3411 switch says to output code using the MIPS software names for the
3412 registers, instead of the hardware names (ie,
3413 .B a0
3414 instead of
3415 .BR $4 ).
3416 The GNU assembler does not support the
3417 .B \-mrnames
3418 switch, and the MIPS assembler will be instructed to run the MIPS C
3419 preprocessor over the source file.  The
3420 .B \-mno\-rnames
3421 switch is default.
3423 .B \-mgpopt
3425 .B \-mno\-gpopt
3427 .B \-mgpopt
3428 switch says to write all of the data declarations before the
3429 instructions in the text section, to all the MIPS assembler to
3430 generate one word memory references instead of using two words for
3431 short global or static data items.  This is on by default if
3432 optimization is selected.
3434 .B \-mstats
3436 .B \-mno\-stats
3437 For each non-inline function processed, the
3438 .B \-mstats
3439 switch causes the compiler to emit one line to the standard error file
3440 to print statistics about the program (number of registers saved,
3441 stack size, etc.).
3443 .B \-mmemcpy
3445 .B \-mno\-memcpy
3447 .B \-mmemcpy
3448 switch makes all block moves call the appropriate string function
3449 .RB ( memcpy
3451 .BR bcopy )
3452 instead of possibly generating inline code.
3454 .B \-mmips\-tfile
3456 .B \-mno\-mips\-tfile
3458 .B \-mno\-mips\-tfile
3459 switch causes the compiler not postprocess the object file with the
3460 .B mips\-tfile
3461 program, after the MIPS assembler has generated it to add debug
3462 support.  If
3463 .B mips\-tfile
3464 is not run, then no local variables will be available to the debugger.
3465 In addition,
3466 .B stage2
3468 .B stage3
3469 objects will have the temporary file names passed to the assembler
3470 embedded in the object file, which means the objects will not compare
3471 the same.
3473 .B \-msoft\-float
3474 Generate output containing library calls for floating point.
3476 WARNING:
3477 the requisite libraries are not part of GNU CC.  Normally the
3478 facilities of the machine's usual C compiler are used, but this can't
3479 be done directly in cross-compilation.  You must make your own
3480 arrangements to provide suitable library functions for cross-compilation.
3482 .B \-mhard\-float
3483 Generate output containing floating point instructions.  This is the
3484 default if you use the unmodified sources.
3486 .B \-mfp64
3487 Assume that the
3488 .B FR
3489 bit in the status word is on, and that there are 32 64-bit floating
3490 point registers, instead of 32 32-bit floating point registers.  You
3491 must also specify the
3492 .B \-mcpu=r4000
3494 .B \-mips3
3495 switches.
3497 .B \-mfp32
3498 Assume that there are 32 32-bit floating point registers.  This is the
3499 default.
3501 .B \-mabicalls
3503 .B \-mno\-abicalls
3504 Emit (or do not emit) the
3505 .BR \&.abicalls ,
3506 .BR \&.cpload ,
3508 .B \&.cprestore
3509 pseudo operations that some System V.4 ports use for position
3510 independent code.
3512 .B \-mhalf\-pic
3514 .B \-mno\-half\-pic
3516 .B \-mhalf\-pic
3517 switch says to put pointers to extern references into the data section
3518 and load them up, rather than put the references in the text section.
3519 This option does not work at present.
3521 .BI \-G num
3522 Put global and static items less than or equal to
3523 .I num
3524 bytes into the small data or bss sections instead of the normal data
3525 or bss section.  This allows the assembler to emit one word memory
3526 reference instructions based on the global pointer
3527 .RB ( gp
3529 .BR $28 ),
3530 instead of the normal two words used.  By default,
3531 .I num
3532 is 8 when the MIPS assembler is used, and 0 when the GNU
3533 assembler is used.  The
3534 .BI \-G num
3535 switch is also passed to the assembler and linker.  All modules should
3536 be compiled with the same
3537 .BI \-G num
3538 value.
3540 .B \-nocpp
3541 Tell the MIPS assembler to not run it's preprocessor over user
3542 assembler files (with a `\|\c
3543 .B .s\c
3544 \&\|' suffix) when assembling them.
3546 These `\|\c
3547 .B \-m\c
3548 \&\|' options are defined for the Intel 80386 family of computers:
3549 .B \-m486
3551 .B \-mno\-486
3552 Control whether or not code is optimized for a 486 instead of an
3553 386.  Code generated for a 486 will run on a 386 and vice versa.
3555 .B \-msoft\-float
3556 Generate output containing library calls for floating point.
3557 .I Warning:
3558 the requisite libraries are not part of GNU CC.
3559 Normally the facilities of the machine's usual C compiler are used, but
3560 this can't be done directly in cross-compilation.  You must make your
3561 own arrangements to provide suitable library functions for
3562 cross-compilation.
3564 On machines where a function returns floating point results in the 80387
3565 register stack, some floating point opcodes may be emitted even if
3566 `\|\c
3567 .B \-msoft-float\c
3568 \&\|' is used.
3570 .B \-mno-fp-ret-in-387
3571 Do not use the FPU registers for return values of functions.
3573 The usual calling convention has functions return values of types
3574 .B float\c
3575 \& and \c
3576 .B double\c
3577 \& in an FPU register, even if there
3578 is no FPU.  The idea is that the operating system should emulate
3579 an FPU.
3581 The option `\|\c
3582 .B \-mno-fp-ret-in-387\c
3583 \&\|' causes such values to be returned
3584 in ordinary CPU registers instead.
3586 These `\|\c
3587 .B \-m\c
3588 \&\|' options are defined for the HPPA family of computers:
3590 .B \-mpa-risc-1-0
3591 Generate code for a PA 1.0 processor.
3593 .B \-mpa-risc-1-1
3594 Generate code for a PA 1.1 processor.
3596 .B \-mkernel
3597 Generate code which is suitable for use in kernels.  Specifically, avoid
3598 .B add\c
3599 \& instructions in which one of the arguments is the DP register;
3600 generate \c
3601 .B addil\c
3602 \& instructions instead.  This avoids a rather serious
3603 bug in the HP-UX linker.
3605 .B \-mshared-libs
3606 Generate code that can be linked against HP-UX shared libraries.  This option
3607 is not fully function yet, and is not on by default for any PA target.  Using
3608 this option can cause incorrect code to be generated by the compiler.
3610 .B \-mno-shared-libs
3611 Don't generate code that will be linked against shared libraries.  This is
3612 the default for all PA targets.
3614 .B \-mlong-calls
3615 Generate code which allows calls to functions greater than 256K away from
3616 the caller when the caller and callee are in the same source file.  Do
3617 not turn this option on unless code refuses to link with \*(lqbranch out of
3618 range errors\*('' from the linker.
3620 .B \-mdisable-fpregs
3621 Prevent floating point registers from being used in any manner.  This is
3622 necessary for compiling kernels which perform lazy context switching of
3623 floating point registers.  If you use this option and attempt to perform
3624 floating point operations, the compiler will abort.
3626 .B \-mdisable-indexing
3627 Prevent the compiler from using indexing address modes.  This avoids some
3628 rather obscure problems when compiling MIG generated code under MACH.
3630 .B \-mtrailing-colon
3631 Add a colon to the end of label definitions (for ELF assemblers).
3633 These `\|\c
3634 .B \-m\c
3635 \&\|' options are defined for the Intel 80960 family of computers:
3637 .BI "\-m" "cpu-type"
3638 Assume the defaults for the machine type
3639 .I cpu-type
3640 for instruction and addressing-mode availability and alignment.
3641 The default
3642 .I cpu-type
3644 .BR kb ;
3645 other choices are
3646 .BR ka ,
3647 .BR mc ,
3648 .BR ca ,
3649 .BR cf ,
3650 .BR sa ,
3652 .BR sb .
3654 .B \-mnumerics
3656 .B \-msoft\-float
3658 .B \-mnumerics
3659 option indicates that the processor does support
3660 floating-point instructions.  The
3661 .B \-msoft\-float
3662 option indicates
3663 that floating-point support should not be assumed.
3665 .B \-mleaf\-procedures
3667 .B \-mno\-leaf\-procedures
3668 Do (or do not) attempt to alter leaf procedures to be callable with the
3669 .I bal
3670 instruction as well as
3671 .IR call .
3672 This will result in more
3673 efficient code for explicit calls when the
3674 .I bal
3675 instruction can be
3676 substituted by the assembler or linker, but less efficient code in other
3677 cases, such as calls via function pointers, or using a linker that doesn't
3678 support this optimization.
3680 .B \-mtail\-call
3682 .B \-mno\-tail\-call
3683 Do (or do not) make additional attempts (beyond those of the
3684 machine-independent portions of the compiler) to optimize tail-recursive
3685 calls into branches.  You may not want to do this because the detection of
3686 cases where this is not valid is not totally complete.  The default is
3687 .BR \-mno\-tail\-call .
3689 .B \-mcomplex\-addr
3691 .B \-mno\-complex\-addr
3692 Assume (or do not assume) that the use of a complex addressing mode is a
3693 win on this implementation of the i960.  Complex addressing modes may not
3694 be worthwhile on the K-series, but they definitely are on the C-series.
3695 The default is currently
3696 .B \-mcomplex\-addr
3697 for all processors except
3698 the CB and CC.
3700 .B \-mcode\-align
3702 .B \-mno\-code\-align
3703 Align code to 8-byte boundaries for faster fetching (or don't bother).
3704 Currently turned on by default for C-series implementations only.
3706 .B \-mic\-compat
3708 .B \-mic2.0\-compat
3710 .B \-mic3.0\-compat
3711 Enable compatibility with iC960 v2.0 or v3.0.
3713 .B \-masm\-compat
3715 .B \-mintel\-asm
3716 Enable compatibility with the iC960 assembler.
3718 .B \-mstrict\-align
3720 .B \-mno\-strict\-align
3721 Do not permit (do permit) unaligned accesses.
3723 .B \-mold\-align
3724 Enable structure-alignment compatibility with Intel's gcc release version
3725 1.3 (based on gcc 1.37).  Currently this is buggy in that
3726 .B #pragma align 1
3727 is always assumed as well, and cannot be turned off.
3729 These `\|\c
3730 .B \-m\c
3731 \&\|' options are defined for the DEC Alpha implementations:
3733 .B \-mno-soft-float
3735 .B \-msoft-float
3736 Use (do not use) the hardware floating-point instructions for
3737 floating-point operations.  When \c
3738 .B \-msoft-float\c
3739 \& is specified,
3740 functions in `\|\c
3741 .B libgcc1.c\c
3742 \&\|' will be used to perform floating-point
3743 operations.  Unless they are replaced by routines that emulate the
3744 floating-point operations, or compiled in such a way as to call such
3745 emulations routines, these routines will issue floating-point
3746 operations.   If you are compiling for an Alpha without floating-point
3747 operations, you must ensure that the library is built so as not to call
3748 them.
3750 Note that Alpha implementations without floating-point operations are
3751 required to have floating-point registers.
3753 .B \-mfp-reg
3755 .B \-mno-fp-regs
3756 Generate code that uses (does not use) the floating-point register set.
3757 .B \-mno-fp-regs\c
3758 \& implies \c
3759 .B \-msoft-float\c
3760 \&.  If the floating-point
3761 register set is not used, floating point operands are passed in integer
3762 registers as if they were integers and floating-point results are passed
3763 in $0 instead of $f0.  This is a non-standard calling sequence, so any
3764 function with a floating-point argument or return value called by code
3765 compiled with \c
3766 .B \-mno-fp-regs\c
3767 \& must also be compiled with that
3768 option.
3770 A typical use of this option is building a kernel that does not use,
3771 and hence need not save and restore, any floating-point registers.
3773 These additional options are available on System V Release 4 for
3774 compatibility with other compilers on those systems:
3776 .B \-G
3777 On SVr4 systems, \c
3778 .B gcc\c
3779 \& accepts the option `\|\c
3780 .B \-G\c
3781 \&\|' (and passes
3782 it to the system linker), for compatibility with other compilers.
3783 However, we suggest you use `\|\c
3784 .B \-symbolic\c
3785 \&\|' or `\|\c
3786 .B \-shared\c
3787 \&\|' as
3788 appropriate, instead of supplying linker options on the \c
3789 .B gcc
3790 command line.
3792 .B \-Qy
3793 Identify the versions of each tool used by the compiler, in a
3794 .B .ident\c
3795 \& assembler directive in the output.
3797 .B \-Qn
3798 Refrain from adding \c
3799 .B .ident\c
3800 \& directives to the output file (this is
3801 the default).
3803 .BI "\-YP," "dirs"
3804 Search the directories \c
3805 .I dirs\c
3806 \&, and no others, for libraries
3807 specified with `\|\c
3808 .B \-l\c
3809 \&\|'.  You can separate directory entries in
3810 .I dirs\c
3811 \& from one another with colons.
3813 .BI "\-Ym," "dir"
3814 Look in the directory \c
3815 .I dir\c
3816 \& to find the M4 preprocessor.
3817 The assembler uses this option.
3818 .SH CODE GENERATION OPTIONS
3819 These machine-independent options control the interface conventions
3820 used in code generation.
3822 Most of them begin with `\|\c
3823 \-f\c
3824 \&\|'.  These options have both positive and negative forms; the negative form
3825 of `\|\c
3826 .B \-ffoo\c
3827 \&\|' would be `\|\c
3828 .B \-fno\-foo\c
3829 \&\|'.  In the table below, only
3830 one of the forms is listed\(em\&the one which is not the default.  You
3831 can figure out the other form by either removing `\|\c
3832 .B no\-\c
3833 \&\|' or adding
3836 .B \-fnonnull\-objects
3837 Assume that objects reached through references are not null
3838 (C++ only).
3840 Normally, GNU C++ makes conservative assumptions about objects reached
3841 through references.  For example, the compiler must check that \c
3842 .B a
3843 is not null in code like the following:
3845 obj &a = g ();
3846 a.f (2);
3848 Checking that references of this sort have non-null values requires
3849 extra code, however, and it is unnecessary for many programs.  You can
3850 use `\|\c
3851 .B \-fnonnull-objects\c
3852 \&\|' to omit the checks for null, if your
3853 program doesn't require checking.
3855 .B \-fpcc\-struct\-return
3856 Use the same convention for returning \c
3857 .B struct\c
3858 \& and \c
3859 .B union
3860 values that is used by the usual C compiler on your system.  This
3861 convention is less efficient for small structures, and on many
3862 machines it fails to be reentrant; but it has the advantage of
3863 allowing intercallability between GCC-compiled code and PCC-compiled
3864 code.
3866 .B \-freg\-struct\-return
3867 Use the convention that
3868 .B struct
3870 .B union
3871 values are returned in registers when possible.  This is more
3872 efficient for small structures than
3873 .BR \-fpcc\-struct\-return .
3875 If you specify neither
3876 .B \-fpcc\-struct\-return
3878 .BR \-freg\-struct\-return ,
3879 GNU CC defaults to whichever convention is standard for the target.
3880 If there is no standard convention, GNU CC defaults to
3881 .BR \-fpcc\-struct\-return .
3883 .B \-fshort\-enums
3884 Allocate to an \c
3885 .B enum\c
3886 \& type only as many bytes as it needs for the
3887 declared range of possible values.  Specifically, the \c
3888 .B enum\c
3889 \& type
3890 will be equivalent to the smallest integer type which has enough room.
3892 .B \-fshort\-double
3893 Use the same size for
3894 .B double
3895 as for
3896 .B float
3899 .B \-fshared\-data
3900 Requests that the data and non-\c
3901 .B const\c
3902 \& variables of this
3903 compilation be shared data rather than private data.  The distinction
3904 makes sense only on certain operating systems, where shared data is
3905 shared between processes running the same program, while private data
3906 exists in one copy per process.
3908 .B \-fno\-common
3909 Allocate even uninitialized global variables in the bss section of the
3910 object file, rather than generating them as common blocks.  This has the
3911 effect that if the same variable is declared (without \c
3912 .B extern\c
3913 \&) in
3914 two different compilations, you will get an error when you link them.
3915 The only reason this might be useful is if you wish to verify that the
3916 program will work on other systems which always work this way.
3918 .B \-fno\-ident
3919 Ignore the `\|\c
3920 .B #ident\c
3921 \&\|' directive.
3923 .B \-fno\-gnu\-linker
3924 Do not output global initializations (such as C++ constructors and
3925 destructors) in the form used by the GNU linker (on systems where the GNU
3926 linker is the standard method of handling them).  Use this option when
3927 you want to use a non-GNU linker, which also requires using the
3928 .B collect2\c
3929 \& program to make sure the system linker includes
3930 constructors and destructors.  (\c
3931 .B collect2\c
3932 \& is included in the GNU CC
3933 distribution.)  For systems which \c
3934 .I must\c
3935 \& use \c
3936 .B collect2\c
3937 \&, the
3938 compiler driver \c
3939 .B gcc\c
3940 \& is configured to do this automatically.
3942 .B \-finhibit-size-directive
3943 Don't output a \c
3944 .B .size\c
3945 \& assembler directive, or anything else that
3946 would cause trouble if the function is split in the middle, and the
3947 two halves are placed at locations far apart in memory.  This option is
3948 used when compiling `\|\c
3949 .B crtstuff.c\c
3950 \&\|'; you should not need to use it
3951 for anything else.
3953 .B \-fverbose-asm
3954 Put extra commentary information in the generated assembly code to
3955 make it more readable.  This option is generally only of use to those
3956 who actually need to read the generated assembly code (perhaps while
3957 debugging the compiler itself).
3959 .B \-fvolatile
3960 Consider all memory references through pointers to be volatile.
3962 .B \-fvolatile\-global
3963 Consider all memory references to extern and global data items to
3964 be volatile.
3966 .B \-fpic
3967 If supported for the target machines, generate position-independent code,
3968 suitable for use in a shared library.
3970 .B \-fPIC
3971 If supported for the target machine, emit position-independent code,
3972 suitable for dynamic linking, even if branches need large displacements.
3974 .BI "\-ffixed\-" "reg"
3975 Treat the register named \c
3976 .I reg\c
3977 \& as a fixed register; generated code
3978 should never refer to it (except perhaps as a stack pointer, frame
3979 pointer or in some other fixed role).
3981 .I reg\c
3982 \& must be the name of a register.  The register names accepted
3983 are machine-specific and are defined in the \c
3984 .B REGISTER_NAMES
3985 macro in the machine description macro file.
3987 This flag does not have a negative form, because it specifies a
3988 three-way choice.
3990 .BI "\-fcall\-used\-" "reg"
3991 Treat the register named \c
3992 .I reg\c
3993 \& as an allocatable register that is
3994 clobbered by function calls.  It may be allocated for temporaries or
3995 variables that do not live across a call.  Functions compiled this way
3996 will not save and restore the register \c
3997 .I reg\c
4000 Use of this flag for a register that has a fixed pervasive role in the
4001 machine's execution model, such as the stack pointer or frame pointer,
4002 will produce disastrous results.
4004 This flag does not have a negative form, because it specifies a
4005 three-way choice.
4007 .BI "\-fcall\-saved\-" "reg"
4008 Treat the register named \c
4009 .I reg\c
4010 \& as an allocatable register saved by
4011 functions.  It may be allocated even for temporaries or variables that
4012 live across a call.  Functions compiled this way will save and restore
4013 the register \c
4014 .I reg\c
4015 \& if they use it.
4017 Use of this flag for a register that has a fixed pervasive role in the
4018 machine's execution model, such as the stack pointer or frame pointer,
4019 will produce disastrous results.
4021 A different sort of disaster will result from the use of this flag for
4022 a register in which function values may be returned.
4024 This flag does not have a negative form, because it specifies a
4025 three-way choice.
4026 .SH PRAGMAS
4027 Two `\|\c
4028 .B #pragma\c
4029 \&\|' directives are supported for GNU C++, to permit using the same
4030 header file for two purposes: as a definition of interfaces to a given
4031 object class, and as the full definition of the contents of that object class.
4033 .B #pragma interface
4034 (C++ only.)
4035 Use this directive in header files that define object classes, to save
4036 space in most of the object files that use those classes.  Normally,
4037 local copies of certain information (backup copies of inline member
4038 functions, debugging information, and the internal tables that
4039 implement virtual functions) must be kept in each object file that
4040 includes class definitions.  You can use this pragma to avoid such
4041 duplication.  When a header file containing `\|\c
4042 .B #pragma interface\c
4043 \&\|' is included in a compilation, this auxiliary information
4044 will not be generated (unless the main input source file itself uses
4045 `\|\c
4046 .B #pragma implementation\c
4047 \&\|').  Instead, the object files will contain references to be
4048 resolved at link time.
4050 .B #pragma implementation
4052 \fB#pragma implementation "\fP\fIobjects\fP\fB.h"\fP
4053 (C++ only.)
4054 Use this pragma in a main input file, when you want full output from
4055 included header files to be generated (and made globally visible).
4056 The included header file, in turn, should use `\|\c
4057 .B #pragma interface\c
4058 \&\|'.
4059 Backup copies of inline member functions, debugging information, and
4060 the internal tables used to implement virtual functions are all
4061 generated in implementation files.
4063 If you use `\|\c
4064 .B #pragma implementation\c
4065 \&\|' with no argument, it applies to an include file with the same
4066 basename as your source file; for example, in `\|\c
4067 .B allclass.cc\c
4068 \&\|', `\|\c
4069 .B #pragma implementation\c
4070 \&\|' by itself is equivalent to `\|\c
4072 #pragma implementation "allclass.h"\c
4073 \&\|'.  Use the string argument if you want a single implementation
4074 file to include code from multiple header files.
4076 There is no way to split up the contents of a single header file into
4077 multiple implementation files.
4078 .SH FILES
4080 .ta \w'LIBDIR/g++\-include 'u
4081 file.c  C source file
4082 file.h  C header (preprocessor) file
4083 file.i  preprocessed C source file
4084 file.C  C++ source file
4085 file.cc C++ source file
4086 file.cxx        C++ source file
4087 file.m  Objective-C source file
4088 file.s  assembly language file
4089 file.o  object file
4090 a.out   link edited output
4091 \fITMPDIR\fR/cc\(**     temporary files
4092 \fILIBDIR\fR/cpp        preprocessor
4093 \fILIBDIR\fR/cc1        compiler for C
4094 \fILIBDIR\fR/cc1plus    compiler for C++
4095 \fILIBDIR\fR/collect    linker front end needed on some machines
4096 \fILIBDIR\fR/libgcc.a   GCC subroutine library
4097 /lib/crt[01n].o start-up routine
4098 \fILIBDIR\fR/ccrt0      additional start-up routine for C++
4099 /lib/libc.a     standard C library, see
4100 .IR intro (3)
4101 /usr/include    standard directory for \fB#include\fP files
4102 \fILIBDIR\fR/include    standard gcc directory for \fB#include\fP files
4103 \fILIBDIR\fR/g++\-include       additional g++ directory for \fB#include\fP
4106 .I LIBDIR
4107 is usually
4108 .B /usr/local/lib/\c
4109 .IR machine / version .
4111 .I TMPDIR
4112 comes from the environment variable
4113 .B TMPDIR
4114 (default
4115 .B /usr/tmp
4116 if available, else
4117 .B /tmp\c
4118 \&).
4119 .SH "SEE ALSO"
4120 cpp(1), as(1), ld(1), gdb(1), adb(1), dbx(1), sdb(1).
4122 .RB "`\|" gcc "\|', `\|" cpp \|',
4123 .RB "`\|" as "\|', `\|" ld \|',
4125 .RB `\| gdb \|'
4126 entries in
4127 .B info\c
4131 Using and Porting GNU CC (for version 2.0)\c
4132 , Richard M. Stallman;
4134 The C Preprocessor\c
4135 , Richard M. Stallman;
4137 Debugging with GDB: the GNU Source-Level Debugger\c
4138 , Richard M. Stallman and Roland H. Pesch;
4140 Using as: the GNU Assembler\c
4141 , Dean Elsner, Jay Fenlason & friends;
4143 ld: the GNU linker\c
4144 , Steve Chamberlain and Roland Pesch.
4145 .SH BUGS
4146 For instructions on reporting bugs, see the GCC manual.
4147 .SH COPYING
4148 Copyright
4149 .if t \(co
4150 1991, 1992, 1993 Free Software Foundation, Inc.
4152 Permission is granted to make and distribute verbatim copies of
4153 this manual provided the copyright notice and this permission notice
4154 are preserved on all copies.
4156 Permission is granted to copy and distribute modified versions of this
4157 manual under the conditions for verbatim copying, provided that the
4158 entire resulting derived work is distributed under the terms of a
4159 permission notice identical to this one.
4161 Permission is granted to copy and distribute translations of this
4162 manual into another language, under the above conditions for modified
4163 versions, except that this permission notice may be included in
4164 translations approved by the Free Software Foundation instead of in
4165 the original English.
4166 .SH AUTHORS
4167 See the GNU CC Manual for the contributors to GNU CC.