summaryrefslogtreecommitdiffstats
path: root/test/CodeGen
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-03-30 21:21:14 +0000
committerChris Lattner <sabre@nondot.org>2004-03-30 21:21:14 +0000
commit3b68c201c89d4ddca30f24c5426668fe08ec1c97 (patch)
treee336f60c5273f0f7fe60818d5d5f73535b899cef /test/CodeGen
parentbc280abd460a823cf33dc50789350b042762adbc (diff)
downloadexternal_llvm-3b68c201c89d4ddca30f24c5426668fe08ec1c97.zip
external_llvm-3b68c201c89d4ddca30f24c5426668fe08ec1c97.tar.gz
external_llvm-3b68c201c89d4ddca30f24c5426668fe08ec1c97.tar.bz2
New testcase for select instructions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12552 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen')
-rw-r--r--test/CodeGen/X86/select.ll32
1 files changed, 32 insertions, 0 deletions
diff --git a/test/CodeGen/X86/select.ll b/test/CodeGen/X86/select.ll
new file mode 100644
index 0000000..6259beb
--- /dev/null
+++ b/test/CodeGen/X86/select.ll
@@ -0,0 +1,32 @@
+; RUN: llvm-as < %s | llc -march=x86
+
+bool %boolSel(bool %A, bool %B, bool %C) {
+ %X = select bool %A, bool %B, bool %C
+ ret bool %X
+}
+
+sbyte %byteSel(bool %A, sbyte %B, sbyte %C) {
+ %X = select bool %A, sbyte %B, sbyte %C
+ ret sbyte %X
+}
+
+short %shortSel(bool %A, short %B, short %C) {
+ %X = select bool %A, short %B, short %C
+ ret short %X
+}
+
+int %intSel(bool %A, int %B, int %C) {
+ %X = select bool %A, int %B, int %C
+ ret int %X
+}
+
+long %longSel(bool %A, long %B, long %C) {
+ %X = select bool %A, long %B, long %C
+ ret long %X
+}
+
+double %doubleSel(bool %A, double %B, double %C) {
+ %X = select bool %A, double %B, double %C
+ ret double %X
+}
+