6834177: Running jsynprog on Solaris Nevada can cause JVM crash

Use CodeCache buffer blob instead of static buffer in AdapterHandlerLibrary.

Reviewed-by: never
This commit is contained in:
Vladimir Kozlov 2009-04-29 12:58:09 -07:00
parent 60e1a19b44
commit 2c4602adb3
3 changed files with 103 additions and 81 deletions

View file

@ -60,6 +60,11 @@ jlong DTraceJSDT::activate(
methodHandle h_method =
methodHandle(THREAD, JNIHandles::resolve_jmethod_id(probe->method));
nmethod* nm = AdapterHandlerLibrary::create_dtrace_nmethod(h_method);
if (nm == NULL) {
delete probes;
THROW_MSG_0(vmSymbols::java_lang_RuntimeException(),
"Unable to register DTrace probes (CodeCache: no room for DTrace nmethods).");
}
h_method()->set_not_compilable(CompLevel_highest_tier);
h_method()->set_code(h_method, nm);
probes->nmethod_at_put(count++, nm);