|
|
1.1 root 1: {\rtf0\ansi{\fonttbl\f0\fnil Times-Roman;\f1\fmodern Courier;\f3\ftech Symbol;\f2\fmodern Ohlfs;\f4\fswiss Helvetica;}
2: \f0\fs28 {\info{\comment build from /build/cc_proj/cc/cc/invoke.texi}}
3: \
4: {{\NeXTHelpMarker \markername Invoking GCC;}
5: ,}{\fs88 {\f4 1}\i\
6: GNU CC Command Options}\
7: \
8: When you invoke GNU CC, it normally does preprocessing,
9: compilation, assembly and linking. The ``overall options'' allow you to stop
10: this process at an intermediate stage. For example, the {\f4\fs24 -c} option says not to
11: run the linker. Then the output consists of object files output by the
12: assembler. \
13: Other options are passed on to one stage of processing. Some
14: options control the preprocessor and others the compiler itself. Yet other
15: options control the assembler and linker; most of these are not documented
16: here, since you rarely need to use any of them. \
17: Most of the command line
18: options that you can use with GNU CC are useful for C programs; when an option
19: is only useful with another language (usually C++), the explanation says so
20: explicitly. If the description for a particular option does not mention a
21: source language, you can use that option with all supported languages. \
22: {See `Compiling C++ Programs' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Invoking G++;}
23: ,}., for a
24: summary of special options for compiling C++ programs. \
25: The {\f1\fs24 gcc} program accepts
26: options and file names as operands. Many options have multiletter names;
27: therefore multiple single-letter options may {\i not} be grouped: {\f4\fs24 -dr} is very
28: different from {\f4\fs24 -d -r}. \
29: You can mix options and other arguments. For the most
30: part, the order you use doesn't matter. Order does matter when you use several
31: options of the same kind; for example, if you specify {\f4\fs24 -L} more than once, the
32: directories are searched in the order specified. \
33: Many options have long names
34: starting with {\f4\fs24 -f} or with {\f4\fs24 -W}---for example, {\f4\fs24 -fforce-mem}, {\f4\fs24 -fstrength-reduce}, {\f4\fs24
35: -Wformat} and so on. Most of these have both positive and negative forms; the
36: negative form of {\f4\fs24 -ffoo} would be {\f4\fs24 -fno-foo}. This manual documents only one of
37: these two forms, whichever one is not the default. \
38: \
39: {{\NeXTHelpMarker \markername Option Summary;}
40: ,}{\b\fs48\f4 1.1 Option Summary}\
41: \
42: Here is a
43: summary of all the options, grouped by type. Explanations are in the following
44: sections. \
45: \
46: {\i Overall Options} {See `Options Controlling the Kind of Output' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Overall Options;}
47: ,}.. {\f1\fs24 -c -S -E -o {\i file} -pipe -v -x {\i language} }\
48: \
49: \
50: {\i C
51: Language Options} {See `Options Controlling C Dialect' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {C Dialect Options;}
52: ,}.. {\f1\fs24 -ansi -fcond-mismatch -fno-asm -fno-builtin }\
53: {\f1\fs24
54: -fsigned-bitfields -fsigned-char }\
55: {\f1\fs24
56: -funsigned-bitfields -funsigned-char -fwritable-strings }\
57: {\f1\fs24
58: -traditional -traditional-cpp -trigraphs }\
59: \
60: \
61: {\i C++ Language Options} {See `Options Controlling C++ Dialect' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {C++ Dialect Options;}
62: ,}.. {\f1\fs24
63: -fall-virtual -fdollars-in-identifiers }\
64: {\f1\fs24 -felide-constructors -fenum-int-equiv }\
65: {\f1\fs24
66: -fexternal-templates -fmemoize-lookups }\
67: {\f1\fs24
68: -fno-strict-prototype -fnonnull-objects }\
69: {\f1\fs24 -fthis-is-variable -nostdinc++ }\
70: \
71: \
72: {\i
73: Warning Options} {See `Options to Request or Suppress Warnings' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Warning Options;}
74: ,}.. {\f1\fs24 -fsyntax-only -pedantic -pedantic-errors }\
75: {\f1\fs24
76: -w -W -Wall -Waggregate-return -Wcast-align }\
77: {\f1\fs24
78: -Wcast-qual -Wchar-subscript -Wcomment -Wconversion }\
79: {\f1\fs24
80: -Wenum-clash -Werror -Wformat -Wid-clash-{\i len} }\
81: {\f1\fs24
82: -Wimplicit -Wimport -Winline -Wmissing-prototypes }\
83: {\f1\fs24
84: -Wnested-externs -Woverloaded-virtual -Wparentheses }\
85: {\f1\fs24
86: -Wpointer-arith -Wredundant-decls -Wreturn-type }\
87: {\f1\fs24
88: -Wshadow -Wstrict-prototypes -Wswitch }\
89: {\f1\fs24
90: -Wtemplate-debugging -Wtraditional -Wtrigraphs }\
91: {\f1\fs24
92: -Wuninitialized -Wunused -Wwrite-strings }\
93: \
94: \
95: {\i Debugging Options} {See `Options for Debugging Your Program or GCC' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Debugging Options;}
96: ,}.. {\f1\fs24 -a -d{\i letters}
97: -fpretend-float }\
98: {\f1\fs24 -g -g{\i level} -ggdb -gdwarf -gdwarf+ }\
99: {\f1\fs24
100: -gstabs -gstabs+ -gcoff -gxcoff -gxcoff+ }\
101: {\f1\fs24
102: -p -pg -save-temps -print-libgcc-file-name }\
103: \
104: \
105: {\i Optimization Options} {See `Options that Control Optimization' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Optimize Options;}
106: ,}.. {\f1\fs24
107: -fcaller-saves -fcse-follow-jumps -fcse-skip-blocks }\
108: {\f1\fs24
109: -fdelayed-branch -fexpensive-optimizations }\
110: {\f1\fs24
111: -ffast-math -ffloat-store -fforce-addr -fforce-mem }\
112: {\f1\fs24
113: -finline-functions -fkeep-inline-functions }\
114: {\f1\fs24
115: -fno-default-inline -fno-defer-pop -fno-function-cse }\
116: {\f1\fs24
117: -fno-inline -fno-peephole -fomit-frame-pointer }\
118: {\f1\fs24
119: -frerun-cse-after-loop -fschedule-insns }\
120: {\f1\fs24
121: -fschedule-insns2 -fstrength-reduce -fthread-jumps }\
122: {\f1\fs24
123: -funroll-all-loops -funroll-loops }\
124: {\f1\fs24 -O -O2 }\
125: \
126: \
127: {\i Preprocessor Options} {See `Options Controlling the Preprocessor' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Preprocessor Options;}
128: ,}.. {\f1\fs24 -A{\i assertion}
129: -C -dD -dM -dN }\
130: {\f1\fs24 -D{\i macro}={\i defn} -E -H }\
131: {\f1\fs24 -idirafter {\i dir} }\
132: {\f1\fs24 -include {\i file}
133: -imacros {\i file} }\
134: {\f1\fs24 -iprefix {\i file} -iwithprefix {\i dir} }\
135: {\f1\fs24 -iwithprefixbefore {\i dir} }\
136: {\f1\fs24
137: -M -MD -MM -MMD -nostdinc -P -trigraphs -U{\i macro} }\
138: \
139: \
140: {\i Assembler Option} {See `Passing Options to the Assembler' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Assembler Options;}
141: ,}.. {\f1\fs24 -Wa,{\i
142: option} }\
143: \
144: \
145: {\i Linker Options} {See `Options for Linking' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Link Options;}
146: ,}.. {\f1\fs24 {\i object-file-name} }\
147: {\f1\fs24 -l{\i library} -nostartfiles -nostdlib }\
148: {\f1\fs24
149: -static -shared -symbolic }\
150: {\f1\fs24 -Wl,{\i option} -Xlinker {\i option} }\
151: {\f1\fs24 -u {\i symbol} }\
152: \
153: \
154: {\i Directory
155: Options} {See `Options for Directory Search' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Directory Options;}
156: ,}.. {\f1\fs24 -B{\i prefix} -I{\i dir} -I- -L{\i dir} }\
157: \
158: \
159: {\i Target Options} {See `' {\NeXTHelpLink \markername ;\linkFilename .
160: is way to avoid overfull hbox. -- rms
161: sor}.
162: .
163: are
164: pes.
165:
166: ;\linkMarkername {Target Options;}
167: ,}.. {\f1\fs24 -b {\i machine} -V {\i version} }\
168: \
169: \
170: {\i
171: Machine Dependent Options} {See `Hardware Models and Configurations' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Submodel Options;}
172: ,}.. {\f1\fs24 {\i M680x0 Options} }\
173: {\f1\fs24
174: -m68000 -m68020 -m68020-40 -m68030 -m68040 -m68881 }\
175: {\f1\fs24
176: -mbitfield -mc68000 -mc68020 -mfpa -mnobitfield }\
177: {\f1\fs24
178: -mrtd -mshort -msoft-float }\
179: \
180: {\f1\fs24 {\i VAX Options} }\
181: {\f1\fs24 -mg -mgnu -munix }\
182: \
183: {\f1\fs24 {\i SPARC Options} }\
184: {\f1\fs24
185: -mepilogue -mfpu -mhard-float }\
186: {\f1\fs24 -mno-fpu -mno-epilogue -msoft-float }\
187: {\f1\fs24
188: -msparclite -mv8 }\
189: \
190: {\f1\fs24 {\i Convex Options} }\
191: {\f1\fs24 -mc1 -mc2 -mc32 -mc34 -mc38 }\
192: {\f1\fs24
193: -margcount -mnoargcount }\
194: {\f1\fs24 -mlong32 -mlong64 }\
195: {\f1\fs24
196: -mbolatile-cache -mvolatile-nocache }\
197: \
198: {\f1\fs24 {\i AMD29K Options} }\
199: {\f1\fs24
200: -m29000 -m29050 -mbw -mdw -mkernel-registers }\
201: {\f1\fs24
202: -mlarge -mnbw -mnodw -mnormal -msmall -mstack-check }\
203: {\f1\fs24 -muser-registers }\
204: \
205: {\f1\fs24 {\i
206: M88K Options} }\
207: {\f1\fs24 -m88000 -m88100 -m88110 -mbig-pic }\
208: {\f1\fs24
209: -mcheck-zero-division -mhandle-large-shift }\
210: {\f1\fs24
211: -midentify-revision -mno-check-zero-division }\
212: {\f1\fs24
213: -mno-ocs-debug-info -mno-ocs-frame-position }\
214: {\f1\fs24
215: -mno-optimize-arg-area -mno-serialize-volatile }\
216: {\f1\fs24
217: -mno-underscores -mocs-debug-info }\
218: {\f1\fs24 -mocs-frame-position -moptimize-arg-area }\
219: {\f1\fs24
220: -mserialize-volatile -mshort-data-{\i num} -msvr3 }\
221: {\f1\fs24
222: -msvr4 -mtrap-large-shift -muse-div-instruction }\
223: {\f1\fs24
224: -mversion-03.00 -mwarn-passed-structs }\
225: \
226: {\f1\fs24 {\i RS/6000 Options and PowerPC} }\
227: {\f1\fs24 -mcpu={\i
228: cpu type} }\
229: {\f1\fs24 -mpower -mno-power -mpower2 -pno-power2 }\
230: {\f1\fs24
231: -mpowerpc -mno-powerpc -mpowerpcsqr -mno-powerpcsqr }\
232: {\f1\fs24 -mpowerpc64 -mno-powerpc64 }\
233: {\f1\fs24
234: -mnew-mnemonics -mno-new-mnemonics }\
235: {\f1\fs24
236: -mnormal-toc -mminimal-toc -mno-fop-in-toc }\
237: \
238: {\f1\fs24 {\i RT Options} }\
239: {\f1\fs24
240: -mcall-lib-mul -mfp-arg-in-fpregs -mfp-arg-in-gregs }\
241: {\f1\fs24
242: -mfull-fp-blocks -mhc-struct-return -min-line-mul }\
243: {\f1\fs24
244: -mminimum-fp-blocks -mnohc-struct-return }\
245: \
246: {\f1\fs24 {\i MIPS Options} }\
247: {\f1\fs24 -mcpu={\i cpu type}
248: -mips2 -mips3 -mint64 }\
249: {\f1\fs24 -mlong64 -mlonglong128 -mmips-as -mgas -mrnames }\
250: {\f1\fs24
251: -mno-rnames -mgpopt -mno-gpopt -mstats -mno-stats }\
252: {\f1\fs24
253: -mmemcpy -mno-memcpy -mno-mips-tfile -mmips-tfile }\
254: {\f1\fs24
255: -msoft-float -mhard-float -mabicalls -mno-abicalls }\
256: {\f1\fs24
257: -mhalf-pic -mno-half-pic -mlong-calls -mno-long-calls }\
258: {\f1\fs24 -G {\i num} -nocpp }\
259: \
260: {\f1\fs24 {\i
261: i386 Options} }\
262: {\f1\fs24 -m486 -mno-486 -msoft-float -msvr3-shlib -mieee-fp }\
263: {\f1\fs24
264: -mno-fp-ret-in-387 }\
265: \
266: {\f1\fs24 {\i HPPA Options} }\
267: {\f1\fs24 -mpa-risc-1-0 }\
268: {\f1\fs24 -mpa-risc-1-1 }\
269: {\f1\fs24 -mlong-calls }\
270: {\f1\fs24
271: -mdisable-fpregs }\
272: {\f1\fs24 -mdisable-indexing }\
273: {\f1\fs24 -mtrailing-colon }\
274: \
275: {\f1\fs24 {\i Intel 960 Options} }\
276: {\f1\fs24 -m{\i
277: cpu type} }\
278: {\f1\fs24 -mnumerics -msoft-float }\
279: {\f1\fs24 -mcode-align -mno-code-align }\
280: {\f1\fs24
281: -mleaf-procedures -mno-leaf-procedures }\
282: {\f1\fs24 -mtail-call -mno-tail-call }\
283: {\f1\fs24
284: -mcomplex-addr -mno-complex-addr }\
285: {\f1\fs24 -mclean-linkage -mno-clean-linkage }\
286: {\f1\fs24
287: -mic-compat -mic2.0-compat -mic3.0-compat }\
288: {\f1\fs24 -masm-compat -mintel-asm }\
289: {\f1\fs24
290: -mstrict-align -mno-strict-align }\
291: {\f1\fs24 -mold-align -mno-old-align }\
292: \
293: {\f1\fs24 {\i
294: DEC Alpha Options} }\
295: {\f1\fs24 -mfp-regs -mno-fp-regs -mno-soft-float }\
296: {\f1\fs24 -msoft-float }\
297: \
298: {\f1\fs24 {\i
299: Clipper Options} }\
300: {\f1\fs24 -mc300 -mc400 }\
301: \
302: {\f1\fs24 {\i System V Options} }\
303: {\f1\fs24 -G -Qy -Qn -YP,{\i paths} -Ym,{\i
304: dir} }\
305: \
306: \
307: {\i Code Generation Options} {See `Options for Code Generation Conventions' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Code Gen Options;}
308: ,}.. {\f1\fs24 -fcall-saved-{\i reg} -fcall-used-{\i reg} }\
309: {\f1\fs24 -ffixed-{\i reg}
310: -finhibit-size-directive }\
311: {\f1\fs24 -fno-common -fno-ident }\
312: {\f1\fs24
313: -fno-gnu-linker -fpcc-struct-return -fpic -fPIC }\
314: {\f1\fs24
315: -freg-struct-return -fshared-data -fshort-enums }\
316: {\f1\fs24
317: -fshort-double -fvolatile -fvolatile-global }\
318: {\f1\fs24 -fverbose-asm }\
319: \
320: \
321: \
322: {{\NeXTHelpMarker \markername Overall Options;}
323: ,}{\b\fs48\f4 1.2 Options
324: Controlling the Kind of Output}\
325: \
326: Compilation can involve up to four stages:
327: preprocessing, compilation proper, assembly and linking, always in that order.
328: The first three stages apply to an individual source file, and end by
329: producing an object file; linking combines all the object files (those newly
330: compiled, and those specified as input) into an executable file. \
331: For any given
332: input file, the file name suffix determines what kind of compilation is done: \
333: \
334: {\f1\fs24 {\i
335: file}.c} C source code which must be preprocessed. \
336: \
337: {\f1\fs24 {\i file}.i} C source code which
338: should not be preprocessed. \
339: \
340: {\f1\fs24 {\i file}.ii} C++ source code which should not be
341: preprocessed. \
342: \
343: {\f1\fs24 {\i file}.m} Objective-C source code. Note that you must link with the
344: library `{\f1\fs24 libobjc.a}' to make an Objective-C program work. \
345: \
346: {\f1\fs24 {\i file}.h} C header file
347: (not to be compiled or linked). \
348: \
349: {\f1\fs24 {\i file}.cc} \
350: {\f1\fs24 {\i file}.cxx} \
351: {\f1\fs24 {\i file}.C} C++ source code which
352: must be preprocessed. Note that in {\f4\fs24 .cxx}, the last two letters must both be
353: literally {\f4\fs24 x}. Likewise, {\f4\fs24 .C} refers to a literal capital C. \
354: \
355: {\f1\fs24 {\i file}.s} Assembler
356: code. \
357: \
358: {\f1\fs24 {\i file}.S} Assembler code which must be preprocessed. \
359: \
360: {\f1\fs24 {\i other}} An object file
361: to be fed straight into linking. Any file name with no recognized suffix is
362: treated this way. \
363: \
364: You can specify the input language explicitly with the {\f4\fs24 -x}
365: option: \
366: \
367: {\f1\fs24 -x {\i language}} Specify explicitly the {\i language} for the following input
368: files (rather than letting the compiler choose a default based on the file
369: name suffix). This option applies to all following input files until the next {\f4\fs24
370: -x} option. Possible values for {\i language} are: {\f1\fs24 c objective-c c++ }\
371: {\f1\fs24
372: c-header cpp-output c++-cpp-output }\
373: {\f1\fs24 assembler assembler-with-cpp }\
374: \
375: \
376: {\f1\fs24 -x none}
377: Turn off any specification of a language, so that subsequent files are handled
378: according to their file name suffixes (as they are if {\f4\fs24 -x} has not been used at
379: all). \
380: \
381: If you only want some of the stages of compilation, you can use {\f4\fs24 -x} (or
382: filename suffixes) to tell {\f1\fs24 gcc} where to start, and one of the options {\f4\fs24 -c}, {\f4\fs24 -S},
383: or {\f4\fs24 -E} to say where {\f1\fs24 gcc} is to stop. Note that some combinations (for example, {\f4\fs24
384: -x cpp-output -E} instruct {\f1\fs24 gcc} to do nothing at all. \
385: \
386: {\f1\fs24 -c} Compile or assemble the
387: source files, but do not link. The linking stage simply is not done. The
388: ultimate output is in the form of an object file for each source file. \
389: By
390: default, the object file name for a source file is made by replacing the
391: suffix {\f4\fs24 .c}, {\f4\fs24 .i}, {\f4\fs24 .s}, etc., with {\f4\fs24 .o}. \
392: Unrecognized input files, not requiring
393: compilation or assembly, are ignored. \
394: \
395: {\f1\fs24 -S} Stop after the stage of compilation
396: proper; do not assemble. The output is in the form of an assembler code file
397: for each non-assembler input file specified. \
398: By default, the assembler file
399: name for a source file is made by replacing the suffix {\f4\fs24 .c}, {\f4\fs24 .i}, etc., with {\f4\fs24 .s}. \
400:
401: Input files that don't require compilation are ignored. \
402: \
403: {\f1\fs24 -E} Stop after the
404: preprocessing stage; do not run the compiler proper. The output is in the form
405: of preprocessed source code, which is sent to the standard output. \
406: Input files
407: which don't require preprocessing are ignored. \
408: \
409: {\f1\fs24 -o {\i file}} Place output in file {\i
410: file}. This applies regardless to whatever sort of output is being produced,
411: whether it be an executable file, an object file, an assembler file or
412: preprocessed C code. \
413: Since only one output file can be specified, it does not
414: make sense to use {\f4\fs24 -o} when compiling more than one input file, unless you are
415: producing an executable file as output. \
416: If {\f4\fs24 -o} is not specified, the default is
417: to put an executable file in `{\f1\fs24 a.out}', the object file for `{\f1\fs24 {\i source}.{\i suffix}}' in `{\f1\fs24 {\i
418: source}.o}', its assembler file in `{\f1\fs24 {\i source}.s}', and all preprocessed C source on
419: standard output. \
420: \
421: {\f1\fs24 -v} Print (on standard error output) the commands executed to
422: run the stages of compilation. Also print the version number of the compiler
423: driver program and of the preprocessor and the compiler proper. \
424: \
425: {\f1\fs24 -pipe} Use
426: pipes rather than temporary files for communication between the various stages
427: of compilation. This fails to work on some systems where the assembler is
428: unable to read from a pipe; but the GNU assembler has no trouble. \
429: \
430: {{\NeXTHelpMarker \markername Invoking G++;}
431: ,}{\b\fs48\f4 1.3 Compiling
432: C++ Programs}\
433: \
434: C++ source files conventionally use one of the suffixes {\f4\fs24 .C}, {\f4\fs24 .cc},
435: or {\f4\fs24 .cxx}; preprocessed C++ files use the suffix {\f4\fs24 .ii}. GNU CC recognizes files
436: with these names and compiles them as C++ programs even if you call the
437: compiler the same way as for compiling C programs (usually with the name {\f1\fs24 gcc}). \
438:
439: However, C++ programs often require class libraries as well as a compiler that
440: understands the C++ language---and under some circumstances, you might want to
441: compile programs from standard input, or otherwise without a suffix that flags
442: them as C++ programs. {\f1\fs24 g++} is a shell script that calls GNU CC with the default
443: language set to C++, and automatically specifies linking against the GNU class
444: library libg++. {\fs18 Prior to release 2 of the compiler, there was a separate {\f1\fs24 g++}
445: compiler. That version was based on GNU CC, but not integrated with it.
446: Versions of {\f1\fs24 g++} with a {\f4\fs24 1.{\i xx}} version number---for example, {\f1\fs24 g++} version 1.37 or
447: 1.42---are much less reliable than the versions integrated with GCC 2.
448: Moreover, combining G++ {\f4\fs24 1.{\i xx}} with a version 2 GCC will simply not work.} On
449: many systems, the script {\f1\fs24 g++} is also installed with the name {\f1\fs24 c++}. \
450: When you
451: compile C++ programs, you may specify many of the same command-line options
452: that you use for compiling programs in any language; or command-line options
453: meaningful for C and related languages; or options that are meaningful only
454: for C++ programs. {See `Options Controlling C Dialect' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {C Dialect Options;}
455: ,}., for explanations of options for languages related to C. {See `Options Controlling C++ Dialect' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {C++ Dialect Options;}
456: ,}.,
457: for explanations of options that are meaningful only for C++ programs. \
458: {{\NeXTHelpMarker \markername C Dialect Options;}
459: ,}{\b\fs48\f4 1.4 Options
460: Controlling C Dialect}\
461: \
462: The following options control the dialect of C (or
463: languages derived from C, such as C++ and Objective C) that the compiler
464: accepts: \
465: \
466: {\f1\fs24 -ansi} Support all ANSI standard C programs. \
467: This turns off certain
468: features of GNU C that are incompatible with ANSI C, such as the {\f1\fs24 asm}, {\f1\fs24 inline}
469: and {\f1\fs24 typeof} keywords, and predefined macros such as {\f1\fs24 unix} and {\f1\fs24 vax} that identify
470: the type of system you are using. It also enables the undesirable and rarely
471: used ANSI trigraph feature, and disallows {\f4\fs24 $} as part of identifiers. \
472: The
473: alternate keywords {\f1\fs24 __asm__}, {\f1\fs24 __extension__}, {\f1\fs24 __inline__} and {\f1\fs24 __typeof__} continue
474: to work despite {\f4\fs24 -ansi}. You would not want to use them in an ANSI C program, of
475: course, but it useful to put them in header files that might be included in
476: compilations done with {\f4\fs24 -ansi}. Alternate predefined macros such as {\f1\fs24 __unix__} and {\f1\fs24
477: __vax__} are also available, with or without {\f4\fs24 -ansi}. \
478: The {\f4\fs24 -ansi} option does not
479: cause non-ANSI programs to be rejected gratuitously. For that, {\f4\fs24 -pedantic} is
480: required in addition to {\f4\fs24 -ansi}. {See `' {\NeXTHelpLink \markername ;\linkFilename .
481: is required in
482: h or
483: d
484: g++} compiler. That version was based on GNU
485: CC;\linkMarkername {Warning Options;}
486: ,}.. \
487: The macro {\f1\fs24 __STRICT_ANSI__} is predefined when
488: the {\f4\fs24 -ansi} option is used. Some header files may notice this macro and refrain
489: from declaring certain functions or defining certain macros that the ANSI
490: standard doesn't call for; this is to avoid interfering with any programs that
491: might use these names for other things. \
492: The functions {\f1\fs24 alloca}, {\f1\fs24 abort}, {\f1\fs24 exit}, and {\f1\fs24
493: _exit} are not builtin functions when {\f4\fs24 -ansi} is used. \
494: \
495: {\f1\fs24 -fno-asm} Do not recognize {\f1\fs24
496: asm}, {\f1\fs24 inline} or {\f1\fs24 typeof} as a keyword. These words may then be used as
497: identifiers. You can use the keywords {\f1\fs24 __asm__}, {\f1\fs24 __inline__} and {\f1\fs24 __typeof__}
498: instead. {\f4\fs24 -ansi} implies {\f4\fs24 -fno-asm}. \
499: \
500: {\f1\fs24 -fno-builtin} Don't recognize builtin
501: functions that do not begin with two leading underscores. Currently, the
502: functions affected include {\f1\fs24 abort}, {\f1\fs24 abs}, {\f1\fs24 alloca}, {\f1\fs24 cos}, {\f1\fs24 exit}, {\f1\fs24 fabs}, {\f1\fs24 ffs}, {\f1\fs24 labs}, {\f1\fs24
503: memcmp}, {\f1\fs24 memcpy}, {\f1\fs24 sin}, {\f1\fs24 sqrt}, {\f1\fs24 strcmp}, {\f1\fs24 strcpy}, and {\f1\fs24 strlen}. \
504: GCC normally generates
505: special code to handle certain builtin functions more efficiently; for
506: instance, calls to {\f1\fs24 alloca} may become single instructions that adjust the stack
507: directly, and calls to {\f1\fs24 memcpy} may become inline copy loops. The resulting code
508: is often both smaller and faster, but since the function calls no longer
509: appear as such, you cannot set a breakpoint on those calls, nor can you change
510: the behavior of the functions by linking with a different library. \
511: The {\f4\fs24 -ansi}
512: option prevents {\f1\fs24 alloca} and {\f1\fs24 ffs} from being builtin functions, since these
513: functions do not have an ANSI standard meaning. \
514: \
515: {\f1\fs24 -trigraphs} Support ANSI C
516: trigraphs. You don't want to know about this brain-damage. The {\f4\fs24 -ansi} option
517: implies {\f4\fs24 -trigraphs}. \
518: \
519: {\f1\fs24 -traditional} Attempt to support some aspects of
520: traditional C compilers. Specifically: \
521: All {\f1\fs24 extern} declarations take effect
522: globally even if they are written inside of a function definition. This
523: includes implicit declarations of functions. \
524: The newer keywords {\f1\fs24 typeof}, {\f1\fs24 inline}
525: , {\f1\fs24 signed}, {\f1\fs24 const} and {\f1\fs24 volatile} are not recognized. (You can still use the
526: alternative keywords such as {\f1\fs24 __typeof__}, {\f1\fs24 __inline__}, and so on.) \
527: Comparisons
528: between pointers and integers are always allowed. \
529: Integer types {\f1\fs24 unsigned short}
530: and {\f1\fs24 unsigned char} promote to {\f1\fs24 unsigned int}. \
531: Out-of-range floating point
532: literals are not an error. \
533: Certain constructs which ANSI regards as a single
534: invalid preprocessing number, such as {\f4\fs24 0xe-0xd}, are treated as expressions
535: instead. \
536: String ``constants'' are not necessarily constant; they are stored in
537: writable space, and identical looking constants are allocated separately.
538: (This is the same as the effect of {\f4\fs24 -fwritable-strings}.) \
539: All automatic
540: variables not declared {\f1\fs24 register} are preserved by {\f1\fs24 longjmp}. Ordinarily, GNU C
541: follows ANSI C: automatic variables not declared {\f1\fs24 volatile} may be clobbered. \
542: In
543: the preprocessor, comments convert to nothing at all, rather than to a space.
544: This allows traditional token concatenation. \
545: In the preprocessor, macro
546: arguments are recognized within string constants in a macro definition (and
547: their values are stringified, though without additional quote marks, when they
548: appear in such a context). The preprocessor always considers a string constant
549: to end at a newline. \
550: The predefined macro {\f1\fs24 __STDC__} is not defined when you use {\f4\fs24
551: -traditional}, but {\f1\fs24 __GNUC__} is (since the GNU extensions which {\f1\fs24 __GNUC__}
552: indicates are not affected by {\f4\fs24 -traditional}). If you need to write header files
553: that work differently depending on whether {\f4\fs24 -traditional} is in use, by testing
554: both of these predefined macros you can distinguish four situations: GNU C,
555: traditional GNU C, other ANSI C compilers, and other old C compilers. {See `Standard Predefined
556: Macros,cpp.info,The C Preprocessor' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Standard Predefined;}
557: ,}., for
558: more discussion of these and other predefined macros. \
559: The preprocessor
560: considers a string constant to end at a newline (unless the newline is escaped
561: with {\f4\fs24 \\}). (Without {\f4\fs24 -traditional}, string constants can contain the newline
562: character as typed.) \
563: The character escape sequences {\f4\fs24 \\x} and {\f4\fs24 \\a} evaluate as
564: the literal characters {\f4\fs24 x} and {\f4\fs24 a} respectively. Without {\f4\fs24 -traditional}, {\f4\fs24 \\x} is a
565: prefix for the hexadecimal representation of a character, and {\f4\fs24 \\a} produces a
566: bell. \
567: In C++ programs, assignment to {\f1\fs24 this} is permitted with {\f4\fs24 -traditional}. (The
568: option {\f4\fs24 -fthis-is-variable} also has this effect.) \
569: \
570: You may wish to use {\f4\fs24
571: -fno-builtin} as well as {\f4\fs24 -traditional} if your program uses names that are
572: normally GNU C builtin functions for other purposes of its own. \
573: \
574: {\f1\fs24
575: -traditional-cpp} Attempt to support some aspects of traditional C
576: preprocessors. This includes the last three items in the table immediately
577: above, but none of the other effects of {\f4\fs24 -traditional}. \
578: \
579: {\f1\fs24 -fcond-mismatch} Allow
580: conditional expressions with mismatched types in the second and third
581: arguments. The value of such an expression is void. \
582: \
583: {\f1\fs24 -funsigned-char} Let the
584: type {\f1\fs24 char} be unsigned, like {\f1\fs24 unsigned char}. \
585: Each kind of machine has a default
586: for what {\f1\fs24 char} should be. It is either like {\f1\fs24 unsigned char} by default or like {\f1\fs24
587: signed char} by default. \
588: Ideally, a portable program should always use {\f1\fs24 signed
589: char} or {\f1\fs24 unsigned char} when it depends on the signedness of an object. But many
590: programs have been written to use plain {\f1\fs24 char} and expect it to be signed, or
591: expect it to be unsigned, depending on the machines they were written for.
592: This option, and its inverse, let you make such a program work with the
593: opposite default. \
594: The type {\f1\fs24 char} is always a distinct type from each of {\f1\fs24 signed
595: char} or {\f1\fs24 unsigned char}, even though its behavior is always just like one of
596: those two. \
597: \
598: {\f1\fs24 -fsigned-char} Let the type {\f1\fs24 char} be signed, like {\f1\fs24 signed char}. \
599: Note
600: that this is equivalent to {\f4\fs24 -fno-unsigned-char}, which is the negative form of {\f4\fs24
601: -funsigned-char}. Likewise, the option {\f4\fs24 -fno-signed-char} is equivalent to {\f4\fs24
602: -funsigned-char}. \
603: \
604: {\f1\fs24 -fsigned-bitfields} \
605: {\f1\fs24 -funsigned-bitfields} \
606: {\f1\fs24 -fno-signed-bitfields} \
607: {\f1\fs24
608: -fno-unsigned-bitfields} These options control whether a bitfield is signed or
609: unsigned, when the declaration does not use either {\f1\fs24 signed} or {\f1\fs24 unsigned}. By
610: default, such a bitfield is signed, because this is consistent: the basic
611: integer types such as {\f1\fs24 int} are signed types. \
612: However, when {\f4\fs24 -traditional} is
613: used, bitfields are all unsigned no matter what. \
614: \
615: {\f1\fs24 -fwritable-strings} Store
616: string constants in the writable data segment and don't uniquize them. This is
617: for compatibility with old programs which assume they can write into string
618: constants. The option {\f4\fs24 -traditional} also has this effect. \
619: Writing into string
620: constants is a very bad idea; ``constants'' should be constant. \
621: \
622: {\f1\fs24
623: -fallow-single-precision} Do not promote single precision math operations to
624: double precision, even when compiling with {\f4\fs24 -traditional}. \
625: Traditional K&R C
626: promotes all floating point operations to double precision, regardless of the
627: sizes of the operands. On the architecture for which you are compiling, single
628: precision may be faster than double precision. If you must use {\f4\fs24 -traditional},
629: but want to use single precision operations when the operands are single
630: precision, use this option. This option has no effect when compiling with ANSI
631: or GNU C conventions (the default). \
632: \
633: \
634: {{\NeXTHelpMarker \markername C++ Dialect Options;}
635: ,}{\b\fs48\f4 1.5 Options Controlling C++ Dialect}\
636: \
637: This
638: section describes the command-line options that are only meaningful for C++
639: programs; but you can also use most of the GNU compiler options regardless of
640: what language your program is in. For example, you might compile a file {\f1\fs24
641: firstClass.C} like this: \
642: {\f1\fs24 g++ -g -felide-constructors -O -c firstClass.C }\
643: \
644: In
645: this example, only {\f4\fs24 -felide-constructors} is an option meant only for C++
646: programs; you can use the other options with any language supported by GNU CC. \
647:
648: Here is a list of options that are {\i only} for compiling C++ programs: \
649: \
650: {\f1\fs24
651: -fall-virtual} Treat all possible member functions as virtual, implicitly. All
652: member functions (except for constructor functions and {\f1\fs24 new} or {\f1\fs24 delete} member
653: operators) are treated as virtual functions of the class where they appear. \
654:
655: This does not mean that all calls to these member functions will be made
656: through the internal table of virtual functions. Under some circumstances, the
657: compiler can determine that a call to a given virtual function can be made
658: directly; in these cases the calls are direct in any case. \
659: \
660: {\f1\fs24
661: -fdollars-in-identifiers} Accept {\f4\fs24 $} in identifiers. You can also explicitly
662: prohibit use of {\f4\fs24 $} with the option {\f4\fs24 -fno-dollars-in-identifiers}. (GNU C++ allows {\f4\fs24
663: $} by default on some target systems but not others.) Traditional C allowed the
664: character {\f4\fs24 $} to form part of identifiers. However, ANSI C and C++ forbid {\f4\fs24 $} in
665: identifiers. \
666: \
667: {\f1\fs24 -felide-constructors} Elide constructors when this seems
668: plausible. With this option, GNU C++ initializes {\f1\fs24 y} directly from the call to {\f1\fs24
669: foo} without going through a temporary in the following code: \
670: {\f1\fs24 A foo (); }\
671: {\f1\fs24
672: A y = foo (); }\
673: \
674: Without this option, GNU C++ (1) initializes {\f1\fs24 y} by calling the
675: appropriate constructor for type {\f1\fs24 A}; (2) assigns the result of {\f1\fs24 foo} to a
676: temporary; and, finally, (3) replaces the initial value of {\f1\fs24 y} with the
677: temporary. \
678: The default behavior ({\f4\fs24 -fno-elide-constructors}) is specified by the
679: draft ANSI C++ standard. If your program's constructors have side effects, {\f4\fs24
680: -felide-constructors} can change your program's behavior, since some
681: constructor calls may be omitted. \
682: \
683: {\f1\fs24 -fenum-int-equiv} Permit implicit conversion
684: of {\f1\fs24 int} to enumeration types. Normally GNU C++ allows conversion of {\f1\fs24 enum} to {\f1\fs24 int}
685: , but not the other way around. \
686: \
687: {\f1\fs24 -fexternal-templates} Produce smaller code for
688: template declarations, by generating only a single copy of each template
689: function where it is defined. To use this option successfully, you must also
690: mark all files that use templates with either {\f4\fs24 #pragma implementation} (the
691: definition) or {\f4\fs24 #pragma interface} (declarations). {See `Declarations and Definitions in One Header' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {C++
692: Interface;}
693: ,}., for more discussion of
694: these pragmas. \
695: When your code is compiled with {\f4\fs24 -fexternal-templates}, all
696: template instantiations are external. You must arrange for all necessary
697: instantiations to appear in the implementation file; you can do this with a {\f1\fs24
698: typedef} that references each instantiation needed. Conversely, when you
699: compile using the default option {\f4\fs24 -fno-external-templates}, all template
700: instantiations are explicitly internal. \
701: You do not need to specify {\f4\fs24
702: -fexternal-templates} when compiling a file that does not define and
703: instantiate templates used in other files, even if your file {\i uses} templates
704: defined in other files that are compiled with {\f4\fs24 -fexternal-templates}. The only
705: side effect is an increase in object size for each file that you compile
706: without {\f4\fs24 -fexternal-templates}. \
707: \
708: {\f1\fs24 -fmemoize-lookups} \
709: {\f1\fs24 -fsave-memoized} Use heuristics
710: to compile faster. These heuristics are not enabled by default, since they are
711: only effective for certain input files. Other input files compile more slowly. \
712:
713: The first time the compiler must build a call to a member function (or
714: reference to a data member), it must (1) determine whether the class
715: implements member functions of that name; (2) resolve which member function to
716: call (which involves figuring out what sorts of type conversions need to be
717: made); and (3) check the visibility of the member function to the caller. All
718: of this adds up to slower compilation. Normally, the second time a call is
719: made to that member function (or reference to that data member), it must go
720: through the same lengthy process again. This means that code like this: \
721: {\f1\fs24
722: cout << "This " << p << " has " << n << " legs.\\n"; }\
723: \
724: makes six passes through
725: all three steps. By using a software cache, a ``hit'' significantly reduces
726: this cost. Unfortunately, using the cache introduces another layer of
727: mechanisms which must be implemented, and so incurs its own overhead. {\f4\fs24
728: -fmemoize-lookups} enables the software cache. \
729: Because access privileges
730: (visibility) to members and member functions may differ from one function
731: context to the next, G++ may need to flush the cache. With the {\f4\fs24
732: -fmemoize-lookups} flag, the cache is flushed after every function that is
733: compiled. The {\f4\fs24 -fsave-memoized} flag enables the same software cache, but when
734: the compiler determines that the context of the last function compiled would
735: yield the same access privileges of the next function to compile, it preserves
736: the cache. This is most helpful when defining many member functions for the
737: same class: with the exception of member functions which are friends of other
738: classes, each member function has exactly the same access privileges as every
739: other, and the cache need not be flushed. \
740: \
741: {\f1\fs24 -fno-strict-prototype} Treat a
742: function declaration with no arguments, such as {\f4\fs24 int foo ();}, as C would treat
743: it---as saying nothing about the number of arguments or their types. Normally,
744: such a declaration in C++ means that the function {\f1\fs24 foo} takes no arguments. \
745: \
746: {\f1\fs24
747: -fnonnull-objects} Assume that objects reached through references are not null. \
748:
749: Normally, GNU C++ makes conservative assumptions about objects reached through
750: references. For example, the compiler must check that {\f1\fs24 a} is not null in code
751: like the following: \
752: {\f1\fs24 obj &a = g (); }\
753: {\f1\fs24 a.f (2); }\
754: \
755: Checking that references of this
756: sort have non-null values requires extra code, however, and it is unnecessary
757: for many programs. You can use {\f4\fs24 -fnonnull-objects} to omit the checks for null,
758: if your program doesn't require checking. \
759: \
760: {\f1\fs24 -fthis-is-variable} Permit assignment
761: to {\f1\fs24 this}. The incorporation of user-defined free store management into C++ has
762: made assignment to {\f4\fs24 this} an anachronism. Therefore, by default it is invalid to
763: assign to {\f1\fs24 this} within a class member function; that is, GNU C++ treats the
764: type of {\f4\fs24 this} in a member function of class {\f1\fs24 X} to be {\f4\fs24 X *const}. However, for
765: backwards compatibility, you can make it valid with {\f4\fs24 -fthis-is-variable}. \
766: \
767: {\f1\fs24
768: -nostdinc++} Do not search for header files in the standard directories
769: specific to C++, but do still search the other standard directories. (This
770: option is used when building libg++.) \
771: \
772: {\f1\fs24 -traditional} For C++ programs (in
773: addition to the effects that apply to both C and C++), this has the same
774: effect as {\f4\fs24 -fthis-is-variable}. {See ` Options Controlling C Dialect' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {C Dialect Options;}
775: ,}.. \
776: \
777: In addition, these optimization, warning, and
778: code generation options have meanings only for C++ programs: \
779: \
780: {\f1\fs24
781: -fno-default-inline} Do not assume {\f4\fs24 inline} for functions defined inside a class
782: scope. {See `Options That Control Optimization' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Optimize Options;}
783: ,}.. \
784: \
785: {\f1\fs24 -Wenum-clash} \
786: {\f1\fs24 -Woverloaded-virtual} \
787: {\f1\fs24 -Wtemplate-debugging} Warnings that
788: apply only to C++ programs. {See `Options to Request or Suppress Warnings' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Warning
789: Options;}
790: ,}.. \
791: \
792: {\f1\fs24 +e{\i n}} Control how virtual function definitions are
793: used, in a fashion compatible with {\f1\fs24 cfront} 1.x. {See `Options for
794: Code Generation Conventions' {\NeXTHelpLink \markername ;\linkFilename /build/cc_proj/cc/cc/invoke.rtf;\linkMarkername {Code Gen Options;}
795: ,}.. \
796: \
797: {{\NeXTHelpMarker \markername Warning Options;}
798: ,}{\b\fs48\f4 1.6 Options to Request or
799: Suppress Warnings}\
800: \
801: Warnings are diagnostic messages that report constructions
802: which are not inherently erroneous but which are risky or suggest there may
803: have been an error. \
804: You can request many specific warnings with options
805: beginning {\f4\fs24 -W}, for example {\f4\fs24 -Wimplicit} to request warnings on implicit
806: declarations. Each of these specific warning options also has a negative form
807: beginning {\f4\fs24 -Wno-} to turn off warnings; for example, {\f4\fs24 -Wno-implicit}. This manual
808: lists only one of the two forms, whichever is not the default. \
809: These options
810: control the amount and kinds of warnings produced by GNU CC: \
811: \
812: {\f1\fs24 -fsyntax-only}
813: Check the code for syntax errors, but don't do anything beyond that. \
814: \
815: {\f1\fs24 -w}
816: Inhibit all warning messages. \
817: \
818: {\f1\fs24 -Wno-import} Inhibit warning messages about the
819: use of {\f4\fs24 #import}. \
820: \
821: {\f1\fs24 -pedantic} Issue all the warnings demanded by strict ANSI
822: standard C; reject all programs that use forbidden extensions. \
823: Valid ANSI
824: standard C programs should compile properly with or without this option
825: (though a rare few will require {\f4\fs24 -ansi}). However, without this option, certain
826: GNU extensions and traditional C features are supported as well. With this
827: option, they are rejected. \
828: {\f4\fs24 -pedantic} does not cause warning messages for use
829: of the alternate keywords whose names begin and end with {\f4\fs24 __}. Pedantic warnings
830: are also disabled in the expression that follows {\f1\fs24 __extension__}. However, only
831: system header files should use these escape routes; application programs
832: should avoid them. {See `' {\NeXTHelpLink \markername ;\linkFilename .
833: ation programs should avoid them.
834: ld use
835: ic
836: ;\linkMarkername {Alternate Keywords;}
837: ,}.. \
838: This option is not intended to be ; it exists only to
839: satisfy \
840: \
841: \
842: \
843: \
844: \
845: \
846: \
847: \
848: \
849: \
850: \
851: \
852: \
853: \
854: \
855: \
856: \
857: \
858: \
859: \
860: \
861: \
862: \
863: \
864: \
865: \
866: \
867: \
868: \
869: \
870: \
871: \
872: \
873: \
874: \
875: \
876: \
877: \
878: \
879: \
880: \
881: \
882: \
883: \
884: \
885: \
886: \
887: \
888: \
889: \
890: \
891: \
892: \
893: \
894: \
895: \
896: \
897: \
898: \
899: \
900: \
901: \
902: \
903: \
904: \
905: \
906: \
907: \
908: \
909: \
910: \
911: \
912: \
913: \
914: \
915: \
916: \
917: \
918: \
919: \
920: \
921: \
922: \
923: \
924: \
925: \
926: \
927: \
928: \
929: \
930: \
931: \
932: \
933: \
934: \
935: \
936: \
937: \
938: \
939: \
940: \
941: \
942: \
943: \
944: \
945: \
946: \
947: \
948: \
949: \
950: \
951: \
952: \
953: \
954: \
955: \
956: \
957: \
958: \
959: \
960: \
961: \
962: \
963: \
964: \
965: \
966: \
967: \
968: \
969: \
970: \
971: \
972: \
973: \
974: \
975: \
976: \
977: \
978: \
979: \
980: \
981: \
982: \
983: \
984: \
985: \
986: \
987: \
988: \
989: \
990: \
991: \
992: \
993: \
994: \
995: \
996: \
997: \
998: \
999: \
1000: \
1001: \
1002: \
1003: \
1004: \
1005: \
1006: \
1007: \
1008: \
1009: \
1010: \
1011: \
1012: \
1013: \
1014: \
1015: \
1016: \
1017: \
1018: \
1019: \
1020: \
1021: \
1022: \
1023: \
1024: \
1025: \
1026: \
1027: \
1028: \
1029: \
1030: \
1031: \
1032: \
1033: \
1034: \
1035: \
1036: \
1037: \
1038: \
1039: \
1040: \
1041: \
1042: \
1043: \
1044: \
1045: \
1046: \
1047: \
1048: \
1049: \
1050: \
1051: \
1052: \
1053: \
1054: \
1055: \
1056: \
1057: \
1058: \
1059: \
1060: {{\NeXTHelpMarker \markername M680x0 Options;}
1061: ,}{\b\fs32\f4 M680x0 Options}\
1062: \
1063: These are the {\f4\fs24 -m} options defined for the 68000 series.
1064: The default values for these options depends on which style of 68000 was
1065: selected when the compiler was configured; the defaults for the most common
1066: choices are given below. \
1067: \
1068: {\f1\fs24 -m68000} \
1069: {\f1\fs24 -mc68000} Generate output for a 68000. This is
1070: the default when the compiler is configured for 68000-based systems. \
1071: \
1072: {\f1\fs24 -m68020} \
1073: {\f1\fs24
1074: -mc68020} Generate output for a 68020. This is the default when the compiler is
1075: configured for 68020-based systems. \
1076: \
1077: {\f1\fs24 -m68881} Generate output containing 68881
1078: instructions for floating point. This is the default for most 68020 systems
1079: unless {\f4\fs24 -nfp} was specified when the compiler was configured. \
1080: \
1081: {\f1\fs24 -m68030} Generate
1082: output for a 68030. This is the default when the compiler is configured for
1083: 68030-based systems. \
1084: \
1085: {\f1\fs24 -m68040} Generate output for a 68040. This is the default
1086: when the compiler is configured for 68040-based systems. \
1087: This option inhibits
1088: the use of 68881/68882 instructions that have to be emulated by software on
1089: the 68040. If your 68040 does not have code to emulate those instructions, use {\f4\fs24
1090: -m68040}. \
1091: \
1092: {\f1\fs24 -m68020-40} Generate output for a 68040, without using any of the new
1093: instructions. This results in code which can run relatively efficiently on
1094: either a 68020/68881 or a 68030 or a 68040. The generated code does use the
1095: 68881 instructions that are emulated on the 68040. \
1096: \
1097: {\f1\fs24 -mfpa} Generate output
1098: containing Sun FPA instructions for floating point. \
1099: \
1100: {\f1\fs24 -msoft-float} Generate
1101: output containing library calls for floating point. {\b Warning:} the requisite
1102: libraries are not part of GNU CC. Normally the facilities of the machine's
1103: usual C compiler are used, but this can't be done directly in
1104: cross-compilation. You must make your own arrangements to provide suitable
1105: library functions for cross-compilation. \
1106: \
1107: {\f1\fs24 -mshort} Consider type {\f1\fs24 int} to be 16
1108: bits wide, like {\f1\fs24 short int}. \
1109: \
1110: {\f1\fs24 -mnobitfield} Do not use the bit-field instructions.
1111: The {\f4\fs24 -m68000} option implies {\f4\fs24 -mnobitfield}. \
1112: \
1113: {\f1\fs24 -mbitfield} Do use the bit-field
1114: instructions. The {\f4\fs24 -m68020} option implies {\f4\fs24 -mbitfield}. This is the default if
1115: you use a configuration designed for a 68020. \
1116: \
1117: {\f1\fs24 -mrtd} Use a different
1118: function-calling convention, in which functions that take a fixed number of
1119: arguments return with the {\f1\fs24 rtd} instruction, which pops their arguments while
1120: returning. This saves one instruction in the caller since there is no need to
1121: pop the arguments there. \
1122: This calling convention is incompatible with the one
1123: normally used on Unix, so you cannot use it if you need to call libraries
1124: compiled with the Unix compiler. \
1125: Also, you must provide function prototypes
1126: for all functions that take variable numbers of arguments (including {\f1\fs24 printf});
1127: otherwise incorrect code will be generated for calls to those functions. \
1128: In
1129: addition, seriously incorrect code will result if you call a function with too
1130: many arguments. (Normally, extra arguments are harmlessly ignored.) \
1131: The {\f1\fs24 rtd}
1132: instruction is supported by the 68010 and 68020 processors, but not by the
1133: 68000. \
1134: \
1135: {{\NeXTHelpMarker \markername VAX Options;}
1136: ,}{\b\fs32\f4 VAX Options}\
1137: \
1138: These {\f4\fs24 -m} options are defined for the Vax: \
1139: \
1140: {\f1\fs24 -munix} Do not
1141: output certain jump instructions ({\f1\fs24 aobleq} and so on) that the Unix assembler
1142: for the Vax cannot handle across long ranges. \
1143: \
1144: {\f1\fs24 -mgnu} Do output those jump
1145: instructions, on the assumption that you will assemble with the GNU assembler. \
1146: \
1147: {\f1\fs24
1148: -mg} Output code for g-format floating point numbers instead of d-format. \
1149: \
1150: {{\NeXTHelpMarker \markername SPARC Options;}
1151: ,}{\b\fs32\f4 SPARC
1152: Options}\
1153: \
1154: These {\f4\fs24 -m} switches are supported on the SPARC: \
1155: \
1156: {\f1\fs24 -mfpu} \
1157: {\f1\fs24 -mhard-float}
1158: Generate output containing floating point instructions. This is the default. \
1159: \
1160: {\f1\fs24
1161: -mno-fpu} \
1162: {\f1\fs24 -msoft-float} Generate output containing library calls for floating
1163: point. {\b Warning:} there is no GNU floating-point library for SPARC. Normally the
1164: facilities of the machine's usual C compiler are used, but this cannot be done
1165: directly in cross-compilation. You must make your own arrangements to provide
1166: suitable library functions for cross-compilation. \
1167: {\f4\fs24 -msoft-float} changes the
1168: calling convention in the output file; therefore, it is only useful if you
1169: compile {\i all} of a program with this option. In particular, you need to compile `{\f1\fs24
1170: libgcc.a}', the library that comes with GNU CC, with {\f4\fs24 -msoft-float} in order for
1171: this to work. \
1172: \
1173: \
1174: \
1175: \
1176: \
1177: \
1178: \
1179: \
1180: \
1181: \
1182: \
1183: \
1184: \
1185: \
1186: \
1187: \
1188: \
1189: \
1190: \
1191: \
1192: \
1193: \
1194: \
1195: \
1196: \
1197: \
1198: \
1199: \
1200: \
1201: \
1202: \
1203: \
1204: \
1205: \
1206: \
1207: \
1208: \
1209: \
1210: \
1211: \
1212: \
1213: \
1214: \
1215: \
1216: \
1217: \
1218: \
1219: \
1220: \
1221: \
1222: \
1223: \
1224: \
1225: \
1226: \
1227: \
1228: \
1229: \
1230: \
1231: \
1232: \
1233: \
1234: \
1235: \
1236: \
1237: \
1238: \
1239: \
1240: \
1241: \
1242: \
1243: \
1244: \
1245: \
1246: \
1247: \
1248: \
1249: \
1250: \
1251: \
1252: \
1253: \
1254: \
1255: \
1256: \
1257: \
1258: \
1259: \
1260: \
1261: \
1262: \
1263: \
1264: \
1265: \
1266: \
1267: \
1268: \
1269: \
1270: \
1271: \
1272: \
1273: \
1274: \
1275: \
1276: \
1277: \
1278: \
1279: \
1280: \
1281: \
1282: \
1283: \
1284: \
1285: \
1286: \
1287: \
1288: \
1289: \
1290: \
1291: \
1292: \
1293: \
1294: \
1295: \
1296: \
1297: \
1298: \
1299: \
1300: \
1301: \
1302: \
1303: \
1304: \
1305: \
1306: \
1307: \
1308: \
1309: \
1310: \
1311: \
1312: \
1313: \
1314: \
1315: \
1316: \
1317: \
1318: \
1319: \
1320: \
1321: \
1322: \
1323: \
1324: \
1325: \
1326: \
1327: \
1328: \
1329: \
1330: \
1331: \
1332: \
1333: \
1334: \
1335: \
1336: \
1337: \
1338: \
1339: \
1340: \
1341: \
1342: \
1343: \
1344: \
1345: \
1346: \
1347: \
1348: \
1349: \
1350: \
1351: \
1352: \
1353: \
1354: \
1355: \
1356: \
1357: \
1358: \
1359: \
1360: \
1361: \
1362: \
1363: \
1364: \
1365: \
1366: \
1367: \
1368: \
1369: \
1370: \
1371: \
1372: \
1373: \
1374: \
1375: \
1376: \
1377: \
1378: \
1379: \
1380: \
1381: \
1382: \
1383: \
1384: \
1385: \
1386: \
1387: \
1388: \
1389: \
1390: \
1391: \
1392: \
1393: \
1394: \
1395: \
1396: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.