Cursor blinking vigorously in emacs -nw when using rust + lsp

What happened?

When I use emacs in terminal mode I get weird behaviour. When I have one buffer open of a rust project then everything is fine, however a moment when I open two buffers of the same project side-by-side the cursor starts blinking vigorously and the UI gets sloppy (with one file it is on par with neovim, but when it starts blinking it just can’t keep up with me typing).

I have had the same issue with basically vanilla doom just +rust with LSP enabled. Now I am using eglot with eglot-booster which somewhat helps the slowness, but the cursor still blinks vigorously so I suspect some processing still occurs. I’ve tried profiling (attaching it below…) but it is not obvious to me what it could be.

What did you expect to happen?

I expect no different behaviour to single buffer vs multiple buffers open.

Steps to reproduce

  1. run emacs -nw
  2. add +rust +lsp into init.el
  3. open rust project
  4. open two buffers with different files from the project and observe the cursor going nuts and general slowness of UI.

System information


Loading data dump...

Profiler output

This is when only one buffer is open.


Loading data dump...

This is when two buffers are open and cursor is blinking vigorously.


Loading data dump...