Lines Matching defs:handle

128 void JNIHandles::destroy_global(jobject handle) {
129 if (handle != NULL) {
130 assert(is_global_handle(handle), "Invalid delete of global JNI handle");
131 *((oop*)handle) = deleted_handle(); // Mark the handle as deleted, allocate will reuse it
136 void JNIHandles::destroy_weak_global(jobject handle) {
137 if (handle != NULL) {
138 assert(!CheckJNICalls || is_weak_global_handle(handle), "Invalid delete of weak global JNI handle");
139 *((oop*)handle) = deleted_handle(); // Mark the handle as deleted, allocate will reuse it
170 bool JNIHandles::is_local_handle(Thread* thread, jobject handle) {
175 if (block->chain_contains(handle)) {
184 // Determine if the handle is somewhere in the current thread's stack.
185 // We easily can't isolate any particular stack frame the handle might
190 // as the java command executable, in which case, this type of handle
198 bool JNIHandles::is_global_handle(jobject handle) {
199 return _global_handles->chain_contains(handle);
203 bool JNIHandles::is_weak_global_handle(jobject handle) {
204 return _weak_global_handles->chain_contains(handle);
398 // the next handle block is valid only if current block is full
430 // the next handle block is valid only if current block is full
467 oop* handle = &(_last->_handles)[_last->_top++];
468 *handle = obj;
469 return (jobject) handle;
474 oop* handle = _free_list;
476 *handle = obj;
477 return (jobject) handle;
509 oop* handle = &(current->_handles)[index];
510 if (*handle == JNIHandles::deleted_handle()) {
511 // this handle was cleared out by a delete call, reuse it
512 *handle = (oop) _free_list;
513 _free_list = handle;
537 bool JNIHandleBlock::contains(jobject handle) const {
538 return ((jobject)&_handles[0] <= handle && handle<(jobject)&_handles[_top]);
542 bool JNIHandleBlock::chain_contains(jobject handle) const {
544 if (current->contains(handle)) {
569 bool JNIHandleBlock::any_contains(jobject handle) {
571 if (current->contains(handle)) {