llvm-project/compiler-rt/test
Alexey Samsonov 4f319cca42 [ASan] Print exact source location of global variables in error reports.
See https://code.google.com/p/address-sanitizer/issues/detail?id=299 for the
original feature request.

Introduce llvm.asan.globals metadata, which Clang (or any other frontend)
may use to report extra information about global variables to ASan
instrumentation pass in the backend. This metadata replaces
llvm.asan.dynamically_initialized_globals that was used to detect init-order
bugs. llvm.asan.globals contains the following data for each global:
  1) source location (file/line/column info);
  2) whether it is dynamically initialized;
  3) whether it is blacklisted (shouldn't be instrumented).

Source location data is then emitted in the binary and can be picked up
by ASan runtime in case it needs to print error report involving some global.
For example:

  0x... is located 4 bytes to the right of global variable 'C::array' defined in '/path/to/file:17:8' (0x...) of size 40

These source locations are printed even if the binary doesn't have any
debug info.

This is an ABI-breaking change. ASan initialization is renamed to
__asan_init_v4(). Pre-built libraries compiled with older Clang will not work
with the fresh runtime.

llvm-svn: 212188
2014-07-02 16:54:41 +00:00
..
BlocksRuntime Move tests for BlocksRuntime and builtins to corresponding directories under test/ 2014-02-14 09:47:31 +00:00
asan [ASan] Print exact source location of global variables in error reports. 2014-07-02 16:54:41 +00:00
builtins Provide mul for IEEE quad. From GuanHong Liu. 2014-06-19 20:34:03 +00:00
dfsan [dfsan] Fix the declaration of dfsan_add_label. 2014-06-04 17:54:51 +00:00
lsan Add %run to all lit tests 2014-04-30 21:34:17 +00:00
msan [msan] Limit stack origin chain length. 2014-06-30 11:22:42 +00:00
profile Run common and profile tests in cross-compiled builds. 2014-05-20 22:04:27 +00:00
sanitizer_common Remove ARM XFAIL from passing test 2014-06-24 16:58:59 +00:00
tsan tsan: fix and re-enable a test 2014-06-27 22:27:02 +00:00
ubsan light up sanitizers for ARM, take 2 2014-05-29 22:38:13 +00:00
CMakeLists.txt InstrProf: Add simple compiler-rt test 2014-03-31 22:45:37 +00:00
lit.common.cfg Add detection of OS X relocatable SDK to compiler-rt as a lit.util function 2014-06-10 14:22:00 +00:00
lit.common.configured.in XFAIL ptrace test on arm 2014-05-20 23:31:26 +00:00