diff options
author | Lang Hames <lhames@gmail.com> | 2014-06-25 00:20:53 +0000 |
---|---|---|
committer | Lang Hames <lhames@gmail.com> | 2014-06-25 00:20:53 +0000 |
commit | 7ede4b96ded381fd054d9c006a4a66c1f69b5e42 (patch) | |
tree | fa706e908f38d34cf0ecdfef8663b1bc9c530973 /lib/Object | |
parent | 49b52b35d411a4cc28eb83bdc440a9839bb5bc17 (diff) | |
download | llvm-7ede4b96ded381fd054d9c006a4a66c1f69b5e42.tar.gz llvm-7ede4b96ded381fd054d9c006a4a66c1f69b5e42.tar.bz2 llvm-7ede4b96ded381fd054d9c006a4a66c1f69b5e42.tar.xz |
[RuntimeDyld] Adds the necessary hooks to MCJIT to be able to debug generated
MachO files using the GDB JIT debugging interface.
Patch by Keno Fischer. Thanks Keno!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@211652 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Object')
-rw-r--r-- | lib/Object/MachOObjectFile.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/Object/MachOObjectFile.cpp b/lib/Object/MachOObjectFile.cpp index 09c842c4a0..dbfc07270a 100644 --- a/lib/Object/MachOObjectFile.cpp +++ b/lib/Object/MachOObjectFile.cpp @@ -1797,7 +1797,7 @@ StringRef MachOObjectFile::getStringTableData() const { bool MachOObjectFile::is64Bit() const { return getType() == getMachOType(false, true) || - getType() == getMachOType(true, true); + getType() == getMachOType(true, true); } void MachOObjectFile::ReadULEB128s(uint64_t Index, @@ -1812,6 +1812,10 @@ void MachOObjectFile::ReadULEB128s(uint64_t Index, } } +const char *MachOObjectFile::getSectionPointer(DataRefImpl Rel) const { + return Sections[Rel.d.a]; +} + ErrorOr<ObjectFile *> ObjectFile::createMachOObjectFile(std::unique_ptr<MemoryBuffer> &Buffer) { StringRef Magic = Buffer->getBuffer().slice(0, 4); |