[PATCH] D66599: [DebugInfo] Remove invalidated locations during LiveDebugValues
Jeremy Morse via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 22 09:32:20 PDT 2019
jmorse marked an inline comment as done.
jmorse added inline comments.
================
Comment at: lib/CodeGen/LiveDebugValues.cpp:1306-1312
+
+ // We track what is on the pending worklist to avoid inserting the same
+ // thing twice. We could avoid this with a custom priority queue, but this
+ // is probably not worth it.
+ SmallPtrSet<MachineBasicBlock *, 16> OnPending;
+
while (!Worklist.empty() || !Pending.empty()) {
----------------
Not technically necessary change here but I think it's worthwhile: the "OnPending" set this function maintains clears itself by going out of scope and back in again. This misled me for a bit, thinking there was something magical going on that meant OnPending didn't need clearing. IMHO YMMV it's better to explicitly clear it (hunk below) for ease of understanding. (Or if it's too irrelevant, then never mind).
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D66599/new/
https://reviews.llvm.org/D66599
More information about the llvm-commits
mailing list