[PATCH] D15447: [compiler-rt] [tsan] Add support for PIE build on AArch64

Adhemerval Zanella via llvm-commits llvm-commits at lists.llvm.org
Fri Dec 11 05:27:51 PST 2015


zatrazz created this revision.
zatrazz added reviewers: dvyukov, eugenis, samsonov, rengolin, kcc.
zatrazz added a subscriber: llvm-commits.
Herald added subscribers: rengolin, aemerson.

This patch adds PIE executable support for aarch64-linux.  It adds
two more segments:

- 0x05500000000-0x05600000000: 39-bits PIE program segments
- 0x2aa00000000-0x2ab00000000: 42-bits PIE program segments

Fortunately it is possible to use the same transformation formula for
the new segments range with some adjustments in shadow to memory
formula (it adds a constant offset based on the VMA size).

I checked by running the testcase build with and without PIE flags.
No regressions found.

This closes the concerns raised in [1] and [2] regarding PIE support
to tsan on aarch64-linux-gnu.

[1] http://reviews.llvm.org/D14199
[2] http://reviews.llvm.org/D15308

http://reviews.llvm.org/D15447

Files:
  lib/tsan/rtl/tsan_platform.h
  lib/tsan/rtl/tsan_platform_posix.cc

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15447.42515.patch
Type: text/x-patch
Size: 6109 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151211/36fff503/attachment.bin>


More information about the llvm-commits mailing list