Annotation of gcc/gcc.info-9, revision 1.1.1.5

1.1.1.5 ! root        1: This is Info file gcc.info, produced by Makeinfo-1.47 from the input
1.1       root        2: file gcc.texinfo.
                      3: 
1.1.1.4   root        4:    This file documents the use and the internals of the GNU compiler.
1.1       root        5: 
1.1.1.4   root        6:    Copyright (C) 1988, 1989, 1990 Free Software Foundation, Inc.
1.1       root        7: 
1.1.1.5 ! root        8:    Permission is granted to make and distribute verbatim copies of this
        !             9: manual provided the copyright notice and this permission notice are
        !            10: preserved on all copies.
1.1       root       11: 
1.1.1.4   root       12:    Permission is granted to copy and distribute modified versions of
1.1       root       13: this manual under the conditions for verbatim copying, provided also
1.1.1.2   root       14: that the sections entitled "GNU General Public License" and "Protect
                     15: Your Freedom--Fight `Look And Feel'" are included exactly as in the
                     16: original, and provided that the entire resulting derived work is
                     17: distributed under the terms of a permission notice identical to this
                     18: one.
1.1       root       19: 
1.1.1.4   root       20:    Permission is granted to copy and distribute translations of this
1.1       root       21: manual into another language, under the above conditions for modified
1.1.1.2   root       22: versions, except that the sections entitled "GNU General Public
                     23: License" and "Protect Your Freedom--Fight `Look And Feel'" and this
1.1.1.5 ! root       24: permission notice may be included in translations approved by the Free
        !            25: Software Foundation instead of in the original English.
1.1       root       26: 
1.1.1.4   root       27: 
                     28: File: gcc.info,  Node: Registers,  Next: Register Classes,  Prev: Storage Layout,  Up: Machine Macros
                     29: 
                     30: Register Usage
                     31: ==============
                     32: 
                     33: `FIRST_PSEUDO_REGISTER'
1.1.1.5 ! root       34:      Number of hardware registers known to the compiler.  They receive
        !            35:      numbers 0 through `FIRST_PSEUDO_REGISTER-1'; thus, the first
        !            36:      pseudo register's number really is assigned the number
1.1.1.4   root       37:      `FIRST_PSEUDO_REGISTER'.
                     38: 
                     39: `FIXED_REGISTERS'
                     40:      An initializer that says which registers are used for fixed
                     41:      purposes all throughout the compiled code and are therefore not
                     42:      available for general allocation.  These would include the stack
                     43:      pointer, the frame pointer (except on machines where that can be
                     44:      used as a general register when no frame pointer is needed), the
                     45:      program counter on machines where that is considered one of the
                     46:      addressable registers, and any other numbered register with a
                     47:      standard use.
                     48: 
1.1.1.5 ! root       49:      This information is expressed as a sequence of numbers, separated
        !            50:      by commas and surrounded by braces.  The Nth number is 1 if
        !            51:      register N is fixed, 0 otherwise.
1.1.1.4   root       52: 
1.1.1.5 ! root       53:      The table initialized from this macro, and the table initialized by
        !            54:      the following one, may be overridden at run time either
1.1.1.4   root       55:      automatically, by the actions of the macro
                     56:      `CONDITIONAL_REGISTER_USAGE', or by the user with the command
                     57:      options `-ffixed-REG', `-fcall-used-REG' and `-fcall-saved-REG'.
                     58: 
                     59: `CALL_USED_REGISTERS'
                     60:      Like `FIXED_REGISTERS' but has 1 for each register that is
                     61:      clobbered (in general) by function calls as well as for fixed
1.1.1.5 ! root       62:      registers.  This macro therefore identifies the registers that are
        !            63:      not available for general allocation of values that must live
        !            64:      across function calls.
1.1.1.4   root       65: 
                     66:      If a register has 0 in `CALL_USED_REGISTERS', the compiler
                     67:      automatically saves it on function entry and restores it on
                     68:      function exit, if the register is used within the function.
                     69: 
                     70: `DEFAULT_CALLER_SAVES'
                     71:      Define this macro if function calls on the target machine do not
                     72:      preserve any registers; in other words, if `CALL_USED_REGISTERS'
                     73:      has 1 for all registers.  This macro enables `-fcaller-saves' by
1.1.1.5 ! root       74:      default. Eventually that option will be enabled by default on all
        !            75:      machines and both the option and this macro will be eliminated.
1.1.1.4   root       76: 
                     77: `CONDITIONAL_REGISTER_USAGE'
                     78:      Zero or more C statements that may conditionally modify two
                     79:      variables `fixed_regs' and `call_used_regs' (both of type `char
                     80:      []') after they have been initialized from the two preceding
                     81:      macros.
                     82: 
                     83:      This is necessary in case the fixed or call-clobbered registers
                     84:      depend on target flags.
                     85: 
                     86:      You need not define this macro if it has no work to do.
                     87: 
1.1.1.5 ! root       88:      If the usage of an entire class of registers depends on the target
        !            89:      flags, you may indicate this to GCC by using this macro to modify
        !            90:      `fixed_regs' and `call_used_regs' to 1 for each of the registers
        !            91:      in the classes which should not be used by GCC.  Also define the
        !            92:      macro `REG_CLASS_FROM_LETTER' to return `NO_REGS' if it is called
        !            93:      with a letter for a class that shouldn't be used.
1.1.1.4   root       94: 
1.1.1.5 ! root       95:      (However, if this class is not included in `GENERAL_REGS' and all
        !            96:      of the insn patterns whose constraints permit this class are
1.1.1.4   root       97:      controlled by target switches, then GCC will automatically avoid
                     98:      using these registers when the target switches are opposed to
                     99:      them.)
                    100: 
                    101: `OVERLAPPING_REGNO_P (REGNO)'
1.1.1.5 ! root      102:      If defined, this is a C expression whose value is nonzero if hard
        !           103:      register number REGNO is an overlapping register.  This means a
        !           104:      hard register which overlaps a hard register with a different
        !           105:      number. (Such overlap is undesirable, but occasionally it allows a
        !           106:      machine to be supported which otherwise could not be.)  This macro
        !           107:      must return nonzero for *all* the registers which overlap each
        !           108:      other.  GNU CC can use an overlapping register only in certain
        !           109:      limited ways.  It can be used for allocation within a basic block,
        !           110:      and may be spilled for reloading; that is all.
1.1.1.4   root      111: 
                    112:      If this macro is not defined, it means that none of the hard
                    113:      registers overlap each other.  This is the usual situation.
                    114: 
                    115: `INSN_CLOBBERS_REGNO_P (INSN, REGNO)'
1.1.1.5 ! root      116:      If defined, this is a C expression whose value should be nonzero if
        !           117:      the insn INSN has the effect of mysteriously clobbering the
1.1.1.4   root      118:      contents of hard register number REGNO.  By "mysterious" we mean
                    119:      that the insn's RTL expression doesn't describe such an effect.
                    120: 
                    121:      If this macro is not defined, it means that no insn clobbers
                    122:      registers mysteriously.  This is the usual situation; all else
                    123:      being equal, it is best for the RTL expression to show all the
                    124:      activity.
                    125: 
                    126: `PRESERVE_DEATH_INFO_REGNO_P (REGNO)'
                    127:      If defined, this is a C expression whose value is nonzero if
1.1.1.5 ! root      128:      accurate `REG_DEAD' notes are needed for hard register number REGNO
        !           129:      at the time of outputting the assembler code.  When this is so, a
        !           130:      few optimizations that take place after register allocation and
        !           131:      could invalidate the death notes are not done when this register is
        !           132:      involved.
        !           133: 
        !           134:      You would arrange to preserve death info for a register when some
        !           135:      of the code in the machine description which is executed to write
        !           136:      the assembler code looks at the death notes.  This is necessary
        !           137:      only when the actual hardware feature which GNU CC thinks of as a
        !           138:      register is not actually a register of the usual sort.  (It might,
        !           139:      for example, be a hardware stack.)
1.1.1.4   root      140: 
1.1.1.5 ! root      141:      If this macro is not defined, it means that no death notes need to
        !           142:      be preserved.  This is the usual situation.
1.1.1.4   root      143: 
                    144: `HARD_REGNO_NREGS (REGNO, MODE)'
                    145:      A C expression for the number of consecutive hard registers,
1.1.1.5 ! root      146:      starting at register number REGNO, required to hold a value of mode
        !           147:      MODE.
1.1.1.4   root      148: 
1.1.1.5 ! root      149:      On a machine where all registers are exactly one word, a suitable
        !           150:      definition of this macro is
1.1.1.4   root      151: 
                    152:           #define HARD_REGNO_NREGS(REGNO, MODE)            \
                    153:              ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD - 1)  \
                    154:               / UNITS_PER_WORD))
                    155: 
                    156: `HARD_REGNO_MODE_OK (REGNO, MODE)'
                    157:      A C expression that is nonzero if it is permissible to store a
                    158:      value of mode MODE in hard register number REGNO (or in several
                    159:      registers starting with that one).  For a machine where all
                    160:      registers are equivalent, a suitable definition is
                    161: 
                    162:           #define HARD_REGNO_MODE_OK(REGNO, MODE) 1
                    163: 
                    164:      It is not necessary for this macro to check for the numbers of
                    165:      fixed registers, because the allocation mechanism considers them
                    166:      to be always occupied.
                    167: 
1.1.1.5 ! root      168:      On some machines, double-precision values must be kept in even/odd
        !           169:      register pairs.  The way to implement that is to define this macro
        !           170:      to reject odd register numbers for such modes.
        !           171: 
        !           172:      GNU CC assumes that it can always move values between registers and
        !           173:      (suitably addressed) memory locations.  If it is impossible to
        !           174:      move a value of a certain mode between memory and certain
1.1.1.4   root      175:      registers, then `HARD_REGNO_MODE_OK' must not allow this mode in
                    176:      those registers.
                    177: 
1.1.1.5 ! root      178:      Many machines have special registers for floating point arithmetic.
        !           179:      Often people assume that floating point machine modes are allowed
        !           180:      only in floating point registers.  This is not true.  Any
        !           181:      registers that can hold integers can safely *hold* a floating
        !           182:      point machine mode, whether or not floating arithmetic can be done
        !           183:      on it in those registers.
        !           184: 
        !           185:      On some machines, though, the converse is true: fixed-point machine
        !           186:      modes may not go in floating registers.  This is true if the
        !           187:      floating registers normalize any value stored in them, because
        !           188:      storing a non-floating value there would garble it.  In this case,
        !           189:      `HARD_REGNO_MODE_OK' should reject fixed-point machine modes in
        !           190:      floating registers.  But if the floating registers do not
        !           191:      automatically normalize, if you can store any bit pattern in one
        !           192:      and retrieve it unchanged without a trap, then any machine mode
        !           193:      may go in a floating register and this macro should say so.
1.1.1.4   root      194: 
                    195:      The primary significance of special floating registers is rather
1.1.1.5 ! root      196:      that they are the registers acceptable in floating point arithmetic
        !           197:      instructions.  However, this is of no concern to
1.1.1.4   root      198:      `HARD_REGNO_MODE_OK'.  You handle it by writing the proper
                    199:      constraints for those instructions.
                    200: 
                    201:      On some machines, the floating registers are especially slow to
                    202:      access, so that it is better to store a value in a stack frame
1.1.1.5 ! root      203:      than in such a register if floating point arithmetic is not being
        !           204:      done.  As long as the floating registers are not in class
1.1.1.4   root      205:      `GENERAL_REGS', they will not be used unless some insn's
                    206:      constraint asks for one.
                    207: 
                    208: `MODES_TIEABLE_P (MODE1, MODE2)'
                    209:      A C expression that is nonzero if it is desirable to choose
                    210:      register allocation so as to avoid move instructions between a
                    211:      value of mode MODE1 and a value of mode MODE2.
                    212: 
                    213:      If `HARD_REGNO_MODE_OK (R, MODE1)' and `HARD_REGNO_MODE_OK (R,
1.1.1.5 ! root      214:      MODE2)' are ever different for any R, then `MODES_TIEABLE_P (MODE1,
        !           215:      MODE2)' must be zero.
1.1.1.4   root      216: 
                    217: `PC_REGNUM'
1.1.1.5 ! root      218:      If the program counter has a register number, define this as that
        !           219:      register number.  Otherwise, do not define it.
1.1.1.4   root      220: 
                    221: `STACK_POINTER_REGNUM'
1.1.1.5 ! root      222:      The register number of the stack pointer register, which must also
        !           223:      be a fixed register according to `FIXED_REGISTERS'.  On many
        !           224:      machines, the hardware determines which register this is.
1.1.1.4   root      225: 
                    226: `FRAME_POINTER_REGNUM'
1.1.1.5 ! root      227:      The register number of the frame pointer register, which is used to
        !           228:      access automatic variables in the stack frame.  On some machines,
        !           229:      the hardware determines which register this is.  On other
        !           230:      machines, you can choose any register you wish for this purpose.
1.1.1.4   root      231: 
                    232: `FRAME_POINTER_REQUIRED'
1.1.1.5 ! root      233:      A C expression which is nonzero if a function must have and use a
        !           234:      frame pointer.  This expression is evaluated twice: at the
        !           235:      beginning of generating RTL, and in the reload pass.  If its value
        !           236:      is nonzero at either time, then the function will have a frame
        !           237:      pointer.
1.1.1.4   root      238: 
                    239:      The expression can in principle examine the current function and
1.1.1.5 ! root      240:      decide according to the facts, but on most machines the constant 0
        !           241:      or the constant 1 suffices.  Use 0 when the machine allows code to
        !           242:      be generated with no frame pointer, and doing so saves some time
        !           243:      or space.  Use 1 when there is no possible advantage to avoiding a
        !           244:      frame pointer.
        !           245: 
        !           246:      In certain cases, the compiler does not know how to produce valid
        !           247:      code without a frame pointer.  The compiler recognizes those cases
        !           248:      and automatically gives the function a frame pointer regardless of
        !           249:      what `FRAME_POINTER_REQUIRED' says.  You don't need to worry about
        !           250:      them.
1.1.1.4   root      251: 
                    252:      In a function that does not require a frame pointer, the frame
                    253:      pointer register can be allocated for ordinary usage, unless you
                    254:      mark it as a fixed register.  See `FIXED_REGISTERS' for more
                    255:      information.
                    256: 
                    257: `ARG_POINTER_REGNUM'
1.1.1.5 ! root      258:      The register number of the arg pointer register, which is used to
        !           259:      access the function's argument list.  On some machines, this is the
        !           260:      same as the frame pointer register.  On some machines, the hardware
        !           261:      determines which register this is.  On other machines, you can
        !           262:      choose any register you wish for this purpose.  If this is not the
        !           263:      same register as the frame pointer register, then you must mark it
        !           264:      as a fixed register according to `FIXED_REGISTERS'.
1.1.1.4   root      265: 
                    266: `STATIC_CHAIN_REGNUM'
                    267:      The register number used for passing a function's static chain
                    268:      pointer.  This is needed for languages such as Pascal and Algol
1.1.1.5 ! root      269:      where functions defined within other functions can access the local
        !           270:      variables of the outer functions; it is not currently used because
        !           271:      C does not provide this feature, but you must define the macro.
1.1.1.4   root      272: 
                    273:      The static chain register need not be a fixed register.
                    274: 
                    275: `STRUCT_VALUE_REGNUM'
                    276:      When a function's value's mode is `BLKmode', the value is not
                    277:      returned according to `FUNCTION_VALUE'.  Instead, the caller
1.1.1.5 ! root      278:      passes the address of a block of memory in which the value should
        !           279:      be stored.
1.1.1.4   root      280: 
1.1.1.5 ! root      281:      If this value is passed in a register, then `STRUCT_VALUE_REGNUM'
        !           282:      should be the number of that register.
1.1.1.4   root      283: 
                    284: `STRUCT_VALUE'
1.1.1.5 ! root      285:      If the structure value address is not passed in a register, define
        !           286:      `STRUCT_VALUE' as an expression returning an RTX for the place
        !           287:      where the address is passed.  If it returns a `mem' RTX, the
        !           288:      address is passed as an "invisible" first argument.
1.1.1.4   root      289: 
                    290: `STRUCT_VALUE_INCOMING_REGNUM'
1.1.1.5 ! root      291:      On some architectures the place where the structure value address
        !           292:      is found by the called function is not the same place that the
        !           293:      caller put it.  This can be due to register windows, or it could
        !           294:      be because the function prologue moves it to a different place.
1.1.1.4   root      295: 
                    296:      If the incoming location of the structure value address is in a
                    297:      register, define this macro as the register number.
                    298: 
                    299: `STRUCT_VALUE_INCOMING'
                    300:      If the incoming location is not a register, define
1.1.1.5 ! root      301:      `STRUCT_VALUE_INCOMING' as an expression for an RTX for where the
        !           302:      called function should find the value.  If it should find the
        !           303:      value on the stack, define this to create a `mem' which refers to
        !           304:      the frame pointer.  If the value is a `mem', the compiler assumes
        !           305:      it is for an invisible first argument, and leaves space for it when
        !           306:      finding the first real argument.
1.1.1.4   root      307: 
                    308: `REG_ALLOC_ORDER'
1.1.1.5 ! root      309:      If defined, an initializer for a vector of integers, containing the
        !           310:      numbers of hard registers in the order in which the GNU CC should
        !           311:      prefer to use them (from most preferred to least).
1.1.1.4   root      312: 
                    313:      If this macro is not defined, registers are used lowest numbered
                    314:      first (all else being equal).
                    315: 
                    316:      One use of this macro is on the 360, where the highest numbered
                    317:      registers must always be saved and the save-multiple-registers
1.1.1.5 ! root      318:      instruction supports only sequences of consecutive registers.  This
        !           319:      macro is defined to cause the highest numbered allocatable
1.1.1.4   root      320:      registers to be used first.
1.1       root      321: 
                    322: 
1.1.1.3   root      323: File: gcc.info,  Node: Register Classes,  Next: Stack Layout,  Prev: Registers,  Up: Machine Macros
                    324: 
                    325: Register Classes
                    326: ================
                    327: 
1.1.1.5 ! root      328:    On many machines, the numbered registers are not all equivalent. For
        !           329: example, certain registers may not be allowed for indexed addressing;
        !           330: certain registers may not be allowed in some instructions.  These
        !           331: machine restrictions are described to the compiler using "register
        !           332: classes".
        !           333: 
        !           334:    You define a number of register classes, giving each one a name and
        !           335: saying which of the registers belong to it.  Then you can specify
        !           336: register classes that are allowed as operands to particular instruction
        !           337: patterns.
        !           338: 
        !           339:    In general, each register will belong to several classes.  In fact,
        !           340: one class must be named `ALL_REGS' and contain all the registers. 
        !           341: Another class must be named `NO_REGS' and contain no registers.  Often
        !           342: the union of two classes will be another class; however, this is not
        !           343: required.
1.1.1.3   root      344: 
1.1.1.4   root      345:    One of the classes must be named `GENERAL_REGS'.  There is nothing
1.1.1.5 ! root      346: terribly special about the name, but the operand constraint letters `r'
        !           347: and `g' specify this class.  If `GENERAL_REGS' is the same as
1.1.1.3   root      348: `ALL_REGS', just define it as a macro which expands to `ALL_REGS'.
                    349: 
1.1.1.4   root      350:    The way classes other than `GENERAL_REGS' are specified in operand
1.1.1.5 ! root      351: constraints is through machine-dependent operand constraint letters.
        !           352: You can define such letters to correspond to various classes, then use
        !           353: them in operand constraints.
        !           354: 
        !           355:    You should define a class for the union of two classes whenever some
        !           356: instruction allows both classes.  For example, if an instruction allows
        !           357: either a floating-point (coprocessor) register or a general register
        !           358: for a certain operand, you should define a class `FLOAT_OR_GENERAL_REGS'
        !           359: which includes both of them.  Otherwise you will get suboptimal code.
1.1.1.3   root      360: 
1.1.1.4   root      361:    You must also specify certain redundant information about the
1.1.1.3   root      362: register classes: for each class, which classes contain it and which
                    363: ones are contained in it; for each pair of classes, the largest class
                    364: contained in their union.
                    365: 
1.1.1.5 ! root      366:    When a value occupying several consecutive registers is expected in a
        !           367: certain class, all the registers used must belong to that class.
        !           368: Therefore, register classes cannot be used to enforce a requirement for
        !           369: a register pair to start with an even-numbered register.  The way to
        !           370: specify this requirement is with `HARD_REGNO_MODE_OK'.
1.1.1.3   root      371: 
1.1.1.4   root      372:    Register classes used for input-operands of bitwise-and or shift
1.1.1.5 ! root      373: instructions have a special requirement: each such class must have, for
        !           374: each fixed-point machine mode, a subclass whose registers can transfer
        !           375: that mode to or from memory.  For example, on some machines, the
        !           376: operations for single-byte values (`QImode') are limited to certain
        !           377: registers.  When this is so, each register class that is used in a
        !           378: bitwise-and or shift instruction must have a subclass consisting of
        !           379: registers from which single-byte values can be loaded or stored.  This
        !           380: is so that `PREFERRED_RELOAD_CLASS' can always have a possible value to
        !           381: return.
1.1.1.3   root      382: 
                    383: `enum reg_class'
1.1.1.5 ! root      384:      An enumeral type that must be defined with all the register class
        !           385:      names as enumeral values.  `NO_REGS' must be first.  `ALL_REGS'
        !           386:      must be the last register class, followed by one more enumeral
        !           387:      value, `LIM_REG_CLASSES', which is not a register class but rather
        !           388:      tells how many classes there are.
1.1.1.3   root      389: 
                    390:      Each register class has a number, which is the value of casting
                    391:      the class name to type `int'.  The number serves as an index in
                    392:      many of the tables described below.
                    393: 
                    394: `N_REG_CLASSES'
                    395:      The number of distinct register classes, defined as follows:
                    396: 
                    397:           #define N_REG_CLASSES (int) LIM_REG_CLASSES
                    398: 
                    399: `REG_CLASS_NAMES'
                    400:      An initializer containing the names of the register classes as C
                    401:      string constants.  These names are used in writing some of the
                    402:      debugging dumps.
                    403: 
                    404: `REG_CLASS_CONTENTS'
1.1.1.5 ! root      405:      An initializer containing the contents of the register classes, as
        !           406:      integers which are bit masks.  The Nth integer specifies the
1.1.1.3   root      407:      contents of class N.  The way the integer MASK is interpreted is
                    408:      that register R is in the class if `MASK & (1 << R)' is 1.
                    409: 
                    410:      When the machine has more than 32 registers, an integer does not
1.1.1.5 ! root      411:      suffice. Then the integers are replaced by sub-initializers,
1.1.1.3   root      412:      braced groupings containing several integers.  Each
                    413:      sub-initializer must be suitable as an initializer for the type
                    414:      `HARD_REG_SET' which is defined in `hard-reg-set.h'.
                    415: 
                    416: `REGNO_REG_CLASS (REGNO)'
                    417:      A C expression whose value is a register class containing hard
                    418:      register REGNO.  In general there is more that one such class;
                    419:      choose a class which is "minimal", meaning that no smaller class
                    420:      also contains the register.
                    421: 
                    422: `BASE_REG_CLASS'
1.1.1.5 ! root      423:      A macro whose definition is the name of the class to which a valid
        !           424:      base register must belong.  A base register is one used in an
        !           425:      address which is the register value plus a displacement.
1.1.1.3   root      426: 
                    427: `INDEX_REG_CLASS'
1.1.1.5 ! root      428:      A macro whose definition is the name of the class to which a valid
        !           429:      index register must belong.  An index register is one used in an
        !           430:      address where its value is either multiplied by a scale factor or
        !           431:      added to another register (as well as added to a displacement).
1.1.1.3   root      432: 
                    433: `REG_CLASS_FROM_LETTER (CHAR)'
                    434:      A C expression which defines the machine-dependent operand
                    435:      constraint letters for register classes.  If CHAR is such a
                    436:      letter, the value should be the register class corresponding to
                    437:      it.  Otherwise, the value should be `NO_REGS'.
                    438: 
                    439: `REGNO_OK_FOR_BASE_P (NUM)'
1.1.1.5 ! root      440:      A C expression which is nonzero if register number NUM is suitable
        !           441:      for use as a base register in operand addresses.  It may be either
        !           442:      a suitable hard register or a pseudo register that has been
        !           443:      allocated such a hard register.
1.1.1.3   root      444: 
                    445: `REGNO_OK_FOR_INDEX_P (NUM)'
1.1.1.5 ! root      446:      A C expression which is nonzero if register number NUM is suitable
        !           447:      for use as an index register in operand addresses.  It may be
        !           448:      either a suitable hard register or a pseudo register that has been
        !           449:      allocated such a hard register.
1.1.1.3   root      450: 
                    451:      The difference between an index register and a base register is
1.1.1.5 ! root      452:      that the index register may be scaled.  If an address involves the
        !           453:      sum of two registers, neither one of them scaled, then either one
        !           454:      may be labeled the "base" and the other the "index"; but whichever
        !           455:      labeling is used must fit the machine's constraints of which
        !           456:      registers may serve in each capacity.  The compiler will try both
        !           457:      labelings, looking for one that is valid, and will reload one or
        !           458:      both registers only if neither labeling works.
1.1.1.3   root      459: 
                    460: `PREFERRED_RELOAD_CLASS (X, CLASS)'
1.1.1.5 ! root      461:      A C expression that places additional restrictions on the register
        !           462:      class to use when it is necessary to copy value X into a register
        !           463:      in class CLASS.  The value is a register class; perhaps CLASS, or
        !           464:      perhaps another, smaller class.  On many machines, the definition
1.1.1.3   root      465: 
                    466:           #define PREFERRED_RELOAD_CLASS(X,CLASS) CLASS
                    467: 
                    468:      is safe.
                    469: 
                    470:      Sometimes returning a more restrictive class makes better code. 
                    471:      For example, on the 68000, when X is an integer constant that is
                    472:      in range for a `moveq' instruction, the value of this macro is
                    473:      always `DATA_REGS' as long as CLASS includes the data registers.
                    474:      Requiring a data register guarantees that a `moveq' will be used.
                    475: 
                    476:      If X is a `const_double', by returning `NO_REGS' you can force X
1.1.1.5 ! root      477:      into a memory constant.  This is useful on certain machines where
        !           478:      immediate floating values cannot be loaded into certain kinds of
        !           479:      registers.
        !           480: 
        !           481:      In a shift instruction or a bitwise-and instruction, the mode of X,
        !           482:      the value being reloaded, may not be the same as the mode of the
        !           483:      instruction's operand.  (They will both be fixed-point modes,
        !           484:      however.)  In such a case, CLASS may not be a safe value to
        !           485:      return.  CLASS is certainly valid for the instruction, but it may
        !           486:      not be valid for reloading X.  This problem can occur on machines
        !           487:      such as the 68000 and 80386 where some registers can handle
        !           488:      full-word values but cannot handle single-byte values.
        !           489: 
        !           490:      On such machines, this macro must examine the mode of X and return
        !           491:      a subclass of CLASS which can handle loads and stores of that
        !           492:      mode.  On the 68000, where address registers cannot handle
        !           493:      `QImode', if X has `QImode' then you must return `DATA_REGS'.  If
        !           494:      CLASS is `ADDR_REGS', then there is no correct value to return;
        !           495:      but the shift and bitwise-and instructions don't use `ADDR_REGS',
        !           496:      so this fatal case never arises.
1.1.1.3   root      497: 
                    498: `CLASS_MAX_NREGS (CLASS, MODE)'
1.1.1.5 ! root      499:      A C expression for the maximum number of consecutive registers of
        !           500:      class CLASS needed to hold a value of mode MODE.
1.1.1.3   root      501: 
1.1.1.5 ! root      502:      This is closely related to the macro `HARD_REGNO_NREGS'. In fact,
        !           503:      the value of the macro `CLASS_MAX_NREGS (CLASS, MODE)' should be
        !           504:      the maximum value of `HARD_REGNO_NREGS (REGNO, MODE)' for all
        !           505:      REGNO values in the class CLASS.
1.1.1.3   root      506: 
                    507:      This macro helps control the handling of multiple-word values in
                    508:      the reload pass.
                    509: 
1.1.1.4   root      510:    Two other special macros describe which constants fit which
1.1.1.3   root      511: constraint letters.
                    512: 
                    513: `CONST_OK_FOR_LETTER_P (VALUE, C)'
                    514:      A C expression that defines the machine-dependent operand
                    515:      constraint letters that specify particular ranges of integer
1.1.1.5 ! root      516:      values.  If C is one of those letters, the expression should check
        !           517:      that VALUE, an integer, is in the appropriate range and return 1
        !           518:      if so, 0 otherwise.  If C is not one of those letters, the value
        !           519:      should be 0 regardless of VALUE.
1.1.1.3   root      520: 
                    521: `CONST_DOUBLE_OK_FOR_LETTER_P (VALUE, C)'
                    522:      A C expression that defines the machine-dependent operand
                    523:      constraint letters that specify particular ranges of floating
1.1.1.5 ! root      524:      values.  If C is one of those letters, the expression should check
        !           525:      that VALUE, an RTX of code `const_double', is in the appropriate
        !           526:      range and return 1 if so, 0 otherwise.  If C is not one of those
        !           527:      letters, the value should be 0 regardless of VALUE.
1.1.1.3   root      528: 
                    529: 
1.1.1.4   root      530: File: gcc.info,  Node: Stack Layout,  Next: Library Calls,  Prev: Register Classes,  Up: Machine Macros
1.1       root      531: 
                    532: Describing Stack Layout
                    533: =======================
                    534: 
                    535: `STACK_GROWS_DOWNWARD'
1.1.1.5 ! root      536:      Define this macro if pushing a word onto the stack moves the stack
        !           537:      pointer to a smaller address.
1.1       root      538: 
1.1.1.2   root      539:      When we say, "define this macro if ...," it means that the
1.1       root      540:      compiler checks this macro only with `#ifdef' so the precise
                    541:      definition used does not matter.
                    542: 
                    543: `FRAME_GROWS_DOWNWARD'
1.1.1.5 ! root      544:      Define this macro if the addresses of local variable slots are at
        !           545:      negative offsets from the frame pointer.
1.1       root      546: 
                    547: `STARTING_FRAME_OFFSET'
1.1.1.5 ! root      548:      Offset from the frame pointer to the first local variable slot to
        !           549:      be allocated.
1.1       root      550: 
                    551:      If `FRAME_GROWS_DOWNWARD', the next slot's offset is found by
                    552:      subtracting the length of the first slot from
1.1.1.5 ! root      553:      `STARTING_FRAME_OFFSET'. Otherwise, it is found by adding the
1.1       root      554:      length of the first slot to the value `STARTING_FRAME_OFFSET'.
                    555: 
                    556: `PUSH_ROUNDING (NPUSHED)'
1.1.1.5 ! root      557:      A C expression that is the number of bytes actually pushed onto the
        !           558:      stack when an instruction attempts to push NPUSHED bytes.
1.1       root      559: 
                    560:      If the target machine does not have a push instruction, do not
                    561:      define this macro.  That directs GNU CC to use an alternate
1.1.1.5 ! root      562:      strategy: to allocate the entire argument block and then store the
        !           563:      arguments into it.
1.1       root      564: 
                    565:      On some machines, the definition
                    566: 
                    567:           #define PUSH_ROUNDING(BYTES) (BYTES)
                    568: 
1.1.1.5 ! root      569:      will suffice.  But on other machines, instructions that appear to
        !           570:      push one byte actually push two bytes in an attempt to maintain
        !           571:      alignment.  Then the definition should be
1.1       root      572: 
                    573:           #define PUSH_ROUNDING(BYTES) (((BYTES) + 1) & ~1)
                    574: 
                    575: `FIRST_PARM_OFFSET (FUNDECL)'
1.1.1.5 ! root      576:      Offset from the argument pointer register to the first argument's
        !           577:      address.  On some machines it may depend on the data type of the
        !           578:      function.  (In the next version of GNU CC, the argument will be
        !           579:      changed to the function data type rather than its declaration.)
1.1       root      580: 
                    581: `FIRST_PARM_CALLER_OFFSET (FUNDECL)'
1.1.1.5 ! root      582:      Define this macro on machines where register parameters have shadow
        !           583:      locations on the stack, at addresses below the nominal parameter.
        !           584:      This matters because certain arguments cannot be passed on the
        !           585:      stack. On these machines, such arguments must be stored into the
        !           586:      shadow locations.
1.1       root      587: 
                    588:      This macro should expand into a C expression whose value is the
                    589:      offset of the first parameter's shadow location from the nominal
1.1.1.5 ! root      590:      stack pointer value.  (That value is itself computed by adding the
        !           591:      value of `STACK_POINTER_OFFSET' to the stack pointer register.)
1.1       root      592: 
                    593: `REG_PARM_STACK_SPACE'
1.1.1.5 ! root      594:      Define this macro if functions should assume that stack space has
        !           595:      been allocated for arguments even when their values are passed in
        !           596:      registers.
1.1       root      597: 
                    598:      The actual allocation of such space would be done either by the
                    599:      call instruction or by the function prologue, or by defining
1.1.1.2   root      600:      `FIRST_PARM_CALLER_OFFSET'.
1.1       root      601: 
                    602: `STACK_ARGS_ADJUST (SIZE)'
1.1.1.5 ! root      603:      Define this macro if the machine requires padding on the stack for
        !           604:      certain function calls.  This is padding on a per-function-call
        !           605:      basis, not padding for individual arguments.
1.1       root      606: 
                    607:      The argument SIZE will be a C variable of type `struct arg_data'
1.1.1.5 ! root      608:      which contains two fields, an integer named `constant' and an RTX
        !           609:      named `var'.  These together represent a size measured in bytes
        !           610:      which is the sum of the integer and the RTX.  Most of the time
        !           611:      `var' is 0, which means that the size is simply the integer.
1.1       root      612: 
1.1.1.5 ! root      613:      The definition should be a C statement or compound statement which
        !           614:      alters the variable supplied in whatever way you wish.
1.1       root      615: 
                    616:      Note that the value you leave in the variable `size' will
                    617:      ultimately be rounded up to a multiple of `STACK_BOUNDARY' bits.
                    618: 
                    619:      This macro is not fully implemented for machines which have push
                    620:      instructions (i.e., on which `PUSH_ROUNDING' is defined).
                    621: 
                    622: `RETURN_POPS_ARGS (FUNTYPE)'
                    623:      A C expression that should be 1 if a function pops its own
1.1.1.5 ! root      624:      arguments on returning, or 0 if the function pops no arguments and
        !           625:      the caller must therefore pop them all after the function returns.
        !           626: 
        !           627:      FUNTYPE is a C variable whose value is a tree node that describes
        !           628:      the function in question.  Normally it is a node of type
        !           629:      `FUNCTION_TYPE' that describes the data type of the function. From
        !           630:      this it is possible to obtain the data types of the value and
        !           631:      arguments (if known).
1.1       root      632: 
                    633:      When a call to a library function is being considered, FUNTYPE
1.1.1.5 ! root      634:      will contain an identifier node for the library function.  Thus, if
        !           635:      you need to distinguish among various library functions, you can
        !           636:      do so by their names.  Note that "library function" in this
        !           637:      context means a function used to perform arithmetic, whose name is
        !           638:      known specially in the compiler and was not mentioned in the C
        !           639:      code being compiled.
1.1       root      640: 
                    641:      On the Vax, all functions always pop their arguments, so the
                    642:      definition of this macro is 1.  On the 68000, using the standard
1.1.1.5 ! root      643:      calling convention, no functions pop their arguments, so the value
        !           644:      of the macro is always 0 in this case.  But an alternative calling
        !           645:      convention is available in which functions that take a fixed
        !           646:      number of arguments pop them but other functions (such as
        !           647:      `printf') pop nothing (the caller pops all).  When this convention
        !           648:      is in use, FUNTYPE is examined to determine whether a function
        !           649:      takes a fixed number of arguments.
        !           650: 
        !           651:      When this macro returns nonzero, the macro `FRAME_POINTER_REQUIRED'
        !           652:      must also return nonzero for proper operation.
1.1.1.2   root      653: 
1.1       root      654: `FUNCTION_VALUE (VALTYPE, FUNC)'
                    655:      A C expression to create an RTX representing the place where a
1.1.1.5 ! root      656:      function returns a value of data type VALTYPE.  VALTYPE is a tree
        !           657:      node representing a data type.  Write `TYPE_MODE (VALTYPE)' to get
        !           658:      the machine mode used to represent that type. On many machines,
        !           659:      only the mode is relevant.  (Actually, on most machines, scalar
        !           660:      values are returned in the same place regardless of mode).
        !           661: 
        !           662:      If the precise function being called is known, FUNC is a tree node
        !           663:      (`FUNCTION_DECL') for it; otherwise, FUNC is a null pointer.  This
        !           664:      makes it possible to use a different value-returning convention
        !           665:      for specific functions when all their calls are known.
1.1       root      666: 
                    667: `FUNCTION_OUTGOING_VALUE (VALTYPE, FUNC)'
1.1.1.5 ! root      668:      Define this macro if the target machine has "register windows" so
        !           669:      that the register in which a function returns its value is not the
        !           670:      same as the one in which the caller sees the value.
        !           671: 
        !           672:      For such machines, `FUNCTION_VALUE' computes the register in which
        !           673:      the caller will see the value, and `FUNCTION_OUTGOING_VALUE'
        !           674:      should be defined in a similar fashion to tell the function where
        !           675:      to put the value.
1.1       root      676: 
                    677:      If `FUNCTION_OUTGOING_VALUE' is not defined, `FUNCTION_VALUE'
                    678:      serves both purposes.
                    679: 
                    680: `RETURN_IN_MEMORY (TYPE)'
1.1.1.5 ! root      681:      A C expression which can inhibit the returning of certain function
        !           682:      values in registers, based on the type of value.  A nonzero value
        !           683:      says to return the function value in memory, just as large
        !           684:      structures are always returned.  Here TYPE will be a C expression
        !           685:      of type `tree', representing the data type of the value.
1.1       root      686: 
                    687:      Note that values of mode `BLKmode' are returned in memory
1.1.1.5 ! root      688:      regardless of this macro.  Also, the option `-fpcc-struct-return'
        !           689:      takes effect regardless of this macro.  On most systems, it is
        !           690:      possible to leave the macro undefined; this causes a default
        !           691:      definition to be used, whose value is the constant 0.
1.1       root      692: 
                    693: `LIBCALL_VALUE (MODE)'
                    694:      A C expression to create an RTX representing the place where a
                    695:      library function returns a value of mode MODE.  If the precise
                    696:      function being called is known, FUNC is a tree node
1.1.1.5 ! root      697:      (`FUNCTION_DECL') for it; otherwise, FUNC is a null pointer.  This
        !           698:      makes it possible to use a different value-returning convention
        !           699:      for specific functions when all their calls are known.
1.1       root      700: 
1.1.1.2   root      701:      Note that "library function" in this context means a compiler
1.1       root      702:      support routine, used to perform arithmetic, whose name is known
1.1.1.5 ! root      703:      specially by the compiler and was not mentioned in the C code being
        !           704:      compiled.
1.1       root      705: 
                    706: `FUNCTION_VALUE_REGNO_P (REGNO)'
                    707:      A C expression that is nonzero if REGNO is the number of a hard
                    708:      register in which the values of called function may come back.
                    709: 
1.1.1.5 ! root      710:      A register whose use for returning values is limited to serving as
        !           711:      the second of a pair (for a value of type `double', say) need not
        !           712:      be recognized by this macro.  So for most machines, this definition
        !           713:      suffices:
1.1       root      714: 
                    715:           #define FUNCTION_VALUE_REGNO_P(N) ((N) == 0)
                    716: 
                    717:      If the machine has register windows, so that the caller and the
1.1.1.5 ! root      718:      called function use different registers for the return value, this
        !           719:      macro should recognize only the caller's register numbers.
1.1       root      720: 
                    721: `FUNCTION_ARG (CUM, MODE, TYPE, NAMED)'
1.1.1.5 ! root      722:      A C expression that controls whether a function argument is passed
        !           723:      in a register, and which register.
1.1       root      724: 
                    725:      The arguments are CUM, which summarizes all the previous
1.1.1.5 ! root      726:      arguments; MODE, the machine mode of the argument; TYPE, the data
        !           727:      type of the argument as a tree node or 0 if that is not known
        !           728:      (which happens for C support library functions); and NAMED, which
        !           729:      is 1 for an ordinary argument and 0 for nameless arguments that
        !           730:      correspond to `...' in the called function's prototype.
1.1       root      731: 
                    732:      The value of the expression should either be a `reg' RTX for the
                    733:      hard register in which to pass the argument, or zero to pass the
                    734:      argument on the stack.
                    735: 
                    736:      For the Vax and 68000, where normally all arguments are pushed,
                    737:      zero suffices as a definition.
                    738: 
1.1.1.5 ! root      739:      The usual way to make the ANSI library `stdarg.h' work on a machine
        !           740:      where some arguments are usually passed in registers, is to cause
        !           741:      nameless arguments to be passed on the stack instead.  This is done
        !           742:      by making `FUNCTION_ARG' return 0 whenever NAMED is 0.
1.1       root      743: 
                    744: `FUNCTION_INCOMING_ARG (CUM, MODE, TYPE, NAMED)'
1.1.1.5 ! root      745:      Define this macro if the target machine has "register windows", so
        !           746:      that the register in which a function sees an arguments is not
        !           747:      necessarily the same as the one in which the caller passed the
        !           748:      argument.
1.1       root      749: 
                    750:      For such machines, `FUNCTION_ARG' computes the register in which
1.1.1.5 ! root      751:      the caller passes the value, and `FUNCTION_INCOMING_ARG' should be
        !           752:      defined in a similar fashion to tell the function being called
        !           753:      where the arguments will arrive.
1.1       root      754: 
                    755:      If `FUNCTION_INCOMING_ARG' is not defined, `FUNCTION_ARG' serves
                    756:      both purposes.
                    757: 
                    758: `FUNCTION_ARG_PARTIAL_NREGS (CUM, MODE, TYPE, NAMED)'
                    759:      A C expression for the number of words, at the beginning of an
                    760:      argument, must be put in registers.  The value must be zero for
                    761:      arguments that are passed entirely in registers or that are
                    762:      entirely pushed on the stack.
                    763: 
                    764:      On some machines, certain arguments must be passed partially in
                    765:      registers and partially in memory.  On these machines, typically
                    766:      the first N words of arguments are passed in registers, and the
                    767:      rest on the stack.  If a multi-word argument (a `double' or a
                    768:      structure) crosses that boundary, its first few words must be
1.1.1.5 ! root      769:      passed in registers and the rest must be pushed.  This macro tells
        !           770:      the compiler when this occurs, and how many of the words should go
        !           771:      in registers.
1.1       root      772: 
                    773:      `FUNCTION_ARG' for these arguments should return the first
                    774:      register to be used by the caller for this argument; likewise
                    775:      `FUNCTION_INCOMING_ARG', for the called function.
                    776: 
                    777: `CUMULATIVE_ARGS'
                    778:      A C type for declaring a variable that is used as the first
                    779:      argument of `FUNCTION_ARG' and other related values.  For some
1.1.1.5 ! root      780:      target machines, the type `int' suffices and can hold the number of
        !           781:      bytes of argument so far.
1.1       root      782: 
                    783: `INIT_CUMULATIVE_ARGS (CUM, FNTYPE)'
                    784:      A C statement (sans semicolon) for initializing the variable CUM
1.1.1.5 ! root      785:      for the state at the beginning of the argument list.  The variable
        !           786:      has type `CUMULATIVE_ARGS'.  The value of FNTYPE is the tree node
        !           787:      for the data type of the function which will receive the args, or 0
        !           788:      if the args are to a compiler support library function.
1.1       root      789: 
                    790: `FUNCTION_ARG_ADVANCE (CUM, MODE, TYPE, NAMED)'
                    791:      A C statement (sans semicolon) to update the summarizer variable
1.1.1.5 ! root      792:      CUM to advance past an argument in the argument list.  The values
        !           793:      MODE, TYPE and NAMED describe that argument. Once this is done,
        !           794:      the variable CUM is suitable for analyzing the *following*
        !           795:      argument with `FUNCTION_ARG', etc.
1.1       root      796: 
                    797: `FUNCTION_ARG_REGNO_P (REGNO)'
                    798:      A C expression that is nonzero if REGNO is the number of a hard
                    799:      register in which function arguments are sometimes passed.  This
1.1.1.5 ! root      800:      does *not* include implicit arguments such as the static chain and
        !           801:      the structure-value address.  On many machines, no registers can be
        !           802:      used for this purpose since all function arguments are pushed on
        !           803:      the stack.
1.1       root      804: 
                    805: `FUNCTION_ARG_PADDING (MODE, SIZE)'
1.1.1.5 ! root      806:      If defined, a C expression which determines whether, and in which
        !           807:      direction, to pad out an argument with extra space.  The value
        !           808:      should be of type `enum direction': either `upward' to pad above
        !           809:      the argument, `downward' to pad below, or `none' to inhibit
        !           810:      padding.
1.1       root      811: 
                    812:      The argument SIZE is an RTX which describes the size of the
1.1.1.5 ! root      813:      argument, in bytes.  It should be used only if MODE is `BLKmode'. 
        !           814:      Otherwise, SIZE is 0.
1.1       root      815: 
                    816:      This macro does not control the *amount* of padding; that is
                    817:      always just enough to reach the next multiple of `PARM_BOUNDARY'.
                    818: 
                    819:      This macro has a default definition which is right for most
1.1.1.5 ! root      820:      systems. For little-endian machines, the default is to pad upward.
        !           821:       For big-endian machines, the default is to pad downward for an
        !           822:      argument of constant size shorter than an `int', and upward
        !           823:      otherwise.
1.1       root      824: 
                    825: `FUNCTION_PROLOGUE (FILE, SIZE)'
                    826:      A C compound statement that outputs the assembler code for entry
                    827:      to a function.  The prologue is responsible for setting up the
                    828:      stack frame, initializing the frame pointer register, saving
1.1.1.5 ! root      829:      registers that must be saved, and allocating SIZE additional bytes
        !           830:      of storage for the local variables.  SIZE is an integer.  FILE is
        !           831:      a stdio stream to which the assembler code should be output.
1.1       root      832: 
1.1.1.5 ! root      833:      The label for the beginning of the function need not be output by
        !           834:      this macro.  That has already been done when the macro is run.
1.1       root      835: 
                    836:      To determine which registers to save, the macro can refer to the
1.1.1.5 ! root      837:      array `regs_ever_live': element R is nonzero if hard register R is
        !           838:      used anywhere within the function.  This implies the function
1.1       root      839:      prologue should save register R, but not if it is one of the
                    840:      call-used registers.
                    841: 
1.1.1.5 ! root      842:      On machines where functions may or may not have frame-pointers, the
        !           843:      function entry code must vary accordingly; it must set up the frame
        !           844:      pointer if one is wanted, and not otherwise.  To determine whether
        !           845:      a frame pointer is in wanted, the macro can refer to the variable
        !           846:      `frame_pointer_needed'.  The variable's value will be 1 at run
        !           847:      time in a function that needs a frame pointer.
        !           848: 
        !           849:      On machines where an argument may be passed partly in registers and
        !           850:      partly in memory, this macro must examine the variable
        !           851:      `current_function_pretend_args_size', and allocate that many bytes
        !           852:      of uninitialized space on the stack just underneath the first
        !           853:      argument arriving on the stack.  (This may not be at the very end
        !           854:      of the stack, if the calling sequence has pushed anything else
        !           855:      since pushing the stack arguments.  But usually, on such machines,
        !           856:      nothing else has been pushed yet, because the function prologue
        !           857:      itself does all the pushing.)
1.1       root      858: 
                    859: `FUNCTION_PROFILER (FILE, LABELNO)'
                    860:      A C statement or compound statement to output to FILE some
1.1.1.5 ! root      861:      assembler code to call the profiling subroutine `mcount'. Before
        !           862:      calling, the assembler code must load the address of a counter
        !           863:      variable into a register where `mcount' expects to find the
        !           864:      address.  The name of this variable is `LP' followed by the number
        !           865:      LABELNO, so you would generate the name using `LP%d' in a
1.1       root      866:      `fprintf'.
                    867: 
                    868:      The details of how the address should be passed to `mcount' are
1.1.1.5 ! root      869:      determined by your operating system environment, not by GNU CC.  To
        !           870:      figure them out, compile a small program for profiling using the
        !           871:      system's installed C compiler and look at the assembler code that
        !           872:      results.
1.1       root      873: 
                    874: `FUNCTION_BLOCK_PROFILER (FILE, LABELNO)'
                    875:      A C statement or compound statement to output to FILE some
1.1.1.5 ! root      876:      assembler code to initialize basic-block profiling for the current
        !           877:      object module.  This code should call the subroutine
1.1       root      878:      `__bb_init_func' once per object module, passing it as its sole
                    879:      argument the address of a block allocated in the object module.
                    880: 
                    881:      The name of the block is a local symbol made with this statement:
                    882: 
                    883:           ASM_GENERATE_INTERNAL_LABEL (BUFFER, "LPBX", 0);
                    884: 
                    885:      Of course, since you are writing the definition of
                    886:      `ASM_GENERATE_INTERNAL_LABEL' as well as that of this macro, you
                    887:      can take a short cut in the definition of this macro and use the
                    888:      name that you know will result.
                    889: 
1.1.1.5 ! root      890:      The first word of this block is a flag which will be nonzero if the
        !           891:      object module has already been initialized.  So test this word
        !           892:      first, and do not call `__bb_init_func' if the flag is nonzero.
1.1       root      893: 
                    894: `BLOCK_PROFILER (FILE, BLOCKNO)'
                    895:      A C statement or compound statement to increment the count
1.1.1.5 ! root      896:      associated with the basic block number BLOCKNO.  Basic blocks are
        !           897:      numbered separately from zero within each compilation.  The count
        !           898:      associated with block number BLOCKNO is at index BLOCKNO in a
        !           899:      vector of words; the name of this array is a local symbol made
        !           900:      with this statement:
1.1       root      901: 
                    902:           ASM_GENERATE_INTERNAL_LABEL (BUFFER, "LPBX", 2);
                    903: 
                    904:      Of course, since you are writing the definition of
                    905:      `ASM_GENERATE_INTERNAL_LABEL' as well as that of this macro, you
                    906:      can take a short cut in the definition of this macro and use the
                    907:      name that you know will result.
                    908: 
1.1.1.2   root      909: `EXIT_IGNORE_STACK'
1.1.1.5 ! root      910:      Define this macro as a C expression that is nonzero if the return
        !           911:      instruction or the function epilogue ignores the value of the stack
        !           912:      pointer; in other words, if it is safe to delete an instruction to
        !           913:      adjust the stack pointer before a return from the function.
1.1       root      914: 
                    915:      Note that this macro's value is relevant only for functions for
1.1.1.5 ! root      916:      which frame pointers are maintained.  It is never safe to delete a
        !           917:      final stack adjustment in a function that has no frame pointer,
        !           918:      and the compiler knows this regardless of `EXIT_IGNORE_STACK'.
1.1       root      919: 
                    920: `FUNCTION_EPILOGUE (FILE, SIZE)'
                    921:      A C compound statement that outputs the assembler code for exit
                    922:      from a function.  The epilogue is responsible for restoring the
                    923:      saved registers and stack pointer to their values when the
                    924:      function was called, and returning control to the caller.  This
                    925:      macro takes the same arguments as the macro `FUNCTION_PROLOGUE',
1.1.1.5 ! root      926:      and the registers to restore are determined from `regs_ever_live'
        !           927:      and `CALL_USED_REGISTERS' in the same way.
1.1       root      928: 
1.1.1.5 ! root      929:      On some machines, there is a single instruction that does all the
        !           930:      work of returning from the function.  On these machines, give that
        !           931:      instruction the name `return' and do not define the macro
        !           932:      `FUNCTION_EPILOGUE' at all.
1.1       root      933: 
                    934:      Do not define a pattern named `return' if you want the
                    935:      `FUNCTION_EPILOGUE' to be used.  If you want the target switches
                    936:      to control whether return instructions or epilogues are used,
1.1.1.5 ! root      937:      define a `return' pattern with a validity condition that tests the
        !           938:      target switches appropriately.  If the `return' pattern's validity
        !           939:      condition is false, epilogues will be used.
        !           940: 
        !           941:      On machines where functions may or may not have frame-pointers, the
        !           942:      function exit code must vary accordingly.  Sometimes the code for
        !           943:      these two cases is completely different.  To determine whether a
        !           944:      frame pointer is in wanted, the macro can refer to the variable
        !           945:      `frame_pointer_needed'.  The variable's value will be 1 at run
        !           946:      time in a function that needs a frame pointer.
        !           947: 
        !           948:      On some machines, some functions pop their arguments on exit while
        !           949:      others leave that for the caller to do.  For example, the 68020
        !           950:      when given `-mrtd' pops arguments in functions that take a fixed
        !           951:      number of arguments.
1.1       root      952: 
                    953:      Your definition of the macro `RETURN_POPS_ARGS' decides which
                    954:      functions pop their own arguments.  `FUNCTION_EPILOGUE' needs to
1.1.1.5 ! root      955:      know what was decided.  The variable `current_function_pops_args'
        !           956:      is nonzero if the function should pop its own arguments.  If so,
        !           957:      use the variable `current_function_args_size' as the number of
        !           958:      bytes to pop.
1.1       root      959: 
                    960: `FIX_FRAME_POINTER_ADDRESS (ADDR, DEPTH)'
                    961:      A C compound statement to alter a memory address that uses the
1.1.1.5 ! root      962:      frame pointer register so that it uses the stack pointer register
        !           963:      instead. This must be done in the instructions that load parameter
        !           964:      values into registers, when the reload pass determines that a
        !           965:      frame pointer is not necessary for the function.  ADDR will be a C
        !           966:      variable name, and the updated address should be stored in that
        !           967:      variable.  DEPTH will be the current depth of stack temporaries
        !           968:      (number of bytes of arguments currently pushed).  The change in
        !           969:      offset between a frame-pointer-relative address and a
        !           970:      stack-pointer-relative address must include DEPTH.
        !           971: 
        !           972:      Even if your machine description specifies there will always be a
        !           973:      frame pointer in the frame pointer register, you must still define
        !           974:      `FIX_FRAME_POINTER_ADDRESS', but the definition will never be
        !           975:      executed at run time, so it may be empty.
1.1       root      976: 
                    977: `LONGJMP_RESTORE_FROM_STACK'
                    978:      Define this macro if the `longjmp' function restores registers
1.1.1.5 ! root      979:      from the stack frames, rather than from those saved specifically by
        !           980:      `setjmp'.  Certain quantities must not be kept in registers across
        !           981:      a call to `setjmp' on such machines.
1.1       root      982: 
                    983: 
1.1.1.4   root      984: File: gcc.info,  Node: Library Calls,  Next: Addressing Modes,  Prev: Stack Layout,  Up: Machine Macros
1.1       root      985: 
1.1.1.4   root      986: Implicit Use of Library Routines
                    987: ================================
1.1       root      988: 
                    989: `MULSI3_LIBCALL'
                    990:      A C string constant giving the name of the function to call for
1.1.1.5 ! root      991:      multiplication of one signed full-word by another.  If you do not
        !           992:      define this macro, the default name is used, which is `__mulsi3',
        !           993:      a function defined in `gnulib'.
1.1       root      994: 
                    995: `UMULSI3_LIBCALL'
                    996:      A C string constant giving the name of the function to call for
1.1.1.5 ! root      997:      multiplication of one unsigned full-word by another.  If you do not
        !           998:      define this macro, the default name is used, which is `__umulsi3',
        !           999:      a function defined in `gnulib'.
1.1       root     1000: 
                   1001: `DIVSI3_LIBCALL'
                   1002:      A C string constant giving the name of the function to call for
1.1.1.5 ! root     1003:      division of one signed full-word by another.  If you do not define
        !          1004:      this macro, the default name is used, which is `__divsi3', a
        !          1005:      function defined in `gnulib'.
1.1       root     1006: 
                   1007: `UDIVSI3_LIBCALL'
                   1008:      A C string constant giving the name of the function to call for
                   1009:      division of one unsigned full-word by another.  If you do not
1.1.1.5 ! root     1010:      define this macro, the default name is used, which is `__udivsi3',
        !          1011:      a function defined in `gnulib'.
1.1       root     1012: 
                   1013: `MODSI3_LIBCALL'
1.1.1.5 ! root     1014:      A C string constant giving the name of the function to call for the
        !          1015:      remainder in division of one signed full-word by another.  If you
        !          1016:      do not define this macro, the default name is used, which is
        !          1017:      `__modsi3', a function defined in `gnulib'.
1.1       root     1018: 
                   1019: `UMODSI3_LIBCALL'
1.1.1.5 ! root     1020:      A C string constant giving the name of the function to call for the
        !          1021:      remainder in division of one unsigned full-word by another.  If
        !          1022:      you do not define this macro, the default name is used, which is
        !          1023:      `__umodsi3', a function defined in `gnulib'.
1.1       root     1024: 
                   1025: `TARGET_MEM_FUNCTIONS'
1.1.1.5 ! root     1026:      Define this macro if GNU CC should generate calls to the System V
        !          1027:      (and ANSI C) library functions `memcpy' and `memset' rather than
        !          1028:      the BSD functions `bcopy' and `bzero'.
1.1       root     1029: 
1.1.1.4   root     1030: `GNULIB_NEEDS_DOUBLE'
                   1031:      Define this macro if only `float' arguments cannot be passed to
                   1032:      library routines (so they must be converted to `double').  This
                   1033:      macro affects both how library calls are generated and how the
                   1034:      library routines in `gnulib.c' accept their arguments.  It is
                   1035:      useful on machines where floating and fixed point arguments are
                   1036:      passed differently, such as the i860.
1.1       root     1037: 
1.1.1.4   root     1038: 

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.