RFR: 8256302: releasing oopStorage when deflating allows for faster deleting

Coleen Phillimore coleenp at openjdk.org
Tue Nov 29 22:03:11 UTC 2022


On Tue, 29 Nov 2022 21:54:52 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

>> The VM Thread can cause a deflation cycle to happen when logging is enabled.
>
> The code prior to your change did chk_for_block_req, ie checked for a safepoint.  I was asking above why it did this in this loop since the code just above does a handshake. That is, why would it be necessary? This code is generally run in another thread.
> Is the safepoint check the slow part or is the OopStorage release()?  Or both?  Do you have a test to point to that gets behind in freeing ObjectMonitors?

Doing a os::free which may call NMT while the thread is in the blocked state is probably okay, but I think you should check this out.  There may be a dcmd that runs at safepoint that does NMT things.

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

PR: https://git.openjdk.org/jdk/pull/11296


More information about the hotspot-runtime-dev mailing list