[llvm-branch-commits] [llvm] [DirectX] Remove DXILResourceMDAnalysis (PR #130323)
Justin Bogner via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Mon Mar 10 18:57:21 PDT 2025
================
@@ -99,18 +96,6 @@ static NamedMDNode *emitResourceMetadata(Module &M, DXILBindingMap &DBM,
Metadata *SmpMD = Smps.empty() ? nullptr : MDNode::get(Context, Smps);
bool HasResources = !DBM.empty();
- if (MDResources.hasUAVs()) {
- assert(!UAVMD && "Old and new UAV representations can't coexist");
- UAVMD = MDResources.writeUAVs(M);
- HasResources = true;
- }
-
- if (MDResources.hasCBuffers()) {
- assert(!CBufMD && "Old and new cbuffer representations can't coexist");
- CBufMD = MDResources.writeCBuffers(M);
- HasResources = true;
- }
-
if (!HasResources)
----------------
bogner wrote:
This can be simplified to `if (DBM.empty())` rather than setting `HasResources` and checking against it now.
https://github.com/llvm/llvm-project/pull/130323
More information about the llvm-branch-commits
mailing list