134 135 136 // Old thread-local info. has been restored. We are not back in the VM. 137 ThreadStateTransition::transition_from_java(_thread, _thread_in_vm); 138 139 // State has been restored now make the anchor frame visible for the profiler. 140 // Do this after the transition because this allows us to put an assert 141 // the Java->vm transition which checks to see that stack is not walkable 142 // on sparc/ia64 which will catch violations of the reseting of last_Java_frame 143 // invariants (i.e. _flags always cleared on return to Java) 144 145 _thread->frame_anchor()->copy(&_anchor); 146 147 // Release handles after we are marked as being inside the VM again, since this 148 // operation might block 149 JNIHandleBlock::release_block(_old_handles, _thread); 150 } 151 152 153 void JavaCallWrapper::oops_do(OopClosure* f) { 154 if (!VTBuffer::is_in_vt_buffer(_receiver)) { 155 f->do_oop((oop*)&_receiver); 156 } else { 157 assert(_receiver->is_value(), "Sanity check"); 158 BufferedValuesDealiaser* dealiaser = Thread::current()->buffered_values_dealiaser(); 159 assert(dealiaser != NULL, "Sanity check"); 160 dealiaser->oops_do(f, _receiver); 161 } 162 handles()->oops_do(f); 163 } 164 165 166 // Helper methods 167 static BasicType runtime_type_from(JavaValue* result) { 168 switch (result->get_type()) { 169 case T_BOOLEAN: // fall through 170 case T_CHAR : // fall through 171 case T_SHORT : // fall through 172 case T_INT : // fall through 173 #ifndef _LP64 174 case T_OBJECT : // fall through 175 case T_ARRAY : // fall through 176 #endif 177 case T_BYTE : // fall through 178 case T_VOID : return T_INT; 179 case T_LONG : return T_LONG; 180 case T_FLOAT : return T_FLOAT; 181 case T_DOUBLE : return T_DOUBLE; | 134 135 136 // Old thread-local info. has been restored. We are not back in the VM. 137 ThreadStateTransition::transition_from_java(_thread, _thread_in_vm); 138 139 // State has been restored now make the anchor frame visible for the profiler. 140 // Do this after the transition because this allows us to put an assert 141 // the Java->vm transition which checks to see that stack is not walkable 142 // on sparc/ia64 which will catch violations of the reseting of last_Java_frame 143 // invariants (i.e. _flags always cleared on return to Java) 144 145 _thread->frame_anchor()->copy(&_anchor); 146 147 // Release handles after we are marked as being inside the VM again, since this 148 // operation might block 149 JNIHandleBlock::release_block(_old_handles, _thread); 150 } 151 152 153 void JavaCallWrapper::oops_do(OopClosure* f) { 154 f->do_oop((oop*)&_receiver); 155 handles()->oops_do(f); 156 } 157 158 159 // Helper methods 160 static BasicType runtime_type_from(JavaValue* result) { 161 switch (result->get_type()) { 162 case T_BOOLEAN: // fall through 163 case T_CHAR : // fall through 164 case T_SHORT : // fall through 165 case T_INT : // fall through 166 #ifndef _LP64 167 case T_OBJECT : // fall through 168 case T_ARRAY : // fall through 169 #endif 170 case T_BYTE : // fall through 171 case T_VOID : return T_INT; 172 case T_LONG : return T_LONG; 173 case T_FLOAT : return T_FLOAT; 174 case T_DOUBLE : return T_DOUBLE; |