-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AirFixObviousSpills should be optimized
https://bugs.webkit.org/show_bug.cgi?id=228052 Reviewed by Yusuke Suzuki. There were two problems with AirFixObviousSpills: - merge() had a quadratic blow-up, as for each element in a vector, it was searching it in a different vector. - it would visit blocks even when their state at head had not changed. I fixed the first problem by making sure that the vectors are sorted before calling merge, and making use of that invariant in the search of the vectors (see filterVectorAgainst) This reduced the total time spent in that phase from 390ms to 230ms, and the worst case time spent in that phase for one function from 100ms to 30ms (all of the results in this Changelog are for JetStream2 on a M1 MBP). I fixed the second problem even more easily by adding a m_shouldVisit BitVector. I also moved the m_wasVisited boolean that was in State to a m_notBottom BitVector for simplicity and symmetry. That change further reduced the total/max time from 230ms/30ms to 140ms/16ms. * b3/air/AirFixObviousSpills.cpp: Canonical link: https://commits.webkit.org/244440@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@286053 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
Robin Morisset
committed
Nov 19, 2021
1 parent
cc9bf24
commit e7fbb7a
Showing
2 changed files
with
124 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters