Attempt some loop opts after write barrier expansion
Roland Westrelin
rwestrel at redhat.com
Tue Jan 3 12:59:02 UTC 2017
http://cr.openjdk.java.net/~roland/shenandoah/wbloopopts/webrev.00/
This attempts a few more rounds of loop opts after write barrier
expansion.
When there are 2 write barriers in a row, the evacuation in progress
tests are merged:
if (evac_in_progress) {
slow_path_1
} else {
fast_path_1
}
if (evac_in_progress) {
slow_path_2
} else {
fast_path_2
}
becomes:
if (evac_in_progress) {
slow_path_1
slow_path_2
} else {
fast_path_1
fast_path_2
}
Loops are unswitched when they contain an evacuation in progress test
that can be moved out of the loop (i.e. no safepoint =
-UseCountedLoopSafepoints).
for (;;) {
some_stuff
if (evac_in_progress) {
slow_path
} else {
fast_path
}
more_stuff
}
becomes
if (evac_in_progress) {
for (;;) {
some_stuff
slow_path
more_stuff
}
} else {
for (;;) {
some_stuff
fast_path
more_stuff
}
}
Roland.
More information about the shenandoah-dev
mailing list