mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
perf(ui_client): skip some initialization not necessary for ui client
In particular, TUI manages its own screen buffers and highlight table, so we don't need to run init_highlight() and default_grid_alloc() in the ui client process.
This commit is contained in:
parent
ab1c2220f0
commit
0d1bc795f8
@ -355,6 +355,12 @@ int main(int argc, char **argv)
|
|||||||
ui_client_channel_id = rv;
|
ui_client_channel_id = rv;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ui_client_channel_id) {
|
||||||
|
time_finish();
|
||||||
|
ui_client_run(remote_ui); // NORETURN
|
||||||
|
}
|
||||||
|
assert(!ui_client_channel_id && !use_builtin_ui);
|
||||||
|
|
||||||
TIME_MSG("expanding arguments");
|
TIME_MSG("expanding arguments");
|
||||||
|
|
||||||
if (params.diff_mode && params.window_count == -1) {
|
if (params.diff_mode && params.window_count == -1) {
|
||||||
@ -397,12 +403,6 @@ int main(int argc, char **argv)
|
|||||||
input_start();
|
input_start();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ui_client_channel_id) {
|
|
||||||
time_finish();
|
|
||||||
ui_client_run(remote_ui); // NORETURN
|
|
||||||
}
|
|
||||||
assert(!ui_client_channel_id && !use_builtin_ui);
|
|
||||||
|
|
||||||
// Wait for UIs to set up Nvim or show early messages
|
// Wait for UIs to set up Nvim or show early messages
|
||||||
// and prompts (--cmd, swapfile dialog, …).
|
// and prompts (--cmd, swapfile dialog, …).
|
||||||
bool use_remote_ui = (embedded_mode && !headless_mode);
|
bool use_remote_ui = (embedded_mode && !headless_mode);
|
||||||
|
Loading…
Reference in New Issue
Block a user