[PATCH] D91595: [Debug] Support checking Machine IR debug info
Djordje Todorovic via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 17 03:47:14 PST 2020
djtodoro added a comment.
Thanks for doing this! (some initial comments inline)
Please add some context about this into https://llvm.org/docs/HowToUpdateDebugInfo.html#id14.
================
Comment at: llvm/lib/CodeGen/MachineCheckDebug.cpp:97
+ CheckDebugMachineModule()
+ : ModulePass(ID) {}
+
----------------
clang-format please
================
Comment at: llvm/lib/CodeGen/MachineDebugify.cpp:150
+ NMD = M.getOrInsertNamedMetadata("llvm.mir.debugify");
+ auto addDebugifyOperand = [&](unsigned N) {
+ NMD->addOperand(MDNode::get(
----------------
clang-format please
================
Comment at: llvm/lib/CodeGen/MachineDebugify.cpp:154
+ };
+ addDebugifyOperand(NumLines); // Add number of lines.
+ addDebugifyOperand(VarSet.size()); // Add number of variables.
----------------
the comments should go above
================
Comment at: llvm/test/CodeGen/Generic/MIRDebugify/check-line-and-variables-x.mir:46
+ !18 = !{!19, !19, i64 0}
+ !19 = !{!"int", !20, i64 0}
+ !20 = !{!"omnipotent char", !21, i64 0}
----------------
we can get rid of these `tbaa` metadata
================
Comment at: llvm/test/CodeGen/Generic/MIRDebugify/check-line-and-variables.mir:31
+---
+name: foo
+alignment: 16
----------------
I think we do not need all of these attributes, only `name` and `alignment`
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91595/new/
https://reviews.llvm.org/D91595
More information about the llvm-commits
mailing list