summaryrefslogtreecommitdiff
path: root/test/CodeGen/R600/literals.ll
diff options
context:
space:
mode:
authorTom Stellard <thomas.stellard@amd.com>2013-08-16 01:11:55 +0000
committerTom Stellard <thomas.stellard@amd.com>2013-08-16 01:11:55 +0000
commit6b88cdb34cc78f815946b8ebe6c2332d084526ad (patch)
tree102bb8a37ee9934f8a15d64e0f44d92ff61be8ae /test/CodeGen/R600/literals.ll
parente7ac2ed1c268891a856ab38db1e34372a79da86a (diff)
downloadllvm-6b88cdb34cc78f815946b8ebe6c2332d084526ad.tar.gz
llvm-6b88cdb34cc78f815946b8ebe6c2332d084526ad.tar.bz2
llvm-6b88cdb34cc78f815946b8ebe6c2332d084526ad.tar.xz
R600: Enable folding of inline literals into REQ_SEQUENCE instructions
Tested-by: Aaron Watry <awatry@gmail.com> git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188517 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/R600/literals.ll')
-rw-r--r--test/CodeGen/R600/literals.ll13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/CodeGen/R600/literals.ll b/test/CodeGen/R600/literals.ll
index 77b168ebde..7a113f1a4c 100644
--- a/test/CodeGen/R600/literals.ll
+++ b/test/CodeGen/R600/literals.ll
@@ -31,3 +31,16 @@ entry:
store float %0, float addrspace(1)* %out
ret void
}
+
+; Make sure inline literals are folded into REG_SEQUENCE instructions.
+; CHECK: @inline_literal_reg_sequence
+; CHECK: MOV T[[GPR:[0-9]]].X, 0.0
+; CHECK-NEXT: MOV T[[GPR]].Y, 0.0
+; CHECK-NEXT: MOV T[[GPR]].Z, 0.0
+; CHECK-NEXT: MOV * T[[GPR]].W, 0.0
+
+define void @inline_literal_reg_sequence(<4 x i32> addrspace(1)* %out) {
+entry:
+ store <4 x i32> <i32 0, i32 0, i32 0, i32 0>, <4 x i32> addrspace(1)* %out
+ ret void
+}