================
@@ -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
_______________________________________________
llvm-branch-commits mailing list
llvm-branch-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

Reply via email to