Commit b636408f authored by Camillo Bruni's avatar Camillo Bruni Committed by Commit Bot

[ic] Reset profiler ticks in property adding N to N transitions

Not resetting the ticks regresses optimization time without substantial
performance benenfits on twitter, facebook, youtube, linkedin and wikipedia.

There was no net positive effect visible otherwise.

Bug: chromium:786908
Change-Id: I98237dee170e7a387f09ccfbad178793361d4a67
Reviewed-on: https://chromium-review.googlesource.com/779435Reviewed-by: 's avatarCamillo Bruni <cbruni@chromium.org>
Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
Commit-Queue: Camillo Bruni <cbruni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#49516}
parent 47383c20
......@@ -370,15 +370,15 @@ static bool MigrateDeprecated(Handle<Object> object) {
}
bool IC::ConfigureVectorState(IC::State new_state, Handle<Object> key) {
bool changed = true;
if (new_state == PREMONOMORPHIC) {
nexus()->ConfigurePremonomorphic();
} else if (new_state == MEGAMORPHIC) {
DCHECK_IMPLIES(!is_keyed(), key->IsName());
IcCheckType property_type = key->IsName() ? PROPERTY : ELEMENT;
if (!nexus()->ConfigureMegamorphic(property_type)) {
vector_set_ = true;
return false;
}
// Even though we don't change the feedback data, we still want to reset the
// profiler ticks. Real-world observations suggest that optimizing these
// functions doesn't improve performance.
changed = nexus()->ConfigureMegamorphic(key->IsName() ? PROPERTY : ELEMENT);
} else {
UNREACHABLE();
}
......@@ -387,7 +387,7 @@ bool IC::ConfigureVectorState(IC::State new_state, Handle<Object> key) {
OnFeedbackChanged(
isolate(), *vector(), slot(), GetHostFunction(),
new_state == PREMONOMORPHIC ? "Premonomorphic" : "Megamorphic");
return true;
return changed;
}
void IC::ConfigureVectorState(Handle<Name> name, Handle<Map> map,
......
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