RFR (S): 8066102: Clean up HeapRegionRemSet files

Kim Barrett kim.barrett at oracle.com
Fri Nov 28 21:18:50 UTC 2014

[resending from proper from address, so it will reach mailing list]

On Nov 28, 2014, at 3:46 AM, Thomas Schatzl <thomas.schatzl at oracle.com> wrote:
> Hi all,
> can I have reviews for this small cleanup? I went over heap region
> remembered set files recently and found dead code, useless code,
> tightened the public interface and tried to document the methods a
> little. I also moved FromCardCache accessor methods from
> OtherRegionTable to HeapRegionRemSet to do away with that needless
> indirection. Imo it fits better that way too.
> CR:
> https://bugs.openjdk.java.net/browse/JDK-8066102
> Webrev:
> http://cr.openjdk.java.net/~tschatzl/8066102/webrev/

Looks good.

This change surprised me though:

978   _bosa(hrrs->bosa()),
943   _bosa(hrrs->_bosa),

Violates the Hotspot coding guidelines item about member access from
outside the class be through accessor functions.  OTOH, the class
being accessed has befriended the class doing this access, and the
(removed by this changeset) bosa() accessor was private.

Regarding Mikael's comment:
> In heapRegionRemSet.hpp:
> +  // One bits in the bitmaps indicate that the given region or card is live.
> typo: "One bit in one of the bitmaps indicate that the.."

I think the existing comment is correct, but might be clearer if it

"Set bits in the bitmaps ..."

More information about the hotspot-gc-dev mailing list