[llvm] [AMDGPU] Improve isBasicBlockPrologue helper function (PR #69924)

via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 24 19:56:21 PDT 2023


ruiling wrote:

I agree that block prologue is hard to get correct behavior within LLVM. But as we strongly depend on it now, we cannot remove it before we came up with alternative solution. I think one possible way to remove block prologue is: don't reconverge the threads at block header, instead *always* setup the exec correctly in the terminators of predecessor block. But there are still many details to work out.

I don't have strong preference which way we should go (either always split block or the change here). But it is important it should work in all cases we have seen (e.g. livenrange-split might still insert vector instruction before end_cf even it is a terminator.)

We definitely want a test for such change, a '.ll' test is always helpful for revisiting the issue again.

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


More information about the llvm-commits mailing list