summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/AMDGPU/amdpal-cs.ll
diff options
context:
space:
mode:
authorTim Renouf <tim.renouf@amd.com>2017-09-29 09:51:22 +0000
committerTim Renouf <tim.renouf@amd.com>2017-09-29 09:51:22 +0000
commitef1ae8ffacc8b04b1a1a8423af051decc4440145 (patch)
treecbc162a1504ea371b2c86985a4c5e6bb2db2f6e7 /llvm/test/CodeGen/AMDGPU/amdpal-cs.ll
parent132291589f9d754cc32c5c2da60da5da61849470 (diff)
downloadbcm5719-llvm-ef1ae8ffacc8b04b1a1a8423af051decc4440145.tar.gz
bcm5719-llvm-ef1ae8ffacc8b04b1a1a8423af051decc4440145.zip
[AMDGPU] calling conventions for AMDPAL OS type
Summary: This commit adds comments on how the AMDPAL OS type overloads the existing AMDGPU_ calling conventions used by Mesa, and adds a couple of new ones. Reviewers: arsenm, nhaehnle, dstuttard Subscribers: mehdi_amini, kzhuravl, wdng, yaxunl, t-tye, llvm-commits Differential Revision: https://reviews.llvm.org/D37752 llvm-svn: 314502
Diffstat (limited to 'llvm/test/CodeGen/AMDGPU/amdpal-cs.ll')
-rw-r--r--llvm/test/CodeGen/AMDGPU/amdpal-cs.ll13
1 files changed, 13 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/AMDGPU/amdpal-cs.ll b/llvm/test/CodeGen/AMDGPU/amdpal-cs.ll
new file mode 100644
index 00000000000..d722a4c2f38
--- /dev/null
+++ b/llvm/test/CodeGen/AMDGPU/amdpal-cs.ll
@@ -0,0 +1,13 @@
+; RUN: llc -mtriple=amdgcn--amdpal -verify-machineinstrs < %s | FileCheck -check-prefix=GCN -check-prefix=SI -enable-var-scope %s
+; RUN: llc -mtriple=amdgcn--amdpal -mcpu=tonga -verify-machineinstrs < %s | FileCheck -check-prefix=GCN -check-prefix=VI -enable-var-scope %s
+; RUN: llc -mtriple=amdgcn--amdpal -mcpu=gfx900 -verify-machineinstrs < %s | FileCheck -check-prefix=GCN -check-prefix=GFX9 -enable-var-scope %s
+
+; amdpal compute shader: check for 47176 (COMPUTE_PGM_RSRC1) in .AMDGPU.config
+; GCN-LABEL: .AMDGPU.config
+; GCN: .long 47176
+; GCN-LABEL: {{^}}cs_amdpal:
+define amdgpu_cs half @cs_amdpal(half %arg0) {
+ %add = fadd half %arg0, 1.0
+ ret half %add
+}
+
OpenPOWER on IntegriCloud