[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
Tue Jan 7 12:58:48 PST 2020
efriedma added inline comments.
================
Comment at: llvm/lib/Transforms/Scalar/DeadStoreElimination.cpp:1706
+ // between them.
+ DenseMap<BasicBlock *, DenseMap<Instruction *, unsigned>> ThrowingBlocks;
----------------
fhahn wrote:
> efriedma wrote:
> > This map seems sort of expensive, but maybe not a big deal relative to other stuff we have here already.
> Yep, we probably should populate it lazily. And I think at least for C/C++ programs, it should not really be needed at all. There's no difference in the MultiSource/SPEC2000/SPEC2006 binaries with and without this patch, now that I updated D72146 to skip throwing instructions modeled in MemorySSA.
That's not surprising. It's theoretically possible to have a function that's readnone and not nothrow, but it doesn't happen in practice for C/C++ code.
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