summaryrefslogtreecommitdiff
path: root/www
diff options
context:
space:
mode:
authorReid Kleckner <reid@kleckner.net>2015-08-03 19:51:18 +0000
committerReid Kleckner <reid@kleckner.net>2015-08-03 19:51:18 +0000
commit7bab8082abb58bc4bb9b4bc69e397ea08712b0c6 (patch)
tree570f68f34b4576cb519facea5b64cdc8ef11b3be /www
parent8eee754fa1eb1df506d5d2acee7555bd9f10208b (diff)
[asan] Print VAs instead of RVAs for module offsets on Windows
Summary: This is consistent with binutils and ASan behavior on other platforms, and makes it easier to use llvm-symbolizer with WinASan. The --relative-address flag to llvm-symbolizer is also no longer needed. An RVA is a "relative virtual address", meaning it is the address of something inside the image minus the base of the mapping at runtime. A VA in this context is an RVA plus the "preferred base" of the module, and not a real runtime address. The real runtime address of a symbol will equal the VA iff the module is loaded at its preferred base at runtime. On Windows, the preferred base is stored in the ImageBase field of one of the PE file header, and this change adds the necessary code to extract it. On Linux, this offset is typically included in program and section headers of executables. ELF shared objects typically use a preferred base of zero, meaning the smallest p_vaddr field in the program headers is zero. This makes it so that PIC and PIE module offsets come out looking like RVAs, but they're actually VAs. The difference between them simply happens to be zero. Reviewers: samsonov, majnemer Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D11681 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@243895 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'www')
0 files changed, 0 insertions, 0 deletions