> What about instead of our current odd way of identifying LTO objects
> simply add a special ELF note telling the linker the plugin to use?
>
> .note._linker_plugin '/...../libltoplugin.so'
>
> that way the linker should try 1) loading that plugin, 2) register the
> specific object with that plugin.
>
> If a full path is undesired (depends on install setup) then specifying
> the plugin SONAME might also work (we'd of course need to bump
> our plugins SONAME for each release to allow parallel install
> of multiple versions or make the plugin contain all the
> dispatch-to-different-GCC-version-lto-wrapper code).

Might be an interesting addition to what we have, but keep in mind
that LLVM uses thin non-ELF files. It is also able to load IR from
previous versions, so for LLVM at least, using the newest plugin is
probably the best default.

> Richard.

Cheers,
Rafael

Reply via email to