RFR: 8310159: Bulk copy with Unsafe::arrayCopy is slower compared to memcpy
Jatin Bhateja
jbhateja at openjdk.org
Thu Nov 16 05:45:32 UTC 2023
On Wed, 15 Nov 2023 17:03:38 GMT, Steve Dohrmann <duke at openjdk.org> wrote:
>> Do you see any concerns while handling multithreaded case where writer is busy copying 256 bytes block in loop and reader try to access a location still not flushed out of write combining buffer.
>
> The results a concurrent reader sees could be different if the copy is using nt writes, but if the read of the destination is not synced with the copy operation, I think the reader would not see consistent state in either case. Is it worse with nt writes?
Thanks for the clarification, agree behavior is similar to non-NT case, in fact using NT for huge copy operations will prevent polluting caches due to destination cache line fills.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/16575#discussion_r1395171526
More information about the hotspot-compiler-dev
mailing list