summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/branch-on-bool.c
diff options
context:
space:
mode:
authorJustin Bogner <mail@justinbogner.com>2013-11-22 10:20:43 +0000
committerJustin Bogner <mail@justinbogner.com>2013-11-22 10:20:43 +0000
commit7fa2eb9f49e6dbf8317405de06d418ae7e77f267 (patch)
tree1d30a14b7be2f99064689718a35feefb4e048d50 /clang/test/CodeGen/branch-on-bool.c
parent0f06606b68fee7b41225d91d79cf2d27a151ff93 (diff)
downloadbcm5719-llvm-7fa2eb9f49e6dbf8317405de06d418ae7e77f267.tar.gz
bcm5719-llvm-7fa2eb9f49e6dbf8317405de06d418ae7e77f267.zip
Revert r193994 and part of r193995
Not long ago I made the CodeGen of for loops simplify the condition at -O0 in the same way we do for if and conditionals. Unfortunately this ties how loops and simple conditions work together too tightly, which makes features such as instrumentation based PGO awkward. Ultimately, we should find a more general way to simplify the logic in a given condition, but for now we'll just avoid using EmitBranchOnBool for loops, like we already do for while and do loops. llvm-svn: 195438
Diffstat (limited to 'clang/test/CodeGen/branch-on-bool.c')
-rw-r--r--clang/test/CodeGen/branch-on-bool.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/clang/test/CodeGen/branch-on-bool.c b/clang/test/CodeGen/branch-on-bool.c
index 78dae1b1fd7..98a3845fba2 100644
--- a/clang/test/CodeGen/branch-on-bool.c
+++ b/clang/test/CodeGen/branch-on-bool.c
@@ -12,11 +12,3 @@ void fold_if(int a, int b) {
else
bar();
}
-
-void fold_for(int a, int b) {
- // CHECK: define {{.*}} @fold_for(
- // CHECK-NOT: = phi
- // CHECK: }
- for (int i = 0; a && i < b; ++i) foo();
- for (int i = 0; a || i < b; ++i) bar();
-}
OpenPOWER on IntegriCloud