RFR: 8259354 Fix race condition in AbstractEventStream.nextThreadName

Erik Gahlin egahlin at openjdk.java.net
Thu Jan 7 04:25:03 UTC 2021


On Tue, 22 Dec 2020 21:11:33 GMT, Carter Kozak <github.com+3854321+carterkozak at openjdk.org> wrote:

> The result of `AtomicLong.incrementAndGet()` is used rather than
> incrementing the long and reading its value separately. The
> previous approach allowed for the static counter to be incremented
> several times before any caller read the value, resulting in
> several callers with the same value.

Marked as reviewed by egahlin (Reviewer).

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

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


More information about the hotspot-jfr-dev mailing list