Commit 29b572d4 authored by verwaest's avatar verwaest Committed by Commit bot

Micro-optimize not-found for elements on objects with empty_fixed_array backing store

BUG=chromium:495949
LOG=n

Review URL: https://codereview.chromium.org/1163033004

Cr-Commit-Position: refs/heads/master@{#28831}
parent bfb81fbe
......@@ -66,6 +66,10 @@ LookupIterator::State LookupIterator::LookupInHolder(Map* const map,
PropertyCellType::kNoCell);
} else {
JSObject* js_object = JSObject::cast(holder);
if (js_object->elements() == isolate()->heap()->empty_fixed_array()) {
return NOT_FOUND;
}
ElementsAccessor* accessor = js_object->GetElementsAccessor();
FixedArrayBase* backing_store = js_object->elements();
number_ = accessor->GetIndexForKey(backing_store, index_);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment