[llvm] [RegAllocBase] Produce IMPLICIT_DEF instead of COPY undef during cleanupFailedVReg (PR #147392)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 10 02:55:35 PDT 2025


arsenm wrote:

The problem isn't the undef copy, it's the fact that storeRegToStack slot doesn't propagate the undef flag from the source when folding the copy. Disabling the optimization works, but we alternatively could pass through the undef flag and let the target produce the undef spill. Or, not emit the spill in the first place (that is complicated since all this code expects a single instruction be produced. I guess we could instead insert an undef KILL in place of a store)

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


More information about the llvm-commits mailing list