RFR: 8251158: Implementation of JEP 387: Elastic Metaspace [v11]

Thomas Stuefe stuefe at openjdk.java.net
Tue Oct 6 12:22:47 UTC 2020


On Mon, 5 Oct 2020 23:23:57 GMT, Richard Reingruber <rrich at openjdk.org> wrote:

>> Thomas Stuefe has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Review Feedback Richard 1
>
> src/hotspot/share/memory/metaspace/metachunk.hpp line 154:
> 
>> 152:   // This means only read or modify these members under expand lock protection.
>> 153:   Metachunk* _prev_in_vs;
>> 154:   Metachunk* _next_in_vs;
> 
> I think the field `_next_in_vs` could be eliminated. The next chunk begins at the `end()` of this chunk.

The idea is good, but at the moment _next_in_vs==NULL marks the last chunk within one root chunk area, and is used e.g.
as loop stop. I would have to make Metachunk aware of the root chunk it lives in, which I rather avoid.

> src/hotspot/share/memory/metaspace/metachunk.hpp line 243:
> 
>> 241:
>> 242:   bool ensure_fully_committed()           { return ensure_committed(word_size()); }
>> 243:   bool ensure_fully_committed_locked()    { return ensure_committed_locked(word_size()); }
> 
> `ensure_fully_committed()` and `ensure_fully_committed_locked()` seem to be unused.

Okay will remove.

-------------

PR: https://git.openjdk.java.net/jdk/pull/336


More information about the hotspot-runtime-dev mailing list