[lld] [llvm] [LLD][COFF] Add support for ARM64EC entry thunks. (PR #88132)
Jacek Caban via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 17 08:19:17 PDT 2024
================
@@ -410,6 +410,10 @@ void SectionChunk::writeTo(uint8_t *buf) const {
applyRelocation(buf + rel.VirtualAddress, rel);
}
+
+ // Write the offset to EC entry thunk preceding section contents.
+ if (Defined *entryThunk = getEntryThunk())
+ write32le(buf - sizeof(uint32_t), entryThunk->getRVA() - rva + 1);
----------------
cjacek wrote:
It's what I observed with MSVC and what Windows expects, I can only speculate about the reason. It could be just "have the low bit set", or it could be interpreted as the offset being from the last byte of the padding, not the first byte of the function. I added a comment about it.
https://github.com/llvm/llvm-project/pull/88132
More information about the llvm-commits
mailing list