summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
diff options
context:
space:
mode:
authorDiana Picus <diana.picus@linaro.org>2017-06-27 10:29:50 +0000
committerDiana Picus <diana.picus@linaro.org>2017-06-27 10:29:50 +0000
commit0e74a134f8578c0a3f8616bd3f2cde5a6131e07b (patch)
tree118b140e3bf944f96664fe1363b184573cf8aa7c /llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
parent71d8b67bea64aef3f604396cf17a5533b2fcbc0b (diff)
downloadbcm5719-llvm-0e74a134f8578c0a3f8616bd3f2cde5a6131e07b.tar.gz
bcm5719-llvm-0e74a134f8578c0a3f8616bd3f2cde5a6131e07b.zip
[ARM] GlobalISel: Support G_SELECT for pointers
All we need to do is mark it as legal, otherwise it's just like s32. llvm-svn: 306390
Diffstat (limited to 'llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll')
-rw-r--r--llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll10
1 files changed, 10 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll b/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
index 01b4bbdf9ad..4c498ff6ca9 100644
--- a/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
+++ b/llvm/test/CodeGen/ARM/GlobalISel/arm-isel.ll
@@ -410,3 +410,13 @@ entry:
%r = select i1 %cond, i32 %a, i32 %b
ret i32 %r
}
+
+define arm_aapcscc i32* @test_select_ptr(i32* %a, i32* %b, i1 %cond) {
+; CHECK-LABEL: test_select_ptr
+; CHECK: cmp r2, #0
+; CHECK: moveq r0, r1
+; CHECK: bx lr
+entry:
+ %r = select i1 %cond, i32* %a, i32* %b
+ ret i32* %r
+}
OpenPOWER on IntegriCloud