Tom Stellard
d26f921796
AMDGPU/SI: Emit constant arrays in the .hsrodata_readonly_agent section
...
Summary: This is done only when targeting HSA.
Reviewers: arsenm
Subscribers: arsenm, llvm-commits
Differential Revision: http://reviews.llvm.org/D13807
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254587 91177308-0d34-0410-b5e6-96231b3b80d8
2015-12-03 03:34:32 +00:00
Tom Stellard
27cbe8f717
AMDGPU/SI: Correctly emit agent global segment variables when targeting HSA
...
Differential Revision: http://reviews.llvm.org/D14508
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254540 91177308-0d34-0410-b5e6-96231b3b80d8
2015-12-02 19:47:57 +00:00
Tom Stellard
26ecf8e5ac
AMDGPU/SI: Don't emit group segment global variables
...
Summary: Only global or readonly segment variables should appear in object files.
Reviewers: arsenm
Subscribers: arsenm, llvm-commits
Differential Revision: http://reviews.llvm.org/D15111
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254519 91177308-0d34-0410-b5e6-96231b3b80d8
2015-12-02 17:00:42 +00:00
Matt Arsenault
7a47a7be12
AMDGPU: Error if too many user SGPRs used
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254332 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-30 21:16:07 +00:00
Matt Arsenault
0f1b95f818
AMDGPU: Rework how private buffer passed for HSA
...
If we know we have stack objects, we reserve the registers
that the private buffer resource and wave offset are passed
and use them directly.
If not, reserve the last 5 SGPRs just in case we need to spill.
After register allocation, try to pick the next available registers
instead of the last SGPRs, and then insert copies from the inputs
to the reserved registers in the progloue.
This also only selectively enables all of the input registers
which are really required instead of always enabling them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254331 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-30 21:16:03 +00:00
Tom Stellard
aa23e0330d
AMDGPU: Add llvm.amdgcn.dispatch.ptr intrinsic
...
Summary:
This returns a pointer to the dispatch packet, which can be used to load
information about the kernel dispach.
Reviewers: arsenm
Subscribers: arsenm, llvm-commits
Differential Revision: http://reviews.llvm.org/D14898
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@254116 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-26 00:43:29 +00:00
Matt Arsenault
dc3ae09deb
AMDGPU: Print more fields in comments
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@252677 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-11 00:27:46 +00:00
Tom Stellard
65cad952e4
AMDGPU/SI: Emit HSA kernels with symbol type STT_AMDGPU_HSA_KERNEL
...
Reviewers: arsenm
Subscribers: arsenm, llvm-commits
Differential Revision: http://reviews.llvm.org/D13804
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@252291 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-06 11:45:14 +00:00
Matt Arsenault
35a96b82c1
AMDGPU: Print number user SGPRs
...
This doesn't quite match how SC prints it, which doesn't put it in a
comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@252144 91177308-0d34-0410-b5e6-96231b3b80d8
2015-11-05 05:27:07 +00:00
Matt Arsenault
ac5ec1c051
AMDGPU: Merge if and switch
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@249082 91177308-0d34-0410-b5e6-96231b3b80d8
2015-10-01 21:51:59 +00:00
NAKAMURA Takumi
09c0ea51ca
Untabify.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@248264 91177308-0d34-0410-b5e6-96231b3b80d8
2015-09-22 11:15:07 +00:00
NAKAMURA Takumi
c36e746e98
Reformat blank lines.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@248263 91177308-0d34-0410-b5e6-96231b3b80d8
2015-09-22 11:14:39 +00:00
Matt Arsenault
5ba7cf9de0
AMDGPU/SI: Fix printing useless info with amdhsa
...
The comments at the bottom would all report 0 if
amdhsa was used.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@245135 91177308-0d34-0410-b5e6-96231b3b80d8
2015-08-15 00:12:39 +00:00
Matt Arsenault
892803aa81
AMDGPU: Fix assert on dbg_value instructions
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@244728 91177308-0d34-0410-b5e6-96231b3b80d8
2015-08-12 09:04:44 +00:00
Tom Stellard
4a888086a4
AMDGPU/SI: Update amd_kernel_code_t definition and add assembler support
...
Reviewers: arsenm
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10772
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@240839 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-26 21:58:31 +00:00
Tom Stellard
ac1a45e511
AMDGPU/SI: Add hsa code object directives
...
Reviewers: arsenm
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10757
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@240831 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-26 21:15:07 +00:00
Tom Stellard
0d1bd457c6
AMDGPU/SI: Emit amd_kernel_code_t in EmitFunctionBodyStart()
...
Summary:
This way the function symbol points to the start of amd_kernel_code_t
rather than the start of the function.
Reviewers: arsenm
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10705
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@240829 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-26 21:14:58 +00:00
Matt Arsenault
dd8f10201c
AMDGPU: Change unreachable into reported error
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239943 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-17 20:55:25 +00:00
Tom Stellard
953c681473
R600 -> AMDGPU rename
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@239657 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-13 03:28:10 +00:00