[gold/ThinLTO] Restore ThinLTO file management in gold plugin
authorTeresa Johnson <tejohnson@google.com>
Sat, 20 Aug 2016 01:24:07 +0000 (01:24 +0000)
committerTeresa Johnson <tejohnson@google.com>
Sat, 20 Aug 2016 01:24:07 +0000 (01:24 +0000)
commit765941a841ee6b48a31aa639bc79c5a4dbe9ebb3
tree523c204f9683733b318e400f9bbc97082d6f9ff9
parent1f76caf3dd0c3935df409aa698c8f87c754b1dc7
[gold/ThinLTO] Restore ThinLTO file management in gold plugin

Summary:
The gold-plugin changes added along with the new LTO API in r278338 had
the effect of removing the management of the PluginInputFile that
ensured the files weren't released back to gold until the backend
threads were complete. Add back the old file handling.

Fixes PR29020.

Reviewers: mehdi_amini

Subscribers: mehdi_amini, llvm-commits, hjl.tools

Differential Revision: https://reviews.llvm.org/D23721

llvm-svn: 279356
llvm/test/tools/gold/X86/thinlto.ll
llvm/tools/gold/gold-plugin.cpp