[llvm] [SLP]Fix graph traversal in getSpillCost (PR #124984)

Philip Reames via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 30 10:23:05 PST 2025


https://github.com/preames approved this pull request.

LGTM - once you've sanity checked the VF=2 costing case and are satisfied that it's correct.

On the math-function examples, the VF=2 vectorization seems to be acceptable.  In practice, the VF=2 subvectors do need to get spilled, but when filled, we're able to fold more vfmv.f.s into loads, thus reducing the total instruction count.  This is a bit of a happy accident, but it unblocks a patch which really does seem like the right direction, so I'm going to run with it.  

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


More information about the llvm-commits mailing list