summaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGExpr.cpp
diff options
context:
space:
mode:
authorRichard Trieu <rtrieu@google.com>2014-04-05 05:17:01 +0000
committerRichard Trieu <rtrieu@google.com>2014-04-05 05:17:01 +0000
commit8123887315f245efdafb56f151dd5048afb2f38c (patch)
tree55a0b979ffc54c09af96e49ef0b4cbde1b7d7a8b /lib/CodeGen/CGExpr.cpp
parent8458c2cf4cc4674fb374fd764783d8892c095f35 (diff)
downloadclang-8123887315f245efdafb56f151dd5048afb2f38c.tar.gz
clang-8123887315f245efdafb56f151dd5048afb2f38c.tar.bz2
clang-8123887315f245efdafb56f151dd5048afb2f38c.tar.xz
Add a new subgroup to -Wtautological-compare, -Wtautological-overlap-compare,
which warns on compound conditionals that always evaluate to the same value. For instance, (x > 5 && x < 3) will always be false since no value for x can satisfy both conditions. This patch also changes the CFG to use these tautological values for better branch analysis. The test for -Wunreachable-code shows how this change catches additional dead code. Patch by Anders Rönnholm. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@205665 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExpr.cpp')
0 files changed, 0 insertions, 0 deletions