On new targets like `gfx1250`, the buffer resource (V#) now uses this format: ``` base (57-bit): resource[56:0] num_records (45-bit): resource[101:57] reserved (6-bit): resource[107:102] stride (14-bit): resource[121:108] ``` This PR changes the type of `num_records` from `i32` to `i64` in both builtin and intrinsic, and also adds the support for lowering the new format. Fixes SWDEV-554034. --------- Co-authored-by: Krzysztof Drewniak <Krzysztof.Drewniak@amd.com>
10 lines
489 B
LLVM
10 lines
489 B
LLVM
; REQUIRES: asserts
|
|
; RUN: not --crash llc -mtriple=amdgcn -mcpu=gfx900 < %s
|
|
; RUN: not --crash llc -global-isel -mtriple=amdgcn -mcpu=gfx900 < %s
|
|
|
|
define amdgpu_ps ptr addrspace(8) @basic_raw_buffer(ptr addrspace(3) inreg %p) {
|
|
%rsrc = call ptr addrspace(8) @llvm.amdgcn.make.buffer.rsrc.p8.p3(ptr addrspace(3) %p, i16 0, i64 1234, i32 5678)
|
|
ret ptr addrspace(8) %rsrc
|
|
}
|
|
declare ptr addrspace(8) @llvm.amdgcn.make.buffer.rsrc.p8.p3(ptr addrspace(3) nocapture readnone, i16, i64, i32)
|