Single byte Atomic::cmpxchg implementation
mikael.gerdin at oracle.com
Thu Sep 4 09:20:06 UTC 2014
On Thursday 04 September 2014 09.05.13 Erik Österlund wrote:
> The implementation of single byte Atomic::cmpxchg on x86 (and all other
> platforms) emulates the single byte cmpxchgb instruction using a loop of
> jint-sized load and cmpxchgl and code to dynamically align the destination
> This code is used for GC-code related to remembered sets currently.
> I have the changes on my platform (amd64, bsd) to simply use the native
> cmpxchgb instead but could provide a patch fixing this unnecessary
> performance glitch for all supported x86 if anybody wants this?
I think that sounds good.
Would you mind looking at other cpu arches to see if they provide something
similar? It's ok if you can't build the code for the other arches, I can help
you with that.
More information about the hotspot-dev