comparison src/share/vm/prims/jvm.cpp @ 7624:b14da2e6f2dc

7174978: NPG: Fix bactrace builder for class redefinition Summary: Remove Method* from backtrace but save version so redefine classes doesn't give inaccurate line numbers. Removed old Merlin API with duplicate code. Reviewed-by: dholmes, sspitsyn
author coleenp
date Thu, 17 Jan 2013 13:40:31 -0500
parents f9eb431c3efe
children c73c3f2c5b3b
comparison
equal deleted inserted replaced
7623:203f64878aab 7624:b14da2e6f2dc
1 /* 1 /*
2 * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1997, 2013, Oracle and/or its affiliates. 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.
482 Handle exception(thread, JNIHandles::resolve_non_null(receiver)); 482 Handle exception(thread, JNIHandles::resolve_non_null(receiver));
483 java_lang_Throwable::fill_in_stack_trace(exception); 483 java_lang_Throwable::fill_in_stack_trace(exception);
484 JVM_END 484 JVM_END
485 485
486 486
487 JVM_ENTRY(void, JVM_PrintStackTrace(JNIEnv *env, jobject receiver, jobject printable))
488 JVMWrapper("JVM_PrintStackTrace");
489 // Note: This is no longer used in Merlin, but we still support it for compatibility.
490 oop exception = JNIHandles::resolve_non_null(receiver);
491 oop stream = JNIHandles::resolve_non_null(printable);
492 java_lang_Throwable::print_stack_trace(exception, stream);
493 JVM_END
494
495
496 JVM_ENTRY(jint, JVM_GetStackTraceDepth(JNIEnv *env, jobject throwable)) 487 JVM_ENTRY(jint, JVM_GetStackTraceDepth(JNIEnv *env, jobject throwable))
497 JVMWrapper("JVM_GetStackTraceDepth"); 488 JVMWrapper("JVM_GetStackTraceDepth");
498 oop exception = JNIHandles::resolve(throwable); 489 oop exception = JNIHandles::resolve(throwable);
499 return java_lang_Throwable::get_stack_trace_depth(exception, THREAD); 490 return java_lang_Throwable::get_stack_trace_depth(exception, THREAD);
500 JVM_END 491 JVM_END