Bug 1511210 part 3 - Remove unnecessary call to ensureHasTypes in jit::CreateThis. r=tcampbell
authorJan de Mooij <jdemooij@mozilla.com>
Sun, 02 Dec 2018 22:38:39 +0000
changeset 505618 6cbbac93c27318820e9a626a25aced587ef3a010
parent 505617 30e5ba51f64aa65ed086da3ccc7b4b139d139e79
child 505619 e18883f3328eb3d949fb7458005d84b2e2bbad3c
push id10290
push userffxbld-merge
push dateMon, 03 Dec 2018 16:23:23 +0000
treeherdermozilla-beta@700bed2445e6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstcampbell
bugs1511210, 833076, 875276
milestone65.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 1511210 part 3 - Remove unnecessary call to ensureHasTypes in jit::CreateThis. r=tcampbell This was added in bug 833076 because back then TypeScript::SetThis assumed non-null script->types. However since bug 875276 we don't need this anymore. Differential Revision: https://phabricator.services.mozilla.com/D13652
js/src/jit/VMFunctions.cpp
--- a/js/src/jit/VMFunctions.cpp
+++ b/js/src/jit/VMFunctions.cpp
@@ -601,20 +601,16 @@ bool CreateThis(JSContext* cx, HandleObj
   if (callee->is<JSFunction>()) {
     RootedFunction fun(cx, &callee->as<JSFunction>());
     if (fun->isInterpreted() && fun->isConstructor()) {
       JSScript* script = JSFunction::getOrCreateScript(cx, fun);
       if (!script) {
         return false;
       }
       AutoRealm ar(cx, script);
-      AutoKeepTypeScripts keepTypes(cx);
-      if (!script->ensureHasTypes(cx, keepTypes)) {
-        return false;
-      }
       if (!js::CreateThis(cx, fun, script, newTarget, GenericObject, rval)) {
         return false;
       }
     }
   }
 
   return true;
 }