[llvm] f999b32 - [DirectX] Add missing Analysis usage to DXILResourceMDWrapper

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 16 11:28:37 PDT 2024


Author: Justin Bogner
Date: 2024-08-16T20:28:34+02:00
New Revision: f999b321d7317fa9e59ce597bd3d63b7035fe774

URL: https://github.com/llvm/llvm-project/commit/f999b321d7317fa9e59ce597bd3d63b7035fe774
DIFF: https://github.com/llvm/llvm-project/commit/f999b321d7317fa9e59ce597bd3d63b7035fe774.diff

LOG: [DirectX] Add missing Analysis usage to DXILResourceMDWrapper

This analysis can't be used with other analyses if this isn't set.

Pull Request: https://github.com/llvm/llvm-project/pull/104244

Added: 
    

Modified: 
    llvm/lib/Target/DirectX/DXILResourceAnalysis.h

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Target/DirectX/DXILResourceAnalysis.h b/llvm/lib/Target/DirectX/DXILResourceAnalysis.h
index 3a2b8a9fd39d59..26d9237d51b49c 100644
--- a/llvm/lib/Target/DirectX/DXILResourceAnalysis.h
+++ b/llvm/lib/Target/DirectX/DXILResourceAnalysis.h
@@ -57,6 +57,10 @@ class DXILResourceMDWrapper : public ModulePass {
   /// Calculate the DXILResource for the module.
   bool runOnModule(Module &M) override;
 
+  void getAnalysisUsage(AnalysisUsage &AU) const override {
+    AU.setPreservesAll();
+  }
+
   void print(raw_ostream &O, const Module *M = nullptr) const override;
 };
 } // namespace llvm


        


More information about the llvm-commits mailing list