aboutsummaryrefslogtreecommitdiffstats
path: root/test/Transforms
diff options
context:
space:
mode:
Diffstat (limited to 'test/Transforms')
-rw-r--r--test/Transforms/InstCombine/select.ll18
1 files changed, 18 insertions, 0 deletions
diff --git a/test/Transforms/InstCombine/select.ll b/test/Transforms/InstCombine/select.ll
index b09cae4..e89c252 100644
--- a/test/Transforms/InstCombine/select.ll
+++ b/test/Transforms/InstCombine/select.ll
@@ -61,3 +61,21 @@ int %test11(int %a) {
ret int %R
}
+int %test12(bool %cond, int %a) {
+ %b = or int %a, 1
+ %c = select bool %cond, int %b, int %a
+ ret int %c
+}
+
+int %test12a(bool %cond, int %a) {
+ %b = shr int %a, ubyte 1
+ %c = select bool %cond, int %b, int %a
+ ret int %c
+}
+
+int %test12b(bool %cond, int %a) {
+ %b = shr int %a, ubyte 1
+ %c = select bool %cond, int %a, int %b
+ ret int %c
+}
+