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

Subversion Repositories open8_urisc

[/] [open8_urisc/] [trunk/] [gnu/] [binutils/] [gold/] [symtab.cc] - Diff between revs 27 and 148

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

Rev 27 Rev 148
Line 77... Line 77...
  this->is_ordinary_shndx_ = false;
  this->is_ordinary_shndx_ = false;
  this->in_real_elf_ = false;
  this->in_real_elf_ = false;
  this->is_defined_in_discarded_section_ = false;
  this->is_defined_in_discarded_section_ = false;
  this->undef_binding_set_ = false;
  this->undef_binding_set_ = false;
  this->undef_binding_weak_ = false;
  this->undef_binding_weak_ = false;
 
  this->is_predefined_ = false;
}
}
 
 
// Return the demangled version of the symbol's name, but only
// Return the demangled version of the symbol's name, but only
// if the --demangle flag was set.
// if the --demangle flag was set.
 
 
Line 131... Line 132...
 
 
void
void
Symbol::init_base_output_data(const char* name, const char* version,
Symbol::init_base_output_data(const char* name, const char* version,
                              Output_data* od, elfcpp::STT type,
                              Output_data* od, elfcpp::STT type,
                              elfcpp::STB binding, elfcpp::STV visibility,
                              elfcpp::STB binding, elfcpp::STV visibility,
                              unsigned char nonvis, bool offset_is_from_end)
                              unsigned char nonvis, bool offset_is_from_end,
 
                              bool is_predefined)
{
{
  this->init_fields(name, version, type, binding, visibility, nonvis);
  this->init_fields(name, version, type, binding, visibility, nonvis);
  this->u_.in_output_data.output_data = od;
  this->u_.in_output_data.output_data = od;
  this->u_.in_output_data.offset_is_from_end = offset_is_from_end;
  this->u_.in_output_data.offset_is_from_end = offset_is_from_end;
  this->source_ = IN_OUTPUT_DATA;
  this->source_ = IN_OUTPUT_DATA;
  this->in_reg_ = true;
  this->in_reg_ = true;
  this->in_real_elf_ = true;
  this->in_real_elf_ = true;
 
  this->is_predefined_ = is_predefined;
}
}
 
 
// Initialize the fields in the base class Symbol for a symbol defined
// Initialize the fields in the base class Symbol for a symbol defined
// in an Output_segment.
// in an Output_segment.
 
 
void
void
Symbol::init_base_output_segment(const char* name, const char* version,
Symbol::init_base_output_segment(const char* name, const char* version,
                                 Output_segment* os, elfcpp::STT type,
                                 Output_segment* os, elfcpp::STT type,
                                 elfcpp::STB binding, elfcpp::STV visibility,
                                 elfcpp::STB binding, elfcpp::STV visibility,
                                 unsigned char nonvis,
                                 unsigned char nonvis,
                                 Segment_offset_base offset_base)
                                 Segment_offset_base offset_base,
 
                                 bool is_predefined)
{
{
  this->init_fields(name, version, type, binding, visibility, nonvis);
  this->init_fields(name, version, type, binding, visibility, nonvis);
  this->u_.in_output_segment.output_segment = os;
  this->u_.in_output_segment.output_segment = os;
  this->u_.in_output_segment.offset_base = offset_base;
  this->u_.in_output_segment.offset_base = offset_base;
  this->source_ = IN_OUTPUT_SEGMENT;
  this->source_ = IN_OUTPUT_SEGMENT;
  this->in_reg_ = true;
  this->in_reg_ = true;
  this->in_real_elf_ = true;
  this->in_real_elf_ = true;
 
  this->is_predefined_ = is_predefined;
}
}
 
 
// Initialize the fields in the base class Symbol for a symbol defined
// Initialize the fields in the base class Symbol for a symbol defined
// as a constant.
// as a constant.
 
 
void
void
Symbol::init_base_constant(const char* name, const char* version,
Symbol::init_base_constant(const char* name, const char* version,
                           elfcpp::STT type, elfcpp::STB binding,
                           elfcpp::STT type, elfcpp::STB binding,
                           elfcpp::STV visibility, unsigned char nonvis)
                           elfcpp::STV visibility, unsigned char nonvis,
 
                           bool is_predefined)
{
{
  this->init_fields(name, version, type, binding, visibility, nonvis);
  this->init_fields(name, version, type, binding, visibility, nonvis);
  this->source_ = IS_CONSTANT;
  this->source_ = IS_CONSTANT;
  this->in_reg_ = true;
  this->in_reg_ = true;
  this->in_real_elf_ = true;
  this->in_real_elf_ = true;
 
  this->is_predefined_ = is_predefined;
}
}
 
 
// Initialize the fields in the base class Symbol for an undefined
// Initialize the fields in the base class Symbol for an undefined
// symbol.
// symbol.
 
 
Line 225... Line 232...
                                     Output_data* od, Value_type value,
                                     Output_data* od, Value_type value,
                                     Size_type symsize, elfcpp::STT type,
                                     Size_type symsize, elfcpp::STT type,
                                     elfcpp::STB binding,
                                     elfcpp::STB binding,
                                     elfcpp::STV visibility,
                                     elfcpp::STV visibility,
                                     unsigned char nonvis,
                                     unsigned char nonvis,
                                     bool offset_is_from_end)
                                     bool offset_is_from_end,
 
                                     bool is_predefined)
{
{
  this->init_base_output_data(name, version, od, type, binding, visibility,
  this->init_base_output_data(name, version, od, type, binding, visibility,
                              nonvis, offset_is_from_end);
                              nonvis, offset_is_from_end, is_predefined);
  this->value_ = value;
  this->value_ = value;
  this->symsize_ = symsize;
  this->symsize_ = symsize;
}
}
 
 
// Initialize the fields in Sized_symbol for a symbol defined in an
// Initialize the fields in Sized_symbol for a symbol defined in an
Line 244... Line 252...
                                        Output_segment* os, Value_type value,
                                        Output_segment* os, Value_type value,
                                        Size_type symsize, elfcpp::STT type,
                                        Size_type symsize, elfcpp::STT type,
                                        elfcpp::STB binding,
                                        elfcpp::STB binding,
                                        elfcpp::STV visibility,
                                        elfcpp::STV visibility,
                                        unsigned char nonvis,
                                        unsigned char nonvis,
                                        Segment_offset_base offset_base)
                                        Segment_offset_base offset_base,
 
                                        bool is_predefined)
{
{
  this->init_base_output_segment(name, version, os, type, binding, visibility,
  this->init_base_output_segment(name, version, os, type, binding, visibility,
                                 nonvis, offset_base);
                                 nonvis, offset_base, is_predefined);
  this->value_ = value;
  this->value_ = value;
  this->symsize_ = symsize;
  this->symsize_ = symsize;
}
}
 
 
// Initialize the fields in Sized_symbol for a symbol defined as a
// Initialize the fields in Sized_symbol for a symbol defined as a
Line 260... Line 269...
template<int size>
template<int size>
void
void
Sized_symbol<size>::init_constant(const char* name, const char* version,
Sized_symbol<size>::init_constant(const char* name, const char* version,
                                  Value_type value, Size_type symsize,
                                  Value_type value, Size_type symsize,
                                  elfcpp::STT type, elfcpp::STB binding,
                                  elfcpp::STT type, elfcpp::STB binding,
                                  elfcpp::STV visibility, unsigned char nonvis)
                                  elfcpp::STV visibility, unsigned char nonvis,
 
                                  bool is_predefined)
{
{
  this->init_base_constant(name, version, type, binding, visibility, nonvis);
  this->init_base_constant(name, version, type, binding, visibility, nonvis,
 
                           is_predefined);
  this->value_ = value;
  this->value_ = value;
  this->symsize_ = symsize;
  this->symsize_ = symsize;
}
}
 
 
// Initialize the fields in Sized_symbol for an undefined symbol.
// Initialize the fields in Sized_symbol for an undefined symbol.
Line 1487... Line 1498...
}
}
 
 
// Add a symbol from a incremental object file.
// Add a symbol from a incremental object file.
 
 
template<int size, bool big_endian>
template<int size, bool big_endian>
Symbol*
Sized_symbol<size>*
Symbol_table::add_from_incrobj(
Symbol_table::add_from_incrobj(
    Object* obj,
    Object* obj,
    const char* name,
    const char* name,
    const char* ver,
    const char* ver,
    elfcpp::Sym<size, big_endian>* sym)
    elfcpp::Sym<size, big_endian>* sym)
Line 1841... Line 1852...
 
 
  if (sym == NULL)
  if (sym == NULL)
    return NULL;
    return NULL;
 
 
  sym->init_output_data(name, version, od, value, symsize, type, binding,
  sym->init_output_data(name, version, od, value, symsize, type, binding,
                        visibility, nonvis, offset_is_from_end);
                        visibility, nonvis, offset_is_from_end,
 
                        defined == PREDEFINED);
 
 
  if (oldsym == NULL)
  if (oldsym == NULL)
    {
    {
      if (binding == elfcpp::STB_LOCAL
      if (binding == elfcpp::STB_LOCAL
          || this->version_script_.symbol_is_local(name))
          || this->version_script_.symbol_is_local(name))
Line 1954... Line 1966...
 
 
  if (sym == NULL)
  if (sym == NULL)
    return NULL;
    return NULL;
 
 
  sym->init_output_segment(name, version, os, value, symsize, type, binding,
  sym->init_output_segment(name, version, os, value, symsize, type, binding,
                           visibility, nonvis, offset_base);
                           visibility, nonvis, offset_base,
 
                           defined == PREDEFINED);
 
 
  if (oldsym == NULL)
  if (oldsym == NULL)
    {
    {
      if (binding == elfcpp::STB_LOCAL
      if (binding == elfcpp::STB_LOCAL
          || this->version_script_.symbol_is_local(name))
          || this->version_script_.symbol_is_local(name))
Line 2066... Line 2079...
 
 
  if (sym == NULL)
  if (sym == NULL)
    return NULL;
    return NULL;
 
 
  sym->init_constant(name, version, value, symsize, type, binding, visibility,
  sym->init_constant(name, version, value, symsize, type, binding, visibility,
                     nonvis);
                     nonvis, defined == PREDEFINED);
 
 
  if (oldsym == NULL)
  if (oldsym == NULL)
    {
    {
      // Version symbols are absolute symbols with name == version.
      // Version symbols are absolute symbols with name == version.
      // We don't want to force them to be local.
      // We don't want to force them to be local.
Line 3451... Line 3464...
    size_t* defined);
    size_t* defined);
#endif
#endif
 
 
#ifdef HAVE_TARGET_32_LITTLE
#ifdef HAVE_TARGET_32_LITTLE
template
template
Symbol*
Sized_symbol<32>*
Symbol_table::add_from_incrobj(
Symbol_table::add_from_incrobj(
    Object* obj,
    Object* obj,
    const char* name,
    const char* name,
    const char* ver,
    const char* ver,
    elfcpp::Sym<32, false>* sym);
    elfcpp::Sym<32, false>* sym);
#endif
#endif
 
 
#ifdef HAVE_TARGET_32_BIG
#ifdef HAVE_TARGET_32_BIG
template
template
Symbol*
Sized_symbol<32>*
Symbol_table::add_from_incrobj(
Symbol_table::add_from_incrobj(
    Object* obj,
    Object* obj,
    const char* name,
    const char* name,
    const char* ver,
    const char* ver,
    elfcpp::Sym<32, true>* sym);
    elfcpp::Sym<32, true>* sym);
#endif
#endif
 
 
#ifdef HAVE_TARGET_64_LITTLE
#ifdef HAVE_TARGET_64_LITTLE
template
template
Symbol*
Sized_symbol<64>*
Symbol_table::add_from_incrobj(
Symbol_table::add_from_incrobj(
    Object* obj,
    Object* obj,
    const char* name,
    const char* name,
    const char* ver,
    const char* ver,
    elfcpp::Sym<64, false>* sym);
    elfcpp::Sym<64, false>* sym);
#endif
#endif
 
 
#ifdef HAVE_TARGET_64_BIG
#ifdef HAVE_TARGET_64_BIG
template
template
Symbol*
Sized_symbol<64>*
Symbol_table::add_from_incrobj(
Symbol_table::add_from_incrobj(
    Object* obj,
    Object* obj,
    const char* name,
    const char* name,
    const char* ver,
    const char* ver,
    elfcpp::Sym<64, true>* sym);
    elfcpp::Sym<64, true>* sym);

powered by: WebSVN 2.1.0

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