Revert I+TF for lexical variables

This reverts the following commits to fix a Node.js regression:
* 5529430dec "[compiler] Consistently use Ignition+TurboFan for lexical variables."
* 7869136716 "[compiler] Improve let+const decision in AstNumbering."

R=adamk@chromium.org, bmeurer@chromium.org, hablich@chromium.org
BUG=
NOTRY=true

Review-Url: https://codereview.chromium.org/2647523002
Cr-Commit-Position: refs/heads/master@{#42484}
This commit is contained in:
ofrobots 2017-01-18 16:39:25 -08:00 committed by Commit bot
parent f3dcdf8862
commit 89b7a4d7d0
3 changed files with 0 additions and 25 deletions

View File

@ -166,12 +166,6 @@ void AstNumberingVisitor::VisitVariableProxyReference(VariableProxy* node) {
default:
break;
}
if (node->var()->binding_needs_init()) {
// Disable FCG+CS for all variable bindings that need explicit
// initialization, i.e. ES2015 style const and let, but not
// named function expressions.
DisableFullCodegenAndCrankshaft(kReferenceToLetOrConstVariable);
}
node->set_base_id(ReserveIdRange(VariableProxy::num_ids()));
}

View File

@ -174,7 +174,6 @@ namespace internal {
V(kReceivedInvalidReturnAddress, "Received invalid return address") \
V(kReferenceToAVariableWhichRequiresDynamicLookup, \
"Reference to a variable which requires dynamic lookup") \
V(kReferenceToLetOrConstVariable, "Reference to let or const variable") \
V(kReferenceToGlobalLexicalVariable, "Reference to global lexical variable") \
V(kReferenceToModuleVariable, "Reference to module-allocated variable") \
V(kReferenceToUninitializedVariable, "Reference to uninitialized variable") \

View File

@ -1,18 +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: --allow-natives-syntax
function foo(j) {
for (var i = 0; i < j + 1; i++) {
if (i === j) %OptimizeOsr();
}
let k = 1
}
foo(1000);
foo(1000);
%OptimizeFunctionOnNextCall(foo);
foo(-1);
assertOptimized(foo);