[lld] [LLD][COFF] Emit base relocation for native CHPE metadata pointer on ARM64X (PR #121500)
Martin Storsjö via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 8 14:38:22 PST 2025
mstorsjo wrote:
> LGTM, thanks - this looks very neat now. Sorry I somehow mixed this up in the previous review, thinking it was about dynamic relocations.
Now I also managed to dig up and reread the original version of the commit - now I understand what that version really did. The previous version was quite confusing, as it modified regular coff object relocations, in order to allocate a new base relocation, done in the function for creating dynamic relocations.
So the problem that is being fixed here, is that the original load config struct in the object files has a plain zero in these files (no relocation) - as we copy over a value synthetically in the linker (rather than by resolving a regular object file relocation), we also need to make sure that a corresponding base relocation is generated here.
(I'm sure you've explained this already once or twice here - but unfortunately it sometimes takes a bit of time to actually understand it.)
https://github.com/llvm/llvm-project/pull/121500
More information about the llvm-commits
mailing list