summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authortstellar <tstellar@91177308-0d34-0410-b5e6-96231b3b80d8>2012-09-24 15:52:51 +0000
committertstellar <tstellar@91177308-0d34-0410-b5e6-96231b3b80d8>2012-09-24 15:52:51 +0000
commit849da177e6282b3fbfa48b53de047776f6b7e903 (patch)
tree969f6c7faca4ca81e4580415ab484f734fa02c0b /test
parent21e19fed812339ddd0868fac84c0c2cc6c6f09ac (diff)
R600: Handle loads from the constants address space.
Reading from constant memory is not supported yet, so constant reads use global memory. git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/R600/@164537 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/CodeGen/R600/load.constant_addrspace.f32.ll9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/CodeGen/R600/load.constant_addrspace.f32.ll b/test/CodeGen/R600/load.constant_addrspace.f32.ll
new file mode 100644
index 0000000000..f5dc9dbc6e
--- /dev/null
+++ b/test/CodeGen/R600/load.constant_addrspace.f32.ll
@@ -0,0 +1,9 @@
+;RUN: llc < %s -march=r600 -mcpu=redwood | FileCheck %s
+
+;CHECK: VTX_READ_eg T{{[0-9]+\.X, T[0-9]+\.X}}
+
+define void @test(float addrspace(1)* %out, float addrspace(2)* %in) {
+ %1 = load float addrspace(2)* %in
+ store float %1, float addrspace(1)* %out
+ ret void
+}