UnsafeAtomicityTest crashes on SPARC
Alan Burlison
Alan.Burlison at oracle.com
Wed Aug 31 16:30:36 UTC 2016
On 31/08/2016 14:48, Andrew Haley wrote:
> This is just a lexicographic comparison in Hadoop. We do have
> misaligned accesses in the new Unsafe, but it's internal. But I would
> have thought the Hadoop code should use Arrays.compare.
Yes, it probably should but they are focused on squeezing every last
drop of performance out wherever they can. The misaligned 64-bit word
hack for lexicographic comparisons makes things a bit faster on the Java
versions and platforms they concentrate on, which is why they've done
it. For Java9 that's no longer true any more and pure-Java is the
fastest way, but of course they aren't using that yet - in fact they
have only moved up to Java7 fairly recently and are currently working on
Java8 support:
https://issues.apache.org/jira/browse/HADOOP-11090
--
Alan Burlison
--
More information about the hotspot-runtime-dev
mailing list