equal
deleted
inserted
replaced
35 // Interface for creating and resolving local/global JNI handles |
35 // Interface for creating and resolving local/global JNI handles |
36 |
36 |
37 class JNIHandles : AllStatic { |
37 class JNIHandles : AllStatic { |
38 friend class VMStructs; |
38 friend class VMStructs; |
39 private: |
39 private: |
|
40 // These are used by the serviceability agent. |
40 static OopStorage* _global_handles; |
41 static OopStorage* _global_handles; |
41 static OopStorage* _weak_global_handles; |
42 static OopStorage* _weak_global_handles; |
|
43 friend void jni_handles_init(); |
42 |
44 |
43 inline static bool is_jweak(jobject handle); |
45 inline static bool is_jweak(jobject handle); |
44 inline static oop* jobject_ptr(jobject handle); // NOT jweak! |
46 inline static oop* jobject_ptr(jobject handle); // NOT jweak! |
45 inline static oop* jweak_ptr(jobject handle); |
47 inline static oop* jweak_ptr(jobject handle); |
46 |
48 |
120 static void oops_do(OopClosure* f); |
122 static void oops_do(OopClosure* f); |
121 // Traversal of weak global handles. Unreachable oops are cleared. |
123 // Traversal of weak global handles. Unreachable oops are cleared. |
122 static void weak_oops_do(BoolObjectClosure* is_alive, OopClosure* f); |
124 static void weak_oops_do(BoolObjectClosure* is_alive, OopClosure* f); |
123 // Traversal of weak global handles. |
125 // Traversal of weak global handles. |
124 static void weak_oops_do(OopClosure* f); |
126 static void weak_oops_do(OopClosure* f); |
125 |
|
126 static OopStorage* global_handles(); |
|
127 static OopStorage* weak_global_handles(); |
|
128 }; |
127 }; |
129 |
128 |
130 |
129 |
131 |
130 |
132 // JNI handle blocks holding local/global JNI handles |
131 // JNI handle blocks holding local/global JNI handles |