llvm-project/llvm/lib/ExecutionEngine/RuntimeDyld
Rafael Auler a33687ec58 [RuntimeDyld] Add allowStubs/allowZeroSyms
This patch introduces functionality used by BOLT when
re-linking the final binary. It adds to MemoryManager a new member
function allowStubAllocation to control whether this MemoryManager
supports increasing code size with stubs or not. Since BOLT can
rewrite some files in-place, it needs to avoid stub insertion done
by the linker. This patch also introduces allowsZeroSymbols to the
JITSymbolResolver class, enabling us to finish a link successfully
even when some symbols resolve to the value zero. When rewriting a
binary, sometimes we do need to resolve a target to zero in case
the input binary calls address zero and we want to be bug
compatible. We also expose reassignSectionAddress as it is used by
BOLT.

Reviewed By: lhames

Differential Revision: https://reviews.llvm.org/D97898
2021-05-18 11:35:27 -07:00
..
Targets [RuntimeDyld][COFF] Report fatal error on error, rather than emiting diagnostic. 2020-10-06 15:16:29 -07:00
CMakeLists.txt llvmbuildectomy - replace llvm-build by plain cmake 2020-11-13 10:35:24 +01:00
JITSymbol.cpp [ORC] Honor linker private global prefix on symbol names. 2020-06-15 10:28:36 -07:00
RTDyldMemoryManager.cpp [CMake][ExecutionEngine] add HAVE_(DE)REGISTER_FRAME as a config.h macros 2020-11-10 13:09:44 -05:00
RuntimeDyld.cpp [RuntimeDyld] Add allowStubs/allowZeroSyms 2021-05-18 11:35:27 -07:00
RuntimeDyldCOFF.cpp [Object] Change ObjectFile::getSymbolValue() return type to Expected<uint64_t> 2020-05-02 14:04:44 +08:00
RuntimeDyldCOFF.h
RuntimeDyldChecker.cpp [JITLink] Switch from StringRef to ArrayRef<char>, add some generic x86-64 utils 2021-03-30 21:07:24 -07:00
RuntimeDyldCheckerImpl.h
RuntimeDyldELF.cpp [RuntimeDyld] Add allowStubs/allowZeroSyms 2021-05-18 11:35:27 -07:00
RuntimeDyldELF.h RuntimeDyldELF.h - make the object namespace explicit for ELFObjectFileBase. NFC. 2020-04-23 13:52:49 +01:00
RuntimeDyldImpl.h [RuntimeDyld] Fixed buffer overflows with absolute symbols 2021-04-26 19:24:03 +02:00
RuntimeDyldMachO.cpp
RuntimeDyldMachO.h