llvm-project/clang
Anna Zaks 14b1af5dcd [analyzer] Fix false positives in Keychain API checker
The checker has several false positives that this patch addresses:
- Do not check if the return status has been compared to error (or no error) at the time when leaks are reported since the status symbol might no longer be alive. Instead, pattern match on the assume and stop tracking allocated symbols on error paths.
- The checker used to report error when an unknown symbol was freed. This could lead to false positives, let's not repot those. This leads to loss of coverage in double frees.
- Do not enforce that we should only call free if we are sure that error was not returned and the pointer is not null. That warning is too noisy and we received several false positive reports about it. (I removed: "Only call free if a valid (non-NULL) buffer was returned")
- Use !isDead instead of isLive in leak reporting. Otherwise, we report leaks for objects we loose track of. This change triggered change #1.

This also adds checker specific dump to the state.

Differential Revision: https://reviews.llvm.org/D28330

llvm-svn: 291866
2017-01-13 00:50:41 +00:00
..
INPUTS
bindings [libclang] Fix python tests 2016-12-03 12:53:06 +00:00
cmake cmake: Don't try to install exports if there aren't any 2016-11-08 05:02:33 +00:00
docs Clear the release notes for 5.0.0 2017-01-12 21:55:16 +00:00
examples Reapply "IntrusiveRefCntPtr -> std::shared_ptr for CompilerInvocationBase and CodeCompleteConsumer" 2017-01-06 19:49:01 +00:00
include UsersManual.rst: Update clang-cl options list again 2017-01-12 19:26:54 +00:00
lib [analyzer] Fix false positives in Keychain API checker 2017-01-13 00:50:41 +00:00
runtime [sanitizer] Passthrough CMAKE_OSX_DEPLOYMENT_TARGET and CMAKE_OSX_SYSROOT when building compiler-rt from clang/runtime/CMakeLists.txt 2016-12-15 23:20:54 +00:00
test [analyzer] Fix false positives in Keychain API checker 2017-01-13 00:50:41 +00:00
tools Unbreak the clang-fuzzer build after r291184. 2017-01-11 16:42:26 +00:00
unittests clang-format: Fix regression introduced by r291801. 2017-01-12 20:06:28 +00:00
utils [TableGen] Only normalize the spelling of GNU-style attributes. 2017-01-05 16:51:54 +00:00
www [Docs][OpenCL] Added OpenCL feature description to Clang documentation. 2017-01-12 17:52:22 +00:00
.arcconfig Upgrade all the .arcconfigs to https. 2016-07-14 13:15:37 +00:00
.clang-format
.clang-tidy
.gitignore
CMakeLists.txt [cmake] Obtain LLVM_CMAKE_PATH from llvm-config 2017-01-09 23:06:39 +00:00
CODE_OWNERS.TXT
INSTALL.txt
LICENSE.TXT
ModuleInfo.txt
NOTES.txt
README.txt

README.txt

//===----------------------------------------------------------------------===//
// C Language Family Front-end
//===----------------------------------------------------------------------===//

Welcome to Clang.  This is a compiler front-end for the C family of languages
(C, C++, Objective-C, and Objective-C++) which is built as part of the LLVM
compiler infrastructure project.

Unlike many other compiler frontends, Clang is useful for a number of things
beyond just compiling code: we intend for Clang to be host to a number of
different source-level tools.  One example of this is the Clang Static Analyzer.

If you're interested in more (including how to build Clang) it is best to read
the relevant web sites.  Here are some pointers:

Information on Clang:              http://clang.llvm.org/
Building and using Clang:          http://clang.llvm.org/get_started.html
Clang Static Analyzer:             http://clang-analyzer.llvm.org/
Information on the LLVM project:   http://llvm.org/

If you have questions or comments about Clang, a great place to discuss them is
on the Clang development mailing list:
  http://lists.llvm.org/mailman/listinfo/cfe-dev

If you find a bug in Clang, please file it in the LLVM bug tracker:
  http://llvm.org/bugs/