Backout 2f9b6bdf63f7 (bug 739512) due to a bad V8 regression. r=me.
authorNicholas Nethercote <nnethercote@mozilla.com>
Mon, 02 Apr 2012 18:02:54 -0700
changeset 90884 9894cd99978190db956376e8ad2320fd600c87ed
parent 90883 ad815bdb133cb89c5be67e47ccd3b23884699218
child 90885 4df84fc7cbf1092c5322f7a094f594f9740a15e3
child 90896 f43822091ed15a9632a792e78496c8bb73976d29
push id22394
push userMs2ger@gmail.com
push dateTue, 03 Apr 2012 07:22:53 +0000
treeherdermozilla-central@9894cd999781 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersme
bugs739512
milestone14.0a1
backs out2f9b6bdf63f7fa8b05ad7e33a99e78671aad8c83
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
Backout 2f9b6bdf63f7 (bug 739512) due to a bad V8 regression. r=me.
js/src/methodjit/Compiler.cpp
js/src/methodjit/MethodJIT.cpp
js/src/methodjit/MethodJIT.h
--- a/js/src/methodjit/Compiler.cpp
+++ b/js/src/methodjit/Compiler.cpp
@@ -1370,18 +1370,21 @@ mjit::Compiler::finishThisUp()
     JS_ASSERT(outerScript == script);
 
     chunk->code = JSC::MacroAssemblerCodeRef(result, execPool, masm.size() + stubcc.size());
     chunk->pcLengths = pcLengths;
 
     if (chunkIndex == 0) {
         jit->invokeEntry = result;
         if (script->function()) {
+            jit->arityCheckEntry = stubCode.locationOf(arityLabel).executableAddress();
             jit->argsCheckEntry = stubCode.locationOf(argsCheckLabel).executableAddress();
             jit->fastEntry = fullCode.locationOf(invokeLabel).executableAddress();
+            void *&addr = isConstructing ? script->jitArityCheckCtor : script->jitArityCheckNormal;
+            addr = jit->arityCheckEntry;
         }
     }
 
     /*
      * WARNING: mics(), callICs() et al depend on the ordering of these
      * variable-length sections.  See JITChunk's declaration for details.
      */
 
--- a/js/src/methodjit/MethodJIT.cpp
+++ b/js/src/methodjit/MethodJIT.cpp
@@ -1357,16 +1357,17 @@ JITScript::destroyChunk(JSContext *cx, u
     if (chunkIndex == 0) {
         if (argsCheckPool) {
             argsCheckPool->release();
             argsCheckPool = NULL;
         }
 
         invokeEntry = NULL;
         fastEntry = NULL;
+        arityCheckEntry = NULL;
         argsCheckEntry = NULL;
 
         if (script->jitNormal == this)
             script->jitArityCheckNormal = NULL;
         else
             script->jitArityCheckCtor = NULL;
 
         // Fixup any ICs still referring to this chunk.
--- a/js/src/methodjit/MethodJIT.h
+++ b/js/src/methodjit/MethodJIT.h
@@ -801,16 +801,17 @@ struct CrossChunkEdge
 };
 
 struct JITScript
 {
     JSScript        *script;
 
     void            *invokeEntry;       /* invoke address */
     void            *fastEntry;         /* cached entry, fastest */
+    void            *arityCheckEntry;   /* arity check address */
     void            *argsCheckEntry;    /* arguments check address */
 
     /* List of inline caches jumping to the fastEntry. */
     JSCList         callers;
 
     uint32_t        nchunks;
     uint32_t        nedges;