RFR: 8309065: Move the logic to determine archive heap location from CDS to G1 GC [v2]
Ashutosh Mehra
duke at openjdk.org
Fri Jun 2 03:14:06 UTC 2023
On Wed, 31 May 2023 14:49:23 GMT, Ashutosh Mehra <duke at openjdk.org> wrote:
>> This patch is the first step towards having a single set of GC APIs for allocating heap space for the archived objects (See https://bugs.openjdk.org/browse/JDK-8296263).
>> It moves some of the G1 specific logic from CDS to G1 gc without changing the functionality.
>>
>> Changes that add/update GC APIs for handling archive heap would be introduced in upcoming patches.
>
> Ashutosh Mehra has updated the pull request incrementally with one additional commit since the last revision:
>
> Remove unused method FileMapInfo::heap_region_mapped_address
>
> Signed-off-by: Ashutosh Mehra <asmehra at redhat.com>
@tschatzl
> I'm not convinced not giving a preferred location is a good idea. That seems to reduce the opportunity to directly map archives significantly. Previously, with only heap size changes, the archive could be mapped in still.
I am not sure I get this. The patch does not change the ability to map the archive. It just moved the calculation to map the archive region from CDS to G1. Before this patch CDS code would determine the address for mapping the archive space towards the top of the heap and pass that address to G1. This patch just moves that calculation to G1. So it should be at-par with the current state. If it is not, please point out and I can work on fixing that.
> Since this change is an intermediate step, could you provide an overview of the final API/change too? It is hard to comment on this without knowing where you are going with that.
Ok, I have updated the description of the main issue [JDK-8296263](https://bugs.openjdk.org/browse/JDK-8296263) with some details on the expected changes in the future patches.
My main aim with this work is mainly code reorganization to avoid using different GC APIs in CDS depending on the GC policy in use. When this is completed I expect it to provide same functionality as today. Any enhancement, like passing preferred location to map archive heap, can be built on top of this.
Hope this helps.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/14208#issuecomment-1573075190
More information about the hotspot-dev
mailing list