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

Subversion Repositories open8_urisc

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

Show entire file | Details | Blame | View Log

Rev 27 Rev 148
Line 284... Line 284...
      break;
      break;
    default:
    default:
      gold_unreachable();
      gold_unreachable();
    }
    }
 
 
  Output_data_space* poc = new Output_data_space(addralign, ds_name);
  Output_data_space* poc;
  Output_section* os = layout->add_output_section_data(name,
  Output_section* os;
                                                       elfcpp::SHT_NOBITS,
 
                                                       flags, poc,
  if (!parameters->incremental_update())
                                                       ORDER_INVALID,
    {
                                                       false);
      poc = new Output_data_space(addralign, ds_name);
 
      os = layout->add_output_section_data(name, elfcpp::SHT_NOBITS, flags,
 
                                           poc, ORDER_INVALID, false);
 
    }
 
  else
 
    {
 
      // When doing an incremental update, we need to allocate each common
 
      // directly from the output section's free list.
 
      poc = NULL;
 
      os = layout->find_output_section(name);
 
    }
 
 
  if (os != NULL)
  if (os != NULL)
    {
    {
      if (commons_section_type == COMMONS_SMALL)
      if (commons_section_type == COMMONS_SMALL)
        os->set_is_small_section();
        os->set_is_small_section();
      else if (commons_section_type == COMMONS_LARGE)
      else if (commons_section_type == COMMONS_LARGE)
Line 327... Line 338...
      // value.  Pass the size in separately so that we don't have to
      // value.  Pass the size in separately so that we don't have to
      // templatize the map code, which is not performance sensitive.
      // templatize the map code, which is not performance sensitive.
      if (mapfile != NULL)
      if (mapfile != NULL)
        mapfile->report_allocate_common(sym, ssym->symsize());
        mapfile->report_allocate_common(sym, ssym->symsize());
 
 
 
      if (poc != NULL)
 
        {
      off = align_address(off, ssym->value());
      off = align_address(off, ssym->value());
      ssym->allocate_common(poc, off);
      ssym->allocate_common(poc, off);
      off += ssym->symsize();
      off += ssym->symsize();
    }
    }
 
      else
 
        {
 
          // For an incremental update, allocate from the free list.
 
          off = os->allocate(ssym->symsize(), ssym->value());
 
          if (off == -1)
 
            gold_fallback(_("out of patch space in section %s; "
 
                            "relink with --incremental-full"),
 
                          os->name());
 
          ssym->allocate_common(os, off);
 
        }
 
    }
 
 
 
  if (poc != NULL)
  poc->set_current_data_size(off);
  poc->set_current_data_size(off);
 
 
  commons->clear();
  commons->clear();
}
}
 
 

powered by: WebSVN 2.1.0

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