projects
/
oota-llvm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
DI: Require subprogram definitions to be distinct
[oota-llvm.git]
/
test
/
Transforms
/
InstCombine
/
apint-shl-trunc.ll
diff --git
a/test/Transforms/InstCombine/apint-shl-trunc.ll
b/test/Transforms/InstCombine/apint-shl-trunc.ll
index 8163e6d527d77f399149555798d29ec2e91625a3..b4450d4a3a000ddb958545915028b7cecbd0e975 100644
(file)
--- a/
test/Transforms/InstCombine/apint-shl-trunc.ll
+++ b/
test/Transforms/InstCombine/apint-shl-trunc.ll
@@
-1,13
+1,24
@@
-; RUN: opt < %s -instcombine -S | grep shl
-; END.
+; RUN: opt < %s -instcombine -S | FileCheck %s
define i1 @test0(i39 %X, i39 %A) {
define i1 @test0(i39 %X, i39 %A) {
+; CHECK-LABEL: @test0(
+; CHECK: %[[V1:.*]] = shl i39 1, %A
+; CHECK: %[[V2:.*]] = and i39 %[[V1]], %X
+; CHECK: %[[V3:.*]] = icmp ne i39 %[[V2]], 0
+; CHECK: ret i1 %[[V3]]
+
%B = lshr i39 %X, %A
%D = trunc i39 %B to i1
ret i1 %D
}
define i1 @test1(i799 %X, i799 %A) {
%B = lshr i39 %X, %A
%D = trunc i39 %B to i1
ret i1 %D
}
define i1 @test1(i799 %X, i799 %A) {
+; CHECK-LABEL: @test1(
+; CHECK: %[[V1:.*]] = shl i799 1, %A
+; CHECK: %[[V2:.*]] = and i799 %[[V1]], %X
+; CHECK: %[[V3:.*]] = icmp ne i799 %[[V2]], 0
+; CHECK: ret i1 %[[V3]]
+
%B = lshr i799 %X, %A
%D = trunc i799 %B to i1
ret i1 %D
%B = lshr i799 %X, %A
%D = trunc i799 %B to i1
ret i1 %D