[PATCH] D113468: Fix nondeterminism in debuginfo generation

Ilya Yanok via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 9 04:13:07 PST 2021


yanok added inline comments.


================
Comment at: llvm/lib/CodeGen/RegAllocFast.cpp:435
   SmallVectorImpl<MachineOperand *> &LRIDbgOperands = LiveDbgValueMap[VirtReg];
   SmallDenseMap<MachineInstr *, SmallVector<const MachineOperand *>>
       SpilledOperandsMap;
----------------
nikic wrote:
> Maybe just switch this to a SmallMapVector?
Yes, that would have the same effect. Thanks for your suggestion, I've modified the patch.


================
Comment at: llvm/lib/CodeGen/RegAllocFast.cpp:445-447
+    if (ProcessedSet.contains(DBG))
+      continue;
+    ProcessedSet.insert(DBG);
----------------
StephenTozer wrote:
> Small suggestion - some prefer the above form for brevity, though personally I'm fine with either.
Thanks for the suggestion, I'll note that. For this specific patch I think switching to SmallMapVector is a simpler way forward though.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D113468/new/

https://reviews.llvm.org/D113468



More information about the llvm-commits mailing list