[lsan] Add an interface function for on-demand leak checking.
authorSergey Matveev <earthdok@google.com>
Fri, 24 Apr 2015 16:53:15 +0000 (16:53 +0000)
committerSergey Matveev <earthdok@google.com>
Fri, 24 Apr 2015 16:53:15 +0000 (16:53 +0000)
commitcbdd0dc88a1fcf6baa494b823cb2559c01578bff
treed2119cf2f3226ceb35ccda0bbe21423855d70ac0
parent4fedac85eea190fe4df8abb836297846db443711
[lsan] Add an interface function for on-demand leak checking.

Summary:
Add an interface function which can be used to periodically trigger
leak detection in a long-running process.

NB: The meaning of the kIgnored tag has been changed to allow easy clean-up
between subsequent leak checks. Previously, this tag was applied to explicitly
ignored (i.e. with __lsan_disable() or __lsan_ignore_object()) chunks *and* any
chunks only reachable from those. With this change, it's only applied to
explicitly ignored chunks.

Reviewers: samsonov

Reviewed By: samsonov

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D9159

llvm-svn: 235728
compiler-rt/include/sanitizer/lsan_interface.h
compiler-rt/lib/lsan/lsan_common.cc
compiler-rt/lib/lsan/lsan_common_linux.cc
compiler-rt/test/lsan/TestCases/recoverable_leak_check.cc [new file with mode: 0644]