]> granicus.if.org Git - llvm/commit
[SLP] Optimize getSpillCost(); NFCI
authorNikita Popov <nikita.ppv@gmail.com>
Tue, 9 Jul 2019 20:24:44 +0000 (20:24 +0000)
committerNikita Popov <nikita.ppv@gmail.com>
Tue, 9 Jul 2019 20:24:44 +0000 (20:24 +0000)
commitb3ee0ad2c35c20ee223487ee6a7daee65730e15b
tree07fe157ff925e47b6c7a778dec8a58a6a1863487
parent132fdde04ea1dc6e68de59c90fbb3494d54df92d
[SLP] Optimize getSpillCost(); NFCI

For a given set of live values, the spill cost will always be the
same for each call. Compute the cost once and multiply it by the
number of calls.

(I'm not sure this spill cost modeling makes sense if there are
multiple calls, as the spill cost will likely be shared across
calls in that case. But that's how it currently works.)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@365552 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Vectorize/SLPVectorizer.cpp