[PATCH] D132580: [Coro][Debuginfo] Add debug info to `_NoopCoro_ResumeDestroy` function

Adrian Prantl via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 24 15:29:40 PDT 2022


aprantl added inline comments.


================
Comment at: llvm/lib/Transforms/Coroutines/CoroEarly.cpp:125
 
+    // Attach debug info to the noop coroutine
+    DIBuilder DB(M);
----------------
nit: `.` at the end 


================
Comment at: llvm/lib/Transforms/Coroutines/CoroEarly.cpp:129
+    StringRef Producer = "LLVM Version " LLVM_VERSION_STRING;
+    auto *CU =
+        DB.createCompileUnit(dwarf::DW_LANG_Mips_Assembler, FileNode, Producer,
----------------
Is there a specific reason why you want to create a new CU here? I would just use the one from the function we're currently processing and mark the new DISubprogram as artificial.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D132580/new/

https://reviews.llvm.org/D132580



More information about the llvm-commits mailing list