Mercurial > hg > graal-compiler
diff src/share/vm/code/nmethod.cpp @ 20813:eb21f2944d7d
Process Graal oops in nmethod::do_unloading_parallel
author | Gilles Duboscq <gilles.m.duboscq@oracle.com> |
---|---|
date | Wed, 08 Apr 2015 15:33:13 +0200 |
parents | 7848fc12602b |
children | e13c65f874e5 |
line wrap: on
line diff
--- 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.