From 2f565b1ae65c5822c8741ec5ff62aa1bb093545e Mon Sep 17 00:00:00 2001 From: Matthew Gaudet Date: Tue, 2 Aug 2022 13:41:01 +0000 Subject: [PATCH] Bug 1782271 - Remove Warp async and generator options r=bthrall Differential Revision: https://phabricator.services.mozilla.com/D153231 --- js/src/jit-test/tests/warp/bug1683306.js | 2 +- js/src/jit-test/tests/warp/bug1683309.js | 5 ++--- js/src/jit-test/tests/warp/bug1683614.js | 5 ++--- js/src/jit/Ion.cpp | 10 ---------- js/src/jit/JitOptions.cpp | 6 ------ js/src/jit/JitOptions.h | 2 -- js/src/shell/fuzz-flags.txt | 4 ---- js/src/shell/js.cpp | 23 ----------------------- 8 files changed, 5 insertions(+), 52 deletions(-) diff --git a/js/src/jit-test/tests/warp/bug1683306.js b/js/src/jit-test/tests/warp/bug1683306.js index 8d07524274ea..3c74c3f6125e 100644 --- a/js/src/jit-test/tests/warp/bug1683306.js +++ b/js/src/jit-test/tests/warp/bug1683306.js @@ -1,4 +1,4 @@ -// |jit-test| --ion-offthread-compile=off; --ion-full-warmup-threshold=0; --ion-gvn=off; --warp-async; --baseline-eager +// |jit-test| --ion-offthread-compile=off; --ion-full-warmup-threshold=0; --ion-gvn=off; --baseline-eager // // Bug 1683306 - Assertion failure: !genObj->hasStackStorage() || genObj->isStackStorageEmpty(), at vm/GeneratorObject.cpp:144 diff --git a/js/src/jit-test/tests/warp/bug1683309.js b/js/src/jit-test/tests/warp/bug1683309.js index 097bed26220d..63a0defe4efb 100644 --- a/js/src/jit-test/tests/warp/bug1683309.js +++ b/js/src/jit-test/tests/warp/bug1683309.js @@ -1,8 +1,7 @@ -// |jit-test| slow; --ion-offthread-compile=off; --warp-async +// |jit-test| slow; --ion-offthread-compile=off; // // Bug 1683309: Assertion failure: [barrier verifier] Unmarked edge: JS Object 0xebbb6d1dee0 'object slot' edge to JS Object 0xebbb6d29f60, at gc/Verifier.cpp:392 -// -// The following testcase crashes on mozilla-central revision 20201217-2ab4142f19bc (debug build, run with --ion-offthread-compile=off --warp-async): + if (helperThreadCount() > 0) { evalInWorker(` diff --git a/js/src/jit-test/tests/warp/bug1683614.js b/js/src/jit-test/tests/warp/bug1683614.js index ffaeaf1196af..1d0a4724ff61 100644 --- a/js/src/jit-test/tests/warp/bug1683614.js +++ b/js/src/jit-test/tests/warp/bug1683614.js @@ -1,6 +1,5 @@ -// |jit-test| --ion-offthread-compile=off; --ion-full-warmup-threshold=0; --warp-async; --baseline-eager; skip-if: !this.hasOwnProperty("ReadableStream") -// -// The following testcase crashes on mozilla-central revision 20201219-3262affdccf6 (debug build, run with --fuzzing-safe --ion-offthread-compile=off --ion-full-warmup-threshold=0 --warp-async --baseline-eager): +// |jit-test| --ion-offthread-compile=off; --ion-full-warmup-threshold=0; --baseline-eager; skip-if: !this.hasOwnProperty("ReadableStream") + gczeal(9, 8); function s() { } new ReadableStream({ diff --git a/js/src/jit/Ion.cpp b/js/src/jit/Ion.cpp index 38c7e96dedd3..a8b2b2829400 100644 --- a/js/src/jit/Ion.cpp +++ b/js/src/jit/Ion.cpp @@ -1690,17 +1690,7 @@ static bool CanIonCompileOrInlineScript(JSScript* script, const char** reason) { return false; } - if (script->isGenerator() && !JitOptions.warpGenerator) { - *reason = "generator script"; - return false; - } - if (script->isAsync()) { - if (!JitOptions.warpAsync) { - *reason = "async script"; - return false; - } - if (script->isModule()) { *reason = "async module"; return false; diff --git a/js/src/jit/JitOptions.cpp b/js/src/jit/JitOptions.cpp index 735ec05ee5a3..248ec77aab9c 100644 --- a/js/src/jit/JitOptions.cpp +++ b/js/src/jit/JitOptions.cpp @@ -129,12 +129,6 @@ DefaultJitOptions::DefaultJitOptions() { // Whether the IonMonkey JIT is enabled. SET_DEFAULT(ion, true); - // Warp compile Async functions - SET_DEFAULT(warpAsync, true); - - // Warp compile Generator functions - SET_DEFAULT(warpGenerator, true); - // Whether the IonMonkey and Baseline JITs are enabled for Trusted Principals. // (Ignored if ion or baselineJit is set to true.) SET_DEFAULT(jitForTrustedPrincipals, false); diff --git a/js/src/jit/JitOptions.h b/js/src/jit/JitOptions.h index 4565320e420a..b42694b84f3f 100644 --- a/js/src/jit/JitOptions.h +++ b/js/src/jit/JitOptions.h @@ -63,8 +63,6 @@ struct DefaultJitOptions { bool baselineInterpreter; bool baselineJit; bool ion; - bool warpAsync; - bool warpGenerator; bool jitForTrustedPrincipals; bool nativeRegExp; bool forceInlineCaches; diff --git a/js/src/shell/fuzz-flags.txt b/js/src/shell/fuzz-flags.txt index 187d32a2b17a..4ef23c103827 100644 --- a/js/src/shell/fuzz-flags.txt +++ b/js/src/shell/fuzz-flags.txt @@ -48,10 +48,6 @@ --spectre-mitigations=on --more-compartments --fast-warmup ---warp-generator ---warp-async ---no-warp-generator ---no-warp-async --large-arraybuffers --no-jit-backend --enable-watchtower diff --git a/js/src/shell/js.cpp b/js/src/shell/js.cpp index 5ddd02033b73..994fe483abdd 100644 --- a/js/src/shell/js.cpp +++ b/js/src/shell/js.cpp @@ -11359,22 +11359,6 @@ static bool SetContextOptions(JSContext* cx, const OptionParser& op) { jit::JitOptions.baselineJit = false; } - if (op.getBoolOption("no-warp-async")) { - jit::JitOptions.warpAsync = false; - } - - if (op.getBoolOption("no-warp-generator")) { - jit::JitOptions.warpGenerator = false; - } - - if (op.getBoolOption("warp-async")) { - jit::JitOptions.warpAsync = true; - } - - if (op.getBoolOption("warp-generator")) { - jit::JitOptions.warpGenerator = true; - } - if (op.getBoolOption("no-ion")) { jit::JitOptions.ion = false; } @@ -12224,13 +12208,6 @@ int main(int argc, char** argv) { !op.addBoolOption('\0', "baseline", "Enable baseline compiler (default)") || !op.addBoolOption('\0', "no-baseline", "Disable baseline compiler") || - !op.addBoolOption('\0', "no-warp-async", - "Don't Warp compile Async Functions") || - !op.addBoolOption('\0', "no-warp-generator", - "Warp compile Generator Functions") || - !op.addBoolOption('\0', "warp-async", "Warp compile Async Functions") || - !op.addBoolOption('\0', "warp-generator", - "Don't Warp compile Generator Functions") || !op.addBoolOption('\0', "baseline-eager", "Always baseline-compile methods") || !op.addIntOption(