[Mlir-commits] [flang] [mlir] [flang] Add debug information for module variables. (PR #91582)

Tom Eccles llvmlistbot at llvm.org
Tue May 14 05:55:57 PDT 2024


================
@@ -48,10 +49,87 @@ class AddDebugInfoPass : public fir::impl::AddDebugInfoBase<AddDebugInfoPass> {
 public:
   AddDebugInfoPass(fir::AddDebugInfoOptions options) : Base(options) {}
   void runOnOperation() override;
+
+private:
+  std::map<std::string, mlir::LLVM::DIModuleAttr> moduleMap;
----------------
tblah wrote:

Could you use `llvm::StringMap` here? I don't think we need a reliable iteration order?

https://llvm.org/docs/ProgrammersManual.html#llvm-adt-stringmap-h

https://github.com/llvm/llvm-project/pull/91582


More information about the Mlir-commits mailing list