Suppress realignment of data segment for incremental links, and fix handling of TLS and BSS sections during incremental update. 2011-05-02 Cary Coutant * layout.cc (Layout::set_segment_offsets): Don't adjust layout for incremental links. * output.cc (Output_segment::set_section_list_addresses): Remove FIXME and test for TLS or BSS. diff --git a/gold/layout.cc b/gold/layout.cc index 67ed8c3..537651a 100644 --- a/gold/layout.cc +++ b/gold/layout.cc @@ -2945,7 +2945,7 @@ Layout::set_segment_offsets(const Target* target, Output_segment* load_seg, if (!are_addresses_set && !has_relro && aligned_addr != addr - && !parameters->incremental_update()) + && !parameters->incremental()) { uint64_t first_off = (common_pagesize - (aligned_addr diff --git a/gold/output.cc b/gold/output.cc index 832428e..8e81b07 100644 --- a/gold/output.cc +++ b/gold/output.cc @@ -4036,10 +4036,7 @@ Output_segment::set_section_list_addresses(Layout* layout, bool reset, } } - // FIXME: Need to handle TLS and .bss with incremental update. - if (!parameters->incremental_update() - || (*p)->is_section_flag_set(elfcpp::SHF_TLS) - || (*p)->is_section_type(elfcpp::SHT_NOBITS)) + if (!parameters->incremental_update()) { off = align_address(off, align); (*p)->set_address_and_file_offset(addr + (off - startoff), off);