G1CollectedHeap::collection_set_iterate_from() has an unnecessary "if" statement
in which the "then" part can never be executed.
if (cl->doHeapRegion(cur) && false) {
cl->incomplete();
return;
}
This can be simplified to
guarantee(!cl->doHeapRegion(cur), err_msg("doHeapRegion returned true"));
Also, G1CollectedHeap::collection_set_iterate() can be simplified because none of the callers
pass a closure where doHeapRegion() returns true.
in which the "then" part can never be executed.
if (cl->doHeapRegion(cur) && false) {
cl->incomplete();
return;
}
This can be simplified to
guarantee(!cl->doHeapRegion(cur), err_msg("doHeapRegion returned true"));
Also, G1CollectedHeap::collection_set_iterate() can be simplified because none of the callers
pass a closure where doHeapRegion() returns true.
- relates to
-
JDK-8159978 Use an array to store the collection set regions instead of linking through regions
-
- Resolved
-