vframe.cpp revision 0
0N/A * Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 0N/A * published by the Free Software Foundation. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 0N/A * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 0N/A * CA 95054 USA or visit www.sun.com if you need additional information or 0N/A * have any questions. 0N/A#
include "incls/_precompiled.incl" 0N/A // Interpreter frame 0N/A // Skip this frame and try again. 0N/A// ------------- javaVFrame -------------- 0N/A "must be at safepoint or it's a java frame of the current thread");
0N/A if (
obj ==
NULL)
continue;
// skip unowned monitor 0N/A // Skip the monitor that the thread is blocked to enter or waiting on 0N/A // If this is the first frame, and java.lang.Object.wait(...) then print out the receiver. 0N/A // Print out all monitors that we have locked or are trying to lock 0N/A // First, assume we have the monitor locked. If we haven't found an 0N/A // owned monitor before and this is the first frame, then we need to 0N/A // see if we have completed the lock or we are blocked trying to 0N/A // acquire it - we can only be blocked if the monitor is inflated 0N/A const char *
lock_state =
"locked";
// assume we have the monitor locked 0N/A// ------------- interpretedVFrame -------------- 0N/A // If the method is native, max_locals is not telling the truth. 0N/A // maxlocals then equals the size of parameters 0N/A // Get oopmap describing oops and int for current bci 0N/A // Find stack location 0N/A // Depending on oop/int put it in the right package 0N/A // Find stack location 0N/A // Depending on oop/int put it in the right package 0N/A // If the method is native, max_locals is not telling the truth. 0N/A // maxlocals then equals the size of parameters 0N/A // Find stack location 0N/A // Depending on oop/int put it in the right package 0N/A // If the method is native, there is no expression stack 0N/A // handle expressions 0N/A // Find stack location 0N/A // Depending on oop/int put it in the right package 0N/A // Get oopmap describing oops and int for current bci 0N/A // handle expressions 0N/A // Find stack location 0N/A // Depending on oop/int put it in the right package 0N/A// ------------- cChunk -------------- 0N/A // 6379830 Cut point for an assertion that occasionally fires when 0N/A // we are using the performance analyzer. 0N/A // Disable this assert when testing the analyzer with fastdebug. 0N/A // -XX:SuppressErrorAt=vframe.cpp:XXX (XXX=following line number) 0N/A assert(
false,
"invalid bci or invalid scope desc");
0N/A// top-frame will be skipped 0N/A // skip top frame, as it may not be at safepoint 0N/A// Step back n frames, skip any pseudo frames in between. 0N/A// This function is used in Class.forName, Class.newInstance, Method.Invoke, 0N/A// AccessController.doPrivileged. 0N/A// NOTE that in JDK 1.4 this has been exposed to Java as 0N/A// sun.reflect.Reflection.getCallerClass(), which can be inlined. 0N/A// Inlined versions must match this routine's logic. 0N/A// Native method prefixing logic does not need to match since 0N/A// the method names don't match and inlining will not occur. 0N/A// Parse::inline_native_Reflection_getCallerClass in 0N/A // This is Method.invoke() -- skip it 0N/A // This is an auxilary frame -- skip it 0N/A // This is non-excluded frame, we need to count it against the depth 0N/A // we have reached the desired depth, we are done 0N/A break;
// classes don't match, can't be a wrapper 0N/A break;
// prefixed name isn't prefixed version of method name, can't be a wrapper 0N/A break;
// matching prefix found 0N/A break;
// didn't find the prefix, can't be a wrapper 0N/A// ------------- javaVFrame -------------- 0N/A // Check frame size and print warning if it looks suspiciously large 0N/A // Check static part 0N/A // it might happen the compiler reports a conflict and 0N/A // the interpreter reports a bogus int. 0N/A // Check expressions 0N/A // frame number and method 0N/A// ------------- externalVFrame --------------