[PATCH] D72299: [DSE] Improve mayThrowBetween for 2 instructions in the same BB.

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 6 14:25:56 PST 2020


efriedma added inline comments.


================
Comment at: llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp:1644
+    return BlockMap->second[SI] !=
+           BlockMap->second[&*std::prev(NI->getIterator())];
+  }
----------------
What happens if NI is the first instruction in the block?  Or is that impossible in this context?


================
Comment at: llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp:1706
+  // between them.
+  DenseMap<BasicBlock *, DenseMap<Instruction *, unsigned>> ThrowingBlocks;
 
----------------
This map seems sort of expensive, but maybe not a big deal relative to other stuff we have here already.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D72299





More information about the llvm-commits mailing list