[PATCH] D121744: [SCCP] Update ValueLatticeElement blockaddresses when removing unreachable BasicBlocks

Nick Desaulniers via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 16 13:40:12 PDT 2022


nickdesaulniers added inline comments.


================
Comment at: llvm/lib/Transforms/Scalar/SCCP.cpp:559
     for (BasicBlock *DeadBB : BlocksToErase)
       DTU.deleteBB(DeadBB);
 
----------------
efriedma wrote:
> Something more like this, I think?  Assuming this doesn't have any side-effects I'm not thinking of.
yeah, that's the simplest fix.

I'm going to pre-commit updating llvm/test/Transforms/SCCP/dangling-block-address.ll's RUN line to use NPM, and run it through update_test_checks.py, just so we can see what changes.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D121744



More information about the llvm-commits mailing list