[PATCH] D83908: [Local] Fix removeUnreachableBlocks change reporting

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 16 06:21:47 PDT 2020


fhahn added a comment.

I think it would be great if we would have a reproducer to see exactly what's going on.

If the block is already set for deletion, whoever added it should take care of dropping references & co and there should be nothing to do for us here.

So it might be more straight forward to not include blocks already pending deletion in `DeadBlockSet`. That way, we could have an early bail out if the deadblockset is empty. Otherwise we know we are going to make changes (mark a new block for deletion at least) and we can always return true at that point I think.

Technically, the function might not actually delete any blocks there and then, but the blocks marked for deletion here will eventually be deleted (Once the DTU flushes the updates).


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D83908





More information about the llvm-commits mailing list