[PATCH] D150261: [AMDGPU][MC] Don't accept attr > 32 for param_load
Diana Picus via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 10 04:22:16 PDT 2023
rovka created this revision.
Herald added subscribers: foad, kerbowa, hiraditya, tpr, dstuttard, yaxunl, jvesely, kzhuravl, arsenm.
Herald added a project: All.
rovka requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.
The docs say the interpolation attribute should be between 0..32 [1][2],
but we currently accept values all the way up to 63.
This patch makes the ASMParser error out for values > 32. It does not
touch codegen though because we're currently not checking anything at
all for codegen (llvm.amdgcn.lds.param.load will happily accept even 128
as an attr, although that won't fit in the encoding).
[1] https://llvm.org/docs/AMDGPU/gfx8_attr.html#amdgpu-synid-gfx8-attr
[2] https://llvm.org/docs/AMDGPU/gfx11_attr.html#amdgpu-synid-gfx11-attr
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D150261
Files:
llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp
llvm/test/MC/AMDGPU/gfx11_asm_ldsdir.s
llvm/test/MC/AMDGPU/gfx11_asm_ldsdir_err.s
llvm/test/MC/AMDGPU/vintrp-err.s
llvm/test/MC/AMDGPU/vintrp.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D150261.520956.patch
Type: text/x-patch
Size: 5618 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230510/7a08e7b6/attachment.bin>
More information about the llvm-commits
mailing list