Ignore:
Timestamp:
Aug 16, 2003, 6:59:22 PM (22 years ago)
Author:
bird
Message:

binutils v2.14 - offical sources.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/GNU/src/binutils/bfd/reloc.c

    • Property cvs2svn:cvs-rev changed from 1.1 to 1.1.1.2
    r608 r609  
    11/* BFD support for handling relocation entries.
    22   Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
    3    2000, 2001
     3   2000, 2001, 2002, 2003
    44   Free Software Foundation, Inc.
    55   Written by Cygnus Support.
    66
    7 This file is part of BFD, the Binary File Descriptor library.
    8 
    9 This program is free software; you can redistribute it and/or modify
    10 it under the terms of the GNU General Public License as published by
    11 the Free Software Foundation; either version 2 of the License, or
    12 (at your option) any later version.
    13 
    14 This program is distributed in the hope that it will be useful,
    15 but WITHOUT ANY WARRANTY; without even the implied warranty of
    16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    17 GNU General Public License for more details.
    18 
    19 You should have received a copy of the GNU General Public License
    20 along with this program; if not, write to the Free Software
    21 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
     7   This file is part of BFD, the Binary File Descriptor library.
     8
     9   This program is free software; you can redistribute it and/or modify
     10   it under the terms of the GNU General Public License as published by
     11   the Free Software Foundation; either version 2 of the License, or
     12   (at your option) any later version.
     13
     14   This program is distributed in the hope that it will be useful,
     15   but WITHOUT ANY WARRANTY; without even the implied warranty of
     16   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     17   GNU General Public License for more details.
     18
     19   You should have received a copy of the GNU General Public License
     20   along with this program; if not, write to the Free Software
     21   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
    2222
    2323/*
     
    6666.typedef enum bfd_reloc_status
    6767.{
    68      {* No errors detected *}
     68{* No errors detected. *}
    6969.  bfd_reloc_ok,
    7070.
    71      {* The relocation was performed, but there was an overflow. *}
     71{* The relocation was performed, but there was an overflow. *}
    7272.  bfd_reloc_overflow,
    7373.
    74      {* The address to relocate was not within the section supplied. *}
     74{* The address to relocate was not within the section supplied. *}
    7575.  bfd_reloc_outofrange,
    7676.
    77      {* Used by special functions *}
     77{* Used by special functions. *}
    7878.  bfd_reloc_continue,
    7979.
    80      {* Unsupported relocation size requested. *}
     80{* Unsupported relocation size requested. *}
    8181.  bfd_reloc_notsupported,
    8282.
    83      {* Unused *}
     83{* Unused. *}
    8484.  bfd_reloc_other,
    8585.
    86      {* The symbol to relocate against was undefined. *}
     86{* The symbol to relocate against was undefined. *}
    8787.  bfd_reloc_undefined,
    8888.
    89      {* The relocation was performed, but may not be ok - presently
    90 .          generated only when linking i960 coff files with i960 b.out
    91 .          symbols.  If this type is returned, the error_message argument
    92 .          to bfd_perform_relocation will be set.  *}
     89{* The relocation was performed, but may not be ok - presently
     90.     generated only when linking i960 coff files with i960 b.out
     91.     symbols.  If this type is returned, the error_message argument
     92.     to bfd_perform_relocation will be set.  *}
    9393.  bfd_reloc_dangerous
    9494. }
     
    9898.typedef struct reloc_cache_entry
    9999.{
    100      {* A pointer into the canonical table of pointers  *}
     100{* A pointer into the canonical table of pointers.  *}
    101101.  struct symbol_cache_entry **sym_ptr_ptr;
    102102.
    103      {* offset in section *}
     103{* offset in section. *}
    104104.  bfd_size_type address;
    105105.
    106      {* addend for relocation value *}
     106{* addend for relocation value. *}
    107107.  bfd_vma addend;
    108108.
    109      {* Pointer to how to perform the required relocation *}
     109{* Pointer to how to perform the required relocation. *}
    110110.  reloc_howto_type *howto;
    111111.
    112 .} arelent;
    113 
     112.}
     113.arelent;
     114.
    114115*/
    115116
     
    251252.enum complain_overflow
    252253.{
    253 .       {* Do not complain on overflow. *}
     254.  {* Do not complain on overflow. *}
    254255.  complain_overflow_dont,
    255256.
    256 .       {* Complain if the bitfield overflows, whether it is considered
    257 .          as signed or unsigned. *}
     257.  {* Complain if the bitfield overflows, whether it is considered
     258.     as signed or unsigned. *}
    258259.  complain_overflow_bitfield,
    259260.
    260 .       {* Complain if the value overflows when considered as signed
    261 .          number. *}
     261.  {* Complain if the value overflows when considered as signed
     262.     number. *}
    262263.  complain_overflow_signed,
    263264.
    264 .       {* Complain if the value overflows when considered as an
    265 .          unsigned number. *}
     265.  {* Complain if the value overflows when considered as an
     266.     unsigned number. *}
    266267.  complain_overflow_unsigned
    267268.};
     
    277278
    278279CODE_FRAGMENT
    279 .struct symbol_cache_entry;             {* Forward declaration *}
     280.struct symbol_cache_entry;             {* Forward declaration. *}
    280281.
    281282.struct reloc_howto_struct
    282283.{
    283      {*  The type field has mainly a documentary use - the back end can
    284 .           do what it wants with it, though normally the back end's
    285 .           external idea of what a reloc number is stored
    286 .           in this field. For example, a PC relative word relocation
    287 .           in a coff environment has the type 023 - because that's
    288 .           what the outside world calls a R_PCRWORD reloc. *}
     284{*  The type field has mainly a documentary use - the back end can
     285.      do what it wants with it, though normally the back end's
     286.      external idea of what a reloc number is stored
     287.      in this field. For example, a PC relative word relocation
     288.      in a coff environment has the type 023 - because that's
     289.      what the outside world calls a R_PCRWORD reloc. *}
    289290.  unsigned int type;
    290291.
    291      {*  The value the final relocation is shifted right by. This drops
    292 .           unwanted data from the relocation.  *}
     292{*  The value the final relocation is shifted right by. This drops
     293.      unwanted data from the relocation.  *}
    293294.  unsigned int rightshift;
    294295.
    295 .       {*  The size of the item to be relocated.  This is *not* a
    296 .           power-of-two measure.  To get the number of bytes operated
    297 .           on by a type of relocation, use bfd_get_reloc_size.  *}
     296.  {*  The size of the item to be relocated.  This is *not* a
     297.      power-of-two measure.  To get the number of bytes operated
     298.      on by a type of relocation, use bfd_get_reloc_size.  *}
    298299.  int size;
    299300.
    300      {*  The number of bits in the item to be relocated.  This is used
    301 .           when doing overflow checking.  *}
     301{*  The number of bits in the item to be relocated.  This is used
     302.      when doing overflow checking.  *}
    302303.  unsigned int bitsize;
    303304.
    304      {*  Notes that the relocation is relative to the location in the
    305 .           data section of the addend. The relocation function will
    306 .           subtract from the relocation value the address of the location
    307 .           being relocated. *}
    308 .  boolean pc_relative;
     305{*  Notes that the relocation is relative to the location in the
     306.      data section of the addend. The relocation function will
     307.      subtract from the relocation value the address of the location
     308.      being relocated. *}
     309.  bfd_boolean pc_relative;
    309310.
    310 .       {*  The bit position of the reloc value in the destination.
    311 .           The relocated value is left shifted by this amount. *}
     311.  {*  The bit position of the reloc value in the destination.
     312.      The relocated value is left shifted by this amount. *}
    312313.  unsigned int bitpos;
    313314.
    314 .       {* What type of overflow error should be checked for when
    315 .          relocating. *}
     315.  {* What type of overflow error should be checked for when
     316.     relocating. *}
    316317.  enum complain_overflow complain_on_overflow;
    317318.
    318      {* If this field is non null, then the supplied function is
    319 .          called rather than the normal function. This allows really
    320 .          strange relocation methods to be accomodated (e.g., i960 callj
    321 .          instructions). *}
     319{* If this field is non null, then the supplied function is
     320.     called rather than the normal function. This allows really
     321.     strange relocation methods to be accomodated (e.g., i960 callj
     322.     instructions). *}
    322323.  bfd_reloc_status_type (*special_function)
    323 .                                   PARAMS ((bfd *abfd,
    324 .                                            arelent *reloc_entry,
    325 .                                            struct symbol_cache_entry *symbol,
    326 .                                            PTR data,
    327 .                                            asection *input_section,
    328 .                                            bfd *output_bfd,
    329 .                                            char **error_message));
     324.    PARAMS ((bfd *, arelent *, struct symbol_cache_entry *, PTR, asection *,
     325.             bfd *, char **));
    330326.
    331      {* The textual name of the relocation type. *}
     327{* The textual name of the relocation type. *}
    332328.  char *name;
    333329.
    334      {* Some formats record a relocation addend in the section contents
    335 .          rather than with the relocation.  For ELF formats this is the
    336 .          distinction between USE_REL and USE_RELA (though the code checks
    337 .          for USE_REL == 1/0).  The value of this field is TRUE if the
    338 .          addend is recorded with the section contents; when performing a
    339 .          partial link (ld -r) the section contents (the data) will be
    340 .          modified.  The value of this field is FALSE if addends are
    341 .          recorded with the relocation (in arelent.addend); when performing
    342 .          a partial link the relocation will be modified.
    343 .          All relocations for all ELF USE_RELA targets should set this field
    344 .          to FALSE (values of TRUE should be looked on with suspicion).
    345 .          However, the converse is not true: not all relocations of all ELF
    346 .          USE_REL targets set this field to TRUE.  Why this is so is peculiar
    347 .          to each particular target.  For relocs that aren't used in partial
    348 .          links (e.g. GOT stuff) it doesn't matter what this is set to.  *}
    349 .  boolean partial_inplace;
     330{* Some formats record a relocation addend in the section contents
     331.     rather than with the relocation.  For ELF formats this is the
     332.     distinction between USE_REL and USE_RELA (though the code checks
     333.     for USE_REL == 1/0).  The value of this field is TRUE if the
     334.     addend is recorded with the section contents; when performing a
     335.     partial link (ld -r) the section contents (the data) will be
     336.     modified.  The value of this field is FALSE if addends are
     337.     recorded with the relocation (in arelent.addend); when performing
     338.     a partial link the relocation will be modified.
     339.     All relocations for all ELF USE_RELA targets should set this field
     340.     to FALSE (values of TRUE should be looked on with suspicion).
     341.     However, the converse is not true: not all relocations of all ELF
     342.     USE_REL targets set this field to TRUE.  Why this is so is peculiar
     343.     to each particular target.  For relocs that aren't used in partial
     344.     links (e.g. GOT stuff) it doesn't matter what this is set to.  *}
     345.  bfd_boolean partial_inplace;
    350346.
    351 .       {* The src_mask selects which parts of the read in data
    352 .          are to be used in the relocation sum.  E.g., if this was an 8 bit
    353 .          byte of data which we read and relocated, this would be
    354 .          0x000000ff. When we have relocs which have an addend, such as
    355 .          sun4 extended relocs, the value in the offset part of a
    356 .          relocating field is garbage so we never use it. In this case
    357 .          the mask would be 0x00000000. *}
     347.  {* src_mask selects the part of the instruction (or data) to be used
     348.     in the relocation sum.  If the target relocations don't have an
     349.     addend in the reloc, eg. ELF USE_REL, src_mask will normally equal
     350.     dst_mask to extract the addend from the section contents.  If
     351.     relocations do have an addend in the reloc, eg. ELF USE_RELA, this
     352.     field should be zero.  Non-zero values for ELF USE_RELA targets are
     353.     bogus as in those cases the value in the dst_mask part of the
     354.     section contents should be treated as garbage.  *}
    358355.  bfd_vma src_mask;
    359356.
    360 .       {* The dst_mask selects which parts of the instruction are replaced
    361 .          into the instruction. In most cases src_mask == dst_mask,
    362 .          except in the above special case, where dst_mask would be
    363 .          0x000000ff, and src_mask would be 0x00000000.   *}
     357.  {* dst_mask selects which parts of the instruction (or data) are
     358.     replaced with a relocated value.  *}
    364359.  bfd_vma dst_mask;
    365360.
    366 .       {* When some formats create PC relative instructions, they leave
    367 .          the value of the pc of the place being relocated in the offset
    368 .          slot of the instruction, so that a PC relative relocation can
    369 .          be made just by adding in an ordinary offset (e.g., sun3 a.out).
    370 .          Some formats leave the displacement part of an instruction
    371 .          empty (e.g., m88k bcs); this flag signals the fact.*}
    372 .  boolean pcrel_offset;
     361.  {* When some formats create PC relative instructions, they leave
     362.     the value of the pc of the place being relocated in the offset
     363.     slot of the instruction, so that a PC relative relocation can
     364.     be made just by adding in an ordinary offset (e.g., sun3 a.out).
     365.     Some formats leave the displacement part of an instruction
     366.     empty (e.g., m88k bcs); this flag signals the fact.  *}
     367.  bfd_boolean pcrel_offset;
     368.};
    373369.
    374 .};
    375 
    376370*/
    377371
     
    383377        The HOWTO define is horrible and will go away.
    384378
    385 .#define HOWTO(C, R,S,B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC) \
    386 .  {(unsigned)C,R,S,B, P, BI, O,SF,NAME,INPLACE,MASKSRC,MASKDST,PC}
     379.#define HOWTO(C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC) \
     380.  { (unsigned) C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC }
    387381
    388382DESCRIPTION
     
    390384        moment, we are compatible, so do it this way.
    391385
    392 .#define NEWHOWTO( FUNCTION, NAME,SIZE,REL,IN) HOWTO(0,0,SIZE,0,REL,0,complain_overflow_dont,FUNCTION, NAME,false,0,0,IN)
     386.#define NEWHOWTO(FUNCTION, NAME, SIZE, REL, IN) \
     387.  HOWTO (0, 0, SIZE, 0, REL, 0, complain_overflow_dont, FUNCTION, \
     388.         NAME, FALSE, 0, 0, IN)
    393389.
    394390
     
    397393
    398394.#define EMPTY_HOWTO(C) \
    399 .  HOWTO((C),0,0,0,false,0,complain_overflow_dont,NULL,NULL,false,0,0,false)
     395.  HOWTO ((C), 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL, \
     396.         NULL, FALSE, 0, 0, FALSE)
    400397.
    401398
     
    403400        Helper routine to turn a symbol into a relocation value.
    404401
    405 .#define HOWTO_PREPARE(relocation, symbol)      \
    406 .  {                                            \
    407 .  if (symbol != (asymbol *)NULL) {             \
    408 .    if (bfd_is_com_section (symbol->section)) { \
    409 .      relocation = 0;                          \
    410 .    }                                          \
    411 .    else {                                     \
    412 .      relocation = symbol->value;              \
    413 .    }                                          \
    414 .  }                                            \
    415 .}
    416 
     402.#define HOWTO_PREPARE(relocation, symbol)               \
     403.  {                                                     \
     404.    if (symbol != (asymbol *) NULL)                     \
     405.      {                                                 \
     406.        if (bfd_is_com_section (symbol->section))       \
     407.          {                                             \
     408.            relocation = 0;                             \
     409.          }                                             \
     410.        else                                            \
     411.          {                                             \
     412.            relocation = symbol->value;                 \
     413.          }                                             \
     414.      }                                                 \
     415.  }
     416.
    417417*/
    418418
     
    454454        How relocs are tied together in an <<asection>>:
    455455
    456 .typedef struct relent_chain {
     456.typedef struct relent_chain
     457.{
    457458.  arelent relent;
    458 .  struct   relent_chain *next;
    459 .} arelent_chain;
    460 
     459.  struct relent_chain *next;
     460.}
     461.arelent_chain;
     462.
    461463*/
    462464
     
    627629
    628630  /* Is the address of the relocation really within the section?  */
    629   if (reloc_entry->address > input_section->_cooked_size /
    630       bfd_octets_per_byte (abfd))
     631  if (reloc_entry->address > (input_section->_cooked_size
     632                              / bfd_octets_per_byte (abfd)))
    631633    return bfd_reloc_outofrange;
    632634
     
    643645
    644646  /* Convert input-section-relative symbol value to absolute.  */
    645   if (output_bfd && howto->partial_inplace == false)
     647  if ((output_bfd && ! howto->partial_inplace)
     648      || reloc_target_output_section == NULL)
    646649    output_base = 0;
    647650  else
     
    656659     symbol we are relocating against, plus any addend.  */
    657660
    658   if (howto->pc_relative == true)
     661  if (howto->pc_relative)
    659662    {
    660663      /* This is a PC relative relocation.  We want to set RELOCATION
     
    669672         the addend to be the negative of the position of the location
    670673         within the section; for example, i386-aout does this.  For
    671          i386-aout, pcrel_offset is false.  Some other targets do not
     674         i386-aout, pcrel_offset is FALSE.  Some other targets do not
    672675         include the position of the location; for example, m88kbcs,
    673          or ELF.  For those targets, pcrel_offset is true.
     676         or ELF.  For those targets, pcrel_offset is TRUE.
    674677
    675678         If we are producing relocateable output, then we must ensure
    676679         that this reloc will be correctly computed when the final
    677          relocation is done.  If pcrel_offset is false we want to wind
     680         relocation is done.  If pcrel_offset is FALSE we want to wind
    678681         up with the negative of the location within the section,
    679682         which means we must adjust the existing addend by the change
    680          in the location within the section.  If pcrel_offset is true
     683         in the location within the section.  If pcrel_offset is TRUE
    681684         we do not want to adjust the existing addend at all.
    682685
     
    689692        input_section->output_section->vma + input_section->output_offset;
    690693
    691       if (howto->pcrel_offset == true)
     694      if (howto->pcrel_offset)
    692695        relocation -= reloc_entry->address;
    693696    }
     
    695698  if (output_bfd != (bfd *) NULL)
    696699    {
    697       if (howto->partial_inplace == false)
     700      if (! howto->partial_inplace)
    698701        {
    699702          /* This is a partial relocation, and we want to apply the relocation
     
    819822                               relocation);
    820823
    821   /*
    822     Either we are relocating all the way, or we don't want to apply
    823     the relocation to the reloc entry (probably because there isn't
    824     any room in the output format to describe addends to relocs)
    825     */
     824  /* Either we are relocating all the way, or we don't want to apply
     825     the relocation to the reloc entry (probably because there isn't
     826     any room in the output format to describe addends to relocs).  */
    826827
    827828  /* The cast to bfd_vma avoids a bug in the Alpha OSF/1 C compiler
     
    850851  relocation >>= (bfd_vma) howto->rightshift;
    851852
    852   /* Shift everything up to where it's going to be used */
    853 
     853  /* Shift everything up to where it's going to be used.  */
    854854  relocation <<= (bfd_vma) howto->bitpos;
    855855
    856   /* Wait for the day when all have the mask in them */
     856  /* Wait for the day when all have the mask in them. */
    857857
    858858  /* What we do:
     
    904904        short x = bfd_get_16 (abfd, (bfd_byte *) data + octets);
    905905        DOIT (x);
    906         bfd_put_16 (abfd, x, (unsigned char *) data + octets);
     906        bfd_put_16 (abfd, (bfd_vma) x, (unsigned char *) data + octets);
    907907      }
    908908      break;
     
    911911        long x = bfd_get_32 (abfd, (bfd_byte *) data + octets);
    912912        DOIT (x);
    913         bfd_put_32 (abfd, x, (bfd_byte *) data + octets);
     913        bfd_put_32 (abfd, (bfd_vma) x, (bfd_byte *) data + octets);
    914914      }
    915915      break;
     
    919919        relocation = -relocation;
    920920        DOIT (x);
    921         bfd_put_32 (abfd, x, (bfd_byte *) data + octets);
     921        bfd_put_32 (abfd, (bfd_vma) x, (bfd_byte *) data + octets);
    922922      }
    923923      break;
     
    928928        relocation = -relocation;
    929929        DOIT (x);
    930         bfd_put_16 (abfd, x, (bfd_byte *) data + octets);
     930        bfd_put_16 (abfd, (bfd_vma) x, (bfd_byte *) data + octets);
    931931      }
    932932      break;
     
    975975        For now, this function should be considered reserved for the
    976976        assembler.
    977 
    978977*/
    979978
     
    10231022
    10241023  /* Is the address of the relocation really within the section?  */
    1025   if (reloc_entry->address > input_section->_cooked_size)
     1024  if (reloc_entry->address > (input_section->_cooked_size
     1025                              / bfd_octets_per_byte (abfd)))
    10261026    return bfd_reloc_outofrange;
    10271027
     
    10381038
    10391039  /* Convert input-section-relative symbol value to absolute.  */
    1040   if (howto->partial_inplace == false)
     1040  if (! howto->partial_inplace)
    10411041    output_base = 0;
    10421042  else
     
    10511051     symbol we are relocating against, plus any addend.  */
    10521052
    1053   if (howto->pc_relative == true)
     1053  if (howto->pc_relative)
    10541054    {
    10551055      /* This is a PC relative relocation.  We want to set RELOCATION
     
    10641064         the addend to be the negative of the position of the location
    10651065         within the section; for example, i386-aout does this.  For
    1066          i386-aout, pcrel_offset is false.  Some other targets do not
     1066         i386-aout, pcrel_offset is FALSE.  Some other targets do not
    10671067         include the position of the location; for example, m88kbcs,
    1068          or ELF.  For those targets, pcrel_offset is true.
     1068         or ELF.  For those targets, pcrel_offset is TRUE.
    10691069
    10701070         If we are producing relocateable output, then we must ensure
    10711071         that this reloc will be correctly computed when the final
    1072          relocation is done.  If pcrel_offset is false we want to wind
     1072         relocation is done.  If pcrel_offset is FALSE we want to wind
    10731073         up with the negative of the location within the section,
    10741074         which means we must adjust the existing addend by the change
    1075          in the location within the section.  If pcrel_offset is true
     1075         in the location within the section.  If pcrel_offset is TRUE
    10761076         we do not want to adjust the existing addend at all.
    10771077
     
    10841084        input_section->output_section->vma + input_section->output_offset;
    10851085
    1086       if (howto->pcrel_offset == true && howto->partial_inplace == true)
     1086      if (howto->pcrel_offset && howto->partial_inplace)
    10871087        relocation -= reloc_entry->address;
    10881088    }
    10891089
    1090   if (howto->partial_inplace == false)
     1090  if (! howto->partial_inplace)
    10911091    {
    10921092      /* This is a partial relocation, and we want to apply the relocation
     
    11041104         If we've relocated with a symbol with a section, change
    11051105         into a ref to the section belonging to the symbol.  */
    1106 
    11071106      reloc_entry->address += input_section->output_offset;
    11081107
     
    11801179       made it no worse
    11811180    7) if they are different you have to figure out which version is
    1182        right
    1183 */
     1181       right.  */
    11841182          relocation -= reloc_entry->addend;
    11851183#endif
     
    12061204                               relocation);
    12071205
    1208   /*
    1209     Either we are relocating all the way, or we don't want to apply
    1210     the relocation to the reloc entry (probably because there isn't
    1211     any room in the output format to describe addends to relocs)
    1212     */
     1206  /* Either we are relocating all the way, or we don't want to apply
     1207     the relocation to the reloc entry (probably because there isn't
     1208     any room in the output format to describe addends to relocs).  */
    12131209
    12141210  /* The cast to bfd_vma avoids a bug in the Alpha OSF/1 C compiler
     
    12371233  relocation >>= (bfd_vma) howto->rightshift;
    12381234
    1239   /* Shift everything up to where it's going to be used */
    1240 
     1235  /* Shift everything up to where it's going to be used.  */
    12411236  relocation <<= (bfd_vma) howto->bitpos;
    12421237
    1243   /* Wait for the day when all have the mask in them */
     1238  /* Wait for the day when all have the mask in them. */
    12441239
    12451240  /* What we do:
     
    12931288        short x = bfd_get_16 (abfd, (bfd_byte *) data);
    12941289        DOIT (x);
    1295         bfd_put_16 (abfd, x, (unsigned char *) data);
     1290        bfd_put_16 (abfd, (bfd_vma) x, (unsigned char *) data);
    12961291      }
    12971292      break;
     
    13001295        long x = bfd_get_32 (abfd, (bfd_byte *) data);
    13011296        DOIT (x);
    1302         bfd_put_32 (abfd, x, (bfd_byte *) data);
     1297        bfd_put_32 (abfd, (bfd_vma) x, (bfd_byte *) data);
    13031298      }
    13041299      break;
     
    13081303        relocation = -relocation;
    13091304        DOIT (x);
    1310         bfd_put_32 (abfd, x, (bfd_byte *) data);
     1305        bfd_put_32 (abfd, (bfd_vma) x, (bfd_byte *) data);
    13111306      }
    13121307      break;
     
    13801375     arrange for the contents of the section to be the negative of the
    13811376     offset of the location within the section; for such targets
    1382      pcrel_offset is false.  Other targets (e.g., m88kbcs or ELF)
     1377     pcrel_offset is FALSE.  Other targets (e.g., m88kbcs or ELF)
    13831378     simply leave the contents of the section as zero; for such
    1384      targets pcrel_offset is true.  If pcrel_offset is false we do not
     1379     targets pcrel_offset is TRUE.  If pcrel_offset is FALSE we do not
    13851380     need to subtract out the offset of the location within the
    13861381     section (which is just ADDRESS).  */
     
    16821677  BFD_RELOC_8_GOTOFF
    16831678ENUMX
     1679  BFD_RELOC_64_PLT_PCREL
     1680ENUMX
    16841681  BFD_RELOC_32_PLT_PCREL
    16851682ENUMX
     
    16891686ENUMX
    16901687  BFD_RELOC_8_PLT_PCREL
     1688ENUMX
     1689  BFD_RELOC_64_PLTOFF
    16911690ENUMX
    16921691  BFD_RELOC_32_PLTOFF
     
    18521851  BFD_RELOC_64_PCREL
    18531852ENUMX
     1853  BFD_RELOC_SPARC_PLT32
     1854ENUMX
    18541855  BFD_RELOC_SPARC_PLT64
    18551856ENUMX
     
    18721873ENUMDOC
    18731874  SPARC little endian relocation
     1875ENUM
     1876  BFD_RELOC_SPARC_TLS_GD_HI22
     1877ENUMX
     1878  BFD_RELOC_SPARC_TLS_GD_LO10
     1879ENUMX
     1880  BFD_RELOC_SPARC_TLS_GD_ADD
     1881ENUMX
     1882  BFD_RELOC_SPARC_TLS_GD_CALL
     1883ENUMX
     1884  BFD_RELOC_SPARC_TLS_LDM_HI22
     1885ENUMX
     1886  BFD_RELOC_SPARC_TLS_LDM_LO10
     1887ENUMX
     1888  BFD_RELOC_SPARC_TLS_LDM_ADD
     1889ENUMX
     1890  BFD_RELOC_SPARC_TLS_LDM_CALL
     1891ENUMX
     1892  BFD_RELOC_SPARC_TLS_LDO_HIX22
     1893ENUMX
     1894  BFD_RELOC_SPARC_TLS_LDO_LOX10
     1895ENUMX
     1896  BFD_RELOC_SPARC_TLS_LDO_ADD
     1897ENUMX
     1898  BFD_RELOC_SPARC_TLS_IE_HI22
     1899ENUMX
     1900  BFD_RELOC_SPARC_TLS_IE_LO10
     1901ENUMX
     1902  BFD_RELOC_SPARC_TLS_IE_LD
     1903ENUMX
     1904  BFD_RELOC_SPARC_TLS_IE_LDX
     1905ENUMX
     1906  BFD_RELOC_SPARC_TLS_IE_ADD
     1907ENUMX
     1908  BFD_RELOC_SPARC_TLS_LE_HIX22
     1909ENUMX
     1910  BFD_RELOC_SPARC_TLS_LE_LOX10
     1911ENUMX
     1912  BFD_RELOC_SPARC_TLS_DTPMOD32
     1913ENUMX
     1914  BFD_RELOC_SPARC_TLS_DTPMOD64
     1915ENUMX
     1916  BFD_RELOC_SPARC_TLS_DTPOFF32
     1917ENUMX
     1918  BFD_RELOC_SPARC_TLS_DTPOFF64
     1919ENUMX
     1920  BFD_RELOC_SPARC_TLS_TPOFF32
     1921ENUMX
     1922  BFD_RELOC_SPARC_TLS_TPOFF64
     1923ENUMDOC
     1924  SPARC TLS relocations
    18741925
    18751926ENUM
     
    19281979              3 - jsr (target of branch)
    19291980
    1930      The GNU linker currently doesn't do any of this optimizing.
    1931 
    1932 ENUM
    1933   BFD_RELOC_ALPHA_USER_LITERAL
    1934 ENUMX
    1935   BFD_RELOC_ALPHA_USER_LITUSE_BASE
    1936 ENUMX
    1937   BFD_RELOC_ALPHA_USER_LITUSE_BYTOFF
    1938 ENUMX
    1939   BFD_RELOC_ALPHA_USER_LITUSE_JSR
    1940 ENUMX
    1941   BFD_RELOC_ALPHA_USER_GPDISP
    1942 ENUMX
    1943   BFD_RELOC_ALPHA_USER_GPRELHIGH
    1944 ENUMX
    1945   BFD_RELOC_ALPHA_USER_GPRELLOW
    1946 ENUMDOC
    1947   The BFD_RELOC_ALPHA_USER_* relocations are used by the assembler to
    1948      process the explicit !<reloc>!sequence relocations, and are mapped
    1949      into the normal relocations at the end of processing.
    1950 
    19511981ENUM
    19521982  BFD_RELOC_ALPHA_HINT
     
    19671997  The CODEADDR relocation outputs a STO_CA in the object file,
    19681998     which is filled by the linker.
     1999
     2000ENUM
     2001  BFD_RELOC_ALPHA_GPREL_HI16
     2002ENUMX
     2003  BFD_RELOC_ALPHA_GPREL_LO16
     2004ENUMDOC
     2005  The GPREL_HI/LO relocations together form a 32-bit offset from the
     2006     GP register.
     2007
     2008ENUM
     2009  BFD_RELOC_ALPHA_BRSGP
     2010ENUMDOC
     2011  Like BFD_RELOC_23_PCREL_S2, except that the source and target must
     2012  share a common GP, and the target address is adjusted for
     2013  STO_ALPHA_STD_GPLOAD.
     2014
     2015ENUM
     2016  BFD_RELOC_ALPHA_TLSGD
     2017ENUMX
     2018  BFD_RELOC_ALPHA_TLSLDM
     2019ENUMX
     2020  BFD_RELOC_ALPHA_DTPMOD64
     2021ENUMX
     2022  BFD_RELOC_ALPHA_GOTDTPREL16
     2023ENUMX
     2024  BFD_RELOC_ALPHA_DTPREL64
     2025ENUMX
     2026  BFD_RELOC_ALPHA_DTPREL_HI16
     2027ENUMX
     2028  BFD_RELOC_ALPHA_DTPREL_LO16
     2029ENUMX
     2030  BFD_RELOC_ALPHA_DTPREL16
     2031ENUMX
     2032  BFD_RELOC_ALPHA_GOTTPREL16
     2033ENUMX
     2034  BFD_RELOC_ALPHA_TPREL64
     2035ENUMX
     2036  BFD_RELOC_ALPHA_TPREL_HI16
     2037ENUMX
     2038  BFD_RELOC_ALPHA_TPREL_LO16
     2039ENUMX
     2040  BFD_RELOC_ALPHA_TPREL16
     2041ENUMDOC
     2042  Alpha thread-local storage relocations.
    19692043
    19702044ENUM
     
    20082082  Like BFD_RELOC_LO16, but PC relative.
    20092083
    2010 ENUMEQ
    2011   BFD_RELOC_MIPS_GPREL
    2012   BFD_RELOC_GPREL16
    2013 ENUMDOC
    2014   Relocation relative to the global pointer.
    2015 
    20162084ENUM
    20172085  BFD_RELOC_MIPS_LITERAL
     
    20232091ENUMX
    20242092  BFD_RELOC_MIPS_CALL16
    2025 ENUMEQX
    2026   BFD_RELOC_MIPS_GPREL32
    2027   BFD_RELOC_GPREL32
    20282093ENUMX
    20292094  BFD_RELOC_MIPS_GOT_HI16
     
    20652130  BFD_RELOC_MIPS_JALR
    20662131COMMENT
     2132ENUM
     2133  BFD_RELOC_FRV_LABEL16
     2134ENUMX
     2135  BFD_RELOC_FRV_LABEL24
     2136ENUMX
     2137  BFD_RELOC_FRV_LO16
     2138ENUMX
     2139  BFD_RELOC_FRV_HI16
     2140ENUMX
     2141  BFD_RELOC_FRV_GPREL12
     2142ENUMX
     2143  BFD_RELOC_FRV_GPRELU12
     2144ENUMX
     2145  BFD_RELOC_FRV_GPREL32
     2146ENUMX
     2147  BFD_RELOC_FRV_GPRELHI
     2148ENUMX
     2149  BFD_RELOC_FRV_GPRELLO
     2150ENUMDOC
     2151  Fujitsu Frv Relocations.
     2152COMMENT
     2153COMMENT
    20672154ENUMDOC
    20682155  MIPS ELF relocations.
     
    20862173ENUMX
    20872174  BFD_RELOC_386_GOTPC
     2175ENUMX
     2176  BFD_RELOC_386_TLS_TPOFF
     2177ENUMX
     2178  BFD_RELOC_386_TLS_IE
     2179ENUMX
     2180  BFD_RELOC_386_TLS_GOTIE
     2181ENUMX
     2182  BFD_RELOC_386_TLS_LE
     2183ENUMX
     2184  BFD_RELOC_386_TLS_GD
     2185ENUMX
     2186  BFD_RELOC_386_TLS_LDM
     2187ENUMX
     2188  BFD_RELOC_386_TLS_LDO_32
     2189ENUMX
     2190  BFD_RELOC_386_TLS_IE_32
     2191ENUMX
     2192  BFD_RELOC_386_TLS_LE_32
     2193ENUMX
     2194  BFD_RELOC_386_TLS_DTPMOD32
     2195ENUMX
     2196  BFD_RELOC_386_TLS_DTPOFF32
     2197ENUMX
     2198  BFD_RELOC_386_TLS_TPOFF32
    20882199ENUMDOC
    20892200  i386/elf relocations
     
    21052216ENUMX
    21062217  BFD_RELOC_X86_64_32S
     2218ENUMX
     2219  BFD_RELOC_X86_64_DTPMOD64
     2220ENUMX
     2221  BFD_RELOC_X86_64_DTPOFF64
     2222ENUMX
     2223  BFD_RELOC_X86_64_TPOFF64
     2224ENUMX
     2225  BFD_RELOC_X86_64_TLSGD
     2226ENUMX
     2227  BFD_RELOC_X86_64_TLSLD
     2228ENUMX
     2229  BFD_RELOC_X86_64_DTPOFF32
     2230ENUMX
     2231  BFD_RELOC_X86_64_GOTTPOFF
     2232ENUMX
     2233  BFD_RELOC_X86_64_TPOFF32
    21072234ENUMDOC
    21082235  x86-64/elf relocations
     
    21362263
    21372264ENUM
     2265  BFD_RELOC_PDP11_DISP_8_PCREL
     2266ENUMX
     2267  BFD_RELOC_PDP11_DISP_6_PCREL
     2268ENUMDOC
     2269  PDP11 relocations
     2270
     2271ENUM
    21382272  BFD_RELOC_PJ_CODE_HI16
    21392273ENUMX
     
    22102344ENUMX
    22112345  BFD_RELOC_PPC_EMB_RELSDA
     2346ENUMX
     2347  BFD_RELOC_PPC64_HIGHER
     2348ENUMX
     2349  BFD_RELOC_PPC64_HIGHER_S
     2350ENUMX
     2351  BFD_RELOC_PPC64_HIGHEST
     2352ENUMX
     2353  BFD_RELOC_PPC64_HIGHEST_S
     2354ENUMX
     2355  BFD_RELOC_PPC64_TOC16_LO
     2356ENUMX
     2357  BFD_RELOC_PPC64_TOC16_HI
     2358ENUMX
     2359  BFD_RELOC_PPC64_TOC16_HA
     2360ENUMX
     2361  BFD_RELOC_PPC64_TOC
     2362ENUMX
     2363  BFD_RELOC_PPC64_PLTGOT16
     2364ENUMX
     2365  BFD_RELOC_PPC64_PLTGOT16_LO
     2366ENUMX
     2367  BFD_RELOC_PPC64_PLTGOT16_HI
     2368ENUMX
     2369  BFD_RELOC_PPC64_PLTGOT16_HA
     2370ENUMX
     2371  BFD_RELOC_PPC64_ADDR16_DS
     2372ENUMX
     2373  BFD_RELOC_PPC64_ADDR16_LO_DS
     2374ENUMX
     2375  BFD_RELOC_PPC64_GOT16_DS
     2376ENUMX
     2377  BFD_RELOC_PPC64_GOT16_LO_DS
     2378ENUMX
     2379  BFD_RELOC_PPC64_PLT16_LO_DS
     2380ENUMX
     2381  BFD_RELOC_PPC64_SECTOFF_DS
     2382ENUMX
     2383  BFD_RELOC_PPC64_SECTOFF_LO_DS
     2384ENUMX
     2385  BFD_RELOC_PPC64_TOC16_DS
     2386ENUMX
     2387  BFD_RELOC_PPC64_TOC16_LO_DS
     2388ENUMX
     2389  BFD_RELOC_PPC64_PLTGOT16_DS
     2390ENUMX
     2391  BFD_RELOC_PPC64_PLTGOT16_LO_DS
    22122392ENUMDOC
    22132393  Power(rs6000) and PowerPC relocations.
     2394
     2395ENUM
     2396  BFD_RELOC_PPC_TLS
     2397ENUMX
     2398  BFD_RELOC_PPC_DTPMOD
     2399ENUMX
     2400  BFD_RELOC_PPC_TPREL16
     2401ENUMX
     2402  BFD_RELOC_PPC_TPREL16_LO
     2403ENUMX
     2404  BFD_RELOC_PPC_TPREL16_HI
     2405ENUMX
     2406  BFD_RELOC_PPC_TPREL16_HA
     2407ENUMX
     2408  BFD_RELOC_PPC_TPREL
     2409ENUMX
     2410  BFD_RELOC_PPC_DTPREL16
     2411ENUMX
     2412  BFD_RELOC_PPC_DTPREL16_LO
     2413ENUMX
     2414  BFD_RELOC_PPC_DTPREL16_HI
     2415ENUMX
     2416  BFD_RELOC_PPC_DTPREL16_HA
     2417ENUMX
     2418  BFD_RELOC_PPC_DTPREL
     2419ENUMX
     2420  BFD_RELOC_PPC_GOT_TLSGD16
     2421ENUMX
     2422  BFD_RELOC_PPC_GOT_TLSGD16_LO
     2423ENUMX
     2424  BFD_RELOC_PPC_GOT_TLSGD16_HI
     2425ENUMX
     2426  BFD_RELOC_PPC_GOT_TLSGD16_HA
     2427ENUMX
     2428  BFD_RELOC_PPC_GOT_TLSLD16
     2429ENUMX
     2430  BFD_RELOC_PPC_GOT_TLSLD16_LO
     2431ENUMX
     2432  BFD_RELOC_PPC_GOT_TLSLD16_HI
     2433ENUMX
     2434  BFD_RELOC_PPC_GOT_TLSLD16_HA
     2435ENUMX
     2436  BFD_RELOC_PPC_GOT_TPREL16
     2437ENUMX
     2438  BFD_RELOC_PPC_GOT_TPREL16_LO
     2439ENUMX
     2440  BFD_RELOC_PPC_GOT_TPREL16_HI
     2441ENUMX
     2442  BFD_RELOC_PPC_GOT_TPREL16_HA
     2443ENUMX
     2444  BFD_RELOC_PPC_GOT_DTPREL16
     2445ENUMX
     2446  BFD_RELOC_PPC_GOT_DTPREL16_LO
     2447ENUMX
     2448  BFD_RELOC_PPC_GOT_DTPREL16_HI
     2449ENUMX
     2450  BFD_RELOC_PPC_GOT_DTPREL16_HA
     2451ENUMX
     2452  BFD_RELOC_PPC64_TPREL16_DS
     2453ENUMX
     2454  BFD_RELOC_PPC64_TPREL16_LO_DS
     2455ENUMX
     2456  BFD_RELOC_PPC64_TPREL16_HIGHER
     2457ENUMX
     2458  BFD_RELOC_PPC64_TPREL16_HIGHERA
     2459ENUMX
     2460  BFD_RELOC_PPC64_TPREL16_HIGHEST
     2461ENUMX
     2462  BFD_RELOC_PPC64_TPREL16_HIGHESTA
     2463ENUMX
     2464  BFD_RELOC_PPC64_DTPREL16_DS
     2465ENUMX
     2466  BFD_RELOC_PPC64_DTPREL16_LO_DS
     2467ENUMX
     2468  BFD_RELOC_PPC64_DTPREL16_HIGHER
     2469ENUMX
     2470  BFD_RELOC_PPC64_DTPREL16_HIGHERA
     2471ENUMX
     2472  BFD_RELOC_PPC64_DTPREL16_HIGHEST
     2473ENUMX
     2474  BFD_RELOC_PPC64_DTPREL16_HIGHESTA
     2475ENUMDOC
     2476  PowerPC and PowerPC64 thread-local storage relocations.
    22142477
    22152478ENUM
     
    22572520  BFD_RELOC_ARM_CP_OFF_IMM
    22582521ENUMX
     2522  BFD_RELOC_ARM_CP_OFF_IMM_S2
     2523ENUMX
    22592524  BFD_RELOC_ARM_ADR_IMM
    22602525ENUMX
     
    23482613ENUMX
    23492614  BFD_RELOC_SH_GOTPC
    2350 ENUMDOC
    2351   Hitachi SH relocs.  Not all of these appear in object files.
     2615ENUMX
     2616  BFD_RELOC_SH_GOT_LOW16
     2617ENUMX
     2618  BFD_RELOC_SH_GOT_MEDLOW16
     2619ENUMX
     2620  BFD_RELOC_SH_GOT_MEDHI16
     2621ENUMX
     2622  BFD_RELOC_SH_GOT_HI16
     2623ENUMX
     2624  BFD_RELOC_SH_GOTPLT_LOW16
     2625ENUMX
     2626  BFD_RELOC_SH_GOTPLT_MEDLOW16
     2627ENUMX
     2628  BFD_RELOC_SH_GOTPLT_MEDHI16
     2629ENUMX
     2630  BFD_RELOC_SH_GOTPLT_HI16
     2631ENUMX
     2632  BFD_RELOC_SH_PLT_LOW16
     2633ENUMX
     2634  BFD_RELOC_SH_PLT_MEDLOW16
     2635ENUMX
     2636  BFD_RELOC_SH_PLT_MEDHI16
     2637ENUMX
     2638  BFD_RELOC_SH_PLT_HI16
     2639ENUMX
     2640  BFD_RELOC_SH_GOTOFF_LOW16
     2641ENUMX
     2642  BFD_RELOC_SH_GOTOFF_MEDLOW16
     2643ENUMX
     2644  BFD_RELOC_SH_GOTOFF_MEDHI16
     2645ENUMX
     2646  BFD_RELOC_SH_GOTOFF_HI16
     2647ENUMX
     2648  BFD_RELOC_SH_GOTPC_LOW16
     2649ENUMX
     2650  BFD_RELOC_SH_GOTPC_MEDLOW16
     2651ENUMX
     2652  BFD_RELOC_SH_GOTPC_MEDHI16
     2653ENUMX
     2654  BFD_RELOC_SH_GOTPC_HI16
     2655ENUMX
     2656  BFD_RELOC_SH_COPY64
     2657ENUMX
     2658  BFD_RELOC_SH_GLOB_DAT64
     2659ENUMX
     2660  BFD_RELOC_SH_JMP_SLOT64
     2661ENUMX
     2662  BFD_RELOC_SH_RELATIVE64
     2663ENUMX
     2664  BFD_RELOC_SH_GOT10BY4
     2665ENUMX
     2666  BFD_RELOC_SH_GOT10BY8
     2667ENUMX
     2668  BFD_RELOC_SH_GOTPLT10BY4
     2669ENUMX
     2670  BFD_RELOC_SH_GOTPLT10BY8
     2671ENUMX
     2672  BFD_RELOC_SH_GOTPLT32
     2673ENUMX
     2674  BFD_RELOC_SH_SHMEDIA_CODE
     2675ENUMX
     2676  BFD_RELOC_SH_IMMU5
     2677ENUMX
     2678  BFD_RELOC_SH_IMMS6
     2679ENUMX
     2680  BFD_RELOC_SH_IMMS6BY32
     2681ENUMX
     2682  BFD_RELOC_SH_IMMU6
     2683ENUMX
     2684  BFD_RELOC_SH_IMMS10
     2685ENUMX
     2686  BFD_RELOC_SH_IMMS10BY2
     2687ENUMX
     2688  BFD_RELOC_SH_IMMS10BY4
     2689ENUMX
     2690  BFD_RELOC_SH_IMMS10BY8
     2691ENUMX
     2692  BFD_RELOC_SH_IMMS16
     2693ENUMX
     2694  BFD_RELOC_SH_IMMU16
     2695ENUMX
     2696  BFD_RELOC_SH_IMM_LOW16
     2697ENUMX
     2698  BFD_RELOC_SH_IMM_LOW16_PCREL
     2699ENUMX
     2700  BFD_RELOC_SH_IMM_MEDLOW16
     2701ENUMX
     2702  BFD_RELOC_SH_IMM_MEDLOW16_PCREL
     2703ENUMX
     2704  BFD_RELOC_SH_IMM_MEDHI16
     2705ENUMX
     2706  BFD_RELOC_SH_IMM_MEDHI16_PCREL
     2707ENUMX
     2708  BFD_RELOC_SH_IMM_HI16
     2709ENUMX
     2710  BFD_RELOC_SH_IMM_HI16_PCREL
     2711ENUMX
     2712  BFD_RELOC_SH_PT_16
     2713ENUMX
     2714  BFD_RELOC_SH_TLS_GD_32
     2715ENUMX
     2716  BFD_RELOC_SH_TLS_LD_32
     2717ENUMX
     2718  BFD_RELOC_SH_TLS_LDO_32
     2719ENUMX
     2720  BFD_RELOC_SH_TLS_IE_32
     2721ENUMX
     2722  BFD_RELOC_SH_TLS_LE_32
     2723ENUMX
     2724  BFD_RELOC_SH_TLS_DTPMOD32
     2725ENUMX
     2726  BFD_RELOC_SH_TLS_DTPOFF32
     2727ENUMX
     2728  BFD_RELOC_SH_TLS_TPOFF32
     2729ENUMDOC
     2730  Renesas / SuperH SH relocs.  Not all of these appear in object files.
    23522731
    23532732ENUM
     
    24612840
    24622841ENUM
     2842  BFD_RELOC_DLX_HI16_S
     2843ENUMDOC
     2844  DLX relocs
     2845ENUM
     2846  BFD_RELOC_DLX_LO16
     2847ENUMDOC
     2848  DLX relocs
     2849ENUM
     2850  BFD_RELOC_DLX_JMP26
     2851ENUMDOC
     2852  DLX relocs
     2853
     2854ENUM
    24632855  BFD_RELOC_M32R_24
    24642856ENUMDOC
    2465   Mitsubishi M32R relocs.
     2857  Renesas M32R (formerly Mitsubishi M32R) relocs.
    24662858  This is a 24 bit absolute address.
    24672859ENUM
     
    25702962ENUMDOC
    25712963  This is a 16 bit offset from the call table base pointer.
    2572 COMMENT
    2573 
     2964ENUM
     2965  BFD_RELOC_V850_LONGCALL
     2966ENUMDOC
     2967  Used for relaxing indirect function calls.
     2968ENUM
     2969  BFD_RELOC_V850_LONGJUMP
     2970ENUMDOC
     2971  Used for relaxing indirect jumps.
     2972ENUM
     2973  BFD_RELOC_V850_ALIGN
     2974ENUMDOC
     2975  Used to maintain alignment whilst relaxing.
    25742976ENUM
    25752977  BFD_RELOC_MN10300_32_PCREL
     
    26793081
    26803082ENUM
     3083  BFD_RELOC_MMIX_GETA
     3084ENUMX
     3085  BFD_RELOC_MMIX_GETA_1
     3086ENUMX
     3087  BFD_RELOC_MMIX_GETA_2
     3088ENUMX
     3089  BFD_RELOC_MMIX_GETA_3
     3090ENUMDOC
     3091  These are relocations for the GETA instruction.
     3092ENUM
     3093  BFD_RELOC_MMIX_CBRANCH
     3094ENUMX
     3095  BFD_RELOC_MMIX_CBRANCH_J
     3096ENUMX
     3097  BFD_RELOC_MMIX_CBRANCH_1
     3098ENUMX
     3099  BFD_RELOC_MMIX_CBRANCH_2
     3100ENUMX
     3101  BFD_RELOC_MMIX_CBRANCH_3
     3102ENUMDOC
     3103  These are relocations for a conditional branch instruction.
     3104ENUM
     3105  BFD_RELOC_MMIX_PUSHJ
     3106ENUMX
     3107  BFD_RELOC_MMIX_PUSHJ_1
     3108ENUMX
     3109  BFD_RELOC_MMIX_PUSHJ_2
     3110ENUMX
     3111  BFD_RELOC_MMIX_PUSHJ_3
     3112ENUMDOC
     3113  These are relocations for the PUSHJ instruction.
     3114ENUM
     3115  BFD_RELOC_MMIX_JMP
     3116ENUMX
     3117  BFD_RELOC_MMIX_JMP_1
     3118ENUMX
     3119  BFD_RELOC_MMIX_JMP_2
     3120ENUMX
     3121  BFD_RELOC_MMIX_JMP_3
     3122ENUMDOC
     3123  These are relocations for the JMP instruction.
     3124ENUM
     3125  BFD_RELOC_MMIX_ADDR19
     3126ENUMDOC
     3127  This is a relocation for a relative address as in a GETA instruction or
     3128  a branch.
     3129ENUM
     3130  BFD_RELOC_MMIX_ADDR27
     3131ENUMDOC
     3132  This is a relocation for a relative address as in a JMP instruction.
     3133ENUM
     3134  BFD_RELOC_MMIX_REG_OR_BYTE
     3135ENUMDOC
     3136  This is a relocation for an instruction field that may be a general
     3137  register or a value 0..255.
     3138ENUM
     3139  BFD_RELOC_MMIX_REG
     3140ENUMDOC
     3141  This is a relocation for an instruction field that may be a general
     3142  register.
     3143ENUM
     3144  BFD_RELOC_MMIX_BASE_PLUS_OFFSET
     3145ENUMDOC
     3146  This is a relocation for two instruction fields holding a register and
     3147  an offset, the equivalent of the relocation.
     3148ENUM
     3149  BFD_RELOC_MMIX_LOCAL
     3150ENUMDOC
     3151  This relocation is an assertion that the expression is not allocated as
     3152  a global register.  It does not modify contents.
     3153
     3154ENUM
    26813155  BFD_RELOC_AVR_7_PCREL
    26823156ENUMDOC
     
    27623236  This is a 32 bit reloc for the AVR that stores 23 bit value
    27633237  into 22 bits.
     3238
     3239ENUM
     3240  BFD_RELOC_390_12
     3241ENUMDOC
     3242   Direct 12 bit.
     3243ENUM
     3244  BFD_RELOC_390_GOT12
     3245ENUMDOC
     3246  12 bit GOT offset.
     3247ENUM
     3248  BFD_RELOC_390_PLT32
     3249ENUMDOC
     3250  32 bit PC relative PLT address.
     3251ENUM
     3252  BFD_RELOC_390_COPY
     3253ENUMDOC
     3254  Copy symbol at runtime.
     3255ENUM
     3256  BFD_RELOC_390_GLOB_DAT
     3257ENUMDOC
     3258  Create GOT entry.
     3259ENUM
     3260  BFD_RELOC_390_JMP_SLOT
     3261ENUMDOC
     3262  Create PLT entry.
     3263ENUM
     3264  BFD_RELOC_390_RELATIVE
     3265ENUMDOC
     3266  Adjust by program base.
     3267ENUM
     3268  BFD_RELOC_390_GOTPC
     3269ENUMDOC
     3270  32 bit PC relative offset to GOT.
     3271ENUM
     3272  BFD_RELOC_390_GOT16
     3273ENUMDOC
     3274  16 bit GOT offset.
     3275ENUM
     3276  BFD_RELOC_390_PC16DBL
     3277ENUMDOC
     3278  PC relative 16 bit shifted by 1.
     3279ENUM
     3280  BFD_RELOC_390_PLT16DBL
     3281ENUMDOC
     3282  16 bit PC rel. PLT shifted by 1.
     3283ENUM
     3284  BFD_RELOC_390_PC32DBL
     3285ENUMDOC
     3286  PC relative 32 bit shifted by 1.
     3287ENUM
     3288  BFD_RELOC_390_PLT32DBL
     3289ENUMDOC
     3290  32 bit PC rel. PLT shifted by 1.
     3291ENUM
     3292  BFD_RELOC_390_GOTPCDBL
     3293ENUMDOC
     3294  32 bit PC rel. GOT shifted by 1.
     3295ENUM
     3296  BFD_RELOC_390_GOT64
     3297ENUMDOC
     3298  64 bit GOT offset.
     3299ENUM
     3300  BFD_RELOC_390_PLT64
     3301ENUMDOC
     3302  64 bit PC relative PLT address.
     3303ENUM
     3304  BFD_RELOC_390_GOTENT
     3305ENUMDOC
     3306  32 bit rel. offset to GOT entry.
     3307ENUM
     3308  BFD_RELOC_390_GOTOFF64
     3309ENUMDOC
     3310  64 bit offset to GOT.
     3311ENUM
     3312  BFD_RELOC_390_GOTPLT12
     3313ENUMDOC
     3314  12-bit offset to symbol-entry within GOT, with PLT handling.
     3315ENUM
     3316  BFD_RELOC_390_GOTPLT16
     3317ENUMDOC
     3318  16-bit offset to symbol-entry within GOT, with PLT handling.
     3319ENUM
     3320  BFD_RELOC_390_GOTPLT32
     3321ENUMDOC
     3322  32-bit offset to symbol-entry within GOT, with PLT handling.
     3323ENUM
     3324  BFD_RELOC_390_GOTPLT64
     3325ENUMDOC
     3326  64-bit offset to symbol-entry within GOT, with PLT handling.
     3327ENUM
     3328  BFD_RELOC_390_GOTPLTENT
     3329ENUMDOC
     3330  32-bit rel. offset to symbol-entry within GOT, with PLT handling.
     3331ENUM
     3332  BFD_RELOC_390_PLTOFF16
     3333ENUMDOC
     3334  16-bit rel. offset from the GOT to a PLT entry.
     3335ENUM
     3336  BFD_RELOC_390_PLTOFF32
     3337ENUMDOC
     3338  32-bit rel. offset from the GOT to a PLT entry.
     3339ENUM
     3340  BFD_RELOC_390_PLTOFF64
     3341ENUMDOC
     3342  64-bit rel. offset from the GOT to a PLT entry.
     3343
     3344ENUM
     3345  BFD_RELOC_390_TLS_LOAD
     3346ENUMX
     3347  BFD_RELOC_390_TLS_GDCALL
     3348ENUMX
     3349  BFD_RELOC_390_TLS_LDCALL
     3350ENUMX
     3351  BFD_RELOC_390_TLS_GD32
     3352ENUMX
     3353  BFD_RELOC_390_TLS_GD64
     3354ENUMX
     3355  BFD_RELOC_390_TLS_GOTIE12
     3356ENUMX
     3357  BFD_RELOC_390_TLS_GOTIE32
     3358ENUMX
     3359  BFD_RELOC_390_TLS_GOTIE64
     3360ENUMX
     3361  BFD_RELOC_390_TLS_LDM32
     3362ENUMX
     3363  BFD_RELOC_390_TLS_LDM64
     3364ENUMX
     3365  BFD_RELOC_390_TLS_IE32
     3366ENUMX
     3367  BFD_RELOC_390_TLS_IE64
     3368ENUMX
     3369  BFD_RELOC_390_TLS_IEENT
     3370ENUMX
     3371  BFD_RELOC_390_TLS_LE32
     3372ENUMX
     3373  BFD_RELOC_390_TLS_LE64
     3374ENUMX
     3375  BFD_RELOC_390_TLS_LDO32
     3376ENUMX
     3377  BFD_RELOC_390_TLS_LDO64
     3378ENUMX
     3379  BFD_RELOC_390_TLS_DTPMOD
     3380ENUMX
     3381  BFD_RELOC_390_TLS_DTPOFF
     3382ENUMX
     3383  BFD_RELOC_390_TLS_TPOFF
     3384ENUMDOC
     3385  s390 tls relocations.
     3386
     3387ENUM
     3388  BFD_RELOC_IP2K_FR9
     3389ENUMDOC
     3390  Scenix IP2K - 9-bit register number / data address
     3391ENUM
     3392  BFD_RELOC_IP2K_BANK
     3393ENUMDOC
     3394  Scenix IP2K - 4-bit register/data bank number
     3395ENUM
     3396  BFD_RELOC_IP2K_ADDR16CJP
     3397ENUMDOC
     3398  Scenix IP2K - low 13 bits of instruction word address
     3399ENUM
     3400  BFD_RELOC_IP2K_PAGE3
     3401ENUMDOC
     3402  Scenix IP2K - high 3 bits of instruction word address
     3403ENUM
     3404  BFD_RELOC_IP2K_LO8DATA
     3405ENUMX
     3406  BFD_RELOC_IP2K_HI8DATA
     3407ENUMX
     3408  BFD_RELOC_IP2K_EX8DATA
     3409ENUMDOC
     3410  Scenix IP2K - ext/low/high 8 bits of data address
     3411ENUM
     3412  BFD_RELOC_IP2K_LO8INSN
     3413ENUMX
     3414  BFD_RELOC_IP2K_HI8INSN
     3415ENUMDOC
     3416  Scenix IP2K - low/high 8 bits of instruction word address
     3417ENUM
     3418  BFD_RELOC_IP2K_PC_SKIP
     3419ENUMDOC
     3420  Scenix IP2K - even/odd PC modifier to modify snb pcl.0
     3421ENUM
     3422  BFD_RELOC_IP2K_TEXT
     3423ENUMDOC
     3424  Scenix IP2K - 16 bit word address in text section.
     3425ENUM
     3426  BFD_RELOC_IP2K_FR_OFFSET
     3427ENUMDOC
     3428  Scenix IP2K - 7-bit sp or dp offset
     3429ENUM
     3430  BFD_RELOC_VPE4KMATH_DATA
     3431ENUMX
     3432  BFD_RELOC_VPE4KMATH_INSN
     3433ENUMDOC
     3434  Scenix VPE4K coprocessor - data/insn-space addressing
    27643435
    27653436ENUM
     
    28613532  BFD_RELOC_IA64_LTOFF_FPTR64I
    28623533ENUMX
     3534  BFD_RELOC_IA64_LTOFF_FPTR32MSB
     3535ENUMX
     3536  BFD_RELOC_IA64_LTOFF_FPTR32LSB
     3537ENUMX
    28633538  BFD_RELOC_IA64_LTOFF_FPTR64MSB
    28643539ENUMX
     
    29033578  BFD_RELOC_IA64_COPY
    29043579ENUMX
     3580  BFD_RELOC_IA64_LTOFF22X
     3581ENUMX
     3582  BFD_RELOC_IA64_LDXMOV
     3583ENUMX
     3584  BFD_RELOC_IA64_TPREL14
     3585ENUMX
    29053586  BFD_RELOC_IA64_TPREL22
    29063587ENUMX
     3588  BFD_RELOC_IA64_TPREL64I
     3589ENUMX
    29073590  BFD_RELOC_IA64_TPREL64MSB
    29083591ENUMX
    29093592  BFD_RELOC_IA64_TPREL64LSB
    29103593ENUMX
    2911   BFD_RELOC_IA64_LTOFF_TP22
    2912 ENUMX
    2913   BFD_RELOC_IA64_LTOFF22X
    2914 ENUMX
    2915   BFD_RELOC_IA64_LDXMOV
     3594  BFD_RELOC_IA64_LTOFF_TPREL22
     3595ENUMX
     3596  BFD_RELOC_IA64_DTPMOD64MSB
     3597ENUMX
     3598  BFD_RELOC_IA64_DTPMOD64LSB
     3599ENUMX
     3600  BFD_RELOC_IA64_LTOFF_DTPMOD22
     3601ENUMX
     3602  BFD_RELOC_IA64_DTPREL14
     3603ENUMX
     3604  BFD_RELOC_IA64_DTPREL22
     3605ENUMX
     3606  BFD_RELOC_IA64_DTPREL64I
     3607ENUMX
     3608  BFD_RELOC_IA64_DTPREL32MSB
     3609ENUMX
     3610  BFD_RELOC_IA64_DTPREL32LSB
     3611ENUMX
     3612  BFD_RELOC_IA64_DTPREL64MSB
     3613ENUMX
     3614  BFD_RELOC_IA64_DTPREL64LSB
     3615ENUMX
     3616  BFD_RELOC_IA64_LTOFF_DTPREL22
    29163617ENUMDOC
    29173618  Intel IA64 Relocations.
     
    29213622ENUMDOC
    29223623  Motorola 68HC11 reloc.
    2923   This is the 8 bits high part of an absolute address.
     3624  This is the 8 bit high part of an absolute address.
    29243625ENUM
    29253626  BFD_RELOC_M68HC11_LO8
    29263627ENUMDOC
    29273628  Motorola 68HC11 reloc.
    2928   This is the 8 bits low part of an absolute address.
     3629  This is the 8 bit low part of an absolute address.
    29293630ENUM
    29303631  BFD_RELOC_M68HC11_3B
    29313632ENUMDOC
    29323633  Motorola 68HC11 reloc.
    2933   This is the 3 bits of a value.
     3634  This is the 3 bit of a value.
     3635ENUM
     3636  BFD_RELOC_M68HC11_RL_JUMP
     3637ENUMDOC
     3638  Motorola 68HC11 reloc.
     3639  This reloc marks the beginning of a jump/call instruction.
     3640  It is used for linker relaxation to correctly identify beginning
     3641  of instruction and change some branchs to use PC-relative
     3642  addressing mode.
     3643ENUM
     3644  BFD_RELOC_M68HC11_RL_GROUP
     3645ENUMDOC
     3646  Motorola 68HC11 reloc.
     3647  This reloc marks a group of several instructions that gcc generates
     3648  and for which the linker relaxation pass can modify and/or remove
     3649  some of them.
     3650ENUM
     3651  BFD_RELOC_M68HC11_LO16
     3652ENUMDOC
     3653  Motorola 68HC11 reloc.
     3654  This is the 16-bit lower part of an address.  It is used for 'call'
     3655  instruction to specify the symbol address without any special
     3656  transformation (due to memory bank window).
     3657ENUM
     3658  BFD_RELOC_M68HC11_PAGE
     3659ENUMDOC
     3660  Motorola 68HC11 reloc.
     3661  This is a 8-bit reloc that specifies the page number of an address.
     3662  It is used by 'call' instruction to specify the page number of
     3663  the symbol.
     3664ENUM
     3665  BFD_RELOC_M68HC11_24
     3666ENUMDOC
     3667  Motorola 68HC11 reloc.
     3668  This is a 24-bit reloc that represents the address with a 16-bit
     3669  value and a 8-bit page number.  The symbol address is transformed
     3670  to follow the 16K memory bank of 68HC12 (seen as mapped in the window).
    29343671
    29353672ENUM
     
    29463683  These relocs are only used within the CRIS assembler.  They are not
    29473684  (at present) written to any object files.
     3685ENUM
     3686  BFD_RELOC_CRIS_COPY
     3687ENUMX
     3688  BFD_RELOC_CRIS_GLOB_DAT
     3689ENUMX
     3690  BFD_RELOC_CRIS_JUMP_SLOT
     3691ENUMX
     3692  BFD_RELOC_CRIS_RELATIVE
     3693ENUMDOC
     3694  Relocs used in ELF shared libraries for CRIS.
     3695ENUM
     3696  BFD_RELOC_CRIS_32_GOT
     3697ENUMDOC
     3698  32-bit offset to symbol-entry within GOT.
     3699ENUM
     3700  BFD_RELOC_CRIS_16_GOT
     3701ENUMDOC
     3702  16-bit offset to symbol-entry within GOT.
     3703ENUM
     3704  BFD_RELOC_CRIS_32_GOTPLT
     3705ENUMDOC
     3706  32-bit offset to symbol-entry within GOT, with PLT handling.
     3707ENUM
     3708  BFD_RELOC_CRIS_16_GOTPLT
     3709ENUMDOC
     3710  16-bit offset to symbol-entry within GOT, with PLT handling.
     3711ENUM
     3712  BFD_RELOC_CRIS_32_GOTREL
     3713ENUMDOC
     3714  32-bit offset to symbol, relative to GOT.
     3715ENUM
     3716  BFD_RELOC_CRIS_32_PLT_GOTREL
     3717ENUMDOC
     3718  32-bit offset to symbol with PLT entry, relative to GOT.
     3719ENUM
     3720  BFD_RELOC_CRIS_32_PLT_PCREL
     3721ENUMDOC
     3722  32-bit offset to symbol with PLT entry, relative to this relocation.
    29483723
    29493724ENUM
     
    30133788ENUMDOC
    30143789  Intel i860 Relocations.
     3790
     3791ENUM
     3792  BFD_RELOC_OPENRISC_ABS_26
     3793ENUMX
     3794  BFD_RELOC_OPENRISC_REL_26
     3795ENUMDOC
     3796  OpenRISC Relocations.
     3797
     3798ENUM
     3799  BFD_RELOC_H8_DIR16A8
     3800ENUMX
     3801  BFD_RELOC_H8_DIR16R8
     3802ENUMX
     3803  BFD_RELOC_H8_DIR24A8
     3804ENUMX
     3805  BFD_RELOC_H8_DIR24R8
     3806ENUMX
     3807  BFD_RELOC_H8_DIR32A16
     3808ENUMDOC
     3809  H8 elf Relocations.
     3810
     3811ENUM
     3812  BFD_RELOC_XSTORMY16_REL_12
     3813ENUMX
     3814  BFD_RELOC_XSTORMY16_12
     3815ENUMX
     3816  BFD_RELOC_XSTORMY16_24
     3817ENUMX
     3818  BFD_RELOC_XSTORMY16_FPTR16
     3819ENUMDOC
     3820  Sony Xstormy16 Relocations.
     3821
     3822ENUM
     3823  BFD_RELOC_VAX_GLOB_DAT
     3824ENUMX
     3825  BFD_RELOC_VAX_JMP_SLOT
     3826ENUMX
     3827  BFD_RELOC_VAX_RELATIVE
     3828ENUMDOC
     3829  Relocations used by VAX ELF.
     3830 
     3831ENUM
     3832  BFD_RELOC_MSP430_10_PCREL
     3833ENUMX
     3834  BFD_RELOC_MSP430_16_PCREL
     3835ENUMX
     3836  BFD_RELOC_MSP430_16
     3837ENUMX
     3838  BFD_RELOC_MSP430_16_PCREL_BYTE
     3839ENUMX
     3840  BFD_RELOC_MSP430_16_BYTE
     3841ENUMDOC
     3842  msp430 specific relocation codes
     3843
     3844ENUM
     3845  BFD_RELOC_IQ2000_OFFSET_16
     3846ENUMX
     3847  BFD_RELOC_IQ2000_OFFSET_21
     3848ENUMX
     3849  BFD_RELOC_IQ2000_UHI16
     3850ENUMDOC
     3851  IQ2000 Relocations.
     3852
     3853ENUM
     3854  BFD_RELOC_XTENSA_RTLD
     3855ENUMDOC
     3856  Special Xtensa relocation used only by PLT entries in ELF shared
     3857  objects to indicate that the runtime linker should set the value
     3858  to one of its own internal functions or data structures.
     3859ENUM
     3860  BFD_RELOC_XTENSA_GLOB_DAT
     3861ENUMX
     3862  BFD_RELOC_XTENSA_JMP_SLOT
     3863ENUMX
     3864  BFD_RELOC_XTENSA_RELATIVE
     3865ENUMDOC
     3866  Xtensa relocations for ELF shared objects.
     3867ENUM
     3868  BFD_RELOC_XTENSA_PLT
     3869ENUMDOC
     3870  Xtensa relocation used in ELF object files for symbols that may require
     3871  PLT entries.  Otherwise, this is just a generic 32-bit relocation.
     3872ENUM
     3873  BFD_RELOC_XTENSA_OP0
     3874ENUMX
     3875  BFD_RELOC_XTENSA_OP1
     3876ENUMX
     3877  BFD_RELOC_XTENSA_OP2
     3878ENUMDOC
     3879  Generic Xtensa relocations.  Only the operand number is encoded
     3880  in the relocation.  The details are determined by extracting the
     3881  instruction opcode.
     3882ENUM
     3883  BFD_RELOC_XTENSA_ASM_EXPAND
     3884ENUMDOC
     3885  Xtensa relocation to mark that the assembler expanded the
     3886  instructions from an original target.  The expansion size is
     3887  encoded in the reloc size.
     3888ENUM
     3889  BFD_RELOC_XTENSA_ASM_SIMPLIFY
     3890ENUMDOC
     3891  Xtensa relocation to mark that the linker should simplify
     3892  assembler-expanded instructions.  This is commonly used
     3893  internally by the linker after analysis of a
     3894  BFD_RELOC_XTENSA_ASM_EXPAND.
    30153895
    30163896ENDSENUM
     
    30453925
    30463926static reloc_howto_type bfd_howto_32 =
    3047 HOWTO (0, 00, 2, 32, false, 0, complain_overflow_bitfield, 0, "VRT32", false, 0xffffffff, 0xffffffff, true);
     3927HOWTO (0, 00, 2, 32, FALSE, 0, complain_overflow_bitfield, 0, "VRT32", FALSE, 0xffffffff, 0xffffffff, TRUE);
    30483928
    30493929/*
     
    31033983     bfd_reloc_code_real_type code;
    31043984{
    3105   if (code > BFD_RELOC_UNUSED)
     3985  if ((int) code > (int) BFD_RELOC_UNUSED)
    31063986    return 0;
    31073987  return bfd_reloc_code_real_names[(int)code];
     
    31133993
    31143994SYNOPSIS
    3115         boolean bfd_generic_relax_section
     3995        bfd_boolean bfd_generic_relax_section
    31163996         (bfd *abfd,
    31173997          asection *section,
    31183998          struct bfd_link_info *,
    3119           boolean *);
     3999          bfd_boolean *);
    31204000
    31214001DESCRIPTION
     
    31244004*/
    31254005
    3126 /*ARGSUSED*/
    3127 boolean
     4006bfd_boolean
    31284007bfd_generic_relax_section (abfd, section, link_info, again)
    31294008     bfd *abfd ATTRIBUTE_UNUSED;
    31304009     asection *section ATTRIBUTE_UNUSED;
    31314010     struct bfd_link_info *link_info ATTRIBUTE_UNUSED;
    3132      boolean *again;
     4011     bfd_boolean *again;
    31334012{
    3134   *again = false;
    3135   return true;
     4013  *again = FALSE;
     4014  return TRUE;
    31364015}
    31374016
     
    31414020
    31424021SYNOPSIS
    3143         boolean bfd_generic_gc_sections
     4022        bfd_boolean bfd_generic_gc_sections
    31444023         (bfd *, struct bfd_link_info *);
    31454024
     
    31494028*/
    31504029
    3151 /*ARGSUSED*/
    3152 boolean
     4030bfd_boolean
    31534031bfd_generic_gc_sections (abfd, link_info)
    31544032     bfd *abfd ATTRIBUTE_UNUSED;
    31554033     struct bfd_link_info *link_info ATTRIBUTE_UNUSED;
    31564034{
    3157   return true;
     4035  return TRUE;
     4036}
     4037
     4038/*
     4039INTERNAL_FUNCTION
     4040        bfd_generic_merge_sections
     4041
     4042SYNOPSIS
     4043        bfd_boolean bfd_generic_merge_sections
     4044         (bfd *, struct bfd_link_info *);
     4045
     4046DESCRIPTION
     4047        Provides default handling for SEC_MERGE section merging for back ends
     4048        which don't have SEC_MERGE support -- i.e., does nothing.
     4049*/
     4050
     4051bfd_boolean
     4052bfd_generic_merge_sections (abfd, link_info)
     4053     bfd *abfd ATTRIBUTE_UNUSED;
     4054     struct bfd_link_info *link_info ATTRIBUTE_UNUSED;
     4055{
     4056  return TRUE;
    31584057}
    31594058
     
    31684067             struct bfd_link_order *link_order,
    31694068             bfd_byte *data,
    3170              boolean relocateable,
     4069             bfd_boolean relocateable,
    31714070             asymbol **symbols);
    31724071
     
    31844083     struct bfd_link_order *link_order;
    31854084     bfd_byte *data;
    3186      boolean relocateable;
     4085     bfd_boolean relocateable;
    31874086     asymbol **symbols;
    31884087{
    3189   /* Get enough memory to hold the stuff */
     4088  /* Get enough memory to hold the stuff. */
    31904089  bfd *input_bfd = link_order->u.indirect.section->owner;
    31914090  asection *input_section = link_order->u.indirect.section;
     
    31984097    goto error_return;
    31994098
    3200   reloc_vector = (arelent **) bfd_malloc ((size_t) reloc_size);
     4099  reloc_vector = (arelent **) bfd_malloc ((bfd_size_type) reloc_size);
    32014100  if (reloc_vector == NULL && reloc_size != 0)
    32024101    goto error_return;
    32034102
    3204   /* read in the section */
     4103  /* Read in the section. */
    32054104  if (!bfd_get_section_contents (input_bfd,
    32064105                                 input_section,
    32074106                                 (PTR) data,
    3208                                  0,
     4107                                 (bfd_vma) 0,
    32094108                                 input_section->_raw_size))
    32104109    goto error_return;
    32114110
    3212   /* We're not relaxing the section, so just copy the size info */
     4111  /* We're not relaxing the section, so just copy the size info. */
    32134112  input_section->_cooked_size = input_section->_raw_size;
    3214   input_section->reloc_done = true;
     4113  input_section->reloc_done = TRUE;
    32154114
    32164115  reloc_count = bfd_canonicalize_reloc (input_bfd,
     
    32404139              asection *os = input_section->output_section;
    32414140
    3242               /* A partial link, so keep the relocs */
     4141              /* A partial link, so keep the relocs. */
    32434142              os->orelocation[os->reloc_count] = *parent;
    32444143              os->reloc_count++;
     
    32534152                        (link_info, bfd_asymbol_name (*(*parent)->sym_ptr_ptr),
    32544153                         input_bfd, input_section, (*parent)->address,
    3255                          true)))
     4154                         TRUE)))
    32564155                    goto error_return;
    32574156                  break;
Note: See TracChangeset for help on using the changeset viewer.