[PATCH] D134794: [lld-macho] Do not error out on dead stripped duplicate symbols

Jez Ng via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 28 11:44:28 PDT 2022


int3 added a comment.

> why is fixing this problem harder than others you have to fix when you want to use lld?

I would argue that reducing barriers to LLD adoption is good, regardless of whether the problem is harder or easier to fix. Even if it's just one extra error, that error might be the one that makes a potential adopter decide that adoption is just too much effort.

(Ngl I have already slightly regretted the choice of not deduplicating strings by default. I'm not convinced it saves us that much link time, and moreover I think it's more likely than not that the average adopter would just add that `--deduplicate-literals` flag rather than fixing their build.)

I think there's a good argument for having stricter behavior by default, though. My preference would be to support this but gate it under a flag (or possibly have a `--ld64-compat` flag that enables this behavior as well as `--deduplicate-literals`.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D134794/new/

https://reviews.llvm.org/D134794



More information about the llvm-commits mailing list