[PATCH] D91595: [Debugify] Support checking Machine IR debug info
Djordje Todorovic via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 23 05:31:06 PST 2020
djtodoro added a comment.
Thanks!
================
Comment at: llvm/lib/CodeGen/MachineCheckDebugify.cpp:56
+ MachineFunction &MF = *MaybeMF;
+ for (MachineBasicBlock &MBB : MF) {
+ for (MachineInstr &MI : MBB) {
----------------
I'm not against adding two loops -- one for finding missing lines, and the other one for finding missing variables.
================
Comment at: llvm/lib/CodeGen/MachineCheckDebugify.cpp:58
+ for (MachineInstr &MI : MBB) {
+ if (MI.isDebugValue()) {
+ const DILocalVariable *LocalVar = MI.getDebugVariable();
----------------
Not sure we want to report missing dbgLoc for meta instructions other than `DBG_VALUE` (e.g., `DBG_LABEL` does not end up in the final code as well..)
================
Comment at: llvm/lib/CodeGen/MachineCheckDebugify.cpp:67
+ const DebugLoc DL = MI.getDebugLoc();
+ if (!DL) {
+ errs() << "WARNING: Instruction with empty DebugLoc in function ";
----------------
Early continue?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91595/new/
https://reviews.llvm.org/D91595
More information about the llvm-commits
mailing list