RFR: 8273300: Check Mutex ranking during a safepoint [v5]

Patricio Chilano Mateo pchilanomate at openjdk.java.net
Wed Sep 15 16:05:48 UTC 2021


On Wed, 15 Sep 2021 11:56:14 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

>> This change checks lock ranking during a safepoint.  For some reason, safepoint checking was excluded, probably from the days where Safepoint_lock and Threads_lock were used.
>> Because of checking during a safepoint, some locks had to get lower ranks.  The CR has the details of which locks these were.  The Service_lock complicates things because it's held during oops_do, which may take out other G1 locks.
>> This was built and tested with Shenandoah.  Thanks to @zhengyu123 for the changes in Shenandoah.
>> Tests run tier1-8.
>
> Coleen Phillimore has updated the pull request incrementally with three additional commits since the last revision:
> 
>  - Revert copyright changes again
>  - Revert "Revert unintended copyright changes."
>    
>    This reverts commit 712af5df87a5cefc16a9844867c3be1ae663b00d.
>  - Revert unintended copyright changes.

Marked as reviewed by pchilanomate (Committer).

src/hotspot/share/runtime/mutex.cpp line 375:

> 373:   Mutex* locks_owned = thread->owned_locks();
> 374: 
> 375:   if (!SafepointSynchronize::is_at_safepoint()) {

I think removing this conditional was okay in your previous change.

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

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


More information about the shenandoah-dev mailing list