[flang-commits] [flang] flang][debug] Run AddDebugInfo before TargetRewrite. (PR #114418)

via flang-commits flang-commits at lists.llvm.org
Mon Nov 4 01:55:54 PST 2024


================
@@ -264,10 +264,10 @@ void createDefaultFIRCodeGenPassPipeline(mlir::PassManager &pm,
   addNestedPassToAllTopLevelOperations(pm, fir::createAbstractResultOpt);
   fir::addCodeGenRewritePass(
       pm, (config.DebugInfo != llvm::codegenoptions::NoDebugInfo));
+  fir::createDebugPasses(pm, config.DebugInfo, config.OptLevel, inputFilename);
----------------
jeanPerier wrote:

Do you still get the correct assembly names for the external procedures (and common blocks) given `addExternalNameConversionPass` that goes from the `_QPfoo` to `foo_` name is now run afterwards?

You can move it before if needed, it does not need to be run after the target-rewrite and compiler-generated-name-conversion-pass.

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


More information about the flang-commits mailing list