OpenCores
URL https://opencores.org/ocsvn/open8_urisc/open8_urisc/trunk

Subversion Repositories open8_urisc

[/] [open8_urisc/] [trunk/] [gnu/] [binutils/] [gold/] [output.h] - Diff between revs 159 and 163

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 159 Rev 163
Line 1031... Line 1031...
  // A reloc against a local symbol or local section symbol.
  // A reloc against a local symbol or local section symbol.
 
 
  Output_reloc(Sized_relobj<size, big_endian>* relobj,
  Output_reloc(Sized_relobj<size, big_endian>* relobj,
               unsigned int local_sym_index, unsigned int type,
               unsigned int local_sym_index, unsigned int type,
               Output_data* od, Address address, bool is_relative,
               Output_data* od, Address address, bool is_relative,
               bool is_symbolless, bool is_section_symbol);
               bool is_symbolless, bool is_section_symbol,
 
               bool use_plt_offset);
 
 
  Output_reloc(Sized_relobj<size, big_endian>* relobj,
  Output_reloc(Sized_relobj<size, big_endian>* relobj,
               unsigned int local_sym_index, unsigned int type,
               unsigned int local_sym_index, unsigned int type,
               unsigned int shndx, Address address, bool is_relative,
               unsigned int shndx, Address address, bool is_relative,
               bool is_symbolless, bool is_section_symbol);
               bool is_symbolless, bool is_section_symbol,
 
               bool use_plt_offset);
 
 
  // A reloc against the STT_SECTION symbol of an output section.
  // A reloc against the STT_SECTION symbol of an output section.
 
 
  Output_reloc(Output_section* os, unsigned int type, Output_data* od,
  Output_reloc(Output_section* os, unsigned int type, Output_data* od,
               Address address);
               Address address);
Line 1214... Line 1216...
  // false), the local symbol index.  For a local section symbol
  // false), the local symbol index.  For a local section symbol
  // (this->is_section_symbol_ is true), the section index in the
  // (this->is_section_symbol_ is true), the section index in the
  // input file.
  // input file.
  unsigned int local_sym_index_;
  unsigned int local_sym_index_;
  // The reloc type--a processor specific code.
  // The reloc type--a processor specific code.
  unsigned int type_ : 29;
  unsigned int type_ : 28;
  // True if the relocation is a RELATIVE relocation.
  // True if the relocation is a RELATIVE relocation.
  bool is_relative_ : 1;
  bool is_relative_ : 1;
  // True if the relocation is one which should not use
  // True if the relocation is one which should not use
  // a symbol, but which obtains its addend from a symbol.
  // a symbol, but which obtains its addend from a symbol.
  bool is_symbolless_ : 1;
  bool is_symbolless_ : 1;
  // True if the relocation is against a section symbol.
  // True if the relocation is against a section symbol.
  bool is_section_symbol_ : 1;
  bool is_section_symbol_ : 1;
 
  // True if the addend should be the PLT offset.  This is used only
 
  // for RELATIVE relocations to local symbols.
 
  // (Used only for RELA, but stored here for space.)
 
  bool use_plt_offset_ : 1;
  // If the reloc address is an input section in an object, the
  // If the reloc address is an input section in an object, the
  // section index.  This is INVALID_CODE if the reloc address is
  // section index.  This is INVALID_CODE if the reloc address is
  // specified in some other way.
  // specified in some other way.
  unsigned int shndx_;
  unsigned int shndx_;
};
};
Line 1266... Line 1272...
 
 
  Output_reloc(Sized_relobj<size, big_endian>* relobj,
  Output_reloc(Sized_relobj<size, big_endian>* relobj,
               unsigned int local_sym_index, unsigned int type,
               unsigned int local_sym_index, unsigned int type,
               Output_data* od, Address address,
               Output_data* od, Address address,
               Addend addend, bool is_relative,
               Addend addend, bool is_relative,
               bool is_symbolless, bool is_section_symbol)
               bool is_symbolless, bool is_section_symbol,
 
               bool use_plt_offset)
    : rel_(relobj, local_sym_index, type, od, address, is_relative,
    : rel_(relobj, local_sym_index, type, od, address, is_relative,
           is_symbolless, is_section_symbol),
           is_symbolless, is_section_symbol, use_plt_offset),
      addend_(addend)
      addend_(addend)
  { }
  { }
 
 
  Output_reloc(Sized_relobj<size, big_endian>* relobj,
  Output_reloc(Sized_relobj<size, big_endian>* relobj,
               unsigned int local_sym_index, unsigned int type,
               unsigned int local_sym_index, unsigned int type,
               unsigned int shndx, Address address,
               unsigned int shndx, Address address,
               Addend addend, bool is_relative,
               Addend addend, bool is_relative,
               bool is_symbolless, bool is_section_symbol)
               bool is_symbolless, bool is_section_symbol,
 
               bool use_plt_offset)
    : rel_(relobj, local_sym_index, type, shndx, address, is_relative,
    : rel_(relobj, local_sym_index, type, shndx, address, is_relative,
           is_symbolless, is_section_symbol),
           is_symbolless, is_section_symbol, use_plt_offset),
      addend_(addend)
      addend_(addend)
  { }
  { }
 
 
  // A reloc against the STT_SECTION symbol of an output section.
  // A reloc against the STT_SECTION symbol of an output section.
 
 
Line 1569... Line 1577...
  add_local(Sized_relobj<size, big_endian>* relobj,
  add_local(Sized_relobj<size, big_endian>* relobj,
            unsigned int local_sym_index, unsigned int type,
            unsigned int local_sym_index, unsigned int type,
            Output_data* od, Address address)
            Output_data* od, Address address)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od,
                                    address, false, false, false));
                                    address, false, false, false, false));
  }
  }
 
 
  void
  void
  add_local(Sized_relobj<size, big_endian>* relobj,
  add_local(Sized_relobj<size, big_endian>* relobj,
            unsigned int local_sym_index, unsigned int type,
            unsigned int local_sym_index, unsigned int type,
            Output_data* od, unsigned int shndx, Address address)
            Output_data* od, unsigned int shndx, Address address)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
                                    address, false, false, false));
                                    address, false, false, false, false));
  }
  }
 
 
  // Add a RELATIVE reloc against a local symbol.
  // Add a RELATIVE reloc against a local symbol.
 
 
  void
  void
  add_local_relative(Sized_relobj<size, big_endian>* relobj,
  add_local_relative(Sized_relobj<size, big_endian>* relobj,
                     unsigned int local_sym_index, unsigned int type,
                     unsigned int local_sym_index, unsigned int type,
                     Output_data* od, Address address)
                     Output_data* od, Address address)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od,
                                    address, true, true, false));
                                    address, true, true, false, false));
  }
  }
 
 
  void
  void
  add_local_relative(Sized_relobj<size, big_endian>* relobj,
  add_local_relative(Sized_relobj<size, big_endian>* relobj,
                     unsigned int local_sym_index, unsigned int type,
                     unsigned int local_sym_index, unsigned int type,
                     Output_data* od, unsigned int shndx, Address address)
                     Output_data* od, unsigned int shndx, Address address)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
                                    address, true, true, false));
                                    address, true, true, false, false));
  }
  }
 
 
  // Add a local relocation which does not use a symbol for the relocation,
  // Add a local relocation which does not use a symbol for the relocation,
  // but which gets its addend from a symbol.
  // but which gets its addend from a symbol.
 
 
Line 1610... Line 1618...
  add_symbolless_local_addend(Sized_relobj<size, big_endian>* relobj,
  add_symbolless_local_addend(Sized_relobj<size, big_endian>* relobj,
                              unsigned int local_sym_index, unsigned int type,
                              unsigned int local_sym_index, unsigned int type,
                              Output_data* od, Address address)
                              Output_data* od, Address address)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od,
                                    address, false, true, false));
                                    address, false, true, false, false));
  }
  }
 
 
  void
  void
  add_symbolless_local_addend(Sized_relobj<size, big_endian>* relobj,
  add_symbolless_local_addend(Sized_relobj<size, big_endian>* relobj,
                              unsigned int local_sym_index, unsigned int type,
                              unsigned int local_sym_index, unsigned int type,
                              Output_data* od, unsigned int shndx,
                              Output_data* od, unsigned int shndx,
                              Address address)
                              Address address)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
                                    address, false, true, false));
                                    address, false, true, false, false));
  }
  }
 
 
  // Add a reloc against a local section symbol.  This will be
  // Add a reloc against a local section symbol.  This will be
  // converted into a reloc against the STT_SECTION symbol of the
  // converted into a reloc against the STT_SECTION symbol of the
  // output section.
  // output section.
Line 1633... Line 1641...
  add_local_section(Sized_relobj<size, big_endian>* relobj,
  add_local_section(Sized_relobj<size, big_endian>* relobj,
                    unsigned int input_shndx, unsigned int type,
                    unsigned int input_shndx, unsigned int type,
                    Output_data* od, Address address)
                    Output_data* od, Address address)
  {
  {
    this->add(od, Output_reloc_type(relobj, input_shndx, type, od,
    this->add(od, Output_reloc_type(relobj, input_shndx, type, od,
                                    address, false, false, true));
                                    address, false, false, true, false));
  }
  }
 
 
  void
  void
  add_local_section(Sized_relobj<size, big_endian>* relobj,
  add_local_section(Sized_relobj<size, big_endian>* relobj,
                    unsigned int input_shndx, unsigned int type,
                    unsigned int input_shndx, unsigned int type,
                    Output_data* od, unsigned int shndx, Address address)
                    Output_data* od, unsigned int shndx, Address address)
  {
  {
    this->add(od, Output_reloc_type(relobj, input_shndx, type, shndx,
    this->add(od, Output_reloc_type(relobj, input_shndx, type, shndx,
                                    address, false, false, true));
                                    address, false, false, true, false));
  }
  }
 
 
  // A reloc against the STT_SECTION symbol of an output section.
  // A reloc against the STT_SECTION symbol of an output section.
  // OS is the Output_section that the relocation refers to; OD is
  // OS is the Output_section that the relocation refers to; OD is
  // the Output_data object being relocated.
  // the Output_data object being relocated.
Line 1765... Line 1773...
  add_local(Sized_relobj<size, big_endian>* relobj,
  add_local(Sized_relobj<size, big_endian>* relobj,
            unsigned int local_sym_index, unsigned int type,
            unsigned int local_sym_index, unsigned int type,
            Output_data* od, Address address, Addend addend)
            Output_data* od, Address address, Addend addend)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od, address,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od, address,
                                    addend, false, false, false));
                                    addend, false, false, false, false));
  }
  }
 
 
  void
  void
  add_local(Sized_relobj<size, big_endian>* relobj,
  add_local(Sized_relobj<size, big_endian>* relobj,
            unsigned int local_sym_index, unsigned int type,
            unsigned int local_sym_index, unsigned int type,
            Output_data* od, unsigned int shndx, Address address,
            Output_data* od, unsigned int shndx, Address address,
            Addend addend)
            Addend addend)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
                                    address, addend, false, false, false));
                                    address, addend, false, false, false,
 
                                    false));
  }
  }
 
 
  // Add a RELATIVE reloc against a local symbol.
  // Add a RELATIVE reloc against a local symbol.
 
 
  void
  void
  add_local_relative(Sized_relobj<size, big_endian>* relobj,
  add_local_relative(Sized_relobj<size, big_endian>* relobj,
                     unsigned int local_sym_index, unsigned int type,
                     unsigned int local_sym_index, unsigned int type,
                     Output_data* od, Address address, Addend addend)
                     Output_data* od, Address address, Addend addend,
 
                     bool use_plt_offset)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od, address,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od, address,
                                    addend, true, true, false));
                                    addend, true, true, false,
 
                                    use_plt_offset));
  }
  }
 
 
  void
  void
  add_local_relative(Sized_relobj<size, big_endian>* relobj,
  add_local_relative(Sized_relobj<size, big_endian>* relobj,
                     unsigned int local_sym_index, unsigned int type,
                     unsigned int local_sym_index, unsigned int type,
                     Output_data* od, unsigned int shndx, Address address,
                     Output_data* od, unsigned int shndx, Address address,
                     Addend addend)
                     Addend addend, bool use_plt_offset)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
                                    address, addend, true, true, false));
                                    address, addend, true, true, false,
 
                                    use_plt_offset));
  }
  }
 
 
  // Add a local relocation which does not use a symbol for the relocation,
  // Add a local relocation which does not use a symbol for the relocation,
  // but which gets it's addend from a symbol.
  // but which gets it's addend from a symbol.
 
 
Line 1808... Line 1820...
  add_symbolless_local_addend(Sized_relobj<size, big_endian>* relobj,
  add_symbolless_local_addend(Sized_relobj<size, big_endian>* relobj,
                              unsigned int local_sym_index, unsigned int type,
                              unsigned int local_sym_index, unsigned int type,
                              Output_data* od, Address address, Addend addend)
                              Output_data* od, Address address, Addend addend)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od, address,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, od, address,
                                    addend, false, true, false));
                                    addend, false, true, false, false));
  }
  }
 
 
  void
  void
  add_symbolless_local_addend(Sized_relobj<size, big_endian>* relobj,
  add_symbolless_local_addend(Sized_relobj<size, big_endian>* relobj,
                              unsigned int local_sym_index, unsigned int type,
                              unsigned int local_sym_index, unsigned int type,
                              Output_data* od, unsigned int shndx,
                              Output_data* od, unsigned int shndx,
                              Address address, Addend addend)
                              Address address, Addend addend)
  {
  {
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
    this->add(od, Output_reloc_type(relobj, local_sym_index, type, shndx,
                                    address, addend, false, true, false));
                                    address, addend, false, true, false,
 
                                    false));
  }
  }
 
 
  // Add a reloc against a local section symbol.  This will be
  // Add a reloc against a local section symbol.  This will be
  // converted into a reloc against the STT_SECTION symbol of the
  // converted into a reloc against the STT_SECTION symbol of the
  // output section.
  // output section.
Line 1831... Line 1844...
  add_local_section(Sized_relobj<size, big_endian>* relobj,
  add_local_section(Sized_relobj<size, big_endian>* relobj,
                    unsigned int input_shndx, unsigned int type,
                    unsigned int input_shndx, unsigned int type,
                    Output_data* od, Address address, Addend addend)
                    Output_data* od, Address address, Addend addend)
  {
  {
    this->add(od, Output_reloc_type(relobj, input_shndx, type, od, address,
    this->add(od, Output_reloc_type(relobj, input_shndx, type, od, address,
                                    addend, false, false, true));
                                    addend, false, false, true, false));
  }
  }
 
 
  void
  void
  add_local_section(Sized_relobj<size, big_endian>* relobj,
  add_local_section(Sized_relobj<size, big_endian>* relobj,
                    unsigned int input_shndx, unsigned int type,
                    unsigned int input_shndx, unsigned int type,
                    Output_data* od, unsigned int shndx, Address address,
                    Output_data* od, unsigned int shndx, Address address,
                    Addend addend)
                    Addend addend)
  {
  {
    this->add(od, Output_reloc_type(relobj, input_shndx, type, shndx,
    this->add(od, Output_reloc_type(relobj, input_shndx, type, shndx,
                                    address, addend, false, false, true));
                                    address, addend, false, false, true,
 
                                    false));
  }
  }
 
 
  // A reloc against the STT_SECTION symbol of an output section.
  // A reloc against the STT_SECTION symbol of an output section.
 
 
  void
  void
Line 2759... Line 2773...
  { return this->flags_; }
  { return this->flags_; }
 
 
  typedef std::map<Section_id, unsigned int> Section_layout_order;
  typedef std::map<Section_id, unsigned int> Section_layout_order;
 
 
  void
  void
  update_section_layout(const Section_layout_order& order_map);
  update_section_layout(const Section_layout_order* order_map);
 
 
  // Update the output section flags based on input section flags.
  // Update the output section flags based on input section flags.
  void
  void
  update_flags_for_input_section(elfcpp::Elf_Xword flags);
  update_flags_for_input_section(elfcpp::Elf_Xword flags);
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.