[PATCH] D99933: [Debug-Info] Use inlined strings in .dwinfo section by default for DBX.
EsmeYi via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 7 04:27:36 PDT 2021
Esme added inline comments.
================
Comment at: llvm/lib/CodeGen/CommandFlags.cpp:417
clEnumValN(DebuggerKind::LLDB, "lldb", "lldb"),
+ clEnumValN(DebuggerKind::DBX, "dbx", "dbx"),
clEnumValN(DebuggerKind::SCE, "sce", "SCE targets (e.g. PS4)")));
----------------
shchenz wrote:
> Esme wrote:
> > Thanks for @shchenz's comments.
> > We have added tuning debugger option DBX in D99400, but missed adding it to llc/opt command flags, which is a one-line change, so I also do it in this patch as well. Is it ok?
> The change here is for controlling the inlined string for llc. It is not necessary. Normally, when you compile source files by using clang, clang FE will set the debugger type for you. You should already test this, right?
>
> Wth this change, now you can test the inlined string settings only with llc.
I've verified both of `clang -gdbx` under Linux and `clang -g` under AIX, and clang FE works well for them.
================
Comment at: llvm/test/DebugInfo/XCOFF/dbx-inlinedstrings.ll:32-33
+
+; CHECK-NOT: DW_FORM_strp
+; CHECK: DW_FORM_string
----------------
dblaikie wrote:
> I'd probably put these CHECK lines up the top near the RUN line - and flesh them out a bit, maybe? Oh, and in the RUN line, run llc to an object, run the object through llvm-dwarfdump rather than checking the assembly directly. Possibly use implicit-check-not DW_FORM_strp, and explicitly check where the DW_FORM_string turns up (perhaps dump debug_info in verbose mode, and check, for instance that the DW_AT_producer is in the right form and has the right value)
>
> (do you have a pointer to the testing that was originally added for this feature when it was introduced for NVPTX? Might be worth comparing it/seeing if there's some inspiration there)
The feature for NVPTX introduced in D41827 is not the main purpose in that patch, so the whole assembly was checked directly there.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D99933/new/
https://reviews.llvm.org/D99933
More information about the llvm-commits
mailing list