aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Frontend/HLSL/HLSLRootSignature.cpp
diff options
context:
space:
mode:
authorFinn Plummer <mail@inbelic.dev>2025-08-07 16:10:50 -0700
committerGitHub <noreply@github.com>2025-08-07 16:10:50 -0700
commitcb2d56ce960714ce6fce39e8b846326969a30c2d (patch)
tree61161e03f939c0a305e4cc45ce532d741b932bf6 /llvm/lib/Frontend/HLSL/HLSLRootSignature.cpp
parent47f54e499210c2a66da0441b7ae54974a57d2182 (diff)
downloadllvm-cb2d56ce960714ce6fce39e8b846326969a30c2d.zip
llvm-cb2d56ce960714ce6fce39e8b846326969a30c2d.tar.gz
llvm-cb2d56ce960714ce6fce39e8b846326969a30c2d.tar.bz2
[NFC][HLSL][DirectX] Consolidate `ResourceClassNames` (#152213)
During the split of the various `Frontend/HLSL` libraries, there was an oversight to duplicate the `ResourceClassNames` definitions. This commit simply consolidates the definitions into `DXContainer.h` as `getResourceClasses`
Diffstat (limited to 'llvm/lib/Frontend/HLSL/HLSLRootSignature.cpp')
-rw-r--r--llvm/lib/Frontend/HLSL/HLSLRootSignature.cpp9
1 files changed, 1 insertions, 8 deletions
diff --git a/llvm/lib/Frontend/HLSL/HLSLRootSignature.cpp b/llvm/lib/Frontend/HLSL/HLSLRootSignature.cpp
index 79904fc..574883e 100644
--- a/llvm/lib/Frontend/HLSL/HLSLRootSignature.cpp
+++ b/llvm/lib/Frontend/HLSL/HLSLRootSignature.cpp
@@ -92,16 +92,9 @@ static raw_ostream &operator<<(raw_ostream &OS,
return OS;
}
-static const EnumEntry<dxil::ResourceClass> ResourceClassNames[] = {
- {"CBV", dxil::ResourceClass::CBuffer},
- {"SRV", dxil::ResourceClass::SRV},
- {"UAV", dxil::ResourceClass::UAV},
- {"Sampler", dxil::ResourceClass::Sampler},
-};
-
static raw_ostream &operator<<(raw_ostream &OS, const ClauseType &Type) {
OS << enumToStringRef(dxil::ResourceClass(llvm::to_underlying(Type)),
- ArrayRef(ResourceClassNames));
+ dxbc::getResourceClasses());
return OS;
}