aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/PowerPC/lbzux.ll
diff options
context:
space:
mode:
authorNadav Rotem <nrotem@apple.com>2012-08-14 05:19:07 +0000
committerNadav Rotem <nrotem@apple.com>2012-08-14 05:19:07 +0000
commit3e883734fab4da8413f16957dd116d4ffd9d3223 (patch)
tree3165c1b0a62a477da5ca386e10ee5dc97d752da3 /test/CodeGen/PowerPC/lbzux.ll
parent443c9ed7688e66c55c43819a75be681574b291de (diff)
downloadexternal_llvm-3e883734fab4da8413f16957dd116d4ffd9d3223.zip
external_llvm-3e883734fab4da8413f16957dd116d4ffd9d3223.tar.gz
external_llvm-3e883734fab4da8413f16957dd116d4ffd9d3223.tar.bz2
During the CodeGenPrepare we often lower intrinsics (such as objsize)
and allow some optimizations to turn conditional branches into unconditional. This commit adds a simple control-flow optimization which merges two consecutive basic blocks which are connected by a single edge. This allows the codegen to operate on larger basic blocks. rdar://11973998 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@161852 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/PowerPC/lbzux.ll')
-rw-r--r--test/CodeGen/PowerPC/lbzux.ll6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/CodeGen/PowerPC/lbzux.ll b/test/CodeGen/PowerPC/lbzux.ll
index 5725c0d..12f1d1f 100644
--- a/test/CodeGen/PowerPC/lbzux.ll
+++ b/test/CodeGen/PowerPC/lbzux.ll
@@ -2,7 +2,7 @@ target datalayout = "E-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f3
target triple = "powerpc64-unknown-linux-gnu"
; RUN: llc < %s | FileCheck %s
-define fastcc void @allocateSpace() nounwind {
+define fastcc void @allocateSpace(i1 %cond1, i1 %cond2) nounwind {
entry:
%0 = load i8** undef, align 8, !tbaa !0
br i1 undef, label %return, label %lor.lhs.false
@@ -20,10 +20,10 @@ while.cond: ; preds = %while.body, %if.the
%idxprom17 = sext i32 0 to i64
%arrayidx18 = getelementptr inbounds i8* %0, i64 %idxprom17
%or = or i32 undef, undef
- br i1 false, label %if.end71, label %while.body
+ br i1 %cond1, label %if.end71, label %while.body
while.body: ; preds = %while.cond
- br i1 undef, label %while.cond, label %if.then45
+ br i1 %cond2, label %while.cond, label %if.then45
if.then45: ; preds = %while.body
%idxprom48139 = zext i32 %or to i64