src/cpu/sparc/vm/templateInterpreter_sparc.cpp
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File
*** old/src/cpu/sparc/vm/templateInterpreter_sparc.cpp Thu Mar 20 11:28:53 2014
--- new/src/cpu/sparc/vm/templateInterpreter_sparc.cpp Thu Mar 20 11:28:53 2014
*** 1565,1602 ****
--- 1565,1588 ----
1*frame::interpreter_frame_monitor_size() : 0;
return size_activation_helper(method->max_locals(), method->max_stack(),
monitor_size) + call_stub_size;
}
! int AbstractInterpreter::layout_activation(Method* method,
! int tempcount,
! int popframe_extra_args,
! int moncount,
! int caller_actual_parameters,
! int callee_param_count,
int callee_local_count,
frame* caller,
frame* interpreter_frame,
bool is_top_frame,
bool is_bottom_frame) {
! int AbstractInterpreter::size_activation(int max_stack,
! int temps,
! int popframe_args,
! int monitors,
! int callee_params,
! int callee_locals,
+ bool is_top_frame) {
// Note: This calculation must exactly parallel the frame setup
// in InterpreterGenerator::generate_fixed_frame.
// If f!=NULL, set up the following variables:
// - Lmethod
// - Llocals
// - Lmonitors (to the indicated number of monitors)
// - Lesp (to the indicated number of temps)
// The frame f (if not NULL) on entry is a description of the caller of the frame
// we are about to layout. We are guaranteed that we will be able to fill in a
// new interpreter frame as its callee (i.e. the stack space is allocated and
// the amount was determined by an earlier call to this method with f == NULL).
// On return f (if not NULL) while describe the interpreter frame we just layed out.
! int monitor_size = moncount * frame::interpreter_frame_monitor_size();
int rounded_vm_local_words = round_to(frame::interpreter_frame_vm_local_words,WordsPerLong);
! int monitor_size = monitors * frame::interpreter_frame_monitor_size();
assert(monitor_size == round_to(monitor_size, WordsPerLong), "must align");
+
//
// Note: if you look closely this appears to be doing something much different
// than generate_fixed_frame. What is happening is this. On sparc we have to do
// this dance with interpreter_sp_adjustment because the window save area would
// appear just below the bottom (tos) of the caller's java expression stack. Because
*** 1617,1637 ****
--- 1603,1651 ----
// this code aware of what the interactions are when that initial caller fram was an osr or
// other adapter frame. deoptimization is complicated enough and hard enough to debug that
// there is no sense in messing working code.
//
! int rounded_cls = round_to((callee_local_count - callee_param_count), WordsPerLong);
! int rounded_cls = round_to((callee_locals - callee_params), WordsPerLong);
assert(rounded_cls == round_to(rounded_cls, WordsPerLong), "must align");
! int raw_frame_size = size_activation_helper(rounded_cls, method->max_stack(),
monitor_size);
! int raw_frame_size = size_activation_helper(rounded_cls, max_stack, monitor_size);
+
+ return raw_frame_size;
+ }
+
+ void AbstractInterpreter::layout_activation(Method* method,
+ int tempcount,
+ int popframe_extra_args,
+ int moncount,
+ int caller_actual_parameters,
+ int callee_param_count,
+ int callee_local_count,
+ frame* caller,
+ frame* interpreter_frame,
+ bool is_top_frame,
+ bool is_bottom_frame) {
+ // Set up the following variables:
+ // - Lmethod
+ // - Llocals
+ // - Lmonitors (to the indicated number of monitors)
+ // - Lesp (to the indicated number of temps)
+ // The frame caller on entry is a description of the caller of the
+ // frame we are about to layout. We are guaranteed that we will be
+ // able to fill in a new interpreter frame as its callee (i.e. the
+ // stack space is allocated and the amount was determined by an
+ // earlier call to the size_activation() method). On return caller
+ // while describe the interpreter frame we just layed out.
if (interpreter_frame != NULL) {
// The skeleton frame must already look like an interpreter frame
// even if not fully filled out.
assert(interpreter_frame->is_interpreted_frame(), "Must be interpreted frame");
+ int rounded_vm_local_words = round_to(frame::interpreter_frame_vm_local_words,WordsPerLong);
+ int monitor_size = moncount * frame::interpreter_frame_monitor_size();
+ assert(monitor_size == round_to(monitor_size, WordsPerLong), "must align");
+
intptr_t* fp = interpreter_frame->fp();
JavaThread* thread = JavaThread::current();
RegisterMap map(thread, false);
// More verification that skeleton frame is properly walkable
*** 1754,1766 ****
--- 1768,1777 ----
intptr_t* lo = interpreter_frame->sp() + (frame::memory_parameter_word_sp_offset - 1);
intptr_t* hi = interpreter_frame->fp() - rounded_vm_local_words;
assert(lo < monitors && montop <= hi, "monitors in bounds");
assert(lo <= esp && esp < monitors, "esp in bounds");
#endif // ASSERT
}
return raw_frame_size;
}
//----------------------------------------------------------------------------------------------------
// Exceptions
void TemplateInterpreterGenerator::generate_throw_exception() {
src/cpu/sparc/vm/templateInterpreter_sparc.cpp
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File