[NFC][Coroutines] Build DominatorTree only once before collecting frame allocas ...
authorDawid Jurczak <dawid_jurek@vp.pl>
Sun, 1 Jan 2023 12:18:58 +0000 (13:18 +0100)
committerDawid Jurczak <dawid_jurek@vp.pl>
Thu, 5 Jan 2023 09:32:28 +0000 (10:32 +0100)
commit7e6c7562cbfc94368c4af51976649db907ebf0d1
tree77bdba249d80d5dcd621a407f358db7beedd5cc7
parent6ee4f253b2c4b5f86bf69936c704e8537ecc921e
[NFC][Coroutines] Build DominatorTree only once before collecting frame allocas (PR58650)

Assuming that collecting frame allocas doesn't modify CFG we can safely
move DominatorTree construction outside loop and avoid expensive computations.

Differential Revision: https://reviews.llvm.org/D140818
llvm/lib/Transforms/Coroutines/CoroFrame.cpp