[clang] [llvm] [SPIR-V] Default to NewPM (PR #239489)

Aiden Grossman via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 5 22:45:58 PST 2026


https://github.com/boomanaiden154 commented:

Where exactly is the SPIRV backend used? I think there are some gaps I haven't finished up yet where `runCodeGenPipeline` isn't used, so we'll use the legacy pipeline by default (mainly in LTO I believe). I was hoping to get to those in the next couple of days. If it's just standard clang/the other SPIRV specific places you fixed, then this shouldn't be an issue.

Also, how much does SPIRV care about LoopStrengthReduction? Enabling the NewPM currently causes optimization regressions, at least for CPU backends, due to LSR not really understanding LCSSA, which the NewPM enforces for loop pipelines. I've started landing patches to fix this, but won't expect it to be done for the next week or two. But given SPIRV is different in that it's virtual ISA, maybe this is a moot point?

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


More information about the cfe-commits mailing list