If the output of debug directives only is requested, we should drop
emission of ',debug' option from the target directive. Required for
supporting of nvprof profiler.
Details
- Reviewers
probinson echristo dblaikie - Commits
- rG2e1a7821895f: [DEBUGINFO, NVPTX] Disable emission of ',debug' option if only debug directives…
rG8831ef7a1642: [DEBUGINFO, NVPTX]DO not emit ',debug' option if no debug info or only debug…
rL348497: [DEBUGINFO, NVPTX] Disable emission of ',debug' option if only debug directives…
rL345972: [DEBUGINFO, NVPTX]DO not emit ',debug' option if no debug info or only debug…
Diff Detail
- Repository
- rL LLVM
Event Timeline
Do you mean basically just line tables or something else? (Minus the need in normal dwarf for a minimal cu to associate the line table with). Also, how does this handle inlining etc?
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), this options should not be added to the target directive. Plus we need to render all the debug directives (.line|.file) to be able to get the correct data from the profiler.
The inlining is handled only in terms of files/location debug directives, nothing else.
LGTM
test/DebugInfo/NVPTX/debug-file-loc-only.ll | ||
---|---|---|
3 ↗ | (On Diff #172164) | Typo: "Bitcode in this test..." (not "int"). |
Looks like Eric still had some questions here? Or at least hadn't commented
about whether the answers/changes addressed his concerns?
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
llvm/trunk/lib/Target/NVPTX/NVPTXAsmPrinter.cpp | ||
---|---|---|
888–890 | 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. | |
956–958 | What's going on here? |
llvm/trunk/lib/Target/NVPTX/NVPTXAsmPrinter.cpp | ||
---|---|---|
888–890 | Yes, because I reworked the patch for the frontend. LineTablesOnly is considered as normal debug info option now. Plus, even before, when we saw -line-table-only option for NVPTX target, we still emitted DICompileUnit::DebugDirectivesOnly debug info kind. So, this is ok even for the previous description. | |
956–958 | I split this patch into 2 different patches. |
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.