RFR: 8336463: Parallel: Add PSOldGen::expand_and_allocate
Albert Mingkun Yang
ayang at openjdk.org
Tue Jul 16 16:37:56 UTC 2024
On Tue, 16 Jul 2024 14:38:45 GMT, Zhengyu Gu <zgu at openjdk.org> wrote:
>> Can you elaborate what are racing here?
>
> Okay, let me ask in a different way: why use `cas_allocate_noexpand()` here, which implies there may be other threads (e.g. GC threads) that may perform allocation concurrently?
There is no non-cas version API for allocate. Maybe I can add a comment to explain, sth like, "Reuse the CAS API even though this is VM thread in safepoint. This method is not invoked repeated, so the CAS overhead should be negligible."?
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20189#discussion_r1679727877
More information about the hotspot-gc-dev
mailing list