Mercurial > hg > truffle
diff src/share/vm/oops/method.cpp @ 8751:1fc4d4768b90
8007725: NPG: Klass::restore_unshareable_info() triggers assert(k->java_mirror() == NULL)
Summary: Check for exception during SystemDictionary::resolve_instance_class_or_null() and clean up.
Reviewed-by: coleenp, acorn, hseigel, minqi
Contributed-by: ioi.lam@oracle.com
author | coleenp |
---|---|
date | Fri, 15 Mar 2013 17:24:40 -0400 |
parents | 5939f5953b45 |
children | 0c3ee6f1fa23 16885e702c88 |
line wrap: on
line diff
--- a/src/share/vm/oops/method.cpp Thu Mar 14 00:33:08 2013 -0700 +++ b/src/share/vm/oops/method.cpp Fri Mar 15 17:24:40 2013 -0400 @@ -798,7 +798,15 @@ backedge_counter()->reset(); _adapter = NULL; _from_compiled_entry = NULL; - assert(_method_data == NULL, "unexpected method data?"); + + // In case of DumpSharedSpaces, _method_data should always be NULL. + // + // During runtime (!DumpSharedSpaces), when we are cleaning a + // shared class that failed to load, this->link_method() may + // have already been called (before an exception happened), so + // this->_method_data may not be NULL. + assert(!DumpSharedSpaces || _method_data == NULL, "unexpected method data?"); + set_method_data(NULL); set_interpreter_throwout_count(0); set_interpreter_invocation_count(0);