RFR: 8075635 - Remove GenerationSpec array
Jesper Wilhelmsson
jesper.wilhelmsson at oracle.com
Tue Mar 24 20:23:07 UTC 2015
Thanks!
/Jesper
Kim Barrett skrev den 24/3/15 21:10:
> On Mar 24, 2015, at 12:27 PM, Jesper Wilhelmsson <jesper.wilhelmsson at oracle.com> wrote:
>>
>> Hi Kim,
>>
>> Thanks for reviewing!
>>
>> A new webrev is available here:
>> http://cr.openjdk.java.net/~jwilhelm/8075635/webrev.01/hotspot/
>>
>> Latest increment:
>> http://cr.openjdk.java.net/~jwilhelm/8075635/webrev.01/hotspot_incremental/
>
> Looks good.
>
>>
>> Comments inline.
>>
>> Kim Barrett skrev den 23/3/15 22:59:
>>> ------------------------------------------------------------------------------
>>> src/share/vm/memory/generationSpec.hpp
>>> 42 GenerationSpec(Generation::Name name, size_t init_size, size_t max_size, size_t alignment) {
>>> 43 _name = name;
>>> 44 _init_size = align_size_up(init_size, alignment);
>>> 45 _max_size = align_size_up(max_size, alignment);
>>> 46 }
>>>
>>> I like that you've eliminated the separate post-construction init_size
>>> and max_size alignment step and are instead doing that in the
>>> constructor.
>>>
>>> Is there anything that ensures init_size <= max_size? Should there be
>>> an assertion to that effect here?
>>
>> This is verified in the collector policy code where initial and max sizes are set up. I wouldn't object to having an assert here if you feel strongly about it. On the other hand we have a quite extensive set off asserts in GenCollectorPolicy::assert_flags() and GenCollectorPolicy::assert_size_info() to make sure this stuff is correct already.
>
> Existing checks seem sufficient.
>
>
More information about the hotspot-gc-dev
mailing list