asan: optimization experiments
authorDmitry Vyukov <dvyukov@google.com>
Tue, 17 Mar 2015 16:59:19 +0000 (16:59 +0000)
committerDmitry Vyukov <dvyukov@google.com>
Tue, 17 Mar 2015 16:59:19 +0000 (16:59 +0000)
commit6e4a97dfceb558e789dcbae737a57eb4c01d7fa4
treedcca1b52852a3bf2729da2613f78a6b5e702afc4
parent78158ce3a4792720e50cfab3c824056a74093ae2
asan: optimization experiments

The experiments can be used to evaluate potential optimizations that remove
instrumentation (assess false negatives). Instead of completely removing
some instrumentation, you set Exp to a non-zero value (mask of optimization
experiments that want to remove instrumentation of this instruction).
If Exp is non-zero, this pass will emit special calls into runtime
(e.g. __asan_report_exp_load1 instead of __asan_report_load1). These calls
make runtime terminate the program in a special way (with a different
exit status). Then you run the new compiler on a buggy corpus, collect
the special terminations (ideally, you don't see them at all -- no false
negatives) and make the decision on the optimization.

The exact reaction to experiments in runtime is not implemented in this patch.
It will be defined and implemented in a subsequent patch.

http://reviews.llvm.org/D8198

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@232502 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Instrumentation/AddressSanitizer.cpp
test/Instrumentation/AddressSanitizer/experiment-call.ll [new file with mode: 0644]
test/Instrumentation/AddressSanitizer/experiment.ll [new file with mode: 0644]