Hello. There is a question, somebody knows how to implement System.ArrayCopy in Java.
Everyone knows that the built-in system.arraycopy (a, 0, b, 0, 2)
parameters that there is an array from which we will copy, starting with which element, the array to which we will copy, starting From which element and how many elements.
Obviously, work with n & gt; 100 elements, speed exceeds cycle copying. So what is the secret? It turns out that the method copies these blocks?
Answer 1, Authority 100%
if you run OpenJDK source sources , it is easy to make sure that System.ArrayCopy
is just Memmove wrapped by pelleton checks.