On Tue, 23 Apr 2024 07:11:34 GMT, Viktor Klang <vkl...@openjdk.org> wrote:
> Has the alternative of moving to a j.u.c.Lock (Needs Reentrant or not?) been > explored/benchmarked? Yes, decided not to do because it's just guarding access to a byte[] and any changes can influence the inlining. Plus, it would need to continue to use monitors when extended as the subclass may assume synchronization in the super class. Limiting it to just the problematic writeTo method seem the least risky. ------------- PR Comment: https://git.openjdk.org/jdk/pull/18901#issuecomment-2071613230