summaryrefslogtreecommitdiff
path: root/test/CodeGen/X86/fast-isel-x86-64.ll
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2011-04-19 04:22:17 +0000
committerChris Lattner <sabre@nondot.org>2011-04-19 04:22:17 +0000
commit90cb88a9b43764ae945e137bcb83fe14ac97d6fd (patch)
treeced49716ab72ef45485f2535b9d6bc8fb8075e83 /test/CodeGen/X86/fast-isel-x86-64.ll
parent75b41f1540f35ef0fd5e4a52c1840f1a19debb03 (diff)
downloadllvm-90cb88a9b43764ae945e137bcb83fe14ac97d6fd.tar.gz
llvm-90cb88a9b43764ae945e137bcb83fe14ac97d6fd.tar.bz2
llvm-90cb88a9b43764ae945e137bcb83fe14ac97d6fd.tar.xz
fix rdar://9297006 - fast isel bails out on trunc to i1 -> bools cry,
a common cause of fast isel rejects on c++ code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129748 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/X86/fast-isel-x86-64.ll')
-rw-r--r--test/CodeGen/X86/fast-isel-x86-64.ll17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/CodeGen/X86/fast-isel-x86-64.ll b/test/CodeGen/X86/fast-isel-x86-64.ll
index bf886e079f..fe8530ca29 100644
--- a/test/CodeGen/X86/fast-isel-x86-64.ll
+++ b/test/CodeGen/X86/fast-isel-x86-64.ll
@@ -127,3 +127,20 @@ define i32 @test11(i32 %X) nounwind {
; CHECK: sarl $3,
}
+
+; rdar://9297006 - Trunc to bool.
+define void @test12(i8 %tmp) nounwind ssp noredzone {
+entry:
+ %tobool = trunc i8 %tmp to i1
+ br i1 %tobool, label %if.then, label %if.end
+
+if.then: ; preds = %entry
+ call void @test12(i8 0) noredzone
+ br label %if.end
+
+if.end: ; preds = %if.then, %entry
+ ret void
+; CHECK: test12:
+; CHECK: testb $1,
+}
+