[PATCH] D46061: [DEBUGINFO, NVPTX] Disable emission of ', debug' option if only debug directives are allowed.

Eric Christopher via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 8 18:41:22 PST 2018


echristo added a comment.

Some inline comments - I'm still not happy with some of how this patch is and would like to see some changes and elaborations of how we split things out. Mostly it's bikeshed naming things, but the current state is a bit more confusing than without.

Thanks!

-eric



================
Comment at: llvm/trunk/lib/Target/NVPTX/NVPTXAsmPrinter.cpp:888-890
+    case DICompileUnit::DebugDirectivesOnly:
+      break;
+    case DICompileUnit::LineTablesOnly:
----------------
This seems to conflict with what you said above:

"When we have full debug info, we need to add debug option to the target directive. When we do not emit debug info or emit just debug directives (i.e. only lineinfo),"

as LineTablesOnly is line tables. If we need to split line tables into "things that handle inlining and things that don't" we should handle that discrepancy, but DebugDirectivesOnly isn't very helpful as a descriptor of what the compiler should be doing and paying attention to.


================
Comment at: llvm/trunk/lib/Target/NVPTX/NVPTXAsmPrinter.cpp:956-958
+  // Output last DWARF .file directives, if any.
+  static_cast<NVPTXTargetStreamer *>(OutStreamer->getTargetStreamer())
+      ->outputDwarfFileDirectives();
----------------
What's going on here?


Repository:
  rL LLVM

https://reviews.llvm.org/D46061





More information about the llvm-commits mailing list