diff options
| author | Mark Searles <m.c.searles@gmail.com> | 2017-05-30 16:22:43 +0000 |
|---|---|---|
| committer | Mark Searles <m.c.searles@gmail.com> | 2017-05-30 16:22:43 +0000 |
| commit | 00ce96f6eed8559c7bbb90768a782ca0cc3c47ea (patch) | |
| tree | d514267920406bea0edfa4c3e573eb87b2c849ef | |
| parent | 95b64a982694b183890d902bc5cc76827fb09679 (diff) | |
| download | bcm5719-llvm-00ce96f6eed8559c7bbb90768a782ca0cc3c47ea.tar.gz bcm5719-llvm-00ce96f6eed8559c7bbb90768a782ca0cc3c47ea.zip | |
[AMDGPU] Require waitcnt before barrier for all targets; adjust tests.
Differential Revision: https://reviews.llvm.org/D33576
llvm-svn: 304217
| -rw-r--r-- | llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h | 2 | ||||
| -rw-r--r-- | llvm/test/CodeGen/AMDGPU/llvm.amdgcn.s.barrier.ll | 3 |
2 files changed, 2 insertions, 3 deletions
diff --git a/llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h b/llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h index 66087942681..0582ce95693 100644 --- a/llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h +++ b/llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h @@ -730,7 +730,7 @@ public: /// \returns True if waitcnt instruction is needed before barrier instruction, /// false otherwise. bool needWaitcntBeforeBarrier() const { - return getGeneration() < GFX9; + return true; } /// \returns true if the flat_scratch register should be initialized with the diff --git a/llvm/test/CodeGen/AMDGPU/llvm.amdgcn.s.barrier.ll b/llvm/test/CodeGen/AMDGPU/llvm.amdgcn.s.barrier.ll index 1b937ab9324..ef9cda14285 100644 --- a/llvm/test/CodeGen/AMDGPU/llvm.amdgcn.s.barrier.ll +++ b/llvm/test/CodeGen/AMDGPU/llvm.amdgcn.s.barrier.ll @@ -3,9 +3,8 @@ ; GCN-LABEL: {{^}}test_barrier: ; GFX8: buffer_store_dword -; GFX8: s_waitcnt ; GFX9: flat_store_dword -; GFX9-NOT: s_waitcnt +; GCN: s_waitcnt ; GCN: s_barrier define amdgpu_kernel void @test_barrier(i32 addrspace(1)* %out, i32 %size) #0 { entry: |

