[Mlir-commits] [llvm] [mlir] [DebugInfo][RemoveDIs] Remove debug-intrinsic printing cmdline options (PR #131855)
Orlando Cazalet-Hyams
llvmlistbot at llvm.org
Thu Mar 20 10:30:27 PDT 2025
================
@@ -34,13 +33,7 @@ void registerToLLVMIRTranslation() {
if (!llvmModule)
return failure();
- // When printing LLVM IR, we should convert the module to the debug info
- // format that LLVM expects us to print.
- // See https://llvm.org/docs/RemoveDIsDebugInfo.html
- llvm::ScopedDbgInfoFormatSetter formatSetter(*llvmModule,
- WriteNewDbgInfoFormat);
- if (WriteNewDbgInfoFormat)
- llvmModule->removeDebugIntrinsicDeclarations();
+ llvmModule->removeDebugIntrinsicDeclarations();
----------------
OCHyams wrote:
Don't these `removeDebugIntrinsicDeclarations` calls (in both files) want to be guarded by `if (UseNewDbgInfoFormat)`?
I don't think it hugely matters if we're about to remove that flag too... but it looks like with your patch we unconditionally remove the intrinsic declarations, even if the intrinsic mode is selected?
https://github.com/llvm/llvm-project/pull/131855
More information about the Mlir-commits
mailing list