From f69acc592fde84a5e1853f65c85aa78bb9c8fdb2 Mon Sep 17 00:00:00 2001 From: Sean Stangl Date: Tue, 15 Dec 2015 13:42:56 -0800 Subject: [PATCH] Bug 470143 - Part 2/2 - TrackedOptimization changes for TypeOfNoSuchVar. r=shu --- js/public/TrackedOptimizationInfo.h | 1 + js/src/doc/JITOptimizations/Outcomes.md | 5 +++++ js/src/jit/IonCaches.cpp | 3 +-- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/js/public/TrackedOptimizationInfo.h b/js/public/TrackedOptimizationInfo.h index 642f4d773055..ee9931278718 100644 --- a/js/public/TrackedOptimizationInfo.h +++ b/js/public/TrackedOptimizationInfo.h @@ -144,6 +144,7 @@ namespace JS { \ _(ICNameStub_ReadSlot) \ _(ICNameStub_CallGetter) \ + _(ICNameStub_TypeOfNoProperty) \ \ _(CantInlineGeneric) \ _(CantInlineNoTarget) \ diff --git a/js/src/doc/JITOptimizations/Outcomes.md b/js/src/doc/JITOptimizations/Outcomes.md index 38e6089319e3..ddd59da2a007 100644 --- a/js/src/doc/JITOptimizations/Outcomes.md +++ b/js/src/doc/JITOptimizations/Outcomes.md @@ -407,6 +407,11 @@ a scope chain object. An inline cache element which loads a bare variable name by calling a getter function on the global object. +### ICNameStub_TypeOfNoProperty + +An inline cache element which loads undefined for the type +of a missing property. + ## Call Inlining Outcomes Optimization outcomes of attempts to inline function calls. diff --git a/js/src/jit/IonCaches.cpp b/js/src/jit/IonCaches.cpp index ea0362616fd3..2d358735af1a 100644 --- a/js/src/jit/IonCaches.cpp +++ b/js/src/jit/IonCaches.cpp @@ -4952,9 +4952,8 @@ NameIC::attachTypeOfNoProperty(JSContext* cx, HandleScript outerScript, IonScrip masm.bind(&failures); attacher.jumpNextStub(masm); - // TODO: ICNameStub_TypeOfNoProperty return linkAndAttachStub(cx, masm, attacher, ion, "generic", - JS::TrackedOutcome::ICNameStub_ReadSlot); + JS::TrackedOutcome::ICNameStub_TypeOfNoProperty); } static bool