//===-- ClasspathVMSystem.cpp - GNU classpath java/lang/VMSystem ----------===// // // The VMKit project // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===----------------------------------------------------------------------===// #include "types.h" #include "ArrayCopy.inc" #include "Classpath.h" #include "JavaArray.h" #include "JavaClass.h" #include "JavaObject.h" #include "JavaThread.h" #include "Jnjvm.h" using namespace j3; extern "C" { JNIEXPORT void JNICALL Java_java_lang_VMSystem_arraycopy( #ifdef NATIVE_JNI JNIEnv *env, jclass _cl, #endif JavaObject* src, jint sstart, JavaObject* dst, jint dstart, jint len) { ArrayCopy(src, sstart, dst, dstart, len); } JNIEXPORT jint JNICALL Java_java_lang_VMSystem_identityHashCode( #ifdef NATIVE_JNI JNIEnv *env, jclass clazz, #endif JavaObject* obj) { llvm_gcroot(obj, 0); if (obj == NULL) return 0; return JavaObject::hashCode(obj); } }