RFR (M) 8169061: Drop os::is_MP checks from Atomics
Andrew Haley
aph at redhat.com
Mon Apr 24 13:06:38 UTC 2017
On 24/04/17 13:53, Aleksey Shipilev wrote:
> Notice the LOCK_IF_MP part, which means we have flag reads, additional branch,
> etc. on the hot path. I would like us to consider dropping runtime os::is_MP
> checks from Atomics. The history of the original change predates OpenJDK, but I
> think it was deemed a plausible optimization in mostly-uniprocessor world.
> Today, this penalizes multi-core platforms without a good reason.
I'm sure that you are right. I (almost) completely ripped this out of
AArch64 too.
My reasoning was more to do with containers and the cloud. Processors
can be dynamically added and removed, and this was enough to make me
shiver. Having said that, there are still usages of is_MP in shared
code, and I see that I've missed removing it in one place in the
AArch64 sources.
Andrew.
More information about the hotspot-dev
mailing list