Bug 1115387 - Create templateObject for SIMD constructors. r=jandem
☠☠ backed out by bbb0b9dffd36 ☠ ☠
authorNicolas B. Pierron <nicolas.b.pierron@mozilla.com>
Tue, 30 Dec 2014 15:01:52 +0100
changeset 247473 1c9c64027cacf7f9bbc0203b0f6bcff8f4887784
parent 247472 d850c0d21fedd6b36799783fbe89d82aee7d74c6
child 247474 d8a111f0fb640baa50e3b485b364bfd9dcdebbdf
push id4489
push userraliiev@mozilla.com
push dateMon, 23 Feb 2015 15:17:55 +0000
treeherdermozilla-beta@fd7c3dc24146 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjandem
bugs1115387
milestone37.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
Bug 1115387 - Create templateObject for SIMD constructors. r=jandem
js/src/jit/BaselineIC.cpp
--- a/js/src/jit/BaselineIC.cpp
+++ b/js/src/jit/BaselineIC.cpp
@@ -9026,16 +9026,25 @@ TryAttachFunCallStub(JSContext *cx, ICCa
         if (!newStub)
             return false;
 
         *attached = true;
         stub->addNewStub(newStub);
         return true;
     }
 
+    if (hook == SimdTypeDescr::call) {
+        Rooted<SimdTypeDescr *> descr(cx, &args.callee().as<SimdTypeDescr>());
+        JSObject *obj = TypedObject::createZeroed(cx, descr, 0, gc::TenuredHeap);
+        if (!obj)
+            return false;
+        templateObject.set(obj);
+        return true;
+    }
+
     return true;
 }
 
 static bool
 GetTemplateObjectForNative(JSContext *cx, HandleScript script, jsbytecode *pc,
                            Native native, const CallArgs &args, MutableHandleNativeObject res)
 {
     // Check for natives to which template objects can be attached. This is