Bug 555687 - OBJ_SCOPE(obj) is unused in TraceRecorder::setProp. r=jorendorff.

--HG--
extra : rebase_source : 7a63d5edfb25a8b4ecacc2b069d9ad5da561ec3a
This commit is contained in:
timeless@mozdev.org 2010-04-05 15:37:33 -05:00
Родитель f2b80a8199
Коммит 5f1353bc72
1 изменённых файлов: 2 добавлений и 3 удалений

Просмотреть файл

@ -11245,9 +11245,8 @@ TraceRecorder::setProp(jsval &l, PropertyCacheEntry* entry, JSScopeProperty* spr
JS_ASSERT(!JSVAL_IS_PRIMITIVE(l)); JS_ASSERT(!JSVAL_IS_PRIMITIVE(l));
JSObject* obj = JSVAL_TO_OBJECT(l); JSObject* obj = JSVAL_TO_OBJECT(l);
LIns* obj_ins = get(&l); LIns* obj_ins = get(&l);
JSScope* scope = OBJ_SCOPE(obj);
JS_ASSERT_IF(entry->directHit(), scope->hasProperty(sprop)); JS_ASSERT_IF(entry->directHit(), OBJ_SCOPE(obj)->hasProperty(sprop));
// Fast path for CallClass. This is about 20% faster than the general case. // Fast path for CallClass. This is about 20% faster than the general case.
v_ins = get(&v); v_ins = get(&v);
@ -11260,7 +11259,7 @@ TraceRecorder::setProp(jsval &l, PropertyCacheEntry* entry, JSScopeProperty* spr
obj2 = obj2->getParent(); obj2 = obj2->getParent();
for (jsuword j = entry->protoIndex(); j; j--) for (jsuword j = entry->protoIndex(); j; j--)
obj2 = obj2->getProto(); obj2 = obj2->getProto();
scope = OBJ_SCOPE(obj2); JSScope *scope = OBJ_SCOPE(obj2);
JS_ASSERT_IF(entry->adding(), obj2 == obj); JS_ASSERT_IF(entry->adding(), obj2 == obj);
// Guard before anything else. // Guard before anything else.