[flang-commits] [flang] [flang][debug] Add support for common blocks. (PR #112398)

Abid Qadeer via flang-commits flang-commits at lists.llvm.org
Thu Oct 17 06:32:17 PDT 2024


================
@@ -90,6 +105,67 @@ bool debugInfoIsAlreadySet(mlir::Location loc) {
 
 } // namespace
 
+bool AddDebugInfoPass::createCommonBlockGlobal(
+    fir::cg::XDeclareOp declOp, const std::string &name,
+    mlir::LLVM::DIFileAttr fileAttr, mlir::LLVM::DIScopeAttr scopeAttr,
+    fir::DebugTypeGenerator &typeGen, mlir::SymbolTable *symbolTable) {
+  mlir::MLIRContext *context = &getContext();
+  mlir::OpBuilder builder(context);
+  std::optional<std::int64_t> optint;
+  auto op = declOp.getMemref().getDefiningOp();
----------------
abidh wrote:

Thanks for the catch. Fixed now.

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


More information about the flang-commits mailing list