[PATCH] D28362: [ThinLTO] Optionally ignore empty index file

Teresa Johnson via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jan 6 13:41:10 PST 2017


tejohnson added a comment.

In https://reviews.llvm.org/D28362#638260, @mehdi_amini wrote:

> > In order to simplify distributed build system integration, where actions
> >  may be scheduled before the Thin Link which determines the list of
> >  objects selected by the linker. The gold plugin currently will emit
> >  0-sized index files for objects not selected by the link, to enable
> >  checking for expected output files by the build system. If the build
> >  system then schedules a backend action for these bitcode files, we want
> >  to be able to fall back to normal compilation instead of failing.
>
> Just thought about it: why not emit an empty *index* instead of an empty file?


I thought about that initially. But it will also need some special handling as e.g. FunctionImportGlobalProcessing::shouldPromoteLocalToGlobal on the module being compiled will complain when it doesn't find summaries for the GVs in that module. There might be other places too, that's the first one I found when I was thinking about this approach.


https://reviews.llvm.org/D28362





More information about the cfe-commits mailing list