RFR: 8307058: Implementation of Generational ZGC [v8]

Erik Österlund eosterlund at openjdk.org
Mon May 8 09:13:39 UTC 2023


On Sat, 6 May 2023 05:22:48 GMT, Quan Anh Mai <qamai at openjdk.org> wrote:

>> Stefan Karlsson has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 917 commits:
>> 
>>  - ZGC: Generational
>>    
>>    Co-authored-by: Stefan Karlsson <stefank at openjdk.org>
>>    Co-authored-by: Per Liden <pliden at openjdk.org>
>>    Co-authored-by: Albert Mingkun Yang <ayang at openjdk.org>
>>    Co-authored-by: Erik Österlund <eosterlund at openjdk.org>
>>    Co-authored-by: Axel Boldt-Christmas <aboldtch at openjdk.org>
>>    Co-authored-by: Stefan Johansson <kstefanj at openjdk.org>
>>  - UPSTREAM: Introduce check_oop infrastructure to check oops in the oop class
>>  - UPSTREAM: RISCV tmp reg cleanup resolve_jobject
>>  - CLEANUP: barrierSetNMethod_aarch64.cpp
>>  - UPSTREAM: Add relaxed add&fetch for aarch64 atomics
>>  - UPSTREAM: assembler_ppc CMPLI
>>    
>>    Co-authored-by: TheRealMDoerr <martin.doerr at sap.com>
>>  - UPSTREAM: assembler_ppc ANDI
>>    
>>    Co-authored-by: TheRealMDoerr <martin.doerr at sap.com>
>>  - UPSTREAM: Add VMErrorCallback infrastructure
>>  - Merge branch 'zgc_generational' into zgc_generational_rebase_target
>>  - Whitespace nit
>>  - ... and 907 more: https://git.openjdk.org/jdk/compare/705ad7d8...349cf9ae
>
> src/hotspot/cpu/x86/gc/z/zBarrierSetAssembler_x86.cpp line 483:
> 
>> 481: 
>> 482:     __ lock();
>> 483:     __ cmpxchgq(rbx, Address(rcx, 0));
> 
> `ref_addr` is not necessarily materialised here?

I think it is, yes. But we want to ensure it's in a register that isn't rbx or rax. So I figured I'd just force materialize it in rcx and call it a day. It might be possible to micro optimize this further and even use the live information we have gathered to eliminate some of the spilling, but I'd like to hold off on that until we integrate. It's again only for atomics, and also happens at most once per field.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/13771#discussion_r1187216401


More information about the hotspot-dev mailing list