< prev index next >

src/share/vm/runtime/jniHandles.cpp

Print this page

        

*** 114,124 **** oop JNIHandles::resolve_jweak(jweak handle) { assert(is_jweak(handle), "precondition"); oop result = jweak_ref(handle); result = guard_value<external_guard>(result); #if INCLUDE_ALL_GCS ! if (result != NULL && UseG1GC) { G1SATBCardTableModRefBS::enqueue(result); } #endif // INCLUDE_ALL_GCS return result; } --- 114,124 ---- oop JNIHandles::resolve_jweak(jweak handle) { assert(is_jweak(handle), "precondition"); oop result = jweak_ref(handle); result = guard_value<external_guard>(result); #if INCLUDE_ALL_GCS ! if (result != NULL && (UseG1GC || (UseShenandoahGC && ShenandoahSATBBarrier))) { G1SATBCardTableModRefBS::enqueue(result); } #endif // INCLUDE_ALL_GCS return result; }
*** 501,511 **** int free = 0; int blocks = 0; for (JNIHandleBlock* current = this; current != NULL; current = current->_next) { for (int index = 0; index < current->_top; index++) { oop* handle = &(current->_handles)[index]; ! if (*handle == JNIHandles::deleted_handle()) { // this handle was cleared out by a delete call, reuse it *handle = (oop) _free_list; _free_list = handle; free++; } --- 501,511 ---- int free = 0; int blocks = 0; for (JNIHandleBlock* current = this; current != NULL; current = current->_next) { for (int index = 0; index < current->_top; index++) { oop* handle = &(current->_handles)[index]; ! if (*handle == JNIHandles::deleted_handle()) { // this handle was cleared out by a delete call, reuse it *handle = (oop) _free_list; _free_list = handle; free++; }
< prev index next >