home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 4 / FreshFish_May-June1994.bin / bbs / gnu / gcc-2.5.8-bin.lha / man / cat1 / gcc.0 < prev   
Text File  |  1994-02-08  |  124KB  |  3,499 lines

  1.  
  2.  
  3.  
  4. GCC(1)                      GNU Tools                      GCC(1)
  5.  
  6.  
  7.  
  8. NAME
  9.      gcc, g++ - GNU project C and C++ Compiler (v2.4)
  10.  
  11. SYNOPSIS
  12.      gcc [ _o_p_t_i_o_n | _f_i_l_e_n_a_m_e ]...
  13.      g++ [ _o_p_t_i_o_n | _f_i_l_e_n_a_m_e ]...
  14.  
  15. WARNING
  16.      The information in this man page is an extract from the full
  17.      documentation  of  the GNU C compiler, and is limited to the
  18.      meaning of the options.
  19.  
  20.      This man page is not kept up to date except when  volunteers
  21.      want  to maintain it.  If you find a discrepancy between the
  22.      man page and the software, please check the Info file, which
  23.      is the authoritative documentation.
  24.  
  25.      If we find that the things in this man page that are out  of
  26.      date cause significant confusion or complaints, we will stop
  27.      distributing the man page.  The  alternative,  updating  the
  28.      man page when we update the Info file, is impossible because
  29.      the rest of the work of maintaining GNU CC leaves us no time
  30.      for that.  The GNU project regards man pages as obsolete and
  31.      should not let them take time away from other things.
  32.  
  33.      For complete and current documentation, refer  to  the  Info
  34.      file  `gcc' or the manual _U_s_i_n_g _a_n_d _P_o_r_t_i_n_g _G_N_U _C_C (_f_o_r _v_e_r_-
  35.      _s_i_o_n _2._0).  Both are  made  from  the  Texinfo  source  file
  36.      gcc.texinfo.
  37.  
  38. DESCRIPTION
  39.      The C and C++ compilers are integrated.  Both process  input
  40.      files  through  one  or  more of four stages: preprocessing,
  41.      compilation, assembly, and linking.   Source  filename  suf-
  42.      fixes  identify  the source language, but which name you use
  43.      for the compiler governs default assumptions:
  44.  
  45.      gcc  assumes preprocessed (.i) files are  C  and  assumes  C
  46.           style linking.
  47.  
  48.      g++  assumes preprocessed (.i) files are C++ and assumes C++
  49.           style linking.
  50.  
  51.      Suffixes of source file names indicate the language and kind
  52.      of processing to be done:
  53.  
  54.      .c    C source; preprocess, compile, assemble
  55.      .C    C++ source; preprocess, compile, assemble
  56.      .cc   C++ source; preprocess, compile, assemble
  57.      .cxx  C++ source; preprocess, compile, assemble
  58.      .m    Objective-C source; preprocess, compile, assemble
  59.      .i    preprocessed C; compile, assemble
  60.  
  61.  
  62.  
  63. GNU Tools            Last change: 1993/10/13                    1
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. GCC(1)                      GNU Tools                      GCC(1)
  71.  
  72.  
  73.  
  74.      .ii   preprocessed C++; compile, assemble
  75.      .s    Assembler source; assemble
  76.      .S    Assembler source; preprocess, assemble
  77.      .h    Preprocessor file; not usually named on command line
  78.  
  79.      Files with other suffixes are passed to the linker.   Common
  80.      cases include:
  81.  
  82.      .o    Object file
  83.      .a    Archive file
  84.  
  85.      Linking is always the last stage unless you use one  of  the
  86.      -c,  -S,  or  -E  options to avoid it (or unless compilation
  87.      errors stop the whole process).  For the link stage, all  .o
  88.      files  corresponding to source files, -l libraries, unrecog-
  89.      nized filenames (including named  .o  object  files  and  .a
  90.      archives) are passed to the linker in command-line order.
  91.  
  92. OPTIONS
  93.      Options must be separate: `-dr' is quite different from  `-d
  94.      -r '.
  95.  
  96.      Most `-f' and `-W' options have two contrary  forms:  -f_n_a_m_e
  97.      and  -fno-_n_a_m_e  (or  -W_n_a_m_e  and  -Wno-_n_a_m_e).  Only the non-
  98.      default forms are shown here.
  99.  
  100.      Here is a summary of  all  the  options,  grouped  by  type.
  101.      Explanations are in the following sections.
  102.  
  103.      Overall Options
  104.           -c -S -E -o _f_i_l_e -pipe -v -x _l_a_n_g_u_a_g_e
  105.  
  106.      Language Options
  107.           -ansi -fall-virtual -fcond-mismatch
  108.           -fdollars-in-identifiers -fenum-int-equiv
  109.           -fexternal-templates -fno-asm -fno-builtin
  110.           -fno-strict-prototype -fsigned-bitfields -fsigned-char
  111.           -fthis-is-variable -funsigned-bitfields -funsigned-char
  112.           -fwritable-strings -traditional -traditional-cpp
  113.           -trigraphs
  114.  
  115.      Warning Options
  116.           -fsyntax-only -pedantic -pedantic-errors -w -W -Wall
  117.           -Waggregate-return -Wcast-align -Wcast-qual
  118.           -Wchar-subscript -Wcomment -Wconversion -Wenum-clash
  119.           -Werror -Wformat -Wid-clash-_l_e_n -Wimplicit -Winline
  120.           -Wmissing-prototypes -Wnested-externs -Wno-import
  121.           -Wparentheses -Wpointer-arith -Wredundant-decls
  122.           -Wreturn-type -Wshadow -Wstrict-prototypes -Wswitch
  123.           -Wtemplate-debugging -Wtraditional -Wtrigraphs
  124.           -Wuninitialized -Wunused -Wwrite-strings
  125.  
  126.  
  127.  
  128.  
  129. GNU Tools            Last change: 1993/10/13                    2
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. GCC(1)                      GNU Tools                      GCC(1)
  137.  
  138.  
  139.  
  140.      Debugging Options
  141.           -a -d_l_e_t_t_e_r_s -fpretend-float -g -g_l_e_v_e_l -gcoff -gxcoff
  142.           -gxcoff+ -gdwarf -gdwarf+ -gstabs -gstabs+ -ggdb -p -pg
  143.           -save-temps -print-libgcc-file-name
  144.  
  145.      Optimization Options
  146.           -fcaller-saves -fcse-follow-jumps -fcse-skip-blocks
  147.           -fdelayed-branch -felide-constructors
  148.           -fexpensive-optimizations -ffast-math -ffloat-store
  149.           -fforce-addr -fforce-mem -finline-functions
  150.           -fkeep-inline-functions -fmemoize-lookups
  151.           -fno-default-inline -fno-defer-pop -fno-function-cse
  152.           -fno-inline -fno-peephole -fomit-frame-pointer
  153.           -frerun-cse-after-loop -fschedule-insns
  154.           -fschedule-insns2 -fstrength-reduce -fthread-jumps
  155.           -funroll-all-loops -funroll-loops -O -O2
  156.  
  157.      Preprocessor Options
  158.           -A_a_s_s_e_r_t_i_o_n -C -dD -dM -dN -D_m_a_c_r_o[=_d_e_f_n] -E -H
  159.           -idirafter _d_i_r -include _f_i_l_e -imacros _f_i_l_e -iprefix
  160.           _f_i_l_e -iwithprefix _d_i_r -M -MD -MM -MMD -nostdinc -P
  161.           -U_m_a_c_r_o -undef
  162.  
  163.      Assembler Option
  164.           -Wa,_o_p_t_i_o_n
  165.  
  166.      Linker Options
  167.           -l_l_i_b_r_a_r_y -nostartfiles -nostdlib -static -shared
  168.           -symbolic -Xlinker _o_p_t_i_o_n -Wl,_o_p_t_i_o_n -u _s_y_m_b_o_l
  169.  
  170.      Directory Options
  171.           -B_p_r_e_f_i_x -I_d_i_r -I- -L_d_i_r
  172.  
  173.      Target Options
  174.           -b  _m_a_c_h_i_n_e -V _v_e_r_s_i_o_n
  175.  
  176.      Configuration Dependent Options
  177.           _M_6_8_0_x_0 _O_p_t_i_o_n_s
  178.           -m68000 -m68020 -m68020-40 -m68030 -m68040 -m68881
  179.           -mbitfield -mc68000 -mc68020 -mfpa -mnobitfield -mrtd
  180.           -mshort -msoft-float
  181.  
  182.           _V_A_X _O_p_t_i_o_n_s
  183.           -mg -mgnu -munix
  184.  
  185.           _S_P_A_R_C _O_p_t_i_o_n_s
  186.           -mepilogue -mfpu -mhard-float -mno-fpu -mno-epilogue
  187.           -msoft-float -msparclite -mv8
  188.  
  189.           _C_o_n_v_e_x _O_p_t_i_o_n_s
  190.           -margcount -mc1 -mc2 -mnoargcount
  191.  
  192.  
  193.  
  194.  
  195. GNU Tools            Last change: 1993/10/13                    3
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. GCC(1)                      GNU Tools                      GCC(1)
  203.  
  204.  
  205.  
  206.           _A_M_D_2_9_K _O_p_t_i_o_n_s
  207.           -m29000 -m29050 -mbw -mdw -mkernel-registers -mlarge
  208.           -mnbw -mnodw -msmall -mstack-check -muser-registers
  209.  
  210.           _M_8_8_K _O_p_t_i_o_n_s
  211.           -m88000 -m88100 -m88110 -mbig-pic -mcheck-zero-division
  212.           -mhandle-large-shift -midentify-revision
  213.           -mno-check-zero-division -mno-ocs-debug-info
  214.           -mno-ocs-frame-position -mno-optimize-arg-area
  215.           -mno-seriazlize-volatile -mno-underscores
  216.           -mocs-debug-info -mocs-frame-position
  217.           -moptimize-arg-area -mserialize-volatile
  218.           -mshort-data-_n_u_m -msvr3 -msvr4 -mtrap-large-shift
  219.           -muse-div-instruction -mversion-03.00
  220.           -mwarn-passed-structs
  221.  
  222.           _R_S_6_0_0_0 _O_p_t_i_o_n_s
  223.           -mfp-in-toc -mno-fop-in-toc
  224.  
  225.           _R_T _O_p_t_i_o_n_s
  226.           -mcall-lib-mul -mfp-arg-in-fpregs -mfp-arg-in-gregs
  227.           -mfull-fp-blocks -mhc-struct-return -min-line-mul
  228.           -mminimum-fp-blocks -mnohc-struct-return
  229.  
  230.           _M_I_P_S _O_p_t_i_o_n_s
  231.           -mcpu=_c_p_u _t_y_p_e -mips2 -mips3 -mint64 -mlong64
  232.           -mlonglong128 -mmips-as -mgas -mrnames -mno-rnames
  233.           -mgpopt -mno-gpopt -mstats -mno-stats -mmemcpy
  234.           -mno-memcpy -mno-mips-tfile -mmips-tfile -msoft-float
  235.           -mhard-float -mabicalls -mno-abicalls -mhalf-pic
  236.           -mno-half-pic -G _n_u_m -nocpp
  237.  
  238.           _i_3_8_6 _O_p_t_i_o_n_s
  239.           -m486 -mno-486 -msoft-float -mno-fp-ret-in-387
  240.  
  241.           _H_P_P_A _O_p_t_i_o_n_s
  242.           -mpa-risc-1-0 -mpa-risc-1-1 -mkernel -mshared-libs
  243.           -mno-shared-libs -mlong-calls -mdisable-fpregs
  244.           -mdisable-indexing -mtrailing-colon
  245.  
  246.           _i_9_6_0 _O_p_t_i_o_n_s
  247.           -m_c_p_u-_t_y_p_e -mnumerics -msoft-float -mleaf-procedures
  248.           -mno-leaf-procedures -mtail-call -mno-tail-call
  249.           -mcomplex-addr -mno-complex-addr -mcode-align
  250.           -mno-code-align -mic-compat -mic2.0-compat
  251.           -mic3.0-compat -masm-compat -mintel-asm -mstrict-align
  252.           -mno-strict-align -mold-align -mno-old-align
  253.  
  254.           _D_E_C _A_l_p_h_a _O_p_t_i_o_n_s
  255.           -mfp-regs -mno-fp-regs -mno-soft-float -msoft-float
  256.  
  257.           _S_y_s_t_e_m _V _O_p_t_i_o_n_s
  258.  
  259.  
  260.  
  261. GNU Tools            Last change: 1993/10/13                    4
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. GCC(1)                      GNU Tools                      GCC(1)
  269.  
  270.  
  271.  
  272.           -G -Qy -Qn -YP,_p_a_t_h_s -Ym,_d_i_r
  273.  
  274.      Code Generation Options
  275.           -fcall-saved-_r_e_g -fcall-used-_r_e_g -ffixed-_r_e_g
  276.           -finhibit-size-directive -fnonnull-objects -fno-common
  277.           -fno-ident -fno-gnu-linker -fpcc-struct-return -fpic
  278.           -fPIC -freg-struct-returno -fshared-data -fshort-enums
  279.           -fshort-double -fvolatile -fvolatile-global
  280.           -fverbose-asm
  281.  
  282. OVERALL OPTIONS
  283.      -x _l_a_n_g_u_a_g_e
  284.           Specify explicitly the _l_a_n_g_u_a_g_e for the following input
  285.           files (rather than choosing a default based on the file
  286.           name suffix) .  This option applies  to  all  following
  287.           input  files  until  the  next  `-x'  option.  Possible
  288.           values of _l_a_n_g_u_a_g_e are `c', `objective-c',  `c-header',
  289.           `c++',       `cpp-output',       `assembler',       and
  290.           `assembler-with-cpp'.
  291.  
  292.      -x none
  293.           Turn off any specification of a language, so that  sub-
  294.           sequent  files are handled according to their file name
  295.           suffixes (as they are if `-x'  has  not  been  used  at
  296.           all).
  297.  
  298.      If you want only some of the four stages  (preprocess,  com-
  299.      pile,  assemble,  link),  you can use `-x' (or filename suf-
  300.      fixes) to tell gcc where to start, and one  of  the  options
  301.      `-c',  `-S', or `-E' to say where gcc is to stop.  Note that
  302.      some combinations (for example, `-x cpp-output -E') instruct
  303.      gcc to do nothing at all.
  304.  
  305.      -c   Compile or assemble the source files, but do not  link.
  306.           The  compiler output is an object file corresponding to
  307.           each source file.
  308.  
  309.           By default, GCC makes the object file name for a source
  310.           file  by  replacing  the suffix `.c', `.i', `.s', etc.,
  311.           with `.o'.  Use -o to select another name.
  312.  
  313.           GCC ignores any unrecognized input files (those that do
  314.           not  require  compilation  or assembly) with the -c op-
  315.           tion.
  316.  
  317.      -S   Stop after the stage of compilation proper; do not  as-
  318.           semble.   The output is an assembler code file for each
  319.           non-assembler input file specified.
  320.  
  321.           By default, GCC makes the assembler  file  name  for  a
  322.           source  file  by replacing the suffix `.c', `.i', etc.,
  323.           with `.s'.  Use -o to select another name.
  324.  
  325.  
  326.  
  327. GNU Tools            Last change: 1993/10/13                    5
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334. GCC(1)                      GNU Tools                      GCC(1)
  335.  
  336.  
  337.  
  338.           GCC ignores any input files that don't require compila-
  339.           tion.
  340.  
  341.      -E   Stop after the preprocessing stage; do not run the com-
  342.           piler  proper.  The output is preprocessed source code,
  343.           which is sent to the standard output.
  344.  
  345.           GCC ignores input files which don't require preprocess-
  346.           ing.
  347.  
  348.      -o _f_i_l_e
  349.           Place output in file _f_i_l_e.  This applies regardless  to
  350.           whatever sort of output GCC is producing, whether it be
  351.           an executable file, an object file, an  assembler  file
  352.           or preprocessed C code.
  353.  
  354.           Since only one output file can be  specified,  it  does
  355.           not make sense to use `-o' when compiling more than one
  356.           input file, unless you are producing an executable file
  357.           as output.
  358.  
  359.           If you do not specify `-o', the default is  to  put  an
  360.           executable   file  in  `a.out',  the  object  file  for
  361.           `_s_o_u_r_c_e._s_u_f_f_i_x' in `_s_o_u_r_c_e.o', its  assembler  file  in
  362.           `_s_o_u_r_c_e.s',  and  all preprocessed C source on standard
  363.           output.
  364.  
  365.      -v   Print (on standard error output) the commands  executed
  366.           to  run the stages of compilation.  Also print the ver-
  367.           sion number of the compiler driver program and  of  the
  368.           preprocessor and the compiler proper.
  369.  
  370.      -pipe
  371.           Use pipes rather than temporary files for communication
  372.           between  the various stages of compilation.  This fails
  373.           to work on some systems where the assembler cannot read
  374.           from a pipe; but the GNU assembler has no trouble.
  375.  
  376. LANGUAGE OPTIONS
  377.      The following options control the dialect of C that the com-
  378.      piler accepts:
  379.  
  380.      -ansi
  381.           Support all ANSI standard C programs.
  382.  
  383.           This turns off certain features of GNU C that  are  in-
  384.           compatible  with  ANSI  C,  such as the asm, inline and
  385.           typeof keywords, and predefined macros such as unix and
  386.           vax that identify the type of system you are using.  It
  387.           also enables the undesirable and rarely used ANSI  tri-
  388.           graph  feature,  and  disallows `$' as part of identif-
  389.           iers.
  390.  
  391.  
  392.  
  393. GNU Tools            Last change: 1993/10/13                    6
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400. GCC(1)                      GNU Tools                      GCC(1)
  401.  
  402.  
  403.  
  404.           The alternate keywords  __asm__,  __extension__,  __in-
  405.           line__ and __typeof__ continue to work despite `-ansi'.
  406.           You would not want to use them in an ANSI C program, of
  407.           course,  but  it  is useful to put them in header files
  408.           that  might  be  included  in  compilations  done  with
  409.           `-ansi'.   Alternate predefined macros such as __unix__
  410.           and  __vax__  are  also  available,  with  or   without
  411.           `-ansi'.
  412.  
  413.           The `-ansi' option does not cause non-ANSI programs  to
  414.           be rejected gratuitously.  For that, `-pedantic' is re-
  415.           quired in addition to `-ansi'.
  416.  
  417.           The preprocessor  predefines  a  macro  __STRICT_ANSI__
  418.           when you use the `-ansi' option.  Some header files may
  419.           notice this macro and refrain  from  declaring  certain
  420.           functions  or  defining  certain  macros  that the ANSI
  421.           standard doesn't call for; this is to avoid interfering
  422.           with  any programs that might use these names for other
  423.           things.
  424.  
  425.      -fno-asm
  426.           Do not recognize asm, inline or typeof  as  a  keyword.
  427.           These  words  may then be used as identifiers.  You can
  428.           use  __asm__,  __inline__   and   __typeof__   instead.
  429.           `-ansi' implies `-fno-asm'.
  430.  
  431.      -fno-builtin
  432.           Don't recognize built-in functions that  do  not  begin
  433.           with two leading underscores.  Currently, the functions
  434.           affected include _exit, abort, abs, alloca, cos,  exit,
  435.           fabs,  labs, memcmp, memcpy, sin, sqrt, strcmp, strcpy,
  436.           and strlen.
  437.  
  438.           The `-ansi' option prevents alloca and _exit from being
  439.           builtin functions.
  440.  
  441.      -fno-strict-prototype
  442.           Treat a function declaration with no arguments, such as
  443.           `int  foo  ();',  as C would treat it-as saying nothing
  444.           about the number  of  arguments  or  their  types  (C++
  445.           only).   Normally, such a declaration in C++ means that
  446.           the function foo takes no arguments.
  447.  
  448.      -trigraphs
  449.           Support ANSI C trigraphs.  The `-ansi'  option  implies
  450.           `-trigraphs'.
  451.  
  452.      -traditional
  453.           Attempt to support some aspects of traditional  C  com-
  454.           pilers.   For details, see the GNU C Manual; the dupli-
  455.           cate list here has been deleted so that  we  won't  get
  456.  
  457.  
  458.  
  459. GNU Tools            Last change: 1993/10/13                    7
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466. GCC(1)                      GNU Tools                      GCC(1)
  467.  
  468.  
  469.  
  470.           complaints when it is out of date.
  471.  
  472.           But one note about C++ programs only (not C).  `-tradi-
  473.           tional'  has  one additional effect for C++: assignment
  474.           to this is permitted.  This is the same as  the  effect
  475.           of `-fthis-is-variable'.
  476.  
  477.      -traditional-cpp
  478.           Attempt  to  support  some  aspects  of  traditional  C
  479.           preprocessors.   This  includes the items that specifi-
  480.           cally mention the preprocessor above, but none  of  the
  481.           other effects of `-traditional'.
  482.  
  483.      -fdollars-in-identifiers
  484.           Permit the use of `$' in identifiers (C++  only).   You
  485.           can also use `-fno-dollars-in-identifiers' to explicit-
  486.           ly prohibit use of `$'.  (GNU C++ allows `$' by default
  487.           on some target systems but not others.)
  488.  
  489.      -fenum-int-equiv
  490.           Permit implicit conversion of int to enumeration  types
  491.           (C++ only).  Normally GNU C++ allows conversion of enum
  492.           to int, but not the other way around.
  493.  
  494.      -fexternal-templates
  495.           Produce smaller code for template declarations, by gen-
  496.           erating  only  a  single copy of each template function
  497.           where it is defined (C++ only).   To  use  this  option
  498.           successfully,  you  must  also  mark all files that use
  499.           templates with either `#pragma implementation' (the de-
  500.           finition) or `#pragma interface' (declarations).
  501.  
  502.           When your code is compiled with `-fexternal-templates',
  503.           all template instantiations are external.  You must ar-
  504.           range for all necessary instantiations to appear in the
  505.           implementation  file;  you  can  do this with a typedef
  506.           that references each instantiation needed.  Conversely,
  507.           when    you    compile   using   the   default   option
  508.           `-fno-external-templates', all template  instantiations
  509.           are explicitly internal.
  510.  
  511.      -fall-virtual
  512.           Treat all possible member functions as virtual,  impli-
  513.           citly.   All  member  functions (except for constructor
  514.           functions and  new  or  delete  member  operators)  are
  515.           treated  as  virtual  functions of the class where they
  516.           appear.
  517.  
  518.           This does not mean that all calls to these member func-
  519.           tions will be made through the internal table of virtu-
  520.           al functions.  Under some circumstances,  the  compiler
  521.           can  determine  that a call to a given virtual function
  522.  
  523.  
  524.  
  525. GNU Tools            Last change: 1993/10/13                    8
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532. GCC(1)                      GNU Tools                      GCC(1)
  533.  
  534.  
  535.  
  536.           can be made directly; in  these  cases  the  calls  are
  537.           direct in any case.
  538.  
  539.      -fcond-mismatch
  540.           Allow conditional expressions with mismatched types  in
  541.           the  second  and third arguments.  The value of such an
  542.           expression is void.
  543.  
  544.      -fthis-is-variable
  545.           Permit assignment to this (C++ only).   The  incorpora-
  546.           tion of user-defined free store management into C++ has
  547.           made assignment to `this' an  anachronism.   Therefore,
  548.           by  default  it  is  invalid to assign to this within a
  549.           class member function.  However, for backwards compati-
  550.           bility,   you   can  make  it  valid  with  `-fthis-is-
  551.           variable'.
  552.  
  553.      -funsigned-char
  554.           Let the type char be unsigned, like unsigned char.
  555.  
  556.           Each kind of machine has a default for what char should
  557.           be.  It is either like unsigned char by default or like
  558.           signed char by default.
  559.  
  560.           Ideally, a portable program should  always  use  signed
  561.           char or unsigned char when it depends on the signedness
  562.           of an object.  But many programs have been  written  to
  563.           use plain char and expect it to be signed, or expect it
  564.           to be unsigned, depending on  the  machines  they  were
  565.           written  for.   This  option,  and its inverse, let you
  566.           make such a program work with the opposite default.
  567.  
  568.           The type char is always a distinct type  from  each  of
  569.           signed char and unsigned char, even though its behavior
  570.           is always just like one of those two.
  571.  
  572.      -fsigned-char
  573.           Let the type char be signed, like signed char.
  574.  
  575.           Note that this is equivalent  to  `-fno-unsigned-char',
  576.           which is the negative form of `-funsigned-char'.  Like-
  577.           wise,    `-fno-signed-char'    is     equivalent     to
  578.           `-funsigned-char'.
  579.  
  580.      -fsigned-bitfields
  581.  
  582.      -funsigned-bitfields
  583.  
  584.      -fno-signed-bitfields
  585.  
  586.      -fno-unsigned-bitfields
  587.           These options control whether a bitfield is  signed  or
  588.  
  589.  
  590.  
  591. GNU Tools            Last change: 1993/10/13                    9
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598. GCC(1)                      GNU Tools                      GCC(1)
  599.  
  600.  
  601.  
  602.           unsigned,  when  declared  with no explicit `signed' or
  603.           `unsigned' qualifier.  By default, such a  bitfield  is
  604.           signed,  because  this is consistent: the basic integer
  605.           types such as int are signed types.
  606.  
  607.           However, when you specify `-traditional', bitfields are
  608.           all unsigned no matter what.
  609.  
  610.      -fwritable-strings
  611.           Store string constants in the writable data segment and
  612.           don't  uniquize  them.   This is for compatibility with
  613.           old programs which assume they can  write  into  string
  614.           constants.  `-traditional' also has this effect.
  615.  
  616.           Writing into string constants is a very bad idea; "con-
  617.           stants" should be constant.
  618.  
  619. PREPROCESSOR OPTIONS
  620.      These options control the C preprocessor, which  is  run  on
  621.      each C source file before actual compilation.
  622.  
  623.      If you use the `-E' option, GCC does nothing except  prepro-
  624.      cessing.   Some  of  these  options make sense only together
  625.      with `-E' because they cause the preprocessor output  to  be
  626.      unsuitable for actual compilation.
  627.  
  628.      -include _f_i_l_e
  629.           Process _f_i_l_e as input before processing the regular in-
  630.           put file.  In effect, the contents of _f_i_l_e are compiled
  631.           first.  Any `-D' and `-U' options on the  command  line
  632.           are always processed before `-include _f_i_l_e', regardless
  633.           of the order in which they are written.  All the  `-in-
  634.           clude' and `-imacros' options are processed in the ord-
  635.           er in which they are written.
  636.  
  637.      -imacros _f_i_l_e
  638.           Process _f_i_l_e as input, discarding the resulting output,
  639.           before  processing the regular input file.  Because the
  640.           output generated from _f_i_l_e is discarded, the  only  ef-
  641.           fect  of  `-imacros _f_i_l_e' is to make the macros defined
  642.           in _f_i_l_e available for  use  in  the  main  input.   The
  643.           preprocessor evaluates any `-D' and `-U' options on the
  644.           command line before processing `-imacros_f_i_l_e',  regard-
  645.           less  of  the order in which they are written.  All the
  646.           `-include' and `-imacros' options are processed in  the
  647.           order in which they are written.
  648.  
  649.      -idirafter _d_i_r
  650.           Add the directory _d_i_r to the second include path.   The
  651.           directories  on  the  second  include path are searched
  652.           when a header file is not found in any  of  the  direc-
  653.           tories in the main include path (the one that `-I' adds
  654.  
  655.  
  656.  
  657. GNU Tools            Last change: 1993/10/13                   10
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664. GCC(1)                      GNU Tools                      GCC(1)
  665.  
  666.  
  667.  
  668.           to).
  669.  
  670.      -iprefix _p_r_e_f_i_x
  671.           Specify _p_r_e_f_i_x as the prefix for subsequent `-iwithpre-
  672.           fix' options.
  673.  
  674.      -iwithprefix _d_i_r
  675.           Add a  directory  to  the  second  include  path.   The
  676.           directory's  name  is  made by concatenating _p_r_e_f_i_x and
  677.           _d_i_r, where _p_r_e_f_i_x was specified previously with `-ipre-
  678.           fix'.
  679.  
  680.      -nostdinc
  681.           Do not  search  the  standard  system  directories  for
  682.           header  files.  Only the directories you have specified
  683.           with `-I' options (and the current  directory,  if  ap-
  684.           propriate) are searched.
  685.  
  686.           By using both `-nostdinc' and `-I-', you can limit  the
  687.           include-file  search file to only those directories you
  688.           specify explicitly.
  689.  
  690.      -nostdinc++
  691.           Do not search for  header  files  in  the  C++-specific
  692.           standard  directories,  but  do  still search the other
  693.           standard directories.  (This option is used when build-
  694.           ing `libg++'.)
  695.  
  696.      -undef
  697.           Do not predefine any  nonstandard  macros.   (Including
  698.           architecture flags).
  699.  
  700.      -E   Run only the C  preprocessor.   Preprocess  all  the  C
  701.           source  files specified and output the results to stan-
  702.           dard output or to the specified output file.
  703.  
  704.      -C   Tell the preprocessor not to  discard  comments.   Used
  705.           with the `-E' option.
  706.  
  707.      -P   Tell the preprocessor not to generate `#line' commands.
  708.           Used with the `-E' option.
  709.  
  710.      -M   Tell the preprocessor to output  a  rule  suitable  for
  711.           make  describing  the dependencies of each object file.
  712.           For each source  file,  the  preprocessor  outputs  one
  713.           make-rule whose target is the object file name for that
  714.           source file and whose dependencies are  all  the  files
  715.           `#include'd  in  it.  This rule may be a single line or
  716.           may be continued with `\'-newline if it is  long.   The
  717.           list  of rules is printed on standard output instead of
  718.           the preprocessed C program.
  719.  
  720.  
  721.  
  722.  
  723. GNU Tools            Last change: 1993/10/13                   11
  724.  
  725.  
  726.  
  727.  
  728.  
  729.  
  730. GCC(1)                      GNU Tools                      GCC(1)
  731.  
  732.  
  733.  
  734.           `-M' implies `-E'.
  735.  
  736.      -MM  Like `-M' but the output mentions only the user  header
  737.           files  included  with  `#include _f_i_l_e"'.  System header
  738.           files included with `#include <_f_i_l_e>' are omitted.
  739.  
  740.      -MD  Like `-M' but the dependency information is written  to
  741.           files  with  names  made by replacing `.o' with `.d' at
  742.           the end of the output file names.  This is in  addition
  743.           to compiling the file as specified-`-MD' does not inhi-
  744.           bit ordinary compilation the way `-M' does.
  745.  
  746.           The Mach utility `md' can be used  to  merge  the  `.d'
  747.           files  into a single dependency file suitable for using
  748.           with the `make' command.
  749.  
  750.      -MMD Like `-MD' except mention only user header  files,  not
  751.           system header files.
  752.  
  753.      -H   Print the name of each header file used, in addition to
  754.           other normal activities.
  755.  
  756.      -A_q_u_e_s_t_i_o_n(_a_n_s_w_e_r)
  757.           Assert the answer _a_n_s_w_e_r for _q_u_e_s_t_i_o_n, in  case  it  is
  758.           tested  with  a  preprocessor  conditional such as `#if
  759.           #_q_u_e_s_t_i_o_n(_a_n_s_w_e_r)'.  `-A-' disables the standard asser-
  760.           tions that normally describe the target machine.
  761.  
  762.      -A_q_u_e_s_t_i_o_n
  763.           (_a_n_s_w_e_r) Assert the answer _a_n_s_w_e_r for _q_u_e_s_t_i_o_n, in case
  764.           it  is  tested  with a preprocessor conditional such as
  765.           `#if #_q_u_e_s_t_i_o_n(_a_n_s_w_e_r)'.  `-A-' disables  the  standard
  766.           assertions that normally describe the target machine.
  767.  
  768.      -D_m_a_c_r_o
  769.           Define macro _m_a_c_r_o with the string `1' as  its  defini-
  770.           tion.
  771.  
  772.      -D_m_a_c_r_o=_d_e_f_n
  773.           Define macro _m_a_c_r_o as _d_e_f_n.    All instances of `-D' on
  774.           the command line are processed before any `-U' options.
  775.  
  776.      -U_m_a_c_r_o
  777.           Undefine macro _m_a_c_r_o.  `-U' options are evaluated after
  778.           all `-D' options, but before any `-include' and `-imac-
  779.           ros' options.
  780.  
  781.      -dM  Tell the preprocessor to output only a list of the mac-
  782.           ro definitions that are in effect at the end of prepro-
  783.           cessing.  Used with the `-E' option.
  784.  
  785.      -dD  Tell the preprocessor to  pass  all  macro  definitions
  786.  
  787.  
  788.  
  789. GNU Tools            Last change: 1993/10/13                   12
  790.  
  791.  
  792.  
  793.  
  794.  
  795.  
  796. GCC(1)                      GNU Tools                      GCC(1)
  797.  
  798.  
  799.  
  800.           into  the  output, in their proper sequence in the rest
  801.           of the output.
  802.  
  803.      -dN  Like `-dD' except that the macro arguments and contents
  804.           are  omitted.   Only  `#define _n_a_m_e' is included in the
  805.           output.
  806.  
  807. ASSEMBLER OPTION
  808.      -Wa,_o_p_t_i_o_n
  809.           Pass _o_p_t_i_o_n as an option to the assembler.   If  _o_p_t_i_o_n
  810.           contains  commas,  it is split into multiple options at
  811.           the commas.
  812.  
  813. LINKER OPTIONS
  814.      These options come into play when the compiler links  object
  815.      files  into an executable output file.  They are meaningless
  816.      if the compiler is not doing a link step.
  817.  
  818.      _o_b_j_e_c_t-_f_i_l_e-_n_a_m_e
  819.           A file name that does not end in a  special  recognized
  820.           suffix is considered to name an object file or library.
  821.           (Object files are distinguished from libraries  by  the
  822.           linker  according to the file contents.)  If GCC does a
  823.           link step, these object files are used as input to  the
  824.           linker.
  825.  
  826.      -l_l_i_b_r_a_r_y
  827.           Use the library named _l_i_b_r_a_r_y when linking.
  828.  
  829.           The linker searches a standard list of directories  for
  830.           the   library,   which   is   actually   a  file  named
  831.           `lib_l_i_b_r_a_r_y.a'.  The linker then uses this file  as  if
  832.           it had been specified precisely by name.
  833.  
  834.           The directories searched include several standard  sys-
  835.           tem directories plus any that you specify with `-L'.
  836.  
  837.           Normally the files found this way  are  library  files-
  838.           archive  files  whose  members  are  object files.  The
  839.           linker handles an archive file by scanning  through  it
  840.           for  members which define symbols that have so far been
  841.           referenced but not defined.   However,  if  the  linker
  842.           finds  an  ordinary  object file rather than a library,
  843.           the object file is linked in the  usual  fashion.   The
  844.           only difference between using an `-l' option and speci-
  845.           fying a file name is that `-l' surrounds  _l_i_b_r_a_r_y  with
  846.           `lib' and `.a' and searches several directories.
  847.  
  848.      -lobjc
  849.           You need this special case of the -l option in order to
  850.           link an Objective C program.
  851.  
  852.  
  853.  
  854.  
  855. GNU Tools            Last change: 1993/10/13                   13
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862. GCC(1)                      GNU Tools                      GCC(1)
  863.  
  864.  
  865.  
  866.      -nostartfiles
  867.           Do not use the standard system startup files when link-
  868.           ing.  The standard libraries are used normally.
  869.  
  870.      -nostdlib
  871.           Don't use the standard  system  libraries  and  startup
  872.           files when linking.  Only the files you specify will be
  873.           passed to the linker.
  874.  
  875.      -static
  876.           On systems that support dynamic linking, this  prevents
  877.           linking  with  the shared libraries.  On other systems,
  878.           this option has no effect.
  879.  
  880.      -shared
  881.           Produce a shared object which can then be  linked  with
  882.           other  objects  to form an executable.  Only a few sys-
  883.           tems support this option.
  884.  
  885.      -symbolic
  886.           Bind references  to  global  symbols  when  building  a
  887.           shared  object.   Warn  about any unresolved references
  888.           (unless overridden by the link editor option  `-Xlinker
  889.           -z  -Xlinker  defs').   Only a few systems support this
  890.           option.
  891.  
  892.      -Xlinker _o_p_t_i_o_n
  893.           Pass _o_p_t_i_o_n as an option to the linker.   You  can  use
  894.           this to supply system-specific linker options which GNU
  895.           CC does not know how to recognize.
  896.  
  897.           If you want to pass an option that takes  an  argument,
  898.           you  must use `-Xlinker' twice, once for the option and
  899.           once for the argument.  For example, to  pass  `-assert
  900.           definitions', you must write `-Xlinker -assert -Xlinker
  901.           definitions'.  It does  not  work  to  write  `-Xlinker
  902.           "-assert  definitions"', because this passes the entire
  903.           string as a single argument,  which  is  not  what  the
  904.           linker expects.
  905.  
  906.      -Wl,_o_p_t_i_o_n
  907.           Pass _o_p_t_i_o_n as an option to the linker.  If _o_p_t_i_o_n con-
  908.           tains  commas, it is split into multiple options at the
  909.           commas.
  910.  
  911.      -u _s_y_m_b_o_l
  912.           Pretend the symbol _s_y_m_b_o_l is undefined, to force  link-
  913.           ing  of library modules to define it.  You can use `-u'
  914.           multiple times with different symbols to force  loading
  915.           of additional library modules.
  916.  
  917.  
  918.  
  919.  
  920.  
  921. GNU Tools            Last change: 1993/10/13                   14
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928. GCC(1)                      GNU Tools                      GCC(1)
  929.  
  930.  
  931.  
  932. DIRECTORY OPTIONS
  933.      These options  specify  directories  to  search  for  header
  934.      files, for libraries and for parts of the compiler:
  935.  
  936.      -I_d_i_r
  937.           Append  directory  _d_i_r  to  the  list  of   directories
  938.           searched for include files.
  939.  
  940.      -I-  Any directories you specify with  `-I'  options  before
  941.           the  `-I-'  option  are  searched  only for the case of
  942.           `#include "_f_i_l_e"'; they are not searched for  `#include
  943.           <_f_i_l_e>'.
  944.  
  945.           If additional directories are specified with  `-I'  op-
  946.           tions  after  the `-I-', these directories are searched
  947.           for all `#include' directives.   (Ordinarily  _a_l_l  `-I'
  948.           directories are used this way.)
  949.  
  950.           In addition, the `-I-' option inhibits the use  of  the
  951.           current  directory  (where  the current input file came
  952.           from) as  the  first  search  directory  for  `#include
  953.           "_f_i_l_e"'.   There  is  no way to override this effect of
  954.           `-I-'.  With `-I.' you can specify searching the direc-
  955.           tory  which  was current when the compiler was invoked.
  956.           That is not exactly the same as what  the  preprocessor
  957.           does by default, but it is often satisfactory.
  958.  
  959.           `-I-' does not inhibit the use of the  standard  system
  960.           directories  for header files.  Thus, `-I-' and `-nost-
  961.           dinc' are independent.
  962.  
  963.      -L_d_i_r
  964.           Add directory _d_i_r to the  list  of  directories  to  be
  965.           searched for `-l'.
  966.  
  967.      -B_p_r_e_f_i_x
  968.           This option specifies where to  find  the  executables,
  969.           libraries and data files of the compiler itself.
  970.  
  971.           The compiler driver program runs one  or  more  of  the
  972.           subprograms `cpp', `cc1' (or, for C++, `cc1plus'), `as'
  973.           and `ld'.  It tries _p_r_e_f_i_x as a prefix for each program
  974.           it    tries    to    run,   both   with   and   without
  975.           `_m_a_c_h_i_n_e/_v_e_r_s_i_o_n/'.
  976.  
  977.           For each subprogram to  be  run,  the  compiler  driver
  978.           first  tries  the `-B' prefix, if any.  If that name is
  979.           not found, or if `-B' was  not  specified,  the  driver
  980.           tries  two standard prefixes, which are `/usr/lib/gcc/'
  981.           and `/usr/local/lib/gcc-lib/'.   If  neither  of  those
  982.           results  in  a  file  name  that is found, the compiler
  983.           driver searches for the unmodified program name,  using
  984.  
  985.  
  986.  
  987. GNU Tools            Last change: 1993/10/13                   15
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994. GCC(1)                      GNU Tools                      GCC(1)
  995.  
  996.  
  997.  
  998.           the  directories  specified  in your `PATH' environment
  999.           variable.
  1000.  
  1001.           The run-time support file `libgcc.a' is  also  searched
  1002.           for  using  the  `-B'  prefix, if needed.  If it is not
  1003.           found there, the two standard prefixes above are tried,
  1004.           and  that  is all.  The file is left out of the link if
  1005.           it is not found by those means.  Most of the  time,  on
  1006.           most machines, `libgcc.a' is not actually necessary.
  1007.  
  1008.           You can get a similar result from the environment vari-
  1009.           able  GCC_EXEC_PREFIX;  if  it is defined, its value is
  1010.           used as a prefix in the same way.  If both the `-B' op-
  1011.           tion  and the GCC_EXEC_PREFIX variable are present, the
  1012.           `-B' option is used first and the environment  variable
  1013.           value second.
  1014.  
  1015. WARNING OPTIONS
  1016.      Warnings are diagnostic messages that  report  constructions
  1017.      which  are  not  inherently erroneous but which are risky or
  1018.      suggest there may have been an error.
  1019.  
  1020.      These options control the amount and kinds of warnings  pro-
  1021.      duced by GNU CC:
  1022.  
  1023.      -fsyntax-only
  1024.           Check the code for syntax errors, but  don't  emit  any
  1025.           output.
  1026.  
  1027.      -w   Inhibit all warning messages.
  1028.  
  1029.      -Wno-import
  1030.           Inhibit warning messages about the use of #import.
  1031.  
  1032.      -pedantic
  1033.           Issue all the warnings demanded by strict ANSI standard
  1034.           C; reject all programs that use forbidden extensions.
  1035.  
  1036.           Valid ANSI standard C programs should compile  properly
  1037.           with or without this option (though a rare few will re-
  1038.           quire `-ansi').  However, without this option,  certain
  1039.           GNU extensions and traditional C features are supported
  1040.           as well.  With this option, they are  rejected.   There
  1041.           is  no  reason  to  _u_s_e  this option; it exists only to
  1042.           satisfy pedants.
  1043.  
  1044.           `-pedantic' does not cause warning messages for use  of
  1045.           the  alternate  keywords whose names begin and end with
  1046.           `__'.  Pedantic warnings are also disabled in  the  ex-
  1047.           pression  that  follows  __extension__.   However, only
  1048.           system header files should use these escape routes; ap-
  1049.           plication programs should avoid them.
  1050.  
  1051.  
  1052.  
  1053. GNU Tools            Last change: 1993/10/13                   16
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060. GCC(1)                      GNU Tools                      GCC(1)
  1061.  
  1062.  
  1063.  
  1064.      -pedantic-errors
  1065.           Like `-pedantic', except that errors are produced rath-
  1066.           er than warnings.
  1067.  
  1068.      -W   Print extra warning messages for these events:
  1069.  
  1070.         o+ A nonvolatile automatic variable might be changed by  a
  1071.           call  to  longjmp.  These warnings are possible only in
  1072.           optimizing compilation.
  1073.  
  1074.           The compiler sees only the calls to setjmp.  It  cannot
  1075.           know  where  longjmp  will be called; in fact, a signal
  1076.           handler could call it at any point in the code.   As  a
  1077.           result,  you  may  get  a warning even when there is in
  1078.           fact no problem  because  longjmp  cannot  in  fact  be
  1079.           called at the place which would cause a problem.
  1080.  
  1081.         o+ A function can return either with or without  a  value.
  1082.           (Falling off the end of the function body is considered
  1083.           returning without a value.)  For example, this function
  1084.           would evoke such a warning:
  1085.  
  1086.           foo (a)
  1087.           {
  1088.             if (a > 0)
  1089.               return a;
  1090.           }
  1091.  
  1092.           Spurious warnings can occur because  GNU  CC  does  not
  1093.           realize  that  certain  functions  (including abort and
  1094.           longjmp) will never return.
  1095.  
  1096.         o+ An expression-statement contains no side effects.
  1097.  
  1098.         o+ An unsigned value is compared against zero with `>'  or
  1099.           `<='.
  1100.  
  1101.      -Wimplicit
  1102.           Warn whenever a function or parameter is implicitly de-
  1103.           clared.
  1104.  
  1105.      -Wreturn-type
  1106.           Warn whenever a function is defined with a  return-type
  1107.           that  defaults  to  int.   Also  warn  about any return
  1108.           statement with no  return-value  in  a  function  whose
  1109.           return-type is not void.
  1110.  
  1111.      -Wunused
  1112.           Warn whenever a local variable is unused aside from its
  1113.           declaration, whenever a function is declared static but
  1114.           never defined, and  whenever  a  statement  computes  a
  1115.           result that is explicitly not used.
  1116.  
  1117.  
  1118.  
  1119. GNU Tools            Last change: 1993/10/13                   17
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126. GCC(1)                      GNU Tools                      GCC(1)
  1127.  
  1128.  
  1129.  
  1130.      -Wswitch
  1131.           Warn whenever  a  switch  statement  has  an  index  of
  1132.           enumeral  type  and lacks a case for one or more of the
  1133.           named codes of that enumeration.  (The  presence  of  a
  1134.           default label prevents this warning.)  case labels out-
  1135.           side the enumeration range also provoke  warnings  when
  1136.           this option is used.
  1137.  
  1138.      -Wcomment
  1139.           Warn whenever a comment-start sequence `/*' appears  in
  1140.           a comment.
  1141.  
  1142.      -Wtrigraphs
  1143.           Warn if any trigraphs are  encountered  (assuming  they
  1144.           are enabled).
  1145.  
  1146.      -Wformat
  1147.           Check calls to printf and scanf,  etc.,  to  make  sure
  1148.           that  the  arguments supplied have types appropriate to
  1149.           the format string specified.
  1150.  
  1151.      -Wchar-subscripts
  1152.           Warn if an array subscript has type char.   This  is  a
  1153.           common cause of error, as programmers often forget that
  1154.           this type is signed on some machines.
  1155.  
  1156.      -Wuninitialized
  1157.           An automatic variable is used without first being  ini-
  1158.           tialized.
  1159.  
  1160.           These warnings are possible only in optimizing compila-
  1161.           tion,  because  they require data flow information that
  1162.           is computed only when optimizing.  If you don't specify
  1163.           `-O', you simply won't get these warnings.
  1164.  
  1165.           These warnings occur only for variables that are candi-
  1166.           dates  for register allocation.  Therefore, they do not
  1167.           occur for a variable  that  is  declared  volatile,  or
  1168.           whose  address is taken, or whose size is other than 1,
  1169.           2, 4 or 8 bytes.  Also, they do not  occur  for  struc-
  1170.           tures,  unions  or arrays, even when they are in regis-
  1171.           ters.
  1172.  
  1173.           Note that there may be no warning about a variable that
  1174.           is  used  only  to compute a value that itself is never
  1175.           used, because such computations may be deleted by  data
  1176.           flow analysis before the warnings are printed.
  1177.  
  1178.           These warnings are made optional because GNU CC is  not
  1179.           smart  enough to see all the reasons why the code might
  1180.           be correct despite appearing to have an error.  Here is
  1181.           one example of how this can happen:
  1182.  
  1183.  
  1184.  
  1185. GNU Tools            Last change: 1993/10/13                   18
  1186.  
  1187.  
  1188.  
  1189.  
  1190.  
  1191.  
  1192. GCC(1)                      GNU Tools                      GCC(1)
  1193.  
  1194.  
  1195.  
  1196.           {
  1197.             int x;
  1198.             switch (y)
  1199.               {
  1200.               case 1: x = 1;
  1201.                 break;
  1202.               case 2: x = 4;
  1203.                 break;
  1204.               case 3: x = 5;
  1205.               }
  1206.             foo (x);
  1207.           }
  1208.  
  1209.           If the value of y is always 1, 2 or 3, then x is always
  1210.           initialized,  but  GNU  CC  doesn't know this.  Here is
  1211.           another common case:
  1212.  
  1213.           {
  1214.             int save_y;
  1215.             if (change_y) save_y = y, y = new_y;
  1216.             ...
  1217.             if (change_y) y = save_y;
  1218.           }
  1219.  
  1220.           This has no bug because save_y is used only  if  it  is
  1221.           set.
  1222.  
  1223.           Some spurious warnings can be avoided if you declare as
  1224.           volatile all the functions you use that never return.
  1225.  
  1226.      -Wparentheses
  1227.           Warn if parentheses are omitted in certain contexts.
  1228.  
  1229.      -Wtemplate-debugging
  1230.           When using templates in a C++ program, warn  if  debug-
  1231.           ging is not yet fully available (C++ only).
  1232.  
  1233.      -Wall
  1234.           All of the above `-W' options combined.  These are  all
  1235.           the  options  which  pertain to usage that we recommend
  1236.           avoiding and that we believe is easy to avoid, even  in
  1237.           conjunction with macros.
  1238.  
  1239.      The remaining `-W...' options are not implied by `-Wall' be-
  1240.      cause they warn about constructions that we consider reason-
  1241.      able to use, on occasion, in clean programs.
  1242.  
  1243.      -Wtraditional
  1244.           Warn about certain constructs that  behave  differently
  1245.           in traditional and ANSI C.
  1246.  
  1247.         o+ Macro arguments occurring within  string  constants  in
  1248.  
  1249.  
  1250.  
  1251. GNU Tools            Last change: 1993/10/13                   19
  1252.  
  1253.  
  1254.  
  1255.  
  1256.  
  1257.  
  1258. GCC(1)                      GNU Tools                      GCC(1)
  1259.  
  1260.  
  1261.  
  1262.           the macro body.  These would substitute the argument in
  1263.           traditional C, but are part of the constant in ANSI C.
  1264.  
  1265.         o+ A function declared external in one block and then used
  1266.           after the end of the block.
  1267.  
  1268.         o+ A switch statement has an operand of type long.
  1269.  
  1270.      -Wshadow
  1271.           Warn whenever a local variable  shadows  another  local
  1272.           variable.
  1273.  
  1274.      -Wid-clash-_l_e_n
  1275.           Warn whenever two distinct  identifiers  match  in  the
  1276.           first _l_e_n characters.  This may help you prepare a pro-
  1277.           gram that will compile with  certain  obsolete,  brain-
  1278.           damaged compilers.
  1279.  
  1280.      -Wpointer-arith
  1281.           Warn about anything that depends on  the  "size  of"  a
  1282.           function  type or of void.  GNU C assigns these types a
  1283.           size of 1, for convenience in calculations with void  *
  1284.           pointers and pointers to functions.
  1285.  
  1286.      -Wcast-qual
  1287.           Warn whenever a pointer is cast so as to remove a  type
  1288.           qualifier from the target type.  For example, warn if a
  1289.           const char * is cast to an ordinary char *.
  1290.  
  1291.      -Wcast-align
  1292.           Warn whenever a pointer is cast such that the  required
  1293.           alignment  of  the  target  is increased.  For example,
  1294.           warn if a char * is cast to an int * on machines  where
  1295.           integers  can  only  be  accessed  at two- or four-byte
  1296.           boundaries.
  1297.  
  1298.      -Wwrite-strings
  1299.           Give string constants the type  const  char[_l_e_n_g_t_h]  so
  1300.           that copying the address of one into a non-const char *
  1301.           pointer will get a warning.  These warnings  will  help
  1302.           you  find  at  compile  time code that can try to write
  1303.           into a string constant, but only if you have been  very
  1304.           careful  about  using  const in declarations and proto-
  1305.           types.  Otherwise, it will just be a nuisance; this  is
  1306.           why we did not make `-Wall' request these warnings.
  1307.  
  1308.      -Wconversion
  1309.           Warn if a prototype causes a type  conversion  that  is
  1310.           different  from  what would happen to the same argument
  1311.           in the absence of a prototype.  This  includes  conver-
  1312.           sions  of  fixed  point to floating and vice versa, and
  1313.           conversions changing the width or signedness of a fixed
  1314.  
  1315.  
  1316.  
  1317. GNU Tools            Last change: 1993/10/13                   20
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323.  
  1324. GCC(1)                      GNU Tools                      GCC(1)
  1325.  
  1326.  
  1327.  
  1328.           point argument except when the same as the default pro-
  1329.           motion.
  1330.  
  1331.      -Waggregate-return
  1332.           Warn if any functions that return structures or  unions
  1333.           are defined or called.  (In languages where you can re-
  1334.           turn an array, this also elicits a warning.)
  1335.  
  1336.      -Wstrict-prototypes
  1337.           Warn if a  function  is  declared  or  defined  without
  1338.           specifying  the argument types.  (An old-style function
  1339.           definition is permitted without a warning  if  preceded
  1340.           by a declaration which specifies the argument types.)
  1341.  
  1342.      -Wmissing-prototypes
  1343.           Warn if a global function is defined without a previous
  1344.           prototype  declaration.  This warning is issued even if
  1345.           the definition itself provides a prototype.  The aim is
  1346.           to  detect global functions that fail to be declared in
  1347.           header files.
  1348.  
  1349.      -Wredundant-decls
  1350.           Warn if anything is declared more than once in the same
  1351.           scope,  even  in  cases  where  multiple declaration is
  1352.           valid and changes nothing.
  1353.  
  1354.      -Wnested-externs
  1355.           Warn if an extern declaration is encountered within  an
  1356.           function.
  1357.  
  1358.      -Wenum-clash
  1359.           Warn about  conversion  between  different  enumeration
  1360.           types (C++ only).
  1361.  
  1362.      -Woverloaded-virtual
  1363.           (C++ only.) In a derived class, the definitions of vir-
  1364.           tual  functions must match the type signature of a vir-
  1365.           tual function declared in the base class.  Use this op-
  1366.           tion  to request warnings when a derived class declares
  1367.           a function that may be an erroneous attempt to define a
  1368.           virtual  function:  that  is, warn when a function with
  1369.           the same name as a virtual function in the base  class,
  1370.           but with a type signature that doesn't match any virtu-
  1371.           al functions from the base class.
  1372.  
  1373.      -Winline
  1374.           Warn if a function can not be inlined,  and  either  it
  1375.           was  declared as inline, or else the -finline-functions
  1376.           option was given.
  1377.  
  1378.      -Werror
  1379.           Treat warnings as errors; abort compilation  after  any
  1380.  
  1381.  
  1382.  
  1383. GNU Tools            Last change: 1993/10/13                   21
  1384.  
  1385.  
  1386.  
  1387.  
  1388.  
  1389.  
  1390. GCC(1)                      GNU Tools                      GCC(1)
  1391.  
  1392.  
  1393.  
  1394.           warning.
  1395.  
  1396. DEBUGGING OPTIONS
  1397.      GNU CC has various special options that are used for  debug-
  1398.      ging either your program or GCC:
  1399.  
  1400.      -g   Produce debugging information in the operating system's
  1401.           native  format (stabs, COFF, XCOFF, or DWARF).  GDB can
  1402.           work with this debugging information.
  1403.  
  1404.           On most systems that use stabs format, `-g' enables use
  1405.           of  extra  debugging information that only GDB can use;
  1406.           this extra information makes debugging work  better  in
  1407.           GDB but will probably make other debuggers crash or re-
  1408.           fuse to read the program.  If you want to  control  for
  1409.           certain  whether to generate the extra information, use
  1410.           `-gstabs+',    `-gstabs',    `-gxcoff+',     `-gxcoff',
  1411.           `-gdwarf+', or `-gdwarf' (see below).
  1412.  
  1413.           Unlike most other C compilers, GNU CC allows you to use
  1414.           `-g'  with `-O'.  The shortcuts taken by optimized code
  1415.           may occasionally produce surprising results: some vari-
  1416.           ables  you  declared may not exist at all; flow of con-
  1417.           trol may briefly move where you did not expect it; some
  1418.           statements  may  not  be  executed because they compute
  1419.           constant results or their values were already at  hand;
  1420.           some statements may execute in different places because
  1421.           they were moved out of loops.
  1422.  
  1423.           Nevertheless it proves possible to debug optimized out-
  1424.           put.  This makes it reasonable to use the optimizer for
  1425.           programs that might have bugs.
  1426.  
  1427.      The following options are useful when GNU  CC  is  generated
  1428.      with the capability for more than one debugging format.
  1429.  
  1430.      -ggdb
  1431.           Produce debugging information in the native format  (if
  1432.           that  is supported), including GDB extensions if at all
  1433.           possible.
  1434.  
  1435.      -gstabs
  1436.           Produce debugging information in stabs format (if  that
  1437.           is  supported),  without  GDB  extensions.  This is the
  1438.           format used by DBX on most BSD systems.
  1439.  
  1440.      -gstabs+
  1441.           Produce debugging information in stabs format (if  that
  1442.           is  supported), using GNU extensions understood only by
  1443.           the GNU debugger (GDB).  The use of these extensions is
  1444.           likely  to make other debuggers crash or refuse to read
  1445.           the program.
  1446.  
  1447.  
  1448.  
  1449. GNU Tools            Last change: 1993/10/13                   22
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455.  
  1456. GCC(1)                      GNU Tools                      GCC(1)
  1457.  
  1458.  
  1459.  
  1460.      -gcoff
  1461.           Produce debugging information in COFF format  (if  that
  1462.           is  supported).  This is the format used by SDB on most
  1463.           System V systems prior to System V Release 4.
  1464.  
  1465.      -gxcoff
  1466.           Produce debugging information in XCOFF format (if  that
  1467.           is  supported).  This is the format used by the DBX de-
  1468.           bugger on IBM RS/6000 systems.
  1469.  
  1470.      -gxcoff+
  1471.           Produce debugging information in XCOFF format (if  that
  1472.           is  supported), using GNU extensions understood only by
  1473.           the GNU debugger (GDB).  The use of these extensions is
  1474.           likely  to make other debuggers crash or refuse to read
  1475.           the program.
  1476.  
  1477.      -gdwarf
  1478.           Produce debugging information in DWARF format (if  that
  1479.           is  supported).  This is the format used by SDB on most
  1480.           System V Release 4 systems.
  1481.  
  1482.      -gdwarf+
  1483.           Produce debugging information in DWARF format (if  that
  1484.           is  supported), using GNU extensions understood only by
  1485.           the GNU debugger (GDB).  The use of these extensions is
  1486.           likely  to make other debuggers crash or refuse to read
  1487.           the program.
  1488.  
  1489.      -g_l_e_v_e_l
  1490.      -ggdb_l_e_v_e_l
  1491.      -gstabs_l_e_v_e_l
  1492.      -gcoff_l_e_v_e_l -gxcoff_l_e_v_e_l
  1493.  
  1494.      -gdwarf_l_e_v_e_l
  1495.           Request debugging information and  also  use  _l_e_v_e_l  to
  1496.           specify how much information.  The default level is 2.
  1497.  
  1498.           Level 1 produces minimal information, enough for making
  1499.           backtraces  in parts of the program that you don't plan
  1500.           to debug.  This includes descriptions of functions  and
  1501.           external  variables,  but  no  information  about local
  1502.           variables and no line numbers.
  1503.  
  1504.           Level 3 includes extra information,  such  as  all  the
  1505.           macro  definitions  present  in  the program.  Some de-
  1506.           buggers support macro expansion when you use `-g3'.
  1507.  
  1508.      -p   Generate extra code to write profile information  suit-
  1509.           able for the analysis program prof.
  1510.  
  1511.      -pg  Generate extra code to write profile information  suit-
  1512.  
  1513.  
  1514.  
  1515. GNU Tools            Last change: 1993/10/13                   23
  1516.  
  1517.  
  1518.  
  1519.  
  1520.  
  1521.  
  1522. GCC(1)                      GNU Tools                      GCC(1)
  1523.  
  1524.  
  1525.  
  1526.           able for the analysis program gprof.
  1527.  
  1528.      -a   Generate extra code to write  profile  information  for
  1529.           basic  blocks,  which  will  record the number of times
  1530.           each basic block  is  executed.   This  data  could  be
  1531.           analyzed  by  a program like tcov.  Note, however, that
  1532.           the format of the data is not what tcov expects.  Even-
  1533.           tually  GNU  gprof  should  be extended to process this
  1534.           data.
  1535.  
  1536.      -d_l_e_t_t_e_r_s
  1537.           Says to make  debugging  dumps  during  compilation  at
  1538.           times specified by _l_e_t_t_e_r_s.  This is used for debugging
  1539.           the compiler.  The file names for most of the dumps are
  1540.           made  by appending a word to the source file name (e.g.
  1541.           `foo.c.rtl' or `foo.c.jump').
  1542.  
  1543.      -dM  Dump all macro definitions, at the end  of  preprocess-
  1544.           ing, and write no output.
  1545.  
  1546.      -dN  Dump all macro names, at the end of preprocessing.
  1547.  
  1548.      -dD  Dump all macro definitions, at the end  of  preprocess-
  1549.           ing, in addition to normal output.
  1550.  
  1551.      -dy  Dump debugging information during parsing, to  standard
  1552.           error.
  1553.  
  1554.      -dr  Dump after RTL generation, to `_f_i_l_e.rtl'.
  1555.  
  1556.      -dx  Just generate RTL for a function instead  of  compiling
  1557.           it.  Usually used with `r'.
  1558.  
  1559.      -dj  Dump after first jump optimization, to `_f_i_l_e.jump'.
  1560.  
  1561.      -ds  Dump after CSE (including the  jump  optimization  that
  1562.           sometimes follows CSE), to `_f_i_l_e.cse'.
  1563.  
  1564.      -dL  Dump after loop optimization, to `_f_i_l_e.loop'.
  1565.  
  1566.      -dt  Dump after the second CSE pass (including the jump  op-
  1567.           timization that sometimes follows CSE), to `_f_i_l_e.cse2'.
  1568.  
  1569.      -df  Dump after flow analysis, to `_f_i_l_e.flow'.
  1570.  
  1571.      -dc  Dump after instruction combination, to `_f_i_l_e.combine'.
  1572.  
  1573.      -dS  Dump after the first instruction  scheduling  pass,  to
  1574.           `_f_i_l_e.sched'.
  1575.  
  1576.      -dl  Dump after local register allocation, to `_f_i_l_e.lreg'.
  1577.  
  1578.  
  1579.  
  1580.  
  1581. GNU Tools            Last change: 1993/10/13                   24
  1582.  
  1583.  
  1584.  
  1585.  
  1586.  
  1587.  
  1588. GCC(1)                      GNU Tools                      GCC(1)
  1589.  
  1590.  
  1591.  
  1592.      -dg  Dump after global register allocation, to `_f_i_l_e.greg'.
  1593.  
  1594.      -dR  Dump after the second instruction scheduling  pass,  to
  1595.           `_f_i_l_e.sched2'.
  1596.  
  1597.      -dJ  Dump after last jump optimization, to `_f_i_l_e.jump2'.
  1598.  
  1599.      -dd  Dump after delayed branch scheduling, to `_f_i_l_e.dbr'.
  1600.  
  1601.      -dk  Dump after  conversion  from  registers  to  stack,  to
  1602.           `_f_i_l_e.stack'.
  1603.  
  1604.      -da  Produce all the dumps listed above.
  1605.  
  1606.      -dm  Print statistics on memory usage, at  the  end  of  the
  1607.           run, to standard error.
  1608.  
  1609.      -dp  Annotate the assembler output with a comment indicating
  1610.           which pattern and alternative was used.
  1611.  
  1612.      -fpretend-float
  1613.           When running a cross-compiler, pretend that the  target
  1614.           machine uses the same floating point format as the host
  1615.           machine.  This causes incorrect output  of  the  actual
  1616.           floating constants, but the actual instruction sequence
  1617.           will probably be the same as GNU  CC  would  make  when
  1618.           running on the target machine.
  1619.  
  1620.      -save-temps
  1621.           Store the usual  "temporary"  intermediate  files  per-
  1622.           manently;  place them in the current directory and name
  1623.           them based on the source file.  Thus, compiling `foo.c'
  1624.           with `-c -save-temps' would produce files `foo.cpp' and
  1625.           `foo.s', as well as `foo.o'.
  1626.  
  1627.      -print-libgcc-file-name
  1628.           Print the  full  absolute  name  of  the  library  file
  1629.           `libgcc.a'  that  would be used when linking-and do not
  1630.           do anything else.  With this option, GNU  CC  does  not
  1631.           compile or link anything; it just prints the file name.
  1632.  
  1633. OPTIMIZATION OPTIONS
  1634.      These options control various sorts of optimizations:
  1635.  
  1636.      -O
  1637.  
  1638.      -O1  Optimize.  Optimizing compilation takes  somewhat  more
  1639.           time, and a lot more memory for a large function.
  1640.  
  1641.           Without `-O', the compiler's goal is to reduce the cost
  1642.           of  compilation  and  to make debugging produce the ex-
  1643.           pected results.  Statements  are  independent:  if  you
  1644.  
  1645.  
  1646.  
  1647. GNU Tools            Last change: 1993/10/13                   25
  1648.  
  1649.  
  1650.  
  1651.  
  1652.  
  1653.  
  1654. GCC(1)                      GNU Tools                      GCC(1)
  1655.  
  1656.  
  1657.  
  1658.           stop  the program with a breakpoint between statements,
  1659.           you can then assign a new  value  to  any  variable  or
  1660.           change  the  program  counter to any other statement in
  1661.           the function and get exactly the results you would  ex-
  1662.           pect from the source code.
  1663.  
  1664.           Without `-O', only variables declared register are  al-
  1665.           located in registers.  The resulting compiled code is a
  1666.           little worse than produced by PCC without `-O'.
  1667.  
  1668.           With `-O', the compiler tries to reduce code  size  and
  1669.           execution time.
  1670.  
  1671.           When   you   specify   `-O',    `-fthread-jumps'    and
  1672.           `-fdelayed-branch'  are  turned  on.   On some machines
  1673.           other flags may also be turned on.
  1674.  
  1675.      -O2  Optimize even more.  Nearly all supported optimizations
  1676.           that  do  not  involve  a space-speed tradeoff are per-
  1677.           formed.  As compared to -O, this option increases  both
  1678.           compilation  time  and the performance of the generated
  1679.           code.
  1680.  
  1681.           -O2 turns on all -f_f_l_a_g options that enable more optim-
  1682.           ization,  except for -funroll-loops, -funroll-all-loops
  1683.           and -fomit-frame-pointer.
  1684.  
  1685.      -O0  Do not optimize.
  1686.  
  1687.           If you use multiple -O options, with or  without  level
  1688.           numbers, the last such option is the one that is effec-
  1689.           tive.
  1690.  
  1691.      Options of the  form  `-f_f_l_a_g'  specify  machine-independent
  1692.      flags.   Most  flags  have both positive and negative forms;
  1693.      the negative form of `-ffoo' would be `-fno-foo'.  The  fol-
  1694.      lowing list shows only one form-the one which is not the de-
  1695.      fault.  You can figure out the other form by either removing
  1696.      `no-' or adding it.
  1697.  
  1698.      -ffloat-store
  1699.           Do not store floating  point  variables  in  registers.
  1700.           This  prevents undesirable excess precision on machines
  1701.           such as the 68000 where the floating registers (of  the
  1702.           68881) keep more precision than a double is supposed to
  1703.           have.
  1704.  
  1705.           For most programs, the excess precision does only good,
  1706.           but  a  few  programs rely on the precise definition of
  1707.           IEEE floating point.  Use `-ffloat-store' for such pro-
  1708.           grams.
  1709.  
  1710.  
  1711.  
  1712.  
  1713. GNU Tools            Last change: 1993/10/13                   26
  1714.  
  1715.  
  1716.  
  1717.  
  1718.  
  1719.  
  1720. GCC(1)                      GNU Tools                      GCC(1)
  1721.  
  1722.  
  1723.  
  1724.      -fmemoize-lookups
  1725.  
  1726.      -fsave-memoized
  1727.           Use heuristics to compile  faster  (C++  only).   These
  1728.           heuristics  are  not enabled by default, since they are
  1729.           only effective for certain input  files.   Other  input
  1730.           files compile more slowly.
  1731.  
  1732.           The first time the compiler must  build  a  call  to  a
  1733.           member  function  (or  reference  to a data member), it
  1734.           must (1) determine whether the class implements  member
  1735.           functions  of that name; (2) resolve which member func-
  1736.           tion to call (which involves figuring out what sorts of
  1737.           type  conversions  need  to be made); and (3) check the
  1738.           visibility of the member function to the  caller.   All
  1739.           of  this  adds up to slower compilation.  Normally, the
  1740.           second time a call is made to that member function  (or
  1741.           reference  to that data member), it must go through the
  1742.           same lengthy process again.  This means that code  like
  1743.           this
  1744.  
  1745.             cout << "This " << p << " has " << n << " legs.\n";
  1746.  
  1747.           makes six passes through all three steps.  By  using  a
  1748.           software  cache,  a  "hit"  significantly  reduces this
  1749.           cost.  Unfortunately, using the cache introduces anoth-
  1750.           er  layer  of mechanisms which must be implemented, and
  1751.           so incurs its own  overhead.   `-fmemoize-lookups'  en-
  1752.           ables the software cache.
  1753.  
  1754.           Because access privileges (visibility) to  members  and
  1755.           member  functions  may differ from one function context
  1756.           to the next, g++ may need to flush the cache.  With the
  1757.           `-fmemoize-lookups'  flag,  the  cache is flushed after
  1758.           every function that is compiled.  The `-fsave-memoized'
  1759.           flag enables the same software cache, but when the com-
  1760.           piler determines that the context of the last  function
  1761.           compiled  would yield the same access privileges of the
  1762.           next function to compile, it preserves the cache.  This
  1763.           is most helpful when defining many member functions for
  1764.           the same class: with the exception of member  functions
  1765.           which  are  friends of other classes, each member func-
  1766.           tion has exactly the same access  privileges  as  every
  1767.           other, and the cache need not be flushed.
  1768.  
  1769.      -fno-default-inline
  1770.           Don't make member functions inline  by  default  merely
  1771.           because  they  are  defined inside the class scope (C++
  1772.           only).
  1773.  
  1774.      -fno-defer-pop
  1775.           Always pop the arguments to each function call as  soon
  1776.  
  1777.  
  1778.  
  1779. GNU Tools            Last change: 1993/10/13                   27
  1780.  
  1781.  
  1782.  
  1783.  
  1784.  
  1785.  
  1786. GCC(1)                      GNU Tools                      GCC(1)
  1787.  
  1788.  
  1789.  
  1790.           as  that function returns.  For machines which must pop
  1791.           arguments after a function call, the compiler  normally
  1792.           lets  arguments  accumulate  on  the  stack for several
  1793.           function calls and pops them all at once.
  1794.  
  1795.      -fforce-mem
  1796.           Force memory operands to be copied into  registers  be-
  1797.           fore doing arithmetic on them.  This may produce better
  1798.           code by making all memory references  potential  common
  1799.           subexpressions.   When  they  are not common subexpres-
  1800.           sions, instruction  combination  should  eliminate  the
  1801.           separate  register-load.   I  am  interested in hearing
  1802.           about the difference this makes.
  1803.  
  1804.      -fforce-addr
  1805.           Force memory address constants to be copied into regis-
  1806.           ters before doing arithmetic on them.  This may produce
  1807.           better code just as `-fforce-mem' may.  I am interested
  1808.           in hearing about the difference this makes.
  1809.  
  1810.      -fomit-frame-pointer
  1811.           Don't keep the frame pointer in a  register  for  func-
  1812.           tions  that  don't  need one.  This avoids the instruc-
  1813.           tions to save, set up and restore  frame  pointers;  it
  1814.           also  makes  an  extra register available in many func-
  1815.           tions.  _I_t _a_l_s_o  _m_a_k_e_s  _d_e_b_u_g_g_i_n_g  _i_m_p_o_s_s_i_b_l_e  _o_n  most
  1816.           machines.
  1817.  
  1818.           On some machines, such as the Vax, this flag has no ef-
  1819.           fect,  because  the standard calling sequence automati-
  1820.           cally handles the frame pointer and nothing is saved by
  1821.           pretending  it  doesn't exist.  The machine-description
  1822.           macro FRAME_POINTER_REQUIRED controls whether a  target
  1823.           machine supports this flag.
  1824.  
  1825.      -finline-functions
  1826.           Integrate all simple functions into their callers.  The
  1827.           compiler heuristically decides which functions are sim-
  1828.           ple enough to be worth integrating in this way.
  1829.  
  1830.           If all calls to a given function  are  integrated,  and
  1831.           the function is declared static, then GCC normally does
  1832.           not output the function as assembler code  in  its  own
  1833.           right.
  1834.  
  1835.      -fcaller-saves
  1836.           Enable values to be allocated in registers that will be
  1837.           clobbered by function calls, by emitting extra instruc-
  1838.           tions to save and restore  the  registers  around  such
  1839.           calls.   Such  allocation is done only when it seems to
  1840.           result in better code than would otherwise be produced.
  1841.  
  1842.  
  1843.  
  1844.  
  1845. GNU Tools            Last change: 1993/10/13                   28
  1846.  
  1847.  
  1848.  
  1849.  
  1850.  
  1851.  
  1852. GCC(1)                      GNU Tools                      GCC(1)
  1853.  
  1854.  
  1855.  
  1856.           This option is enabled by default on certain  machines,
  1857.           usually those which have no call-preserved registers to
  1858.           use instead.
  1859.  
  1860.      -fkeep-inline-functions
  1861.           Even if all calls to a given function  are  integrated,
  1862.           and  the function is declared static, nevertheless out-
  1863.           put a separate run-time callable version of  the  func-
  1864.           tion.
  1865.  
  1866.      -fno-function-cse
  1867.           Do not put function addresses in registers;  make  each
  1868.           instruction  that calls a constant function contain the
  1869.           function's address explicitly.
  1870.  
  1871.           This option results in less efficient  code,  but  some
  1872.           strange  hacks  that  alter the assembler output may be
  1873.           confused by the optimizations performed when  this  op-
  1874.           tion is not used.
  1875.  
  1876.      -fno-peephole
  1877.           Disable any machine-specific peephole optimizations.
  1878.  
  1879.      -ffast-math
  1880.           This option allows GCC to violate  some  ANSI  or  IEEE
  1881.           rules/specifications in the interest of optimizing code
  1882.           for speed.  For example, it allows the compiler to  as-
  1883.           sume  arguments  to  the sqrt function are non-negative
  1884.           numbers.
  1885.  
  1886.           This option should never be turned on by any  `-O'  op-
  1887.           tion  since  it can result in incorrect output for pro-
  1888.           grams which depend on an exact implementation  of  IEEE
  1889.           or ANSI rules/specifications for math functions.
  1890.  
  1891.      The following options control specific  optimizations.   The
  1892.      `-O2'  option  turns  on  all  of these optimizations except
  1893.      `-funroll-loops' and `-funroll-all-loops'.
  1894.  
  1895.      The `-O' option usually turns on  the  `-fthread-jumps'  and
  1896.      `-fdelayed-branch' options, but specific machines may change
  1897.      the default optimizations.
  1898.  
  1899.      You can use the following  flags  in  the  rare  cases  when
  1900.      "fine-tuning" of optimizations to be performed is desired.
  1901.  
  1902.      -fstrength-reduce
  1903.           Perform the optimizations of  loop  strength  reduction
  1904.           and elimination of iteration variables.
  1905.  
  1906.      -fthread-jumps
  1907.           Perform optimizations where we check to see if  a  jump
  1908.  
  1909.  
  1910.  
  1911. GNU Tools            Last change: 1993/10/13                   29
  1912.  
  1913.  
  1914.  
  1915.  
  1916.  
  1917.  
  1918. GCC(1)                      GNU Tools                      GCC(1)
  1919.  
  1920.  
  1921.  
  1922.           branches  to  a  location where another comparison sub-
  1923.           sumed by the first is found.  If so, the  first  branch
  1924.           is  redirected  to either the destination of the second
  1925.           branch or a point immediately following  it,  depending
  1926.           on whether the condition is known to be true or false.
  1927.  
  1928.      -funroll-loops
  1929.           Perform the optimization of loop  unrolling.   This  is
  1930.           only  done  for loops whose number of iterations can be
  1931.           determined at compile time or run time.
  1932.  
  1933.      -funroll-all-loops
  1934.           Perform the optimization of loop  unrolling.   This  is
  1935.           done  for  all  loops.  This usually makes programs run
  1936.           more slowly.
  1937.  
  1938.      -fcse-follow-jumps
  1939.           In common subexpression elimination, scan through  jump
  1940.           instructions when the target of the jump is not reached
  1941.           by any other path.  For example, when CSE encounters an
  1942.           if  statement  with an else clause, CSE will follow the
  1943.           jump when the condition tested is false.
  1944.  
  1945.      -fcse-skip-blocks
  1946.           This is similar to `-fcse-follow-jumps', but causes CSE
  1947.           to  follow  jumps which conditionally skip over blocks.
  1948.           When CSE encounters a simple if statement with no  else
  1949.           clause,  `-fcse-skip-blocks'  causes  CSE to follow the
  1950.           jump around the body of the if.
  1951.  
  1952.      -frerun-cse-after-loop
  1953.           Re-run common subexpression elimination after loop  op-
  1954.           timizations has been performed.
  1955.  
  1956.      -felide-constructors
  1957.           Elide  constructors  when  this  seems  plausible  (C++
  1958.           only).   With this flag, GNU C++ initializes y directly
  1959.           from the call to foo without going through a  temporary
  1960.           in the following code:
  1961.  
  1962.           A foo (); A y = foo ();
  1963.  
  1964.           Without this option, GNU C++  first  initializes  y  by
  1965.           calling  the  appropriate  constructor for type A; then
  1966.           assigns the result of foo to a temporary; and, finally,
  1967.           replaces the initial valyue of `y' with the temporary.
  1968.  
  1969.           The  default  behavior  (`-fno-elide-constructors')  is
  1970.           specified  by  the  draft  ANSI  C++ standard.  If your
  1971.           program's  constructors  have   side   effects,   using
  1972.           `-felide-constructors'  can  make your program act dif-
  1973.           ferently, since some constructor calls may be omitted.
  1974.  
  1975.  
  1976.  
  1977. GNU Tools            Last change: 1993/10/13                   30
  1978.  
  1979.  
  1980.  
  1981.  
  1982.  
  1983.  
  1984. GCC(1)                      GNU Tools                      GCC(1)
  1985.  
  1986.  
  1987.  
  1988.      -fexpensive-optimizations
  1989.           Perform a number of minor optimizations that are  rela-
  1990.           tively expensive.
  1991.  
  1992.      -fdelayed-branch
  1993.           If supported for the target machine, attempt to reorder
  1994.           instructions  to  exploit  instruction  slots available
  1995.           after delayed branch instructions.
  1996.  
  1997.      -fschedule-insns
  1998.           If supported for the target machine, attempt to reorder
  1999.           instructions  to  eliminate execution stalls due to re-
  2000.           quired data being  unavailable.   This  helps  machines
  2001.           that  have  slow floating point or memory load instruc-
  2002.           tions by allowing other instructions to be issued until
  2003.           the result of the load or floating point instruction is
  2004.           required.
  2005.  
  2006.      -fschedule-insns2
  2007.           Similar to `-fschedule-insns', but  requests  an  addi-
  2008.           tional  pass  of  instruction scheduling after register
  2009.           allocation has been done.  This is especially useful on
  2010.           machines  with  a  relatively small number of registers
  2011.           and where memory load instructions take more  than  one
  2012.           cycle.
  2013.  
  2014. TARGET OPTIONS
  2015.      By default, GNU CC  compiles  code  for  the  same  type  of
  2016.      machine  that  you  are  using.  However, it can also be in-
  2017.      stalled as a cross-compiler, to compile for some other  type
  2018.      of  machine.   In  fact, several different configurations of
  2019.      GNU CC, for different target machines, can be installed side
  2020.      by  side.   Then  you specify which one to use with the `-b'
  2021.      option.
  2022.  
  2023.      In addition, older and newer versions of GNU CC can  be  in-
  2024.      stalled  side  by  side.   One of them (probably the newest)
  2025.      will be the default, but  you  may  sometimes  wish  to  use
  2026.      another.
  2027.  
  2028.      -b _m_a_c_h_i_n_e
  2029.           The argument _m_a_c_h_i_n_e specifies the target  machine  for
  2030.           compilation.   This  is  useful when you have installed
  2031.           GNU CC as a cross-compiler.
  2032.  
  2033.           The value to use for _m_a_c_h_i_n_e is the same as was  speci-
  2034.           fied  as  the machine type when configuring GNU CC as a
  2035.           cross-compiler.  For example, if a  cross-compiler  was
  2036.           configured  with  `configure i386v', meaning to compile
  2037.           for an 80386 running System V, then you  would  specify
  2038.           `-b i386v' to run that cross compiler.
  2039.  
  2040.  
  2041.  
  2042.  
  2043. GNU Tools            Last change: 1993/10/13                   31
  2044.  
  2045.  
  2046.  
  2047.  
  2048.  
  2049.  
  2050. GCC(1)                      GNU Tools                      GCC(1)
  2051.  
  2052.  
  2053.  
  2054.           When you do not specify `-b', it normally means to com-
  2055.           pile for the same type of machine that you are using.
  2056.  
  2057.      -V _v_e_r_s_i_o_n
  2058.           The argument _v_e_r_s_i_o_n specifies which version of GNU  CC
  2059.           to  run.  This is useful when multiple versions are in-
  2060.           stalled.  For example, _v_e_r_s_i_o_n might be `2.0',  meaning
  2061.           to run GNU CC version 2.0.
  2062.  
  2063.           The default version, when you do not specify  `-V',  is
  2064.           controlled  by  the way GNU CC is installed.  Normally,
  2065.           it will be a version that is  recommended  for  general
  2066.           use.
  2067.  
  2068. MACHINE DEPENDENT OPTIONS
  2069.      Each of the target machine types can have  its  own  special
  2070.      options,   starting  with  `-m',  to  choose  among  various
  2071.      hardware models  or  configurations-for  example,  68010  vs
  2072.      68020,  floating  coprocessor  or  none.  A single installed
  2073.      version of the compiler can compile for any model or  confi-
  2074.      guration, according to the options specified.
  2075.  
  2076.      Some configurations of the compiler also support  additional
  2077.      special options, usually for command-line compatibility with
  2078.      other compilers on the same platform.
  2079.  
  2080.      These are the `-m' options defined for the 68000 series:
  2081.  
  2082.      -m68000
  2083.  
  2084.      -mc68000
  2085.           Generate output for a 68000.  This is the default  when
  2086.           the compiler is configured for 68000-based systems.
  2087.  
  2088.      -m68020
  2089.  
  2090.      -mc68020
  2091.           Generate output for a  68020  (rather  than  a  68000).
  2092.           This is the default when the compiler is configured for
  2093.           68020-based systems.
  2094.  
  2095.      -m68881
  2096.           Generate  output  containing  68881  instructions   for
  2097.           floating  point.   This  is the default for most 68020-
  2098.           based systems unless -nfp was specified when  the  com-
  2099.           piler was configured.
  2100.  
  2101.      -m68030
  2102.           Generate output for a 68030.  This is the default  when
  2103.           the compiler is configured for 68030-based systems.
  2104.  
  2105.      -m68040
  2106.  
  2107.  
  2108.  
  2109. GNU Tools            Last change: 1993/10/13                   32
  2110.  
  2111.  
  2112.  
  2113.  
  2114.  
  2115.  
  2116. GCC(1)                      GNU Tools                      GCC(1)
  2117.  
  2118.  
  2119.  
  2120.           Generate output for a 68040.  This is the default  when
  2121.           the compiler is configured for 68040-based systems.
  2122.  
  2123.      -m68020-40
  2124.           Generate output for a 68040, without using any  of  the
  2125.           new  instructions.   This results in code which can run
  2126.           relatively efficiently on either  a  68020/68881  or  a
  2127.           68030 or a 68040.
  2128.  
  2129.      -mfpa
  2130.           Generate output containing  Sun  FPA  instructions  for
  2131.           floating point.
  2132.  
  2133.      -msoft-float
  2134.           Generate output containing library calls  for  floating
  2135.           point.   _W_A_R_N_I_N_G:  the requisite libraries are not part
  2136.           of GNU CC.  Normally the facilities  of  the  machine's
  2137.           usual  C  compiler  are  used,  but  this can't be done
  2138.           directly in cross-compilation.  You must make your  own
  2139.           arrangements  to provide suitable library functions for
  2140.           cross-compilation.
  2141.  
  2142.      -mshort
  2143.           Consider type int to be 16 bits wide, like short int.
  2144.  
  2145.      -mnobitfield
  2146.           Do not use the bit-field instructions.   `-m68000'  im-
  2147.           plies `-mnobitfield'.
  2148.  
  2149.      -mbitfield
  2150.           Do use the bit-field instructions.   `-m68020'  implies
  2151.           `-mbitfield'.  This is the default if you use the unmo-
  2152.           dified sources.
  2153.  
  2154.      -mrtd
  2155.           Use a different function-calling convention,  in  which
  2156.           functions  that take a fixed number of arguments return
  2157.           with the rtd instruction, which  pops  their  arguments
  2158.           while  returning.   This  saves  one instruction in the
  2159.           caller since there is no  need  to  pop  the  arguments
  2160.           there.
  2161.  
  2162.           This calling convention is incompatible  with  the  one
  2163.           normally used on Unix, so you cannot use it if you need
  2164.           to call libraries compiled with the Unix compiler.
  2165.  
  2166.           Also, you must  provide  function  prototypes  for  all
  2167.           functions  that take variable numbers of arguments (in-
  2168.           cluding printf); otherwise incorrect code will be  gen-
  2169.           erated for calls to those functions.
  2170.  
  2171.           In addition, seriously incorrect code  will  result  if
  2172.  
  2173.  
  2174.  
  2175. GNU Tools            Last change: 1993/10/13                   33
  2176.  
  2177.  
  2178.  
  2179.  
  2180.  
  2181.  
  2182. GCC(1)                      GNU Tools                      GCC(1)
  2183.  
  2184.  
  2185.  
  2186.           you  call a function with too many arguments.  (Normal-
  2187.           ly, extra arguments are harmlessly ignored.)
  2188.  
  2189.           The rtd instruction is supported by the 68010 and 68020
  2190.           processors, but not by the 68000.
  2191.  
  2192.      These `-m' options are defined for the Vax:
  2193.  
  2194.      -munix
  2195.           Do not output certain jump instructions (aobleq and  so
  2196.           on)  that  the Unix assembler for the Vax cannot handle
  2197.           across long ranges.
  2198.  
  2199.      -mgnu
  2200.           Do output those jump instructions,  on  the  assumption
  2201.           that you will assemble with the GNU assembler.
  2202.  
  2203.      -mg  Output code for g-format floating point numbers instead
  2204.           of d-format.
  2205.  
  2206.      These `-m' switches are supported on the SPARC:
  2207.  
  2208.      -mfpu
  2209.  
  2210.      -mhard-float
  2211.           Generate output containing floating point instructions.
  2212.           This is the default.
  2213.  
  2214.      -mno-fpu
  2215.  
  2216.      -msoft-float
  2217.           Generate output containing library calls  for  floating
  2218.           point.  _W_a_r_n_i_n_g: there is no GNU floating-point library
  2219.           for SPARC.  Normally the facilities  of  the  machine's
  2220.           usual  C  compiler  are  used,  but this cannot be done
  2221.           directly in cross-compilation.  You must make your  own
  2222.           arrangements  to provide suitable library functions for
  2223.           cross-compilation.
  2224.  
  2225.           -msoft-float changes the calling convention in the out-
  2226.           put  file;  therefore, it is only useful if you compile
  2227.           _a_l_l of a program with this option.
  2228.  
  2229.      -mno-epilogue
  2230.  
  2231.      -mepilogue
  2232.           With -mepilogue (the default), the compiler always  em-
  2233.           its code for function exit at the end of each function.
  2234.           Any function exit in the middle of the  function  (such
  2235.           as a return statement in C) will generate a jump to the
  2236.           exit code at the end of the function.
  2237.  
  2238.  
  2239.  
  2240.  
  2241. GNU Tools            Last change: 1993/10/13                   34
  2242.  
  2243.  
  2244.  
  2245.  
  2246.  
  2247.  
  2248. GCC(1)                      GNU Tools                      GCC(1)
  2249.  
  2250.  
  2251.  
  2252.           With -mno-epilogue, the compiler  tries  to  emit  exit
  2253.           code inline at every function exit.
  2254.  
  2255.      -mv8
  2256.  
  2257.      -msparclite
  2258.           These two options select variations on the SPARC archi-
  2259.           tecture.
  2260.  
  2261.           By default  (unless  specifically  configured  for  the
  2262.           Fujitsu SPARClite), GCC generates code for the v7 vari-
  2263.           ant of the SPARC architecture.
  2264.  
  2265.           -mv8 will give you SPARC v8 code.  The only  difference
  2266.           from  v7  code  is  that the compiler emits the integer
  2267.           multiply and integer divide instructions which exist in
  2268.           SPARC v8 but not in SPARC v7.
  2269.  
  2270.           -msparclite will give you SPARClite  code.   This  adds
  2271.           the  integer  multiply,  integer  divide  step and scan
  2272.           (ffs) instructions which exist in SPARClite but not  in
  2273.           SPARC v7.
  2274.  
  2275.      These `-m' options are defined for the Convex:
  2276.  
  2277.      -mc1 Generate output for a C1.  This is the default when the
  2278.           compiler is configured for a C1.
  2279.  
  2280.      -mc2 Generate output for a C2.  This is the default when the
  2281.           compiler is configured for a C2.
  2282.  
  2283.      -margcount
  2284.           Generate code which puts an argument count in the  word
  2285.           preceding  each argument list.  Some nonportable Convex
  2286.           and Vax programs need this word.  (Debuggers don't, ex-
  2287.           cept for functions with variable-length argument lists;
  2288.           this info is in the symbol table.)
  2289.  
  2290.      -mnoargcount
  2291.           Omit the argument count word.  This is the  default  if
  2292.           you use the unmodified sources.
  2293.  
  2294.      These `-m' options are defined for the AMD Am29000:
  2295.  
  2296.      -mdw Generate code that assumes the DW  bit  is  set,  i.e.,
  2297.           that byte and halfword operations are directly support-
  2298.           ed by the hardware.  This is the default.
  2299.  
  2300.      -mnodw
  2301.           Generate code that assumes the DW bit is not set.
  2302.  
  2303.      -mbw Generate code that assumes the system supports byte and
  2304.  
  2305.  
  2306.  
  2307. GNU Tools            Last change: 1993/10/13                   35
  2308.  
  2309.  
  2310.  
  2311.  
  2312.  
  2313.  
  2314. GCC(1)                      GNU Tools                      GCC(1)
  2315.  
  2316.  
  2317.  
  2318.           halfword write operations.  This is the default.
  2319.  
  2320.      -mnbw
  2321.           Generate code that assumes the systems does not support
  2322.           byte  and  halfword  write  operations.   This  implies
  2323.           `-mnodw'.
  2324.  
  2325.      -msmall
  2326.           Use a small memory model that assumes that all function
  2327.           addresses  are either within a single 256 KB segment or
  2328.           at an absolute address of less than 256K.  This  allows
  2329.           the  call  instruction  to  be used instead of a const,
  2330.           consth, calli sequence.
  2331.  
  2332.      -mlarge
  2333.           Do not assume that the call instruction  can  be  used;
  2334.           this is the default.
  2335.  
  2336.      -m29050
  2337.           Generate code for the Am29050.
  2338.  
  2339.      -m29000
  2340.           Generate code for the Am29000.  This is the default.
  2341.  
  2342.      -mkernel-registers
  2343.           Generate references to registers gr64-gr95  instead  of
  2344.           gr96-gr127.   This  option  can  be used when compiling
  2345.           kernel code that wants a set of global  registers  dis-
  2346.           joint from that used by user-mode code.
  2347.  
  2348.           Note that when this option is used, register  names  in
  2349.           `-f' flags must use the normal, user-mode, names.
  2350.  
  2351.      -muser-registers
  2352.           Use the normal set  of  global  registers,  gr96-gr127.
  2353.           This is the default.
  2354.  
  2355.      -mstack-check
  2356.           Insert a call to __msp_check after each  stack  adjust-
  2357.           ment.  This is often used for kernel code.
  2358.  
  2359.      These `-m' options are defined for  Motorola  88K  architec-
  2360.      tures:
  2361.  
  2362.      -m88000
  2363.           Generate code that works well on both  the  m88100  and
  2364.           the m88110.
  2365.  
  2366.      -m88100
  2367.           Generate code that works best for the m88100, but  that
  2368.           also runs on the m88110.
  2369.  
  2370.  
  2371.  
  2372.  
  2373. GNU Tools            Last change: 1993/10/13                   36
  2374.  
  2375.  
  2376.  
  2377.  
  2378.  
  2379.  
  2380. GCC(1)                      GNU Tools                      GCC(1)
  2381.  
  2382.  
  2383.  
  2384.      -m88110
  2385.           Generate code that works best for the m88110,  and  may
  2386.           not run on the m88100.
  2387.  
  2388.      -midentify-revision
  2389.           Include an ident  directive  in  the  assembler  output
  2390.           recording  the source file name, compiler name and ver-
  2391.           sion, timestamp, and compilation flags used.
  2392.  
  2393.      -mno-underscores
  2394.           In assembler output, emit symbol names  without  adding
  2395.           an  underscore character at the beginning of each name.
  2396.           The default is to use an underscore as prefix  on  each
  2397.           name.
  2398.  
  2399.      -mno-check-zero-division
  2400.  
  2401.      -mcheck-zero-division
  2402.           Early models of the 88K architecture had problems  with
  2403.           division  by  zero;  in particular, many of them didn't
  2404.           trap.  Use these options to avoid including (or to  in-
  2405.           clude explicitly) additional code to detect division by
  2406.           zero and signal an exception.  All  GCC  configurations
  2407.           for the 88K use `-mcheck-zero-division' by default.
  2408.  
  2409.      -mocs-debug-info
  2410.  
  2411.      -mno-ocs-debug-info
  2412.           Include  (or  omit)  additional  debugging  information
  2413.           (about registers used in each stack frame) as specified
  2414.           in the 88Open  Object  Compatibility  Standard,  "OCS".
  2415.           This  extra  information is not needed by GDB.  The de-
  2416.           fault for DG/UX, SVr4, and Delta 88 SVr3.2  is  to  in-
  2417.           clude  this  information; other 88k configurations omit
  2418.           this information by default.
  2419.  
  2420.      -mocs-frame-position
  2421.  
  2422.      -mno-ocs-frame-position
  2423.           Force (or do not require) register values to be  stored
  2424.           in  a particular place in stack frames, as specified in
  2425.           OCS.  The DG/UX, Delta88 SVr3.2, and BCS configurations
  2426.           use  `-mocs-frame-position';  other  88k configurations
  2427.           have the default `-mno-ocs-frame-position'.
  2428.  
  2429.      -moptimize-arg-area
  2430.  
  2431.      -mno-optimize-arg-area
  2432.           Control  how  to  store  function  arguments  in  stack
  2433.           frames.   `-moptimize-arg-area'  saves  space,  but may
  2434.           break       some       debuggers       (not       GDB).
  2435.           `-mno-optimize-arg-area'  conforms better to standards.
  2436.  
  2437.  
  2438.  
  2439. GNU Tools            Last change: 1993/10/13                   37
  2440.  
  2441.  
  2442.  
  2443.  
  2444.  
  2445.  
  2446. GCC(1)                      GNU Tools                      GCC(1)
  2447.  
  2448.  
  2449.  
  2450.           By default GCC does not optimize the argument area.
  2451.  
  2452.      -mshort-data-_n_u_m
  2453.           _n_u_m Generate smaller data references by making them re-
  2454.           lative to r0, which allows loading a value using a sin-
  2455.           gle instruction (rather than the usual two).  You  con-
  2456.           trol  which  data references are affected by specifying
  2457.           _n_u_m with this option.   For  example,  if  you  specify
  2458.           `-mshort-data-512',  then  the data references affected
  2459.           are those involving  displacements  of  less  than  512
  2460.           bytes.   `-mshort-data-_n_u_m'  is  not  effective for _n_u_m
  2461.           greater than 64K.
  2462.  
  2463.      -mserialize-volatile
  2464.  
  2465.      -mno-serialize-volatile
  2466.           Do, or do not, generate code  to  guarantee  sequential
  2467.           consistency of volatile memory references.
  2468.  
  2469.           GNU CC always guarantees consistency  by  default,  for
  2470.           the  preferred  processor  submodel.   How this is done
  2471.           depends on the submodel.
  2472.  
  2473.           The m88100 processor does not reorder memory references
  2474.           and  so always provides sequential consistency.  If you
  2475.           use `-m88100', GNU CC does not generate any special in-
  2476.           structions for sequential consistency.
  2477.  
  2478.           The order of memory references made by the m88110  pro-
  2479.           cessor  does not always match the order of the instruc-
  2480.           tions requesting those references.   In  particular,  a
  2481.           load  instruction  may execute before a preceding store
  2482.           instruction.  Such reordering violates sequential  con-
  2483.           sistency  of volatile memory references, when there are
  2484.           multiple  processors.   When  you  use   `-m88000'   or
  2485.           `-m88110',  GNU  CC generates special instructions when
  2486.           appropriate, to force execution in the proper order.
  2487.  
  2488.           The extra code generated to guarantee  consistency  may
  2489.           affect  the  performance  of  your application.  If you
  2490.           know that you can safely forgo this guarantee, you  may
  2491.           use the option `-mno-serialize-volatile'.
  2492.  
  2493.           If you use the `-m88100' option but require  sequential
  2494.           consistency  when  running on the m88110 processor, you
  2495.           should use `-mserialize-volatile'.
  2496.  
  2497.      -msvr4
  2498.  
  2499.      -msvr3
  2500.           Turn on (`-msvr4') or off  (`-msvr3')  compiler  exten-
  2501.           sions  related to System V release 4 (SVr4).  This con-
  2502.  
  2503.  
  2504.  
  2505. GNU Tools            Last change: 1993/10/13                   38
  2506.  
  2507.  
  2508.  
  2509.  
  2510.  
  2511.  
  2512. GCC(1)                      GNU Tools                      GCC(1)
  2513.  
  2514.  
  2515.  
  2516.           trols the following:
  2517.  
  2518.         o+ Which variant of the assembler syntax  to  emit  (which
  2519.           you can select independently using `-mversion-03.00').
  2520.  
  2521.         o+ `-msvr4' makes the C  preprocessor  recognize  `#pragma
  2522.           weak'
  2523.  
  2524.         o+ `-msvr4' makes GCC issue additional declaration  direc-
  2525.           tives used in SVr4.
  2526.  
  2527.      `-msvr3' is the default for all m88K  configurations  except
  2528.      the SVr4 configuration.
  2529.  
  2530.      -mtrap-large-shift
  2531.  
  2532.      -mhandle-large-shift
  2533.           Include code to detect bit-shifts of more than 31 bits;
  2534.           respectively,  trap  such shifts or emit code to handle
  2535.           them properly.  By default GCC makes no special  provi-
  2536.           sion for large bit shifts.
  2537.  
  2538.      -muse-div-instruction
  2539.           Very early models of the 88K architecture didn't have a
  2540.           divide  instruction,  so GCC avoids that instruction by
  2541.           default.  Use this option to specify that it's safe  to
  2542.           use the divide instruction.
  2543.  
  2544.      -mversion-03.00
  2545.           In the DG/UX configuration, there are  two  flavors  of
  2546.           SVr4.   This  option  modifies -msvr4 to select whether
  2547.           the hybrid-COFF or real-ELF flavor is used.  All  other
  2548.           configurations ignore this option.
  2549.  
  2550.      -mwarn-passed-structs
  2551.           Warn when a function passes a struct as an argument  or
  2552.           result.   Structure-passing  conventions  have  changed
  2553.           during the evolution of the C language, and  are  often
  2554.           the  source  of  portability problems.  By default, GCC
  2555.           issues no such warning.
  2556.  
  2557.      These options are defined for the IBM RS6000:
  2558.  
  2559.      -mfp-in-toc
  2560.  
  2561.      -mno-fp-in-toc
  2562.           Control whether or not floating-point constants  go  in
  2563.           the  Table  of  Contents  (TOC),  a table of all global
  2564.           variable and function addresses.  By default  GCC  puts
  2565.           floating-point  constants  there; if the TOC overflows,
  2566.           `-mno-fp-in-toc' will reduce the size of the TOC, which
  2567.           may avoid the overflow.
  2568.  
  2569.  
  2570.  
  2571. GNU Tools            Last change: 1993/10/13                   39
  2572.  
  2573.  
  2574.  
  2575.  
  2576.  
  2577.  
  2578. GCC(1)                      GNU Tools                      GCC(1)
  2579.  
  2580.  
  2581.  
  2582.      These `-m' options are defined for the IBM RT PC:
  2583.  
  2584.      -min-line-mul
  2585.           Use an in-line code sequence  for  integer  multiplies.
  2586.           This is the default.
  2587.  
  2588.      -mcall-lib-mul
  2589.           Call lmul$$ for integer multiples.
  2590.  
  2591.      -mfull-fp-blocks
  2592.           Generate full-size floating point data blocks,  includ-
  2593.           ing  the minimum amount of scratch space recommended by
  2594.           IBM.  This is the default.
  2595.  
  2596.      -mminimum-fp-blocks
  2597.           Do not include extra scratch space  in  floating  point
  2598.           data  blocks.  This results in smaller code, but slower
  2599.           execution, since scratch space must be allocated dynam-
  2600.           ically.
  2601.  
  2602.      -mfp-arg-in-fpregs
  2603.           Use a calling sequence incompatible with the  IBM  cal-
  2604.           ling  convention  in which floating point arguments are
  2605.           passed  in  floating  point   registers.    Note   that
  2606.           varargs.h  and  stdargs.h  will  not work with floating
  2607.           point operands if this option is specified.
  2608.  
  2609.      -mfp-arg-in-gregs
  2610.           Use the normal calling convention  for  floating  point
  2611.           arguments.  This is the default.
  2612.  
  2613.      -mhc-struct-return
  2614.           Return structures of more  than  one  word  in  memory,
  2615.           rather than in a register.  This provides compatibility
  2616.           with   the   MetaWare   HighC   (hc)   compiler.    Use
  2617.           `-fpcc-struct-return'  for compatibility with the Port-
  2618.           able C Compiler (pcc).
  2619.  
  2620.      -mnohc-struct-return
  2621.           Return some structures of more than one word in  regis-
  2622.           ters,  when convenient.  This is the default.  For com-
  2623.           patibility with the IBM-supplied compilers, use  either
  2624.           `-fpcc-struct-return' or `-mhc-struct-return'.
  2625.  
  2626.      These `-m' options are defined for the MIPS family  of  com-
  2627.      puters:
  2628.  
  2629.      -mcpu=_c_p_u-_t_y_p_e
  2630.           Assume the defaults for the machine type _c_p_u-_t_y_p_e  when
  2631.           scheduling  instructions.   The default _c_p_u-_t_y_p_e is de-
  2632.           fault, which picks the longest cycles times for any  of
  2633.           the  machines, in order that the code run at reasonable
  2634.  
  2635.  
  2636.  
  2637. GNU Tools            Last change: 1993/10/13                   40
  2638.  
  2639.  
  2640.  
  2641.  
  2642.  
  2643.  
  2644. GCC(1)                      GNU Tools                      GCC(1)
  2645.  
  2646.  
  2647.  
  2648.           rates on all MIPS cpu's.  Other  choices  for  _c_p_u-_t_y_p_e
  2649.           are  r2000,  r3000,  r4000, and r6000.  While picking a
  2650.           specific _c_p_u-_t_y_p_e will  schedule  things  appropriately
  2651.           for  that  particular  chip, the compiler will not gen-
  2652.           erate any code that does not meet level 1 of  the  MIPS
  2653.           ISA  (instruction  set architecture) without the -mips2
  2654.           or -mips3 switches being used.
  2655.  
  2656.      -mips2
  2657.           Issue instructions from level 2 of the MIPS ISA (branch
  2658.           likely,  square root instructions).  The -mcpu=r4000 or
  2659.           -mcpu=r6000 switch must be  used  in  conjunction  with
  2660.           -mips2.
  2661.  
  2662.      -mips3
  2663.           Issue instructions from level 3 of the MIPS ISA (64 bit
  2664.           instructions).   The -mcpu=r4000 switch must be used in
  2665.           conjunction with -mips2.
  2666.  
  2667.      -mint64
  2668.  
  2669.      -mlong64
  2670.  
  2671.      -mlonglong128
  2672.           These options don't work at present.
  2673.  
  2674.      -mmips-as
  2675.           Generate  code  for  the  MIPS  assembler,  and  invoke
  2676.           mips-tfile  to  add  normal debug information.  This is
  2677.           the default for all  platforms  except  for  the  OSF/1
  2678.           reference  platform,  using the OSF/rose object format.
  2679.           If any of the -ggdb, -gstabs, or -gstabs+ switches  are
  2680.           used, the mips-tfile program will encapsulate the stabs
  2681.           within MIPS ECOFF.
  2682.  
  2683.      -mgas
  2684.           Generate code for the GNU assembler.  This is  the  de-
  2685.           fault  on  the  OSF/1  reference  platform,  using  the
  2686.           OSF/rose object format.
  2687.  
  2688.      -mrnames
  2689.  
  2690.      -mno-rnames
  2691.           The -mrnames switch says to output code using the  MIPS
  2692.           software  names  for  the  registers,  instead  of  the
  2693.           hardware names (ie, a0 instead of $4).  The GNU  assem-
  2694.           bler does not support the -mrnames switch, and the MIPS
  2695.           assembler will be instructed to run the MIPS C  prepro-
  2696.           cessor over the source file.  The -mno-rnames switch is
  2697.           default.
  2698.  
  2699.      -mgpopt
  2700.  
  2701.  
  2702.  
  2703. GNU Tools            Last change: 1993/10/13                   41
  2704.  
  2705.  
  2706.  
  2707.  
  2708.  
  2709.  
  2710. GCC(1)                      GNU Tools                      GCC(1)
  2711.  
  2712.  
  2713.  
  2714.      -mno-gpopt
  2715.           The -mgpopt switch says to write all of  the  data  de-
  2716.           clarations before the instructions in the text section,
  2717.           to all the MIPS assembler to generate one  word  memory
  2718.           references  instead of using two words for short global
  2719.           or static data items.  This is on by default if optimi-
  2720.           zation is selected.
  2721.  
  2722.      -mstats
  2723.  
  2724.      -mno-stats
  2725.           For each non-inline  function  processed,  the  -mstats
  2726.           switch  causes  the  compiler  to  emit one line to the
  2727.           standard error file to print statistics about the  pro-
  2728.           gram (number of registers saved, stack size, etc.).
  2729.  
  2730.      -mmemcpy
  2731.  
  2732.      -mno-memcpy
  2733.           The -mmemcpy switch makes all block moves call the  ap-
  2734.           propriate  string function (memcpy or bcopy) instead of
  2735.           possibly generating inline code.
  2736.  
  2737.      -mmips-tfile
  2738.  
  2739.      -mno-mips-tfile
  2740.           The -mno-mips-tfile  switch  causes  the  compiler  not
  2741.           postprocess  the  object  file with the mips-tfile pro-
  2742.           gram, after the MIPS assembler has generated it to  add
  2743.           debug support.  If mips-tfile is not run, then no local
  2744.           variables will be available to the debugger.  In  addi-
  2745.           tion, stage2 and stage3 objects will have the temporary
  2746.           file names passed to the assembler embedded in the  ob-
  2747.           ject file, which means the objects will not compare the
  2748.           same.
  2749.  
  2750.      -msoft-float
  2751.           Generate output containing library calls  for  floating
  2752.           point.   _W_A_R_N_I_N_G:  the requisite libraries are not part
  2753.           of GNU CC.  Normally the facilities  of  the  machine's
  2754.           usual  C  compiler  are  used,  but  this can't be done
  2755.           directly in cross-compilation.  You must make your  own
  2756.           arrangements  to provide suitable library functions for
  2757.           cross-compilation.
  2758.  
  2759.      -mhard-float
  2760.           Generate output containing floating point instructions.
  2761.           This is the default if you use the unmodified sources.
  2762.  
  2763.      -mfp64
  2764.           Assume that the FR bit in the status word  is  on,  and
  2765.           that  there are 32 64-bit floating point registers, in-
  2766.  
  2767.  
  2768.  
  2769. GNU Tools            Last change: 1993/10/13                   42
  2770.  
  2771.  
  2772.  
  2773.  
  2774.  
  2775.  
  2776. GCC(1)                      GNU Tools                      GCC(1)
  2777.  
  2778.  
  2779.  
  2780.           stead of 32 32-bit floating point registers.  You  must
  2781.           also specify the -mcpu=r4000 and -mips3 switches.
  2782.  
  2783.      -mfp32
  2784.           Assume that there are 32 32-bit floating  point  regis-
  2785.           ters.  This is the default.
  2786.  
  2787.      -mabicalls
  2788.  
  2789.      -mno-abicalls
  2790.           Emit (or do  not  emit)  the  .abicalls,  .cpload,  and
  2791.           .cprestore pseudo operations that some System V.4 ports
  2792.           use for position independent code.
  2793.  
  2794.      -mhalf-pic
  2795.  
  2796.      -mno-half-pic
  2797.           The -mhalf-pic switch says to put  pointers  to  extern
  2798.           references  into  the  data  section  and load them up,
  2799.           rather than put the references  in  the  text  section.
  2800.           This option does not work at present.  -G_n_u_m Put global
  2801.           and static items less than or equal to _n_u_m  bytes  into
  2802.           the  small  data  or bss sections instead of the normal
  2803.           data or bss section.  This allows the assembler to emit
  2804.           one  word  memory  reference  instructions based on the
  2805.           global pointer (gp or $28), instead of the  normal  two
  2806.           words  used.  By default, _n_u_m is 8 when the MIPS assem-
  2807.           bler is used, and 0 when the  GNU  assembler  is  used.
  2808.           The  -G_n_u_m  switch  is also passed to the assembler and
  2809.           linker.  All modules should be compiled with  the  same
  2810.           -G_n_u_m value.
  2811.  
  2812.      -nocpp
  2813.           Tell the MIPS assembler to not  run  it's  preprocessor
  2814.           over user assembler files (with a `.s' suffix) when as-
  2815.           sembling them.
  2816.  
  2817.      These `-m' options are defined for the Intel 80386 family of
  2818.      computers: -m486
  2819.  
  2820.      -mno-486
  2821.           Control whether or not code is optimized for a 486  in-
  2822.           stead  of an 386.  Code generated for a 486 will run on
  2823.           a 386 and vice versa.
  2824.  
  2825.      -msoft-float
  2826.           Generate output containing library calls  for  floating
  2827.           point.   _W_a_r_n_i_n_g:  the requisite libraries are not part
  2828.           of GNU CC.  Normally the facilities  of  the  machine's
  2829.           usual  C  compiler  are  used,  but  this can't be done
  2830.           directly in cross-compilation.  You must make your  own
  2831.           arrangements  to provide suitable library functions for
  2832.  
  2833.  
  2834.  
  2835. GNU Tools            Last change: 1993/10/13                   43
  2836.  
  2837.  
  2838.  
  2839.  
  2840.  
  2841.  
  2842. GCC(1)                      GNU Tools                      GCC(1)
  2843.  
  2844.  
  2845.  
  2846.           cross-compilation.
  2847.  
  2848.           On machines where a  function  returns  floating  point
  2849.           results  in  the  80387  register  stack, some floating
  2850.           point opcodes may be emitted even if `-msoft-float'  is
  2851.           used.
  2852.  
  2853.      -mno-fp-ret-in-387
  2854.           Do not use the FPU registers for return values of func-
  2855.           tions.
  2856.  
  2857.           The  usual  calling  convention  has  functions  return
  2858.           values  of  types  float and double in an FPU register,
  2859.           even if there is no FPU.  The idea is that the  operat-
  2860.           ing system should emulate an FPU.
  2861.  
  2862.           The option `-mno-fp-ret-in-387' causes such  values  to
  2863.           be returned in ordinary CPU registers instead.
  2864.  
  2865.      These `-m' options are defined for the HPPA family  of  com-
  2866.      puters:
  2867.  
  2868.      -mpa-risc-1-0
  2869.           Generate code for a PA 1.0 processor.
  2870.  
  2871.      -mpa-risc-1-1
  2872.           Generate code for a PA 1.1 processor.
  2873.  
  2874.      -mkernel
  2875.           Generate code which is suitable  for  use  in  kernels.
  2876.           Specifically,  avoid  add  instructions in which one of
  2877.           the arguments is the DP register;  generate  addil  in-
  2878.           structions  instead.   This avoids a rather serious bug
  2879.           in the HP-UX linker.
  2880.  
  2881.      -mshared-libs
  2882.           Generate code that can be linked against  HP-UX  shared
  2883.           libraries.   This option is not fully function yet, and
  2884.           is not on by default for any PA target.  Using this op-
  2885.           tion  can  cause  incorrect code to be generated by the
  2886.           compiler.
  2887.  
  2888.      -mno-shared-libs
  2889.           Don't generate code that will be linked against  shared
  2890.           libraries.  This is the default for all PA targets.
  2891.  
  2892.      -mlong-calls
  2893.           Generate code which allows calls to  functions  greater
  2894.           than 256K away from the caller when the caller and cal-
  2895.           lee are in the same source file.  Do not turn this  op-
  2896.           tion on unless code refuses to link with "branch out of
  2897.           range errors from the linker.
  2898.  
  2899.  
  2900.  
  2901. GNU Tools            Last change: 1993/10/13                   44
  2902.  
  2903.  
  2904.  
  2905.  
  2906.  
  2907.  
  2908. GCC(1)                      GNU Tools                      GCC(1)
  2909.  
  2910.  
  2911.  
  2912.      -mdisable-fpregs
  2913.           Prevent floating point registers from being used in any
  2914.           manner.   This is necessary for compiling kernels which
  2915.           perform lazy context switching of floating point regis-
  2916.           ters.   If  you  use this option and attempt to perform
  2917.           floating point operations, the compiler will abort.
  2918.  
  2919.      -mdisable-indexing
  2920.           Prevent the compiler from using indexing address modes.
  2921.           This avoids some rather obscure problems when compiling
  2922.           MIG generated code under MACH.
  2923.  
  2924.      -mtrailing-colon
  2925.           Add a colon to the end of label  definitions  (for  ELF
  2926.           assemblers).
  2927.  
  2928.      These `-m' options are defined for the Intel 80960 family of
  2929.      computers:
  2930.  
  2931.      -m_c_p_u-_t_y_p_e
  2932.           Assume the defaults for the machine type  _c_p_u-_t_y_p_e  for
  2933.           instruction and addressing-mode availability and align-
  2934.           ment.  The default _c_p_u-_t_y_p_e is kb;  other  choices  are
  2935.           ka, mc, ca, cf, sa, and sb.
  2936.  
  2937.      -mnumerics
  2938.  
  2939.      -msoft-float
  2940.           The -mnumerics option indicates that the processor does
  2941.           support  floating-point instructions.  The -msoft-float
  2942.           option indicates that floating-point support should not
  2943.           be assumed.
  2944.  
  2945.      -mleaf-procedures
  2946.  
  2947.      -mno-leaf-procedures
  2948.           Do (or do not) attempt to alter leaf procedures  to  be
  2949.           callable  with  the  _b_a_l  instruction  as well as _c_a_l_l.
  2950.           This will result in more efficient  code  for  explicit
  2951.           calls  when  the  _b_a_l instruction can be substituted by
  2952.           the assembler or linker, but  less  efficient  code  in
  2953.           other  cases,  such  as calls via function pointers, or
  2954.           using a linker that doesn't support this optimization.
  2955.  
  2956.      -mtail-call
  2957.  
  2958.      -mno-tail-call
  2959.           Do (or do not) make additional attempts  (beyond  those
  2960.           of the machine-independent portions of the compiler) to
  2961.           optimize tail-recursive calls into branches.   You  may
  2962.           not  want  to  do  this  because the detection of cases
  2963.           where this is not valid is not totally  complete.   The
  2964.  
  2965.  
  2966.  
  2967. GNU Tools            Last change: 1993/10/13                   45
  2968.  
  2969.  
  2970.  
  2971.  
  2972.  
  2973.  
  2974. GCC(1)                      GNU Tools                      GCC(1)
  2975.  
  2976.  
  2977.  
  2978.           default is -mno-tail-call.
  2979.  
  2980.      -mcomplex-addr
  2981.  
  2982.      -mno-complex-addr
  2983.           Assume (or do not assume) that the use of a complex ad-
  2984.           dressing  mode  is  a win on this implementation of the
  2985.           i960.  Complex addressing modes may not  be  worthwhile
  2986.           on  the  K-series,  but  they  definitely are on the C-
  2987.           series.  The default is  currently  -mcomplex-addr  for
  2988.           all processors except the CB and CC.
  2989.  
  2990.      -mcode-align
  2991.  
  2992.      -mno-code-align
  2993.           Align code to 8-byte boundaries for faster fetching (or
  2994.           don't  bother).   Currently turned on by default for C-
  2995.           series implementations only.
  2996.  
  2997.      -mic-compat
  2998.  
  2999.      -mic2.0-compat
  3000.  
  3001.      -mic3.0-compat
  3002.           Enable compatibility with iC960 v2.0 or v3.0.
  3003.  
  3004.      -masm-compat
  3005.  
  3006.      -mintel-asm
  3007.           Enable compatibility with the iC960 assembler.
  3008.  
  3009.      -mstrict-align
  3010.  
  3011.      -mno-strict-align
  3012.           Do not permit (do permit) unaligned accesses.
  3013.  
  3014.      -mold-align
  3015.           Enable structure-alignment compatibility  with  Intel's
  3016.           gcc release version 1.3 (based on gcc 1.37).  Currently
  3017.           this is buggy in that #pragma align 1 is always assumed
  3018.           as well, and cannot be turned off.
  3019.  
  3020.      These `-m' options are defined for the DEC Alpha implementa-
  3021.      tions:
  3022.  
  3023.      -mno-soft-float
  3024.  
  3025.      -msoft-float
  3026.           Use (do not use) the hardware  floating-point  instruc-
  3027.           tions for floating-point operations.  When -msoft-float
  3028.           is specified, functions in `libgcc1.c' will be used  to
  3029.           perform floating-point operations.  Unless they are re-
  3030.  
  3031.  
  3032.  
  3033. GNU Tools            Last change: 1993/10/13                   46
  3034.  
  3035.  
  3036.  
  3037.  
  3038.  
  3039.  
  3040. GCC(1)                      GNU Tools                      GCC(1)
  3041.  
  3042.  
  3043.  
  3044.           placed by  routines  that  emulate  the  floating-point
  3045.           operations,  or  compiled in such a way as to call such
  3046.           emulations  routines,   these   routines   will   issue
  3047.           floating-point  operations.    If you are compiling for
  3048.           an Alpha without floating-point  operations,  you  must
  3049.           ensure  that  the  library  is  built so as not to call
  3050.           them.
  3051.  
  3052.           Note that Alpha implementations without  floating-point
  3053.           operations  are  required to have floating-point regis-
  3054.           ters.
  3055.  
  3056.      -mfp-reg
  3057.  
  3058.      -mno-fp-regs
  3059.           Generate code that uses (does not  use)  the  floating-
  3060.           point register set.  -mno-fp-regs implies -msoft-float.
  3061.           If the floating-point register set is not used,  float-
  3062.           ing  point  operands are passed in integer registers as
  3063.           if they were integers and  floating-point  results  are
  3064.           passed  in  $0  instead of $f0.  This is a non-standard
  3065.           calling sequence, so any function with a floating-point
  3066.           argument  or  return value called by code compiled with
  3067.           -mno-fp-regs must also be compiled with that option.
  3068.  
  3069.           A typical use of this option is building a kernel  that
  3070.           does  not use, and hence need not save and restore, any
  3071.           floating-point registers.
  3072.  
  3073.      These additional options are available on System V Release 4
  3074.      for compatibility with other compilers on those systems:
  3075.  
  3076.      -G   On SVr4 systems,  gcc  accepts  the  option  `-G'  (and
  3077.           passes it to the system linker), for compatibility with
  3078.           other compilers.  However, we suggest you use `-symbol-
  3079.           ic'  or  `-shared' as appropriate, instead of supplying
  3080.           linker options on the gcc command line.
  3081.  
  3082.      -Qy  Identify the versions of each tool  used  by  the  com-
  3083.           piler, in a .ident assembler directive in the output.
  3084.  
  3085.      -Qn  Refrain from adding .ident  directives  to  the  output
  3086.           file (this is the default).
  3087.  
  3088.      -YP,_d_i_r_s
  3089.           Search the directories _d_i_r_s, and  no  others,  for  li-
  3090.           braries specified with `-l'.  You can separate directo-
  3091.           ry entries in _d_i_r_s from one another with colons.
  3092.  
  3093.      -Ym,_d_i_r
  3094.           Look in the directory _d_i_r to find the M4  preprocessor.
  3095.           The assembler uses this option.
  3096.  
  3097.  
  3098.  
  3099. GNU Tools            Last change: 1993/10/13                   47
  3100.  
  3101.  
  3102.  
  3103.  
  3104.  
  3105.  
  3106. GCC(1)                      GNU Tools                      GCC(1)
  3107.  
  3108.  
  3109.  
  3110. CODE GENERATION OPTIONS
  3111.      These machine-independent options control the interface con-
  3112.      ventions used in code generation.
  3113.  
  3114.      Most of them begin with `-f'.  These options have both posi-
  3115.      tive  and negative forms; the negative form of `-ffoo' would
  3116.      be `-fno-foo'.  In the table below, only one of the forms is
  3117.      listed-the one which is not the default.  You can figure out
  3118.      the other form by either removing `no-' or adding it.
  3119.  
  3120.      -fnonnull-objects
  3121.           Assume that objects reached through references are  not
  3122.           null (C++ only).
  3123.  
  3124.           Normally, GNU C++ makes conservative assumptions  about
  3125.           objects  reached  through references.  For example, the
  3126.           compiler must check that a is not null in code like the
  3127.           following:
  3128.  
  3129.           obj &a = g (); a.f (2);
  3130.  
  3131.           Checking that references of  this  sort  have  non-null
  3132.           values requires extra code, however, and it is unneces-
  3133.           sary  for  many  programs.   You  can  use  `-fnonnull-
  3134.           objects'  to  omit the checks for null, if your program
  3135.           doesn't require checking.
  3136.  
  3137.      -fpcc-struct-return
  3138.           Use the same convention for returning struct and  union
  3139.           values  that  is  used  by the usual C compiler on your
  3140.           system.  This convention is less  efficient  for  small
  3141.           structures,  and  on many machines it fails to be reen-
  3142.           trant; but it has the advantage of allowing intercalla-
  3143.           bility between GCC-compiled code and PCC-compiled code.
  3144.  
  3145.      -freg-struct-return
  3146.           Use the convention that struct and union values are re-
  3147.           turned  in registers when possible.  This is more effi-
  3148.           cient for small structures than -fpcc-struct-return.
  3149.  
  3150.           If  you   specify   neither   -fpcc-struct-return   nor
  3151.           -freg-struct-return,  GNU CC defaults to whichever con-
  3152.           vention is standard for the target.   If  there  is  no
  3153.           standard     convention,    GNU    CC    defaults    to
  3154.           -fpcc-struct-return.
  3155.  
  3156.      -fshort-enums
  3157.           Allocate to an enum type only as many bytes as it needs
  3158.           for the declared range of possible values.  Specifical-
  3159.           ly, the enum type will be equivalent  to  the  smallest
  3160.           integer type which has enough room.
  3161.  
  3162.  
  3163.  
  3164.  
  3165. GNU Tools            Last change: 1993/10/13                   48
  3166.  
  3167.  
  3168.  
  3169.  
  3170.  
  3171.  
  3172. GCC(1)                      GNU Tools                      GCC(1)
  3173.  
  3174.  
  3175.  
  3176.      -fshort-double
  3177.           Use the same size for double as for float .
  3178.  
  3179.      -fshared-data
  3180.           Requests that the data and non-const variables of  this
  3181.           compilation  be  shared  data rather than private data.
  3182.           The distinction makes sense only on  certain  operating
  3183.           systems,  where shared data is shared between processes
  3184.           running the same program, while private data exists  in
  3185.           one copy per process.
  3186.  
  3187.      -fno-common
  3188.           Allocate even uninitialized global variables in the bss
  3189.           section of the object file, rather than generating them
  3190.           as common blocks.  This has the effect that if the same
  3191.           variable  is declared (without extern) in two different
  3192.           compilations, you will get an error when you link them.
  3193.           The  only reason this might be useful is if you wish to
  3194.           verify that the program  will  work  on  other  systems
  3195.           which always work this way.
  3196.  
  3197.      -fno-ident
  3198.           Ignore the `#ident' directive.
  3199.  
  3200.      -fno-gnu-linker
  3201.           Do not output global initializations (such as C++  con-
  3202.           structors  and destructors) in the form used by the GNU
  3203.           linker (on systems where the GNU linker is the standard
  3204.           method  of  handling  them).   Use this option when you
  3205.           want to use a non-GNU linker, which also requires using
  3206.           the collect2 program to make sure the system linker in-
  3207.           cludes constructors and destructors.  (collect2 is  in-
  3208.           cluded  in the GNU CC distribution.)  For systems which
  3209.           _m_u_s_t use collect2, the compiler driver gcc  is  config-
  3210.           ured to do this automatically.
  3211.  
  3212.      -finhibit-size-directive
  3213.           Don't output a .size assembler directive,  or  anything
  3214.           else  that would cause trouble if the function is split
  3215.           in the middle, and the two halves are placed  at  loca-
  3216.           tions  far  apart  in memory.  This option is used when
  3217.           compiling `crtstuff.c'; you should not need to  use  it
  3218.           for anything else.
  3219.  
  3220.      -fverbose-asm
  3221.           Put extra commentary information in the  generated  as-
  3222.           sembly  code  to make it more readable.  This option is
  3223.           generally only of use to those  who  actually  need  to
  3224.           read  the generated assembly code (perhaps while debug-
  3225.           ging the compiler itself).
  3226.  
  3227.      -fvolatile
  3228.  
  3229.  
  3230.  
  3231. GNU Tools            Last change: 1993/10/13                   49
  3232.  
  3233.  
  3234.  
  3235.  
  3236.  
  3237.  
  3238. GCC(1)                      GNU Tools                      GCC(1)
  3239.  
  3240.  
  3241.  
  3242.           Consider all memory references through pointers  to  be
  3243.           volatile.
  3244.  
  3245.      -fvolatile-global
  3246.           Consider all memory references  to  extern  and  global
  3247.           data items to be volatile.
  3248.  
  3249.      -fpic
  3250.           If  supported  for  the   target   machines,   generate
  3251.           position-independent code, suitable for use in a shared
  3252.           library.
  3253.  
  3254.      -fPIC
  3255.           If supported for the  target  machine,  emit  position-
  3256.           independent code, suitable for dynamic linking, even if
  3257.           branches need large displacements.
  3258.  
  3259.      -ffixed-_r_e_g
  3260.           Treat the register named _r_e_g as a fixed register;  gen-
  3261.           erated code should never refer to it (except perhaps as
  3262.           a stack pointer, frame pointer or in some  other  fixed
  3263.           role).
  3264.  
  3265.           _r_e_g must be the name of a register.  The register names
  3266.           accepted  are  machine-specific  and are defined in the
  3267.           REGISTER_NAMES macro in the machine  description  macro
  3268.           file.
  3269.  
  3270.           This flag does not have a  negative  form,  because  it
  3271.           specifies a three-way choice.
  3272.  
  3273.      -fcall-used-_r_e_g
  3274.           Treat the register named _r_e_g as an allocatable register
  3275.           that  is  clobbered by function calls.  It may be allo-
  3276.           cated for temporaries or variables  that  do  not  live
  3277.           across  a  call.   Functions compiled this way will not
  3278.           save and restore the register _r_e_g.
  3279.  
  3280.           Use of this flag for a register that has a  fixed  per-
  3281.           vasive  role  in the machine's execution model, such as
  3282.           the stack pointer or frame pointer, will produce disas-
  3283.           trous results.
  3284.  
  3285.           This flag does not have a  negative  form,  because  it
  3286.           specifies a three-way choice.
  3287.  
  3288.      -fcall-saved-_r_e_g
  3289.           Treat the register named _r_e_g as an allocatable register
  3290.           saved  by functions.  It may be allocated even for tem-
  3291.           poraries or variables that live across a  call.   Func-
  3292.           tions  compiled  this way will save and restore the re-
  3293.           gister _r_e_g if they use it.
  3294.  
  3295.  
  3296.  
  3297. GNU Tools            Last change: 1993/10/13                   50
  3298.  
  3299.  
  3300.  
  3301.  
  3302.  
  3303.  
  3304. GCC(1)                      GNU Tools                      GCC(1)
  3305.  
  3306.  
  3307.  
  3308.           Use of this flag for a register that has a  fixed  per-
  3309.           vasive  role  in the machine's execution model, such as
  3310.           the stack pointer or frame pointer, will produce disas-
  3311.           trous results.
  3312.  
  3313.           A different sort of disaster will result from  the  use
  3314.           of  this  flag  for a register in which function values
  3315.           may be returned.
  3316.  
  3317.           This flag does not have a  negative  form,  because  it
  3318.           specifies a three-way choice.
  3319.  
  3320. PRAGMAS
  3321.      Two `#pragma' directives are supported for GNU C++, to  per-
  3322.      mit using the same header file for two purposes: as a defin-
  3323.      ition of interfaces to a given object class, and as the full
  3324.      definition of the contents of that object class.
  3325.  
  3326.      #pragma interface
  3327.           (C++ only.) Use this directive in header files that de-
  3328.           fine  object  classes, to save space in most of the ob-
  3329.           ject files that use  those  classes.   Normally,  local
  3330.           copies  of certain information (backup copies of inline
  3331.           member functions, debugging information, and the inter-
  3332.           nal  tables  that  implement virtual functions) must be
  3333.           kept in each object file that  includes  class  defini-
  3334.           tions.   You can use this pragma to avoid such duplica-
  3335.           tion.  When a header file  containing  `#pragma  inter-
  3336.           face'  is included in a compilation, this auxiliary in-
  3337.           formation will not be generated (unless the main  input
  3338.           source file itself uses `#pragma implementation').  In-
  3339.           stead, the object files will contain references  to  be
  3340.           resolved at link time.
  3341.  
  3342.      #pragma implementation
  3343.  
  3344.      #pragma implementation "_o_b_j_e_c_t_s.h"
  3345.           (C++ only.) Use this pragma in a main input file,  when
  3346.           you  want  full output from included header files to be
  3347.           generated (and made globally  visible).   The  included
  3348.           header  file,  in turn, should use `#pragma interface'.
  3349.           Backup copies of inline member functions, debugging in-
  3350.           formation,  and  the  internal tables used to implement
  3351.           virtual functions are all generated  in  implementation
  3352.           files.
  3353.  
  3354.           If you use `#pragma implementation' with  no  argument,
  3355.           it applies to an include file with the same basename as
  3356.           your  source  file;  for  example,  in   `allclass.cc',
  3357.           `#pragma  implementation'  by  itself  is equivalent to
  3358.           `#pragma implementation "allclass.h"'.  Use the  string
  3359.           argument  if  you  want a single implementation file to
  3360.  
  3361.  
  3362.  
  3363. GNU Tools            Last change: 1993/10/13                   51
  3364.  
  3365.  
  3366.  
  3367.  
  3368.  
  3369.  
  3370. GCC(1)                      GNU Tools                      GCC(1)
  3371.  
  3372.  
  3373.  
  3374.           include code from multiple header files.
  3375.  
  3376.           There is no way to split up the contents  of  a  single
  3377.           header file into multiple implementation files.
  3378.  
  3379. FILES
  3380.      file.c             C source file
  3381.      file.h             C header (preprocessor) file
  3382.      file.i             preprocessed C source file
  3383.      file.C             C++ source file
  3384.      file.cc            C++ source file
  3385.      file.cxx           C++ source file
  3386.      file.m             Objective-C source file
  3387.      file.s             assembly language file
  3388.      file.o             object file
  3389.      a.out              link edited output
  3390.      _T_M_P_D_I_R/cc*         temporary files
  3391.      _L_I_B_D_I_R/cpp         preprocessor
  3392.      _L_I_B_D_I_R/cc1         compiler for C
  3393.      _L_I_B_D_I_R/cc1plus     compiler for C++
  3394.      _L_I_B_D_I_R/collect     linker front end needed on some machines
  3395.      _L_I_B_D_I_R/libgcc.a    GCC subroutine library
  3396.      /lib/crt[01n].o    start-up routine
  3397.      _L_I_B_D_I_R/ccrt0       additional start-up routine for C++
  3398.      /lib/libc.a        standard C library, see
  3399.      _i_n_t_r_o(3)
  3400.      /usr/include       standard directory for #include files
  3401.      _L_I_B_D_I_R/include     standard gcc directory for #include files
  3402.      _L_I_B_D_I_R/g++-include additional g++ directory for #include
  3403.  
  3404.      _L_I_B_D_I_R is usually /usr/local/lib/_m_a_c_h_i_n_e/_v_e_r_s_i_o_n.
  3405.      _T_M_P_D_I_R comes from the environment variable  TMPDIR  (default
  3406.      /usr/tmp if available, else /tmp).
  3407.  
  3408. SEE ALSO
  3409.      cpp(1), as(1), ld(1), gdb(1), adb(1), dbx(1), sdb(1).
  3410.      `gcc', `cpp', `as', `ld', and `gdb' entries in info.
  3411.      _U_s_i_n_g _a_n_d _P_o_r_t_i_n_g _G_N_U  _C_C  (_f_o_r  _v_e_r_s_i_o_n  _2._0),  Richard  M.
  3412.      Stallman; _T_h_e _C _P_r_e_p_r_o_c_e_s_s_o_r, Richard M. Stallman; _D_e_b_u_g_g_i_n_g
  3413.      _w_i_t_h _G_D_B: _t_h_e _G_N_U _S_o_u_r_c_e-_L_e_v_e_l _D_e_b_u_g_g_e_r, Richard M. Stallman
  3414.      and  Roland H. Pesch; _U_s_i_n_g _a_s: _t_h_e _G_N_U _A_s_s_e_m_b_l_e_r, Dean Els-
  3415.      ner, Jay Fenlason & friends; _l_d: _t_h_e _G_N_U _l_i_n_k_e_r, Steve Cham-
  3416.      berlain and Roland Pesch.
  3417.  
  3418. BUGS
  3419.      For instructions on reporting bugs, see the GCC manual.
  3420.  
  3421. COPYING
  3422.      Copyright 1991, 1992, 1993 Free Software Foundation, Inc.
  3423.  
  3424.      Permission is granted to make and distribute verbatim copies
  3425.      of  this  manual provided the copyright notice and this per-
  3426.  
  3427.  
  3428.  
  3429. GNU Tools            Last change: 1993/10/13                   52
  3430.  
  3431.  
  3432.  
  3433.  
  3434.  
  3435.  
  3436. GCC(1)                      GNU Tools                      GCC(1)
  3437.  
  3438.  
  3439.  
  3440.      mission notice are preserved on all copies.
  3441.  
  3442.      Permission is granted to copy and distribute  modified  ver-
  3443.      sions of this manual under the conditions for verbatim copy-
  3444.      ing, provided that the entire resulting derived work is dis-
  3445.      tributed under the terms of a permission notice identical to
  3446.      this one.
  3447.  
  3448.      Permission is granted to copy and distribute translations of
  3449.      this  manual  into  another language, under the above condi-
  3450.      tions for modified versions, except that this permission no-
  3451.      tice  may  be  included in translations approved by the Free
  3452.      Software Foundation instead of in the original English.
  3453.  
  3454. AUTHORS
  3455.      See the GNU CC Manual for the contributors to GNU CC.
  3456.  
  3457.  
  3458.  
  3459.  
  3460.  
  3461.  
  3462.  
  3463.  
  3464.  
  3465.  
  3466.  
  3467.  
  3468.  
  3469.  
  3470.  
  3471.  
  3472.  
  3473.  
  3474.  
  3475.  
  3476.  
  3477.  
  3478.  
  3479.  
  3480.  
  3481.  
  3482.  
  3483.  
  3484.  
  3485.  
  3486.  
  3487.  
  3488.  
  3489.  
  3490.  
  3491.  
  3492.  
  3493.  
  3494.  
  3495. GNU Tools            Last change: 1993/10/13                   53
  3496.  
  3497.  
  3498.  
  3499.