Revert^2 "ART: Removes SuspendCheck for plain
loops with a low trip count."
This change removes SuspendCheck for plain loops with a low trip count.
The SuspendCheck in the codegen makes sure that the thread can be
interrupted during execution for GC. Not being able to do so might
decrease the responsiveness of GC in the case when a very long loop
or a long recursion is being executed.
However, for plain loops with a small trip count, the removal of
SuspendCheck should not affect the GC's responsiveness by a large
margin. Consequently, since the thread won't be interrupted for
plain loops, it is assumed that the performance might increase
by removing SuspendCheck.
Also add explicit checks to existing code to ensure that SuspendCheck
is never null when it is used.
This reverts commit 8f6b99fba2d043265a84d599a967d52f66738ad6
Reason for revert: Included fix for CHAGuardVisitor::HoistGuard crash
by disabling codegen for optimized SuspendCheck nodes instead of
removing the SuspendCheck node itself.
Test: art/test.py -v -j12 --host --64 -t 2233-checker\
-remove-loop-suspend-check --run-test --optimizing
Change-Id: Id6296aded91e1cf49b8f3f339dc83613cbedf876
13 files changed