Commit 43c02e49 authored by rmcilroy's avatar rmcilroy Committed by Commit bot

[Interpreter] Change ignition fallback flag to only fallback on catch, not eval.

Now that we support eval in Ignition, remove the fallback for eval checks
and make the flag only fallback on catch blocks.

BUG=v8:4280,v8:4676
LOG=N

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

Cr-Commit-Position: refs/heads/master@{#33384}
parent 009b3514
......@@ -761,8 +761,7 @@ static bool CompileUnoptimizedCode(CompilationInfo* info) {
// TODO(rmcilroy): Remove this temporary work-around when ignition supports
// catch and eval.
static bool IgnitionShouldFallbackToFullCodeGen(Scope* scope) {
if (scope->is_eval_scope() || scope->is_catch_scope() ||
scope->calls_eval()) {
if (scope->is_catch_scope()) {
return true;
}
for (auto inner_scope : *scope->inner_scopes()) {
......@@ -779,7 +778,7 @@ static bool UseIgnition(CompilationInfo* info) {
}
// Checks whether the scope chain is supported.
if (FLAG_ignition_fallback_on_eval_and_catch &&
if (FLAG_ignition_fallback_on_catch &&
IgnitionShouldFallbackToFullCodeGen(info->scope())) {
return false;
}
......
......@@ -299,9 +299,8 @@ DEFINE_BOOL(ignition, false, "use ignition interpreter")
DEFINE_STRING(ignition_filter, "*", "filter for ignition interpreter")
DEFINE_BOOL(ignition_fake_try_catch, false,
"enable fake try-catch-finally blocks in ignition for testing")
DEFINE_BOOL(ignition_fallback_on_eval_and_catch, false,
"fallback to full-codegen for functions which contain eval, catch"
"and es6 blocks")
DEFINE_BOOL(ignition_fallback_on_catch, false,
"fallback to full-codegen for functions which contain catch blocks")
DEFINE_BOOL(print_bytecode, false,
"print bytecode generated by ignition interpreter")
DEFINE_BOOL(trace_ignition_codegen, false,
......
......@@ -582,6 +582,7 @@
}], # ignition == True
['ignition == True and arch == arm64', {
'test-decls/CrossScriptReferencesHarmony': [SKIP],
'test-js-arm64-variables/lookup_slots': [SKIP],
'test-spaces/SizeOfFirstPageIsLargeEnough': [SKIP],
'test-heap/Regress538257': [SKIP],
......
......@@ -70,7 +70,7 @@ class BytecodeGraphTester {
i::FLAG_ignition = true;
i::FLAG_always_opt = false;
i::FLAG_allow_natives_syntax = true;
i::FLAG_ignition_fallback_on_eval_and_catch = false;
i::FLAG_ignition_fallback_on_catch = false;
// Set ignition filter flag via SetFlagsFromString to avoid double-free
// (or potential leak with StrDup() based on ownership confusion).
ScopedVector<char> ignition_filter(64);
......
......@@ -25,7 +25,7 @@ class BytecodeGeneratorHelper {
BytecodeGeneratorHelper() {
i::FLAG_ignition = true;
i::FLAG_ignition_fake_try_catch = true;
i::FLAG_ignition_fallback_on_eval_and_catch = false;
i::FLAG_ignition_fallback_on_catch = false;
i::FLAG_ignition_filter = StrDup(kFunctionName);
i::FLAG_always_opt = false;
i::FLAG_allow_natives_syntax = true;
......
......@@ -66,7 +66,7 @@ class InterpreterTester {
feedback_vector_(feedback_vector) {
i::FLAG_ignition = true;
i::FLAG_ignition_fake_try_catch = true;
i::FLAG_ignition_fallback_on_eval_and_catch = false;
i::FLAG_ignition_fallback_on_catch = false;
i::FLAG_always_opt = false;
// Set ignition filter flag via SetFlagsFromString to avoid double-free
// (or potential leak with StrDup() based on ownership confusion).
......
......@@ -760,6 +760,7 @@
'arguments-load-across-eval': [SKIP],
'arguments-read-and-assignment': [SKIP],
'array-bounds-check-removal': [SKIP],
'array-constructor': [SKIP],
'array-functions-prototype-misc': [SKIP],
'array-join': [SKIP],
'array-literal-feedback': [SKIP],
......@@ -805,12 +806,15 @@
'cross-realm-filtering': [SKIP],
'cyclic-array-to-string': [SKIP],
'd8-worker-sharedarraybuffer': [SKIP],
'declare-locally': [SKIP],
'delete-in-with': [SKIP],
'deopt-minus-zero': [SKIP],
'deserialize-optimize-inner': [SKIP],
'double-equals': [SKIP],
'eval-enclosing-function-name': [SKIP],
'eval': [SKIP],
'eval-stack-trace': [SKIP],
'eval-typeof-non-existing': [SKIP],
'fast-prototype': [SKIP],
'field-type-tracking': [SKIP],
'for-in-opt': [SKIP],
......@@ -819,10 +823,13 @@
'get-caller-js-function': [SKIP],
'get-prototype-of': [SKIP],
'getter-in-prototype': [SKIP],
'global-const-var-conflicts': [SKIP],
'global-hash': [SKIP],
'global-load-from-eval-in-with': [SKIP],
'global-load-from-nested-eval': [SKIP],
'global-vars-with': [SKIP],
'instanceof-2': [SKIP],
'invalid-lhs': [SKIP],
'json-replacer-number-wrapper-tostring': [SKIP],
'json-replacer-order': [SKIP],
'json': [SKIP],
......@@ -833,6 +840,7 @@
'mirror-object': [SKIP],
'object-literal-gc': [SKIP],
'osr-elements-kind': [SKIP],
'override-read-only-property': [SKIP],
'property-load-across-eval': [SKIP],
'proto-accessor': [SKIP],
'readonly': [SKIP],
......@@ -848,11 +856,16 @@
'regress/regress-1125': [SKIP],
'regress/regress-1129': [SKIP],
'regress/regress-1170187': [SKIP],
'regress/regress-1170': [SKIP],
'regress/regress-117409': [SKIP],
'regress/regress-1177809': [SKIP],
'regress/regress-1178598': [SKIP],
'regress/regress-119609': [SKIP],
'regress/regress-1199637': [SKIP],
'regress/regress-1200351': [SKIP],
'regress/regress-123919': [SKIP],
'regress/regress-124594': [SKIP],
'regress/regress-124': [SKIP],
'regress/regress-125515': [SKIP],
'regress/regress-128018': [SKIP],
'regress/regress-131994': [SKIP],
......@@ -861,6 +874,7 @@
'regress/regress-1369': [SKIP],
'regress/regress-1412': [SKIP],
'regress/regress-1436': [SKIP],
'regress/regress-147497': [SKIP],
'regress/regress-1493017': [SKIP],
'regress/regress-1523': [SKIP],
'regress/regress-1560': [SKIP],
......@@ -872,6 +886,7 @@
'regress/regress-1757': [SKIP],
'regress/regress-1790': [SKIP],
'regress/regress-1853': [SKIP],
'regress/regress-186': [SKIP],
'regress/regress-1980': [SKIP],
'regress/regress-2054': [SKIP],
'regress/regress-2071': [SKIP],
......@@ -881,6 +896,7 @@
'regress/regress-2339': [SKIP],
'regress/regress-2374': [SKIP],
'regress/regress-2593': [SKIP],
'regress/regress-259': [SKIP],
'regress/regress-2618': [SKIP],
'regress/regress-263': [SKIP],
'regress/regress-265': [SKIP],
......@@ -919,10 +935,14 @@
'regress/regress-403292': [SKIP],
'regress/regress-410912': [SKIP],
'regress/regress-4121': [SKIP],
'regress/regress-4169': [SKIP],
'regress/regress-419663': [SKIP],
'regress/regress-4214': [SKIP],
'regress/regress-4255-4': [SKIP],
'regress/regress-430201b': [SKIP],
'regress/regress-430201': [SKIP],
'regress/regress-4309-1': [SKIP],
'regress/regress-4309-2': [SKIP],
'regress/regress-4309-3': [SKIP],
'regress/regress-4320': [SKIP],
'regress/regress-4325': [SKIP],
......@@ -939,6 +959,7 @@
'regress/regress-453481': [SKIP],
'regress/regress-4534': [SKIP],
'regress/regress-454725': [SKIP],
'regress/regress-455207': [SKIP],
'regress/regress-457935': [SKIP],
'regress/regress-470804': [SKIP],
'regress/regress-476488': [SKIP],
......@@ -958,6 +979,7 @@
'regress/regress-806473': [SKIP],
'regress/regress-842017': [SKIP],
'regress/regress-84234': [SKIP],
'regress/regress-88591': [SKIP],
'regress/regress-88858': [SKIP],
'regress/regress-94425': [SKIP],
'regress/regress-94873': [SKIP],
......@@ -971,6 +993,7 @@
'regress/regress-arguments-gc': [SKIP],
'regress/regress-assignment-in-test-context': [SKIP],
'regress/regress-bce-underflow': [SKIP],
'regress/regress-builtinbust-7': [SKIP],
'regress/regress-cnlt-elements': [SKIP],
'regress/regress-cnlt-enum-indices': [SKIP],
'regress/regress-cntl-descriptors-enum': [SKIP],
......@@ -978,11 +1001,13 @@
'regress/regress-convert-enum': [SKIP],
'regress/regress-crbug-109362': [SKIP],
'regress/regress-crbug-119800': [SKIP],
'regress/regress-crbug-135008': [SKIP],
'regress/regress-crbug-163530': [SKIP],
'regress/regress-crbug-229923': [SKIP],
'regress/regress-crbug-242502': [SKIP],
'regress/regress-crbug-242924': [SKIP],
'regress/regress-crbug-245480': [SKIP],
'regress/regress-crbug-259300': [SKIP],
'regress/regress-crbug-350864': [SKIP],
'regress/regress-crbug-351262': [SKIP],
'regress/regress-crbug-352058': [SKIP],
......@@ -1000,6 +1025,7 @@
'regress/regress-crbug-431602': [SKIP],
'regress/regress-crbug-432493': [SKIP],
'regress/regress-crbug-450642': [SKIP],
'regress/regress-crbug-451770': [SKIP],
'regress/regress-crbug-455644': [SKIP],
'regress/regress-crbug-465298': [SKIP],
'regress/regress-crbug-467180': [SKIP],
......@@ -1012,8 +1038,11 @@
'regress/regress-crbug-487289': [SKIP],
'regress/regress-crbug-489293': [SKIP],
'regress/regress-crbug-489597': [SKIP],
'regress/regress-crbug-498022': [SKIP],
'regress/regress-crbug-498142': [SKIP],
'regress/regress-crbug-501809': [SKIP],
'regress/regress-crbug-503968': [SKIP],
'regress/regress-crbug-504729': [SKIP],
'regress/regress-crbug-506443': [SKIP],
'regress/regress-crbug-507070': [SKIP],
'regress/regress-crbug-517592': [SKIP],
......@@ -1049,6 +1078,7 @@
'regress/regress-transcendental': [SKIP],
'regress/regress-typedarray-length': [SKIP],
'regress/splice-missing-wb': [SKIP],
'scope-calls-eval': [SKIP],
'shift-for-integer-div': [SKIP],
'simple-constructor': [SKIP],
'sparse-array-reverse': [SKIP],
......@@ -1072,10 +1102,6 @@
'with-prototype': [SKIP],
'with-readonly': [SKIP],
'with-value': [SKIP],
'regress/regress-builtinbust-7': [SKIP],
'regress/regress-crbug-451770': [SKIP],
'regress/regress-crbug-503968': [SKIP],
'regress/regress-crbug-504729': [SKIP],
}], # ignition == True
['ignition == True and (arch == arm or arch == arm64)', {
......@@ -1087,6 +1113,7 @@
'compiler/osr-nested': [SKIP],
'compiler/osr-one': [SKIP],
'compiler/osr-two': [SKIP],
'copy-on-write-assert': [SKIP],
'mul-exhaustive-part*': [SKIP],
'regress/regress-1257': [SKIP],
'regress/regress-165637': [SKIP],
......
......@@ -605,6 +605,7 @@
'built-ins/Array/prototype/toString/S15.4.4.2_A1_T4': [SKIP],
'built-ins/Date/15.9.1.15-1': [SKIP],
'built-ins/Date/prototype/toISOString/15.9.5.43-0-13': [SKIP],
'built-ins/eval/S15.1.2.1_A3.3_T4': [SKIP],
'built-ins/JSON/stringify/*': [SKIP],
'built-ins/Object/defineProperty/15.2.3.6-4-625gs': [SKIP],
'built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A12': [SKIP],
......@@ -640,6 +641,7 @@
'language/default-parameters/class-definitions': [SKIP],
'language/default-parameters/generators': [SKIP],
'language/default-parameters/param-ref-uninitialized': [SKIP],
'language/eval-code/10.4.2-1-4': [SKIP],
'language/expressions/delete/11.4.1-4.a-5': [SKIP],
'language/expressions/delete/11.4.1-4.a-6': [SKIP],
'language/expressions/object/method-definition/name-prop-name-yield-expr': [SKIP],
......@@ -655,6 +657,7 @@
'language/identifier-resolution/S10.2.2_A1_T7': [SKIP],
'language/identifier-resolution/S10.2.2_A1_T8': [SKIP],
'language/identifier-resolution/S10.2.2_A1_T9': [SKIP],
'language/line-terminators/S7.3_A3.1_T1': [SKIP],
'language/object-literal/concise-generator': [SKIP],
'language/object-literal/getter': [SKIP],
'language/object-literal/method': [SKIP],
......
......@@ -42,7 +42,7 @@ ALL_VARIANT_FLAGS = {
"turbofan_opt": [["--turbo", "--always-opt"]],
"nocrankshaft": [["--nocrankshaft"]],
"ignition": [["--ignition", "--turbo", "--ignition-fake-try-catch",
"--ignition-fallback-on-eval-and-catch"]],
"--ignition-fallback-on-catch"]],
"preparser": [["--min-preparse-length=0"]],
}
......@@ -53,7 +53,7 @@ FAST_VARIANT_FLAGS = {
"turbofan": [["--turbo"]],
"nocrankshaft": [["--nocrankshaft"]],
"ignition": [["--ignition", "--turbo", "--ignition-fake-try-catch",
"--ignition-fallback-on-eval-and-catch"]],
"--ignition-fallback-on-catch"]],
"preparser": [["--min-preparse-length=0"]],
}
......
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