summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
diff options
context:
space:
mode:
authorDiana Picus <diana.picus@linaro.org>2017-01-25 08:47:40 +0000
committerDiana Picus <diana.picus@linaro.org>2017-01-25 08:47:40 +0000
commitd83df5d372d47a137c4ea237f097a7ce8cc906c1 (patch)
treecbd1406e9aed27a9182f1d1f0fb44a7e1fbb6126 /llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
parent8b6c6bedcbad953260157903e03210249e5f4b90 (diff)
downloadbcm5719-llvm-d83df5d372d47a137c4ea237f097a7ce8cc906c1.tar.gz
bcm5719-llvm-d83df5d372d47a137c4ea237f097a7ce8cc906c1.zip
[ARM] GlobalISel: Support i1 add and ABI extensions
Add support for: * i1 add * i1 function arguments, if passed through registers * i1 returns, with ABI signext/zeroext Differential Revision: https://reviews.llvm.org/D27706 llvm-svn: 293035
Diffstat (limited to 'llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll')
-rw-r--r--llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll17
1 files changed, 17 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll b/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
index 2c0c17c7eec..ba2a5469f85 100644
--- a/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
+++ b/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
@@ -7,6 +7,23 @@ entry:
ret void
}
+define zeroext i1 @test_zext_i1(i1 %x) {
+; CHECK-LABEL: test_zext_i1
+; CHECK: and r0, r0, #1
+; CHECK: bx lr
+entry:
+ ret i1 %x
+}
+
+define signext i1 @test_sext_i1(i1 %x) {
+; CHECK-LABEL: test_sext_i1
+; CHECK: and r0, r0, #1
+; CHECK: rsb r0, r0, #0
+; CHECK: bx lr
+entry:
+ ret i1 %x
+}
+
define zeroext i8 @test_ext_i8(i8 %x) {
; CHECK-LABEL: test_ext_i8:
; CHECK: uxtb r0, r0
OpenPOWER on IntegriCloud