Yaxun Liu | cc56a8b | 2017-11-06 14:32:33 +0000 | [diff] [blame] | 1 | ; RUN: llc -march=amdgcn -mtriple=amdgcn---amdgiz -mcpu=unknown -verify-machineinstrs < %s 2>&1 | FileCheck -check-prefix=ERROR -check-prefix=GCN %s |
| 2 | ; RUN: llc -march=r600 -mtriple=r600---amdgiz -mcpu=unknown -verify-machineinstrs < %s 2>&1 | FileCheck -check-prefix=ERROR -check-prefix=R600 %s |
| 3 | target datalayout = "A5" |
Matt Arsenault | 8e00194 | 2016-06-02 18:37:16 +0000 | [diff] [blame] | 4 | |
| 5 | ; Should not crash when the processor is not recognized and the |
| 6 | ; wavefront size feature not set. |
| 7 | |
| 8 | ; Should also not have fragments of r600 and gcn isa mixed. |
| 9 | |
| 10 | ; ERROR: 'unknown' is not a recognized processor for this target (ignoring processor) |
| 11 | |
| 12 | ; GCN-NOT: MOV |
| 13 | ; GCN: buffer_store_dword |
| 14 | ; GCN: ScratchSize: 8{{$}} |
| 15 | |
| 16 | ; R600: MOV |
Matt Arsenault | 3dbeefa | 2017-03-21 21:39:51 +0000 | [diff] [blame] | 17 | define amdgpu_kernel void @foo() { |
Yaxun Liu | cc56a8b | 2017-11-06 14:32:33 +0000 | [diff] [blame] | 18 | %alloca = alloca i32, align 4, addrspace(5) |
| 19 | store volatile i32 0, i32 addrspace(5)* %alloca |
Matt Arsenault | 8e00194 | 2016-06-02 18:37:16 +0000 | [diff] [blame] | 20 | ret void |
| 21 | } |