[PATCH] D50887: [DWARF] Missing location debug information with -O2.
Vedant Kumar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 17 10:42:31 PDT 2018
vsk added a subscriber: mattd.
vsk added inline comments.
================
Comment at: lib/CodeGen/MachineInstr.cpp:2029
+void MachineInstr::collectDebugValues(
+ SmallVectorImpl<MachineInstr *> &DbgValues) {
+ MachineInstr &MI = *this;
----------------
vsk wrote:
> aprantl wrote:
> > I understand that this is not your code, but is there a way to use the list of USEs instead of linearily scanning through all instructions? I'm not sure if MIR has that capability, so it's possible that the answer is no.
> `MachineInstrIterator::use_instructions(Reg)` should do it, and a MRI should be available in the contexts where collecting debug values is a useful thing to do. @CarlosAlbertoEnciso would you mind trying that out? It might require moving `collectDebugValues` elsewhere, but it could be a nice simplification. (I haven't tried this myself, & it's possible this won't work out, in which case we can look at it in a follow-up.)
+ @mattd
Repository:
rL LLVM
https://reviews.llvm.org/D50887
More information about the llvm-commits
mailing list