[jdk17u] Integrated: 8276205: Shenandoah: CodeCache_lock should always be held for initializing code cache iteration

Zhengyu Gu zgu at openjdk.java.net
Wed Nov 17 14:33:52 UTC 2021


On Mon, 15 Nov 2021 15:58:43 GMT, Zhengyu Gu <zgu at openjdk.org> wrote:

> I would like to backport this Shenandoah specific fix to jdk17u.
> 
> This patch fixed the bug that not holding CodeCache_lock while initializing concurrent nmethod iterations, that can lead to miscount number of concurrent walker and result assertion failure.
> 
> The patch fixed a bug that prevents iterators from walking nmethod concurrently due to holding CodeCache_lock during the walk.
> 
> The original patch does not apply cleanly, due to context changes. But the patch is small and simple, conflicts can be easily resolved manually.
> 
> 
> Test:
> - [x] hotspot_gc_shenandoah

This pull request has now been integrated.

Changeset: f1a8a22f
Author:    Zhengyu Gu <zgu at openjdk.org>
URL:       https://git.openjdk.java.net/jdk17u/commit/f1a8a22f54438ede20d73297b19b9f95cfc3ad21
Stats:     7 lines in 2 files changed: 2 ins; 1 del; 4 mod

8276205: Shenandoah: CodeCache_lock should always be held for initializing code cache iteration

Reviewed-by: shade
Backport-of: 99b7b95e014da6e491ba7adfd21de53d6ae166fe

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

PR: https://git.openjdk.java.net/jdk17u/pull/262


More information about the jdk-updates-dev mailing list