equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright 1997-2009 Sun Microsystems, Inc. All Rights Reserved. |
2 * Copyright 1997-2010 Sun Microsystems, Inc. All Rights Reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
232 // Compute the caller frame based on the sender sp of stub_frame and stored frame sizes info. |
232 // Compute the caller frame based on the sender sp of stub_frame and stored frame sizes info. |
233 CodeBlob* cb = stub_frame.cb(); |
233 CodeBlob* cb = stub_frame.cb(); |
234 // Verify we have the right vframeArray |
234 // Verify we have the right vframeArray |
235 assert(cb->frame_size() >= 0, "Unexpected frame size"); |
235 assert(cb->frame_size() >= 0, "Unexpected frame size"); |
236 intptr_t* unpack_sp = stub_frame.sp() + cb->frame_size(); |
236 intptr_t* unpack_sp = stub_frame.sp() + cb->frame_size(); |
|
237 |
|
238 // If the deopt call site is a MethodHandle invoke call site we have |
|
239 // to adjust the unpack_sp. |
|
240 nmethod* deoptee_nm = deoptee.cb()->as_nmethod_or_null(); |
|
241 if (deoptee_nm != NULL && deoptee_nm->is_method_handle_return(deoptee.pc())) |
|
242 unpack_sp = deoptee.unextended_sp(); |
237 |
243 |
238 #ifdef ASSERT |
244 #ifdef ASSERT |
239 assert(cb->is_deoptimization_stub() || cb->is_uncommon_trap_stub(), "just checking"); |
245 assert(cb->is_deoptimization_stub() || cb->is_uncommon_trap_stub(), "just checking"); |
240 Events::log("fetch unroll sp " INTPTR_FORMAT, unpack_sp); |
246 Events::log("fetch unroll sp " INTPTR_FORMAT, unpack_sp); |
241 #endif |
247 #endif |