Modified: trunk/Source/_javascript_Core/ChangeLog (273778 => 273779)
--- trunk/Source/_javascript_Core/ChangeLog 2021-03-03 01:56:54 UTC (rev 273778)
+++ trunk/Source/_javascript_Core/ChangeLog 2021-03-03 02:02:22 UTC (rev 273779)
@@ -1,5 +1,18 @@
2021-03-02 Yusuke Suzuki <[email protected]>
+ Flaky JSC test: stress/shared-array-buffer-sort-while-different-thread-is-modifying.js.default
+ https://bugs.webkit.org/show_bug.cgi?id=221129
+
+ Reviewed by Saam Barati.
+
+ Speculative fix for JSC shell's termination handling change.
+
+ * jsc.cpp:
+ (CommandLine::CommandLine):
+ (jscmain):
+
+2021-03-02 Yusuke Suzuki <[email protected]>
+
[JSC] Remove ImpureProxyType
https://bugs.webkit.org/show_bug.cgi?id=222626
Modified: trunk/Source/_javascript_Core/jsc.cpp (273778 => 273779)
--- trunk/Source/_javascript_Core/jsc.cpp 2021-03-03 01:56:54 UTC (rev 273778)
+++ trunk/Source/_javascript_Core/jsc.cpp 2021-03-03 02:02:22 UTC (rev 273779)
@@ -413,9 +413,7 @@
}
enum CommandLineForWorkersTag { CommandLineForWorkers };
- CommandLine(CommandLineForWorkersTag)
- {
- }
+ explicit CommandLine(CommandLineForWorkersTag);
Vector<Script> m_scripts;
Vector<String> m_arguments;
@@ -436,6 +434,7 @@
void parseArguments(int, char**);
};
+static LazyNeverDestroyed<CommandLine> mainCommandLine;
static const char interactivePrompt[] = ">>> ";
@@ -3381,6 +3380,11 @@
jscExit(EXIT_SUCCESS);
}
+CommandLine::CommandLine(CommandLineForWorkersTag)
+ : m_treatWatchdogExceptionAsSuccess(mainCommandLine->m_treatWatchdogExceptionAsSuccess)
+{
+}
+
template<typename Func>
int runJSC(const CommandLine& options, bool isWorker, const Func& func)
{
@@ -3502,12 +3506,12 @@
// Note that the options parsing can affect VM creation, and thus
// comes first.
- CommandLine options(argc, argv);
+ mainCommandLine.construct(argc, argv);
{
Options::AllowUnfinalizedAccessScope scope;
processConfigFile(Options::configFile(), "jsc");
- if (options.m_dump)
+ if (mainCommandLine->m_dump)
Options::dumpGeneratedBytecodes() = true;
}
@@ -3574,18 +3578,18 @@
#endif
int result = runJSC(
- options, false,
+ mainCommandLine.get(), false,
[&] (VM& vm, GlobalObject* globalObject, bool& success) {
UNUSED_PARAM(vm);
#if PLATFORM(COCOA)
vm.setOnEachMicrotaskTick(WTFMove(onEachMicrotaskTick));
#endif
- runWithOptions(globalObject, options, success);
+ runWithOptions(globalObject, mainCommandLine.get(), success);
});
printSuperSamplerState();
- if (options.m_dumpMemoryFootprint) {
+ if (mainCommandLine->m_dumpMemoryFootprint) {
MemoryFootprint footprint = MemoryFootprint::now();
printf("Memory Footprint:\n Current Footprint: %" PRIu64 "\n Peak Footprint: %" PRIu64 "\n", footprint.current, footprint.peak);