Commit 291d9a78 authored by machenbach's avatar machenbach Committed by Commit bot

Revert of [stubs] KeyedLoadIC_Generic: prototype chain lookup support...

Revert of [stubs] KeyedLoadIC_Generic: prototype chain lookup support (patchset #2 id:20001 of https://codereview.chromium.org/2652213003/ )

Reason for revert:
Speculative revert for breaking a layout test:
https://build.chromium.org/p/client.v8.fyi/builders/V8-Blink%20Linux%2064/builds/13113

Unfortunately, the test results archive is not giving much info this time.

Original issue's description:
> [stubs] KeyedLoadIC_Generic: prototype chain lookup support
>
> Performing lookups on the prototype chain in the stub avoids a
> bunch of slow-path runtime calls. For now, only receivers with
> dictionary-mode properties do this; fast-mode receivers will follow
> if it's beneficial.
>
> Review-Url: https://codereview.chromium.org/2652213003
> Cr-Commit-Position: refs/heads/master@{#42751}
> Committed: https://chromium.googlesource.com/v8/v8/+/82e10f5fbacbbd71bc65e99322f432470692bf41

TBR=ishell@chromium.org,jkummerow@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review-Url: https://codereview.chromium.org/2657393002
Cr-Commit-Position: refs/heads/master@{#42754}
parent bf511b42
...@@ -1403,8 +1403,7 @@ void AccessorAssembler::KeyedLoadICGeneric(const LoadICParameters* p) { ...@@ -1403,8 +1403,7 @@ void AccessorAssembler::KeyedLoadICGeneric(const LoadICParameters* p) {
Variable var_value(this, MachineRepresentation::kTagged); Variable var_value(this, MachineRepresentation::kTagged);
Label if_index(this), if_unique_name(this), if_element_hole(this), Label if_index(this), if_unique_name(this), if_element_hole(this),
if_oob(this), slow(this), stub_cache_miss(this), if_oob(this), slow(this), stub_cache_miss(this),
if_property_dictionary(this), if_found_on_receiver(this), if_property_dictionary(this), if_found_on_receiver(this);
lookup_prototype_chain(this);
Node* receiver = p->receiver; Node* receiver = p->receiver;
GotoIf(TaggedIsSmi(receiver), &slow); GotoIf(TaggedIsSmi(receiver), &slow);
...@@ -1529,8 +1528,7 @@ void AccessorAssembler::KeyedLoadICGeneric(const LoadICParameters* p) { ...@@ -1529,8 +1528,7 @@ void AccessorAssembler::KeyedLoadICGeneric(const LoadICParameters* p) {
Variable var_name_index(this, MachineType::PointerRepresentation()); Variable var_name_index(this, MachineType::PointerRepresentation());
Label dictionary_found(this, &var_name_index); Label dictionary_found(this, &var_name_index);
NameDictionaryLookup<NameDictionary>(properties, key, &dictionary_found, NameDictionaryLookup<NameDictionary>(properties, key, &dictionary_found,
&var_name_index, &var_name_index, &slow);
&lookup_prototype_chain);
Bind(&dictionary_found); Bind(&dictionary_found);
{ {
LoadPropertyFromNameDictionary(properties, var_name_index.value(), LoadPropertyFromNameDictionary(properties, var_name_index.value(),
...@@ -1547,50 +1545,6 @@ void AccessorAssembler::KeyedLoadICGeneric(const LoadICParameters* p) { ...@@ -1547,50 +1545,6 @@ void AccessorAssembler::KeyedLoadICGeneric(const LoadICParameters* p) {
Return(value); Return(value);
} }
Bind(&lookup_prototype_chain);
{
Variable var_holder_map(this, MachineRepresentation::kTagged);
Variable var_holder_instance_type(this, MachineRepresentation::kWord32);
Label return_undefined(this);
Variable* merged_variables[] = {&var_holder_map, &var_holder_instance_type};
Label loop(this, arraysize(merged_variables), merged_variables);
var_holder_map.Bind(receiver_map);
var_holder_instance_type.Bind(instance_type);
Goto(&loop);
Bind(&loop);
{
// Bailout if it can be an integer indexed exotic case.
GotoIf(Word32Equal(var_holder_instance_type.value(),
Int32Constant(JS_TYPED_ARRAY_TYPE)),
&slow);
Node* proto = LoadMapPrototype(var_holder_map.value());
GotoIf(WordEqual(proto, NullConstant()), &return_undefined);
Node* proto_map = LoadMap(proto);
Node* proto_instance_type = LoadMapInstanceType(proto_map);
var_holder_map.Bind(proto_map);
var_holder_instance_type.Bind(proto_instance_type);
Label next_proto(this), return_value(this, &var_value), goto_slow(this);
TryGetOwnProperty(p->context, receiver, proto, proto_map,
proto_instance_type, var_unique.value(), &return_value,
&var_value, &next_proto, &goto_slow);
// This trampoline and the next are required to appease Turbofan's
// variable merging.
Bind(&next_proto);
Goto(&loop);
Bind(&goto_slow);
Goto(&slow);
Bind(&return_value);
Return(var_value.value());
}
Bind(&return_undefined);
Return(UndefinedConstant());
}
Bind(&slow); Bind(&slow);
{ {
Comment("KeyedLoadGeneric_slow"); Comment("KeyedLoadGeneric_slow");
......
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