[aarch64-port-dev ] RFR(s): AArch64: 8149080: Recoginize disjoint array copy in stub code
edward.nevill at gmail.com
Fri Feb 5 14:32:41 UTC 2016
On Fri, 2016-02-05 at 12:58 +0000, Andrew Haley wrote:
> On 02/05/2016 12:47 PM, Hui Shi wrote:
> > Arraycopy without overlapping is faster than overlapped copy.
> The only thing which varies is the direction of copying. I'm not
> aware of anything which makes one direction faster than the other.
> Measurements, please.
Copy backwards doesn't prefetch. The difference with and without
prefetch can be very significant on some micro-arches.
if (direction == copy_forwards && PrefetchCopyIntervalInBytes > 0)
__ prfm(Address(s, PrefetchCopyIntervalInBytes), PLDL1KEEP);
I have done some experiments with prefetch enabled for backwards copy
and it shows almost identical performance to forwards copy.
More information about the hotspot-compiler-dev