[flang-commits] [clang] [flang] [flang][Driver] Support -gsplit-dwarf. (PR #160540)

Tarun Prabhu via flang-commits flang-commits at lists.llvm.org
Wed Sep 24 10:51:34 PDT 2025


================
@@ -898,7 +898,19 @@ static void generateMachineCodeOrAssemblyImpl(clang::DiagnosticsEngine &diags,
   llvm::CodeGenFileType cgft = (act == BackendActionTy::Backend_EmitAssembly)
                                    ? llvm::CodeGenFileType::AssemblyFile
                                    : llvm::CodeGenFileType::ObjectFile;
-  if (tm.addPassesToEmitFile(codeGenPasses, os, nullptr, cgft)) {
+  std::unique_ptr<llvm::ToolOutputFile> DwoOS;
+  if (!codeGenOpts.SplitDwarfOutput.empty()) {
+    std::error_code EC;
----------------
tarunprabhu wrote:

Should be lowercase.

```suggestion
    std::error_code ec;
```

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


More information about the flang-commits mailing list