if (verboseJNI) VM.sysWrite("JNI called: GetDoubleArrayRegion   \n");
if (traceJNI) VM.sysWrite("JNI called: GetDoubleArrayRegion   \n");
  private static void GetDoubleArrayRegion(int envJREF, int arrayJREF, int startIndex,                                            int length, VM_Address bufAddress) {    if (verboseJNI) VM.sysWrite("JNI called: GetDoubleArrayRegion   \n");    VM_JNIEnvironment env;    try {      env = VM_Thread.getCurrentThread().getJNIEnv();      double sourceArray[] = (double []) env.getJNIRef(arrayJREF);      if ((startIndex<0) || (startIndex+length>sourceArray.length)) {        env.recordException(new ArrayIndexOutOfBoundsException());        return;      }      VM_Memory.memcopy(bufAddress, VM_Magic.objectAsAddress(sourceArray).add(startIndex*8), length*8);     } catch (Throwable unexpected) {      env = VM_Thread.getCurrentThread().getJNIEnv();      env.recordException(unexpected);      return;    }  }