< prev index next > src/hotspot/share/runtime/frame.cpp
Print this page
oop frame::interpreter_callee_receiver(Symbol* signature) {
return *interpreter_callee_receiver_addr(signature);
}
- void frame::oops_interpreted_do(OopClosure* f, const RegisterMap* map, bool query_oop_map_cache) const {
+ template <typename RegisterMapT>
+ void frame::oops_interpreted_do(OopClosure* f, const RegisterMapT* map, bool query_oop_map_cache) const {
assert(is_interpreted_frame(), "Not an interpreted frame");
Thread *thread = Thread::current();
methodHandle m (thread, interpreter_frame_method());
jint bci = interpreter_frame_bci();
// is installed as a GC root.
f->do_oop(interpreter_frame_mirror_addr());
int max_locals = m->is_native() ? m->size_of_parameters() : m->max_locals();
- Symbol* signature = nullptr;
- bool has_receiver = false;
-
// Process a callee's arguments if we are at a call site
// (i.e., if we are at an invoke bytecode)
// This is used sometimes for calling into the VM, not for another
// interpreted or compiled frame.
- if (!m->is_native()) {
+ if (!m->is_native() && map != nullptr && map->include_argument_oops()) {
Bytecode_invoke call = Bytecode_invoke_check(m, bci);
- if (map != nullptr && call.is_valid()) {
- signature = call.signature();
- has_receiver = call.has_receiver();
- if (map->include_argument_oops() &&
- interpreter_frame_expression_stack_size() > 0) {
- ResourceMark rm(thread); // is this right ???
- // we are at a call site & the expression stack is not empty
- // => process callee's arguments
- //
- // Note: The expression stack can be empty if an exception
- // occurred during method resolution/execution. In all
- // cases we empty the expression stack completely be-
- // fore handling the exception (the exception handling
- // code in the interpreter calls a blocking runtime
- // routine which can cause this code to be executed).
- // (was bug gri 7/27/98)
- oops_interpreted_arguments_do(signature, has_receiver, f);
- }
+ if (call.is_valid() && interpreter_frame_expression_stack_size() > 0) {
+ ResourceMark rm(thread); // is this right ???
+ Symbol* signature = call.signature();
+ bool has_receiver = call.has_receiver();
+ // we are at a call site & the expression stack is not empty
+ // => process callee's arguments
+ //
+ // Note: The expression stack can be empty if an exception
+ // occurred during method resolution/execution. In all
+ // cases we empty the expression stack completely be-
+ // fore handling the exception (the exception handling
+ // code in the interpreter calls a blocking runtime
+ // routine which can cause this code to be executed).
+ // (was bug gri 7/27/98)
+ // if (dolog) {
+ // log_trace(continuations, tracking)("Processing arguments");
+ // }
+ oops_interpreted_arguments_do(signature, has_receiver, f);
}
}
InterpreterFrameClosure blk(this, max_locals, m->max_stack(), f);
OopMapCache::compute_one_oop_map(m, bci, &mask);
}
mask.iterate_oop(&blk);
}
+ template void frame::oops_interpreted_do(OopClosure* f, const RegisterMap* map, bool query_oop_map_cache) const;
+ template void frame::oops_interpreted_do(OopClosure* f, const SmallRegisterMapNoArgs* map, bool query_oop_map_cache) const;
+ template void frame::oops_interpreted_do(OopClosure* f, const SmallRegisterMapWithArgs* map, bool query_oop_map_cache) const;
void frame::oops_interpreted_arguments_do(Symbol* signature, bool has_receiver, OopClosure* f) const {
InterpretedArgumentOopFinder finder(signature, has_receiver, this, f);
finder.oops_do();
}
< prev index next >