RFR: 8306843: JVMTI tag map extremely slow after JDK-8292741 [v3]

Serguei Spitsyn sspitsyn at openjdk.org
Tue May 9 08:01:30 UTC 2023


On Mon, 8 May 2023 14:15:18 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

>> The ResourceHashtable conversion for JDK-8292741 didn't add the resizing code.  The old hashtable code was tuned for resizing in anticipation of large hashtables for JVMTI tags.  This patch ports over the old hashtable resizing code.  It also adds a ResourceHashtable::put_fast() function that prepends to the bucket list, which is also reclaims the performance of the old hashtable for this test with 10M tags.  The ResourceHashtable put function is really a put_if_absent. This can be cleaned up in a future change.  Also, the remove function needed a lambda to destroy the WeakHandle, since resizing requires copying entries.
>> 
>> Tested with JVMTI and JDI tests locally, and tier1-4 tests.
>
> Coleen Phillimore has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Rename and comment put_when_absent.

src/hotspot/share/prims/jvmtiTagMapTable.cpp line 50:

> 48:     _wh = src._wh;
> 49:     _obj = nullptr;
> 50:   }

There can be just one line at 51 instead of two lines at 45 and 49.
Then, I do not see where in the class `JvmtiTagMapKey` the `_obj` can obtain non nullptr value.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/13818#discussion_r1188273505


More information about the hotspot-dev mailing list