================
@@ -261,10 +300,22 @@ getRootSignature(RootSignatureBindingInfo &RSBI,
 }
 
 static void reportInvalidHandleTy(
-    Module &M,
+    Module &M, const llvm::ArrayRef<dxil::ResourceInfo::ResourceBinding> &RDs,
     const iterator_range<SmallVectorImpl<dxil::ResourceInfo>::iterator>
         &Resources) {
   for (auto Res = Resources.begin(), End = Resources.end(); Res != End; Res++) 
{
+    llvm::dxil::ResourceInfo::ResourceBinding Binding = Res->getBinding();
+    bool IsBound = false;
+    for (const auto &RD : RDs) {
+      if (Binding.overlapsWith(RD)) {
----------------
inbelic wrote:

nit: you could probably move the error reporting to be inside this if statement 
and then you don't need the `IsBound` and `continue`

https://github.com/llvm/llvm-project/pull/147573
_______________________________________________
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