Implementation of system. arraycopy. Java

Hello. There is a question, does anyone know how system. arraycopy is implemented in Java. Everyone knows that the built-in method System.arraycopy(a, 0, b, 0, 2) parameters, which is, the array from which we will copy, starting with which element, the array to which we will copy, starting with which element and how many elements. Obviously, the work at n > 100 elements, by the speed exceeds the copying cycle. So what's the secret ? It turns out that the method copies the data in blocks ?

Author: ImZ, 2017-08-21

1 answers

If you run through the OpenJDK sources, you can easily see that System.arraycopy is just memmove wrapped in a swaddling blanket of checks.

 5
Author: Sergey Gornostaev, 2017-08-21 20:30:16