Mercurial > hg > truffle
diff src/share/vm/classfile/systemDictionary.cpp @ 989:148e5441d916
6863023: need non-perm oops in code cache for JSR 292
Summary: Make a special root-list for those few nmethods which might contain non-perm oops.
Reviewed-by: twisti, kvn, never, jmasa, ysr
author | jrose |
---|---|
date | Tue, 15 Sep 2009 21:53:47 -0700 |
parents | 6a93908f268f |
children | 54b3b351d6f9 |
line wrap: on
line diff
--- a/src/share/vm/classfile/systemDictionary.cpp Tue Sep 15 11:09:34 2009 -0700 +++ b/src/share/vm/classfile/systemDictionary.cpp Tue Sep 15 21:53:47 2009 -0700 @@ -2414,6 +2414,8 @@ vmSymbols::makeSite_name(), vmSymbols::makeSite_signature(), &args, CHECK_(empty)); oop call_site_oop = (oop) result.get_jobject(); + assert(call_site_oop->is_oop() + /*&& sun_dyn_CallSiteImpl::is_instance(call_site_oop)*/, "must be sane"); sun_dyn_CallSiteImpl::set_vmmethod(call_site_oop, mh_invdyn()); if (TraceMethodHandles) { tty->print_cr("Linked invokedynamic bci=%d site="INTPTR_FORMAT":", caller_bci, call_site_oop); @@ -2450,6 +2452,8 @@ oop boot_method_oop = (oop) result.get_jobject(); if (boot_method_oop != NULL) { + assert(boot_method_oop->is_oop() + && java_dyn_MethodHandle::is_instance(boot_method_oop), "must be sane"); // probably no race conditions, but let's be careful: if (Atomic::cmpxchg_ptr(boot_method_oop, ik->adr_bootstrap_method(), NULL) == NULL) ik->set_bootstrap_method(boot_method_oop);