# HG changeset patch # User Gilles Duboscq # Date 1428499993 -7200 # Node ID eb21f2944d7d94ca24efdb503d45bed710dba87f # Parent 0d6563e4d1f533599772952a87966c01fbdba8c3 Process Graal oops in nmethod::do_unloading_parallel diff -r 0d6563e4d1f5 -r eb21f2944d7d src/share/vm/code/nmethod.cpp --- a/src/share/vm/code/nmethod.cpp Tue Apr 07 18:57:54 2015 +0200 +++ b/src/share/vm/code/nmethod.cpp Wed Apr 08 15:33:13 2015 +0200 @@ -2093,6 +2093,27 @@ unloading_occurred = true; } +#ifdef GRAAL + // Follow Graal method + if (_graal_installed_code != NULL) { + if (_graal_installed_code->is_a(HotSpotNmethod::klass()) && HotSpotNmethod::isDefault(_graal_installed_code)) { + if (!is_alive->do_object_b(_graal_installed_code)) { + _graal_installed_code = NULL; + } + } else { + if (can_unload(is_alive, (oop*)&_graal_installed_code, unloading_occurred)) { + return false; + } + } + } + + if (_speculation_log != NULL) { + if (!is_alive->do_object_b(_speculation_log)) { + _speculation_log = NULL; + } + } +#endif + // When class redefinition is used all metadata in the CodeCache has to be recorded, // so that unused "previous versions" can be purged. Since walking the CodeCache can // be expensive, the "mark on stack" is piggy-backed on this parallel unloading code.