llvm-project/llvm/tools/llvm-rtdyld
Lang Hames 776f1d50c8 [RuntimeDyld][COFF] Skip non-loaded sections when calculating ImageBase.
Non-loaded sections (whose unused load-address defaults to zero) should not
be taken into account when calculating ImageBase, or ImageBase will be
incorrectly set to 0.

Patch by Andrew Scheidecker. Thanks Andrew!

https://reviews.llvm.org/D51343

+        // The Sections list may contain sections that weren't loaded for
+        // whatever reason: they may be debug sections, and ProcessAllSections
+        // is false, or they may be sections that contain 0 bytes. If the
+        // section isn't loaded, the load address will be 0, and it should not
+        // be included in the ImageBase calculation.

llvm-svn: 344995
2018-10-23 01:36:33 +00:00
..
CMakeLists.txt
LLVMBuild.txt
llvm-rtdyld.cpp [RuntimeDyld][COFF] Skip non-loaded sections when calculating ImageBase. 2018-10-23 01:36:33 +00:00