diff options
author | Dmitry Vyukov <dvyukov@google.com> | 2016-09-22 13:42:02 +0000 |
---|---|---|
committer | Dmitry Vyukov <dvyukov@google.com> | 2016-09-22 13:42:02 +0000 |
commit | cc1f318b5a5fa3f36832f246ffb74be87fb35027 (patch) | |
tree | 64e5099814cbb16e110f6ff456a800a6513f90e4 /lldb/packages/Python/lldbsuite/test | |
parent | 9e05266dcbc05c28469d1ec296aa374e3526c5f0 (diff) | |
download | bcm5719-llvm-cc1f318b5a5fa3f36832f246ffb74be87fb35027.tar.gz bcm5719-llvm-cc1f318b5a5fa3f36832f246ffb74be87fb35027.zip |
tsan: support pie binaries on newer kernels
4.1+ Linux kernels map pie binaries at 0x55:
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=d1fd836dcf00d2028c700c7e44d2c23404062c90
Currently tsan does not support app memory at 0x55 (https://github.com/google/sanitizers/issues/503).
Older kernels also map pie binaries at 0x55 when ASLR is disables (most notably under gdb).
This change extends tsan mapping for linux/x86_64 to cover 0x554-0x568 app range and fixes both 4.1+ kernels and gdb.
This required to slightly shrink low and high app ranges and move heap. The mapping become even more non-linear, since now we xor lower bits. Now even a continuous app range maps to split, intermixed shadow ranges. This breaks ShadowToMemImpl as it assumes linear mapping at least within a continuous app range (however it turned out to be already broken at least on arm64/42-bit vma as uncovered by r281970). So also change ShadowToMemImpl to hopefully a more robust implementation that does not assume a linear mapping.
llvm-svn: 282152
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test')
0 files changed, 0 insertions, 0 deletions