[INFER] On destruction, release JIT code for scripts before debugger hooks try to recompile them, bug 679461.
authorBrian Hackett <bhackett1024@gmail.com>
Mon, 29 Aug 2011 15:03:59 -0700
changeset 77473 6c8e0affe03e4b3eaa7482807998a44cf8e53e6a
parent 77472 cbda722273a9c8f56c68d045ce3e28fc8f4fda70
child 77474 f35ac2fed8fcb37d608b451f12f8e360ccba32c2
push id78
push userclegnitto@mozilla.com
push dateFri, 16 Dec 2011 17:32:24 +0000
treeherdermozilla-release@79d24e644fdd [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs679461
milestone9.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
[INFER] On destruction, release JIT code for scripts before debugger hooks try to recompile them, bug 679461.
js/src/jsscript.cpp
--- a/js/src/jsscript.cpp
+++ b/js/src/jsscript.cpp
@@ -1354,16 +1354,20 @@ js_CallNewScriptHook(JSContext *cx, JSSc
     }
 }
 
 void
 js_CallDestroyScriptHook(JSContext *cx, JSScript *script)
 {
     JSDestroyScriptHook hook;
 
+#ifdef JS_METHODJIT
+    mjit::ReleaseScriptCode(cx, script);
+#endif
+
     hook = cx->debugHooks->destroyScriptHook;
     if (hook)
         hook(cx, script, cx->debugHooks->destroyScriptHookData);
     Debugger::onDestroyScript(script);
     JS_ClearScriptTraps(cx, script);
 }
 
 static void