|
LLVM
3.7.0
|
#include <RuntimeDyld.h>
Classes | |
| class | LoadedObjectInfo |
| Information about the loaded object. More... | |
| struct | LoadedObjectInfoHelper |
| class | MemoryManager |
| Memory Management. More... | |
| class | SymbolInfo |
| Information about a named symbol. More... | |
| class | SymbolResolver |
| Symbol resolution. More... | |
Public Member Functions | |
| RuntimeDyld (MemoryManager &MemMgr, SymbolResolver &Resolver) | |
| Construct a RuntimeDyld instance. More... | |
| ~RuntimeDyld () | |
| std::unique_ptr< LoadedObjectInfo > | loadObject (const object::ObjectFile &O) |
| Add the referenced object file to the list of objects to be loaded and relocated. More... | |
| void * | getSymbolLocalAddress (StringRef Name) const |
| Get the address of our local copy of the symbol. More... | |
| SymbolInfo | getSymbol (StringRef Name) const |
| Get the target address and flags for the named symbol. More... | |
| void | resolveRelocations () |
| Resolve the relocations for all symbols we currently know about. More... | |
| void | mapSectionAddress (const void *LocalAddress, uint64_t TargetAddress) |
| Map a section to its target address space value. More... | |
| void | registerEHFrames () |
| Register any EH frame sections that have been loaded but not previously registered with the memory manager. More... | |
| void | deregisterEHFrames () |
| bool | hasError () |
| StringRef | getErrorString () |
| void | setProcessAllSections (bool ProcessAllSections) |
| By default, only sections that are "required for execution" are passed to the RTDyldMemoryManager, and other sections are discarded. More... | |
Protected Member Functions | |
| void | reassignSectionAddress (unsigned SectionID, uint64_t Addr) |
Friends | |
| class | RuntimeDyldCheckerImpl |
Definition at line 34 of file RuntimeDyld.h.
| llvm::RuntimeDyld::RuntimeDyld | ( | RuntimeDyld::MemoryManager & | MemMgr, |
| RuntimeDyld::SymbolResolver & | Resolver | ||
| ) |
Construct a RuntimeDyld instance.
Definition at line 832 of file RuntimeDyld.cpp.
| llvm::RuntimeDyld::~RuntimeDyld | ( | ) |
Definition at line 846 of file RuntimeDyld.cpp.
| void llvm::RuntimeDyld::deregisterEHFrames | ( | ) |
Definition at line 936 of file RuntimeDyld.cpp.
Referenced by llvm::MCJIT::~MCJIT().
| StringRef llvm::RuntimeDyld::getErrorString | ( | ) |
Definition at line 929 of file RuntimeDyld.cpp.
Referenced by llvm::MCJIT::addObjectFile(), and llvm::MCJIT::generateCodeForModule().
| RuntimeDyld::SymbolInfo llvm::RuntimeDyld::getSymbol | ( | StringRef | Name | ) | const |
Get the target address and flags for the named symbol.
This address is the one used for relocation.
Definition at line 910 of file RuntimeDyld.cpp.
Referenced by llvm::MCJIT::findExistingSymbol(), and llvm::MCJIT::getPointerToFunction().
| void * llvm::RuntimeDyld::getSymbolLocalAddress | ( | StringRef | Name | ) | const |
Get the address of our local copy of the symbol.
This may or may not be the address used for relocation (clients can copy the data around and resolve relocatons based on where they put it).
Definition at line 904 of file RuntimeDyld.cpp.
| bool llvm::RuntimeDyld::hasError | ( | ) |
Definition at line 927 of file RuntimeDyld.cpp.
Referenced by llvm::MCJIT::addObjectFile(), and llvm::MCJIT::generateCodeForModule().
| std::unique_ptr< RuntimeDyld::LoadedObjectInfo > llvm::RuntimeDyld::loadObject | ( | const object::ObjectFile & | O | ) |
Add the referenced object file to the list of objects to be loaded and relocated.
Definition at line 882 of file RuntimeDyld.cpp.
References llvm::createRuntimeDyldCOFF(), llvm::createRuntimeDyldELF(), llvm::createRuntimeDyldMachO(), llvm::object::ObjectFile::getArch(), llvm::object::Binary::isCOFF(), llvm::object::Binary::isELF(), llvm::object::Binary::isMachO(), and llvm::report_fatal_error().
Referenced by llvm::MCJIT::addObjectFile(), and llvm::MCJIT::generateCodeForModule().
| void llvm::RuntimeDyld::mapSectionAddress | ( | const void * | LocalAddress, |
| uint64_t | TargetAddress | ||
| ) |
Map a section to its target address space value.
Map the address of a JIT section as returned from the memory manager to the address in the target process as the running code will see it. This is the address which will be used for relocation resolution.
Definition at line 922 of file RuntimeDyld.cpp.
Referenced by llvm::MCJIT::mapSectionAddress().
|
protected |
Definition at line 918 of file RuntimeDyld.cpp.
| void llvm::RuntimeDyld::registerEHFrames | ( | ) |
Register any EH frame sections that have been loaded but not previously registered with the memory manager.
Note, RuntimeDyld is responsible for identifying the EH frame and calling the memory manager with the EH frame section data. However, the memory manager itself will handle the actual target-specific EH frame registration.
Definition at line 931 of file RuntimeDyld.cpp.
Referenced by llvm::MCJIT::finalizeLoadedModules().
| void llvm::RuntimeDyld::resolveRelocations | ( | ) |
Resolve the relocations for all symbols we currently know about.
Definition at line 916 of file RuntimeDyld.cpp.
Referenced by llvm::MCJIT::finalizeLoadedModules().
|
inline |
By default, only sections that are "required for execution" are passed to the RTDyldMemoryManager, and other sections are discarded.
Passing 'true' to this method will cause RuntimeDyld to pass all sections to its memory manager regardless of whether they are "required to execute" in the usual sense. This is useful for inspecting metadata sections that may not contain relocations, E.g. Debug info, stackmaps.
Must be called before the first object file is loaded.
Definition at line 230 of file RuntimeDyld.h.
Referenced by llvm::MCJIT::setProcessAllSections().
|
friend |
Definition at line 35 of file RuntimeDyld.h.
1.8.6