RFR: jsr166 jdk9 integration wave 13

Martin Buchholz martinrb at google.com
Wed Dec 14 03:37:10 UTC 2016

Hotspot appears to have support for the array filling code pattern, but
Arrays.fill itself is not intrinsified.  There are bounds checks which
hotspot may not be able to elide.  For almost all software, Arrays.fill is
good enough, but core library collections are an exception.  Also, we
introduce other little abstractions like shiftTailOverGap and
circularClear.  Another possibility is to introduce our own tiny helper
method without checks

nullOutSlice(Object[] a, int from, int to)

On Tue, Dec 13, 2016 at 5:26 PM, Paul Sandoz <paul.sandoz at oracle.com> wrote:

> One general question: why did you replace Arrays.fill with an explicit
> loop in many cases?

More information about the core-libs-dev mailing list