On 1/4/22 08:23, Richard Biener wrote:
Since we have a fixed set of supported linkers and we know their implementation
status with respect to linker plugin support we can maybe auto-add
-fno-use-linker-plugin
(via specs?) when -fuse-ld=lld or -fuse-ld=mold is used?

Well, if I'm correct, we do so when GCC is configured with --with-ld=...
That can perform version detection and so on. I still hope that ld.mold will
support LTO plug-in quite soon. It's even possible that it will be there
once GCC 12.1 is released.

But yes,
adding a note to
the documentation that for lld and mold LTO support is severely
restricted compared to
GNU ld or gold on platforms that support the linker plugin and thus
their use is discouraged
there might be a good idea.

I'm going to do that if ld.mold LTO support won't be available
when 12.1 gets released.

Martin

Reply via email to