This is https://bugs.llvm.org//show_bug.cgi?id=38919.
Currently, LLD may report "unsupported relocation target while parsing debug info"
when parsing the debug information.
At the same time in the bug sample, it does that for zeroed R_X86_64_NONE relocation:
000000009cca 015e00000001 R_X86_64_64 0000000000000000 + 0 000000009cfa 000000000000 R_X86_64_NONE 0 000000009d69 015f00000001 R_X86_64_64 0000000000000000 + 0
Which obviously has "invalid" target (not defined symbol) because it is zeroed out.
I believe the nature of R_*_NONE relocation assumes them should be ignored and
that is why they were invented. So this patch teaches LLD to stop reporting
debug information parsing errors for them.
Looks like calling getRelExpr is overkill as you don't really need a symbol and a relocation target location. You probably should define a more lightweight predicate or just Target->NoneRelType.