r25817 optimized hydrogen keyed loads with string keys.
(https://codereview.chromium.org/
755513003).
This CL adapts that work for the vector-ic keyed load.
BUG=
Review URL: https://codereview.chromium.org/
820673002
Cr-Commit-Position: refs/heads/master@{#25903}
void TypeFeedbackOracle::KeyedPropertyReceiverTypes(
- FeedbackVectorICSlot slot, SmallMapList* receiver_types, bool* is_string) {
+ FeedbackVectorICSlot slot, SmallMapList* receiver_types, bool* is_string,
+ IcCheckType* key_type) {
receiver_types->Clear();
KeyedLoadICNexus nexus(feedback_vector_, slot);
CollectReceiverTypes<FeedbackNexus>(&nexus, receiver_types);
*is_string = HasOnlyStringMaps(receiver_types);
+ *key_type = nexus.FindFirstName() != NULL ? PROPERTY : ELEMENT;
}
bool* is_string,
IcCheckType* key_type);
void KeyedPropertyReceiverTypes(FeedbackVectorICSlot slot,
- SmallMapList* receiver_types,
- bool* is_string);
+ SmallMapList* receiver_types, bool* is_string,
+ IcCheckType* key_type);
void AssignmentReceiverTypes(TypeFeedbackId id,
Handle<String> name,
SmallMapList* receiver_types);
IcCheckType key_type;
if (FLAG_vector_ics) {
oracle()->KeyedPropertyReceiverTypes(slot, expr->GetReceiverTypes(),
- &is_string);
- key_type = ELEMENT;
+ &is_string, &key_type);
} else {
oracle()->KeyedPropertyReceiverTypes(id, expr->GetReceiverTypes(),
&is_string, &key_type);