[clang] [HLSL][SPIRV] Allow large z value in numthreads (PR #144934)
Nathan Gauër via cfe-commits
cfe-commits at lists.llvm.org
Mon Jun 23 03:47:31 PDT 2025
================
@@ -1033,12 +1033,15 @@ void SemaHLSL::handleRootSignatureAttr(Decl *D, const ParsedAttr &AL) {
void SemaHLSL::handleNumThreadsAttr(Decl *D, const ParsedAttr &AL) {
llvm::VersionTuple SMVersion =
getASTContext().getTargetInfo().getTriple().getOSVersion();
+ bool IsDXIL = getASTContext().getTargetInfo().getTriple().getArch() ==
+ llvm::Triple::dxil;
+
uint32_t ZMax = 1024;
----------------
Keenuts wrote:
The highest value I could found was on AMD's 9070 -> 1024x1024x1024
High-end NV are 1024x1024x64
So seems that in practice, this limit is OK. But in theory a hardware could set this limit to any value.
https://github.com/llvm/llvm-project/pull/144934
More information about the cfe-commits
mailing list