Integrated: 8274191: Improve g1 evacuation failure injector performance
Thomas Schatzl
tschatzl at openjdk.java.net
Fri Sep 24 12:10:00 UTC 2021
On Thu, 23 Sep 2021 12:13:18 GMT, Thomas Schatzl <tschatzl at openjdk.org> wrote:
> Hi all,
>
> can I have reviews for this change that improves evacuation failure injector performance to be usable for pinned region performance work?
>
> The suspected reason I think why performance is so bad (image in the CR), is that the unsynchronized reads and writes to `G1YoungGCEvacFailureInjector::_evacuation_failure_object_count` cause massive performance issue if done millions of times.
>
> This change makes that counter thread-local, fixing that issue completely.
>
> I initially had a prototype using a `THREAD_LOCAL`, but when testing I had the feeling that this is/was slightly slower and I thought that adding a variable to every thread where most do not use them seems to be a waste.
>
> Testing: local testing, GHA
>
> Thanks,
> Thomas
This pull request has now been integrated.
Changeset: db23ecdf
Author: Thomas Schatzl <tschatzl at openjdk.org>
URL: https://git.openjdk.java.net/jdk/commit/db23ecdfae44a5387c2407e9e0f300f08770e7c0
Stats: 36 lines in 6 files changed: 15 ins; 11 del; 10 mod
8274191: Improve g1 evacuation failure injector performance
Reviewed-by: kbarrett, ayang
-------------
PR: https://git.openjdk.java.net/jdk/pull/5650
More information about the hotspot-gc-dev
mailing list