[clang] [llvm] [SPIRV] Rewrite phis of resource pointers as phis of indices (PR #246509)

Dmitry Sidorov via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 30 02:12:08 PST 2026


MrSidims wrote:

> It turns a phi or select of getpointer calls on one handle into a phi or select of their indices, followed by a getpointer

Does any other backend have this routine?

> An undef input becomes index 0. The pass allows it only when every use of the pointer is a memory access, since the handle may be poison on that edge.

This looks a bit odd. Why you need this?

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


More information about the cfe-commits mailing list