diff options
author | Ryan Dahl <ry@tinyclouds.org> | 2020-01-30 10:49:33 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-01-30 10:49:33 -0500 |
commit | 2338e7679c8840314642dbf3ea838908f5f35d3c (patch) | |
tree | fd8a56d12bc84167e306fb7fdf71a32ab86362ad /cli/lib.rs | |
parent | 51089836eb835d6b4cc03653dcb0b7a281017157 (diff) |
Remove --current-thread flag (#3830)
This flag was added to evaluate performance relative to tokio's threaded
runtime. Although it's faster in the HTTP benchmark, it's clear the runtime
is not the only perf problem.
Removing this flag will simplify further refactors, in particular
adopting the #[tokio::main] macro. This will be done in a follow up.
Ultimately we expect to move to the current thread runtime with Isolates
pinned to specific threads, but that will be a much larger refactor. The
--current-thread just complicates that effort.
Diffstat (limited to 'cli/lib.rs')
-rw-r--r-- | cli/lib.rs | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/cli/lib.rs b/cli/lib.rs index fe20cd135..7a0d66cf5 100644 --- a/cli/lib.rs +++ b/cli/lib.rs @@ -378,7 +378,6 @@ fn run_repl(flags: DenoFlags) { } fn run_script(flags: DenoFlags) { - let use_current_thread = flags.current_thread; let (mut worker, state) = create_worker_and_state(flags); let maybe_main_module = state.main_module.as_ref(); @@ -416,11 +415,7 @@ fn run_script(flags: DenoFlags) { js_check(worker_.execute("window.dispatchEvent(new Event('unload'))")); }; - if use_current_thread { - tokio_util::run_on_current_thread(main_future); - } else { - tokio_util::run(main_future); - } + tokio_util::run(main_future); } fn format_command(files: Option<Vec<String>>, check: bool) { |