# HG changeset patch # User Gilles Duboscq # Date 1367846718 -7200 # Node ID f0ef8f58a1d909796c131317466ab172c785749c # Parent 314814fa0223b773b0fd0caf3184be8fabe873ab Use root method for deopt reason collecting if possible in non-graalvm diff -r 314814fa0223 -r f0ef8f58a1d9 src/share/vm/runtime/deoptimization.cpp --- a/src/share/vm/runtime/deoptimization.cpp Mon May 06 14:39:31 2013 +0200 +++ b/src/share/vm/runtime/deoptimization.cpp Mon May 06 15:25:18 2013 +0200 @@ -1345,8 +1345,12 @@ bool create_if_missing = ProfileTraps; methodHandle profiled_method; -#ifdef GRAALVM - profiled_method = nm->method(); +#ifdef GRAAL + if (nm->is_compiled_by_graal()) { + profiled_method = nm->method(); + } else { + profiled_method = trap_method; + } #else profiled_method = trap_method; #endif