Linux LTO with lld from llvm 9

David Nadlinger code at
Fri Oct 4 14:50:26 UTC 2019

On 4 Oct 2019, at 4:06, Newbie2019 via digitalmars-d-ldc wrote:
> when I link with gold I get this error:
> ld-new: fatal error: LLVM gold plugin has failed to create LTO module: 
> Unknown attribute kind (62) (Producer: 'LLVM9.0.0' Reader: 'LLVM 
> 8.0.1')
> clang-8: error: linker command failed with exit code 1 (use -v to see 
> invocation)

Seems like you are trying to use LTO with LDC built against LLVM 9.0, 
but the linker plugin (probably from clang) is built against LLVM 8.0? 
The plugin [1] is separate from the linker itself. should generally work fine. Perhaps others can chime in as to 
what the current situation with LLD on Linux is; I haven't tried it 

  — David


More information about the digitalmars-d-ldc mailing list