This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[gold][patch] Fix two plugin bugs


This patch fixes two plugin problems: (1) When using -r with plugins,
gold crashes if it needs to defer layout for any input sections, and
(2) gold does not complain about an undefined symbol if the symbol was
defined in an IR file, but omitted from the replacement file(s) (PR
11683).

Tested on x86_64 with no regressions.

-cary


        * object.cc (Sized_relobj::do_layout): Defer layout for reloc sections.
        (Sized_relobj::do_layout_deferred_sections): Do layout for deferred
        reloc sections.
        * object.h (Sized_relobj::deferred_layout_relocs_): New data member.

        PR 11683
        * symtab.h (Symbol::is_placeholder): New member function.
        * target-reloc.h (relocate_section): Check for placeholder symbols.

        * testsuite/Makefile.am (plugin_test_8): New test.
        (plugin_test_9): New test.
        * testsuite/Makefile.in: Regenerate.

Attachment: gold-plugin-11683-patch.txt
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]