# HG changeset patch # User coleenp # Date 1471974299 14400 # Node ID 6e951c9e7318db55dcb59a86b81fdd815082b9b0 # Parent a2b2936240b9958718bd5fc0ce1ab76ab43b760e 8038797: JVMTI FollowReferences does not report roots reachable from nmethods Summary: Also follow nmethods found on the execution stack. Reviewed-by: dlong, mgerdin diff -r a2b2936240b9 -r 6e951c9e7318 hotspot/src/share/vm/prims/jvmtiTagMap.cpp --- a/hotspot/src/share/vm/prims/jvmtiTagMap.cpp Mon Aug 22 15:54:22 2016 +0000 +++ b/hotspot/src/share/vm/prims/jvmtiTagMap.cpp Tue Aug 23 13:44:59 2016 -0400 @@ -3119,6 +3119,11 @@ } } + // Follow oops from compiled nmethod + if (jvf->cb() != NULL && jvf->cb()->is_nmethod()) { + blk->set_context(thread_tag, tid, depth, method); + jvf->cb()->as_nmethod()->oops_do(blk); + } } else { blk->set_context(thread_tag, tid, depth, method); if (is_top_frame) {