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/ > * archive.cc (Archive::get_elf_object_for_member): Unlock external > members of thin archives so that they may be used by plugins. Thanks! This is the problem, but Archive::include_member() is supposed to be responsible for unlocking external members of thin archives, and does it properly except in the plugin case. I've chosen to fix this by adding an RAII class to unlock the object when include_member() returns. I've also modified the test plugin library a bit to make it easy to add a test case for claiming members of a thin archive. The failure to unlock these objects is actually the cause of PR 15660 (at least I'm pretty certain of that), which complains that the linker is running out of file descriptors when linking a very large application using LTO. The gcc LTO plugin doesn't use the get_input_file API, so the problem went undetected until actually running out of available file descriptors. -cary 2015-02-03 Cary Coutant <ccoutant@google.com> Peter Collingbourne <pcc@google.com> gold/ PR gold/15660 * archive.cc (Thin_archive_object_unlocker): New class. (Archive::include_member): Unlock external members of thin archives. * testsuite/Makefile.am (plugin_test_1): Rename .syms files. (plugin_test_2): Likewise. (plugin_test_3): Likewise. (plugin_test_4): Likewise. (plugin_test_5): Likewise. (plugin_test_6): Likewise. (plugin_test_7): Likewise. (plugin_test_8): Likewise. (plugin_test_9): Likewise. (plugin_test_10): Likewise. (plugin_test_11): New test case. * testsuite/Makefile.in: Regenerate. * testsuite/plugin_test.c (claim_file_hook): Check for parallel .syms file to decide whether to claim file. (all_symbols_read_hook): Likewise. * testsuite/plugin_test_1.sh: Adjust expected output. * testsuite/plugin_test_2.sh: Likewise. * testsuite/plugin_test_3.sh: Likewise. * testsuite/plugin_test_6.sh: Likewise. * testsuite/plugin_test_tls.sh: Likewise. * testsuite/plugin_test_11.sh: New testcase.
Attachment:
patch-pr15660.txt
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |