Revert of [compiler] Make feedback vector cope with flag changes. (patchset #1 id:1 of https://codereview.chromium.org/1869693003/ )

Reason for revert:
Blocks current roll: https://codereview.chromium.org/1876713002/ according to bisect: https://codereview.chromium.org/1872353002/#ps80001

Original issue's description:
> [compiler] Make feedback vector cope with flag changes.
>
> This fixes corner cases where the layout of feedback vectors baked into
> the snapshot is different from the expected layout, depending on some
> runtime flags. We make sure the feedback vector is regenereated for
> functions that are not compiled. Flag changes of this kind are only
> allowed when code is not serialized.
>
> An alternative solution would be to not serialize the feedback vector
> for such cases in the first place. That solution however would have a
> higher overhead, as it would required the serializer to be able to
> recognize feedback vectors while generating a snapshot.
>
> R=mvstanton@chromium.org
> TEST=mjsunit/regress/regress-crbug-600995
> BUG=chromium:600995
> LOG=n
>
> Committed: https://crrev.com/460bff5fb6af2bd79e610f89afdf6da9dba3cf0c
> Cr-Commit-Position: refs/heads/master@{#35339}

TBR=mvstanton@chromium.org,mstarzinger@chromium.org

BUG=chromium:600995
LOG=N
NOTRY=true

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

Cr-Commit-Position: refs/heads/master@{#35392}
This commit is contained in:
hablich 2016-04-11 08:35:22 -07:00 committed by Commit bot
parent 8ce0a943e3
commit 78049e9c48
2 changed files with 3 additions and 15 deletions

View File

@ -524,11 +524,9 @@ void EnsureFeedbackVector(CompilationInfo* info) {
if (!info->has_shared_info()) return;
// If no type feedback vector exists, we create one now. At this point the
// AstNumbering pass has already run. Note the snapshot can contain outdated
// vectors for a different configuration, hence we also recreate a new vector
// when the function is not compiled (i.e. no code was serialized).
if (info->shared_info()->feedback_vector()->is_empty() ||
!info->shared_info()->is_compiled()) {
// AstNumbering pass has already run. Note that we should reuse any existing
// feedback vector rather than creating a new one.
if (info->shared_info()->feedback_vector()->is_empty()) {
Handle<TypeFeedbackMetadata> feedback_metadata = TypeFeedbackMetadata::New(
info->isolate(), info->literal()->feedback_vector_spec());
Handle<TypeFeedbackVector> feedback_vector =

View File

@ -1,10 +0,0 @@
// Copyright 2016 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Flags: --noharmony-iterator-close
// The {Set} function will produce a different type feedback vector layout
// depending on whether Harmony iterator finalization is enabled or not.
new Set();