summaryrefslogtreecommitdiff
path: root/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
diff options
context:
space:
mode:
authorAndrew Kaylor <andrew.kaylor@intel.com>2013-08-19 19:38:06 +0000
committerAndrew Kaylor <andrew.kaylor@intel.com>2013-08-19 19:38:06 +0000
commit32bd10b1a33df2cc4d067a16901d56665f4ba085 (patch)
tree6466dbe72520fc19b147dc028bbaa814a5b3ff23 /lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
parent1e09ed13893ad9d463c6c08c996170bac6e60449 (diff)
downloadllvm-32bd10b1a33df2cc4d067a16901d56665f4ba085.tar.gz
llvm-32bd10b1a33df2cc4d067a16901d56665f4ba085.tar.bz2
llvm-32bd10b1a33df2cc4d067a16901d56665f4ba085.tar.xz
Adding comments to document RuntimeDyld relocation handling
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188697 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp')
-rw-r--r--lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
index 943622fba8..a00b951e0a 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
@@ -41,6 +41,9 @@ void RuntimeDyldImpl::resolveRelocations() {
// Just iterate over the sections we have and resolve all the relocations
// in them. Gross overkill, but it gets the job done.
for (int i = 0, e = Sections.size(); i != e; ++i) {
+ // The Section here (Sections[i]) refers to the section in which the
+ // symbol for the relocation is located. The SectionID in the relocation
+ // entry provides the section to which the relocation will be applied.
uint64_t Addr = Sections[i].LoadAddress;
DEBUG(dbgs() << "Resolving relocations Section #" << i
<< "\t" << format("%p", (uint8_t *)Addr)