[lld] [llvm] [LTO] [LLD] Don't alias the __imp_func and func symbol resolutions (PR #71376)
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Sat Nov 18 00:27:41 PST 2023
https://github.com/MaskRay approved this pull request.
> The only level that knows of the potential relationship between the `__imp_` prefixed and unprefixed symbol, across regular and bitcode object files, is LLD itself.
Agreed.
> Previously, the aliasing of global resolutions at the LTO level would trigger a failed assert with "Multiple prevailing defs are not allowed" for this case, as both importedFunc and __imp_importedFunc could be prevailing. Add a case to the existing LLD test case lto-imp-prefix.ll to test this as well.
Confirmed.
The LLD fix is indeed better than https://reviews.llvm.org/D49138 . Whether the unprefixed is external does not matter now.
https://github.com/llvm/llvm-project/pull/71376
More information about the llvm-commits
mailing list