Changed merge operation for uninitialized values analysis to "intersect" (previous union).
The effect is that if a variable is uninitialized along a branch (but initialized along another), at merge points it is considered uninitialized. Previously we had the opposite behavior. The new behavior is more conservative, and more in line with gcc's behavior.
llvm-svn: 48689
diff --git a/clang/lib/Analysis/UninitializedValues.cpp b/clang/lib/Analysis/UninitializedValues.cpp
index 25a5ecb..3edf04d 100644
--- a/clang/lib/Analysis/UninitializedValues.cpp
+++ b/clang/lib/Analysis/UninitializedValues.cpp
@@ -223,7 +223,7 @@
//===----------------------------------------------------------------------===//
namespace {
- typedef ExprDeclBitVector_Types::Union Merge;
+ typedef ExprDeclBitVector_Types::Intersect Merge;
typedef DataflowSolver<UninitializedValues,TransferFuncs,Merge> Solver;
}