Mercurial > hg > truffle
comparison src/share/vm/prims/unsafe.cpp @ 2376:c7f3d0b4570f
7017732: move static fields into Class to prepare for perm gen removal
Reviewed-by: kvn, coleenp, twisti, stefank
author | never |
---|---|
date | Fri, 18 Mar 2011 16:00:34 -0700 |
parents | d411927672ed |
children | 38fea01eb669 e1162778c1c8 |
comparison
equal
deleted
inserted
replaced
2375:d673ef06fe96 | 2376:c7f3d0b4570f |
---|---|
686 | 686 |
687 if ((modifiers & JVM_ACC_STATIC) == 0) { | 687 if ((modifiers & JVM_ACC_STATIC) == 0) { |
688 THROW_0(vmSymbols::java_lang_IllegalArgumentException()); | 688 THROW_0(vmSymbols::java_lang_IllegalArgumentException()); |
689 } | 689 } |
690 | 690 |
691 return JNIHandles::make_local(env, java_lang_Class::as_klassOop(mirror)); | 691 return JNIHandles::make_local(env, mirror); |
692 UNSAFE_END | 692 UNSAFE_END |
693 | 693 |
694 //@deprecated | 694 //@deprecated |
695 UNSAFE_ENTRY(jint, Unsafe_FieldOffset(JNIEnv *env, jobject unsafe, jobject field)) | 695 UNSAFE_ENTRY(jint, Unsafe_FieldOffset(JNIEnv *env, jobject unsafe, jobject field)) |
696 UnsafeWrapper("Unsafe_FieldOffset"); | 696 UnsafeWrapper("Unsafe_FieldOffset"); |
704 UNSAFE_ENTRY(jobject, Unsafe_StaticFieldBaseFromClass(JNIEnv *env, jobject unsafe, jobject clazz)) | 704 UNSAFE_ENTRY(jobject, Unsafe_StaticFieldBaseFromClass(JNIEnv *env, jobject unsafe, jobject clazz)) |
705 UnsafeWrapper("Unsafe_StaticFieldBase"); | 705 UnsafeWrapper("Unsafe_StaticFieldBase"); |
706 if (clazz == NULL) { | 706 if (clazz == NULL) { |
707 THROW_0(vmSymbols::java_lang_NullPointerException()); | 707 THROW_0(vmSymbols::java_lang_NullPointerException()); |
708 } | 708 } |
709 return JNIHandles::make_local(env, java_lang_Class::as_klassOop(JNIHandles::resolve_non_null(clazz))); | 709 return JNIHandles::make_local(env, JNIHandles::resolve_non_null(clazz)); |
710 UNSAFE_END | 710 UNSAFE_END |
711 | 711 |
712 UNSAFE_ENTRY(void, Unsafe_EnsureClassInitialized(JNIEnv *env, jobject unsafe, jobject clazz)) | 712 UNSAFE_ENTRY(void, Unsafe_EnsureClassInitialized(JNIEnv *env, jobject unsafe, jobject clazz)) |
713 UnsafeWrapper("Unsafe_EnsureClassInitialized"); | 713 UnsafeWrapper("Unsafe_EnsureClassInitialized"); |
714 if (clazz == NULL) { | 714 if (clazz == NULL) { |