[lld] [LLD][COFF] Fix handling of weak aliases referencing lazy symbols (PR #112243)
Martin Storsjö via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 14 12:41:50 PDT 2024
================
@@ -340,7 +340,10 @@ class Undefined : public Symbol {
// If this symbol is external weak, try to resolve it to a defined
// symbol by searching the chain of fallback symbols. Returns the symbol if
// successful, otherwise returns null.
- Defined *getWeakAlias();
+ Symbol *getWeakAlias();
----------------
mstorsjo wrote:
In trying to read the diff and the effects of it - I see that a number of callers are switched from `getWeakAlias()` to `getDefinedWeakAlias()` - but what I don't see from the point of view of the diff, is what remaining callers there are, that still are calling `getWeakAlias()`?
Because any caller that is switched to `getDefinedWeakAlias()` will essentially be doing the same as before (minus the UB in `cast<Undefined>()`), but which callers do get the new behaviour of `getWeakAlias()` where it potentially returns something else?
https://github.com/llvm/llvm-project/pull/112243
More information about the llvm-commits
mailing list