diff --git a/src/cpu/sparc/vm/frame_sparc.cpp b/src/cpu/sparc/vm/frame_sparc.cpp index edac2b3ca731a6ea8bea1cb24b43c344e545194d..83fd37182ca535b13f0b40a80434247056cfd089 100644 --- a/src/cpu/sparc/vm/frame_sparc.cpp +++ b/src/cpu/sparc/vm/frame_sparc.cpp @@ -839,3 +839,9 @@ void frame::describe_pd(FrameValues& values, int frame_no) { } #endif + +intptr_t *frame::initial_deoptimization_info() { + // unused... but returns fp() to minimize changes introduced by 7087445 + return fp(); +} + diff --git a/src/cpu/x86/vm/frame_x86.cpp b/src/cpu/x86/vm/frame_x86.cpp index 21705957e50d1b1aebef8b563c2c479cb4f64068..3d82d062289ae69c3126122cf70b1caa515ad973 100644 --- a/src/cpu/x86/vm/frame_x86.cpp +++ b/src/cpu/x86/vm/frame_x86.cpp @@ -666,3 +666,9 @@ void frame::describe_pd(FrameValues& values, int frame_no) { } #endif + +intptr_t *frame::initial_deoptimization_info() { + // used to reset the saved FP + return fp(); +} + diff --git a/src/cpu/x86/vm/sharedRuntime_x86_32.cpp b/src/cpu/x86/vm/sharedRuntime_x86_32.cpp index f21ed399f7c55f4e19daef656f68f94fb73fc3b3..9b43aba25dd3ec42f6042a433d5ffed89801afce 100644 --- a/src/cpu/x86/vm/sharedRuntime_x86_32.cpp +++ b/src/cpu/x86/vm/sharedRuntime_x86_32.cpp @@ -2471,7 +2471,7 @@ void SharedRuntime::generate_deopt_blob() { __ movl(counter, rbx); // Pick up the initial fp we should save - __ movptr(rbp, Address(rdi, Deoptimization::UnrollBlock::initial_fp_offset_in_bytes())); + __ movptr(rbp, Address(rdi, Deoptimization::UnrollBlock::initial_info_offset_in_bytes())); // Now adjust the caller's stack to make up for the extra locals // but record the original sp so that we can save it in the skeletal interpreter @@ -2691,7 +2691,7 @@ void SharedRuntime::generate_uncommon_trap_blob() { __ movl(counter, rbx); // Pick up the initial fp we should save - __ movptr(rbp, Address(rdi, Deoptimization::UnrollBlock::initial_fp_offset_in_bytes())); + __ movptr(rbp, Address(rdi, Deoptimization::UnrollBlock::initial_info_offset_in_bytes())); // Now adjust the caller's stack to make up for the extra locals // but record the original sp so that we can save it in the skeletal interpreter diff --git a/src/cpu/x86/vm/sharedRuntime_x86_64.cpp b/src/cpu/x86/vm/sharedRuntime_x86_64.cpp index 06b3d8d0c072f20e72ffefe8e7ade0f7e572b936..effb3ce365aee0b63bef937bb911c9379097de65 100644 --- a/src/cpu/x86/vm/sharedRuntime_x86_64.cpp +++ b/src/cpu/x86/vm/sharedRuntime_x86_64.cpp @@ -2730,7 +2730,7 @@ void SharedRuntime::generate_deopt_blob() { __ movl(rdx, Address(rdi, Deoptimization::UnrollBlock::number_of_frames_offset_in_bytes())); // Pick up the initial fp we should save - __ movptr(rbp, Address(rdi, Deoptimization::UnrollBlock::initial_fp_offset_in_bytes())); + __ movptr(rbp, Address(rdi, Deoptimization::UnrollBlock::initial_info_offset_in_bytes())); // Now adjust the caller's stack to make up for the extra locals // but record the original sp so that we can save it in the skeletal interpreter @@ -2922,7 +2922,7 @@ void SharedRuntime::generate_uncommon_trap_blob() { // Pick up the initial fp we should save __ movptr(rbp, Address(rdi, - Deoptimization::UnrollBlock::initial_fp_offset_in_bytes())); + Deoptimization::UnrollBlock::initial_info_offset_in_bytes())); // Now adjust the caller's stack to make up for the extra locals but // record the original sp so that we can save it in the skeletal diff --git a/src/cpu/zero/vm/frame_zero.cpp b/src/cpu/zero/vm/frame_zero.cpp index 9e3211224d4359c3a672425864d292419e6a5410..35b6e52e41e24f59b512fd01156589fd57b36c61 100644 --- a/src/cpu/zero/vm/frame_zero.cpp +++ b/src/cpu/zero/vm/frame_zero.cpp @@ -425,3 +425,9 @@ void frame::describe_pd(FrameValues& values, int frame_no) { } #endif + +intptr_t *frame::initial_deoptimization_info() { + // unused... but returns fp() to minimize changes introduced by 7087445 + return fp(); +} + diff --git a/src/share/vm/runtime/arguments.cpp b/src/share/vm/runtime/arguments.cpp index c159e48f0be715a73c095391536d324b2903d4d4..c802f0351d408840df628827eabef5fe45881c5e 100644 --- a/src/share/vm/runtime/arguments.cpp +++ b/src/share/vm/runtime/arguments.cpp @@ -3018,9 +3018,6 @@ jint Arguments::parse(const JavaVMInitArgs* args) { } #ifdef JAVASE_EMBEDDED - #ifdef PPC - UNSUPPORTED_OPTION(EnableInvokeDynamic, "Invoke dynamic"); - #endif UNSUPPORTED_OPTION(UseG1GC, "G1 GC"); #endif diff --git a/src/share/vm/runtime/deoptimization.cpp b/src/share/vm/runtime/deoptimization.cpp index b2f172d1d70bacd47a1c1d9ce4b8f36b650cea01..db95badcdedf2b20577d683c0def15e2c6ef7ca3 100644 --- a/src/share/vm/runtime/deoptimization.cpp +++ b/src/share/vm/runtime/deoptimization.cpp @@ -103,7 +103,7 @@ Deoptimization::UnrollBlock::UnrollBlock(int size_of_deoptimized_frame, _frame_pcs = frame_pcs; _register_block = NEW_C_HEAP_ARRAY(intptr_t, RegisterMap::reg_count * 2); _return_type = return_type; - _initial_fp = 0; + _initial_info = 0; // PD (x86 only) _counter_temp = 0; _unpack_kind = 0; @@ -486,9 +486,10 @@ Deoptimization::UnrollBlock* Deoptimization::fetch_unroll_info_helper(JavaThread frame_sizes, frame_pcs, return_type); - // On some platforms, we need a way to pass fp to the unpacking code - // so the skeletal frames come out correct. - info->set_initial_fp((intptr_t) array->sender().fp()); + // On some platforms, we need a way to pass some platform dependent + // information to the unpacking code so the skeletal frames come out + // correct (initial fp value, unextended sp, ...) + info->set_initial_info((intptr_t) array->sender().initial_deoptimization_info()); if (array->frames() > 1) { if (VerifyStack && TraceDeoptimization) { diff --git a/src/share/vm/runtime/deoptimization.hpp b/src/share/vm/runtime/deoptimization.hpp index 853cd9a017e39b8edfc16aaa19fe6029c5358a5b..161d3a31afe4972c1c0d766d412ab25307db764f 100644 --- a/src/share/vm/runtime/deoptimization.hpp +++ b/src/share/vm/runtime/deoptimization.hpp @@ -137,7 +137,7 @@ class Deoptimization : AllStatic { address* _frame_pcs; // Array of frame pc's, in bytes, for unrolling the stack intptr_t* _register_block; // Block for storing callee-saved registers. BasicType _return_type; // Tells if we have to restore double or long return value - intptr_t _initial_fp; // FP of the sender frame + intptr_t _initial_info; // Platform dependent data for the sender frame (was FP on x86) int _caller_actual_parameters; // The number of actual arguments at the // interpreted caller of the deoptimized frame @@ -170,7 +170,7 @@ class Deoptimization : AllStatic { // Returns the total size of frames int size_of_frames() const; - void set_initial_fp(intptr_t fp) { _initial_fp = fp; } + void set_initial_info(intptr_t info) { _initial_info = info; } int caller_actual_parameters() const { return _caller_actual_parameters; } @@ -184,7 +184,7 @@ class Deoptimization : AllStatic { static int register_block_offset_in_bytes() { return offset_of(UnrollBlock, _register_block); } static int return_type_offset_in_bytes() { return offset_of(UnrollBlock, _return_type); } static int counter_temp_offset_in_bytes() { return offset_of(UnrollBlock, _counter_temp); } - static int initial_fp_offset_in_bytes() { return offset_of(UnrollBlock, _initial_fp); } + static int initial_info_offset_in_bytes() { return offset_of(UnrollBlock, _initial_info); } static int unpack_kind_offset_in_bytes() { return offset_of(UnrollBlock, _unpack_kind); } static int sender_sp_temp_offset_in_bytes() { return offset_of(UnrollBlock, _sender_sp_temp); } diff --git a/src/share/vm/runtime/frame.hpp b/src/share/vm/runtime/frame.hpp index 0273edf928fdb903c310e8bd657d753cfc28aa6a..ec3e3e6ebe35afa46ffb73285c29ee1e0d23c8d0 100644 --- a/src/share/vm/runtime/frame.hpp +++ b/src/share/vm/runtime/frame.hpp @@ -221,6 +221,10 @@ class frame VALUE_OBJ_CLASS_SPEC { // returns the stack pointer of the calling frame intptr_t* sender_sp() const; + // Deoptimization info, if needed (platform dependent). + // Stored in the initial_info field of the unroll info, to be used by + // the platform dependent deoptimization blobs. + intptr_t *initial_deoptimization_info(); // Interpreter frames: