RFR: 8277372: Add getters for BOT and card table members [v4]
Thomas Schatzl
tschatzl at openjdk.java.net
Wed Dec 1 11:27:28 UTC 2021
On Wed, 1 Dec 2021 09:03:02 GMT, Vishal Chand <duke at openjdk.java.net> wrote:
>> src/hotspot/share/gc/parallel/objectStartArray.hpp line 52:
>>
>>> 50: static uint _block_size;
>>> 51: static uint _block_size_in_words;
>>> 52:
>>
>> Almost the same naming issue as in the `BlockOffsetTable/SharedArray`; I would prefer if these members (and getters) here were named similarly to the ones there.
>> It is true that `ObjectStartArray` and `BlockOffsetTable` are basically the same thing, but any eventual merge is another issue.
>
> Shall these be renamed to osa_card_shift? Something like this?
Okay, `_osa_card_shift` and so on is also acceptable to me, but just `_card_shift`/`_card_size` would be fine too. We typically do not prefix members with abbreviations of class name they are in; I see now that we have that `_bot` prefix in the other class, for me the `bot` prefix not necessarily refers to the class but to the concept of a block offset table.
Maybe just reduce the names in both cases to `_card_size`/`_card_shift`/`_log_card_<something>`? What do others think?
-------------
PR: https://git.openjdk.java.net/jdk/pull/6570
More information about the hotspot-dev
mailing list