[llvm] [Sink] Allow sinking of loads to distant blocks (PR #135986)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 17 13:08:14 PDT 2025


https://github.com/nikic commented:

What you're doing here looks like it will be extremely expensive even if you don't hit a degenerate case.

You're performing AA queries on all stores in a potentially large number of blocks (and I think the block walk may not even stop at the origin block if there is a way past it), and you're doing that for every single potentially sinkable load.

If you want to do something like this you probably need to make use of MemorySSA or similar.

https://github.com/llvm/llvm-project/pull/135986


More information about the llvm-commits mailing list