1fd4821f6b3ac57a44c2ce91025686da4641d197 |
|
10-Jul-2014 |
Vladimir Marko <vmarko@google.com> |
Rewrite topological sort order and improve GVN. Rewrite the topological sort order to include a full loop before the blocks that go after the loop. Add a new iterator class LoopRepeatingTopologicalSortIterator that differs from the RepeatingTopologicalSortIterator by repeating only loops and repeating them early. It returns to the loop head if the head needs recalculation when we reach the end of the loop. In GVN, use the new loop-repeating topological sort iterator and for a loop head merge only the preceding blocks' LVNs if we're not currently recalculating this loop. Also fix LocalValueNumbering::InPlaceIntersectMaps() which was keeping only the last element of the intersection, avoid some unnecessary processing during LVN merge and add some missing braces to MIRGraph::InferTypeAndSize(). Bug: 16398693 (cherry picked from 55fff044d3a4f7196098e25bab1dad106d9b54a2) Change-Id: Id7bcd99c8abed1b7500b9ef723313d4c5fc6f1e8
|
55fff044d3a4f7196098e25bab1dad106d9b54a2 |
|
10-Jul-2014 |
Vladimir Marko <vmarko@google.com> |
Rewrite topological sort order and improve GVN. Rewrite the topological sort order to include a full loop before the blocks that go after the loop. Add a new iterator class LoopRepeatingTopologicalSortIterator that differs from the RepeatingTopologicalSortIterator by repeating only loops and repeating them early. It returns to the loop head if the head needs recalculation when we reach the end of the loop. In GVN, use the new loop-repeating topological sort iterator and for a loop head merge only the preceding blocks' LVNs if we're not currently recalculating this loop. Also fix LocalValueNumbering::InPlaceIntersectMaps() which was keeping only the last element of the intersection, avoid some unnecessary processing during LVN merge and add some missing braces to MIRGraph::InferTypeAndSize(). Bug: 16398693 Change-Id: I4e10d4acb626a5b8a28ec0de106a7b37f9cbca32
|