this post was submitted on 24 Nov 2023
1 points (100.0% liked)

Emacs

311 readers
3 users here now

A community for the timeless and infinitely powerful editor. Want to see what Emacs is capable of?!

Get Emacs

Rules

  1. Posts should be emacs related
  2. Be kind please
  3. Yes, we already know: Google results for "emacs" and "vi" link to each other. We good.

Emacs Resources

Emacs Tutorials

Useful Emacs configuration files and distributions

Quick pain-saver tip

founded 1 year ago
MODERATORS
 

A "I just want no input lag no matter how many packages I install. Its a frigging editor after all!! Is that too much to ask??"

B "Yes. (it's an OS btw)"

A "Sigh."

top 16 comments
sorted by: hot top controversial new old
[–] nv-elisp@alien.top 1 points 10 months ago (1 children)

So stop sighing and start profiling.

[–] NotFromSkane@alien.top 1 points 10 months ago (3 children)

The issue is almost always the gui, not any package. Input latency in the gui is awful but it's fine in the tui

[–] rileyrgham@alien.top 1 points 10 months ago

There's a different read loop? I've not really noticed a difference tbh.

[–] geza42@alien.top 1 points 10 months ago

That is not true. There are some features which makes only the GUI version slower, but it's definitely not "almost always" that the GUI is the reason. There are a lot of features/packages which makes Emacs slower in general, no matter GUI/TUI.

So profiling, or bisecting the init file can be used find out the problem.

[–] sunnyata@alien.top 1 points 10 months ago

B "Yes. (it's an OS btw)"

Haha, I absolutely hate it when people say that.

A "How can it be an OS if it hasn't got a scheduler?"

B "Doesn't need one, it hasn't got threads."

(I get zero lag myself BTW unless I'm connecting to an LSP server or something like that. Not since I gave up on using it for email anyway.)

[–] zoechi@alien.top 1 points 10 months ago

I didn't have any such issues since binary compilation became available.

[–] xpusostomos@alien.top 1 points 10 months ago

Unless the package is a mode that's actually active, I can't see why packages would cause input lag.

[–] camber-weaver@alien.top 1 points 10 months ago (1 children)

I've noticed I have a lot of latency right after startup and the thing which seems to help is a manual garbage collect. That's bit odd because the last thing I do in my config is set a 5 second timer which is fed a lambda to run a gc after the timer expires. Regardless, I still have better results if I run the gc manually.

I do load of metric ass ton of packages (and modes) and I recursively parse my Org/Org Roam directory for org-agenda items so I'm doing a lot of questionable things.

As others have said, sounds like we might both benefit by spending some quality time with the profiler.

[–] camber-weaver@alien.top 1 points 10 months ago

As a minimal effort first attempts, I just installed XanMod kernel. If that makes a noticeable impact I will loop back here to report.

[–] electricity-wizard@alien.top 1 points 10 months ago

I had some latency and stuttering after 29 I started using gcmh and it works much better. Hopefully that will help you

[–] bravosierrasierra@alien.top 1 points 10 months ago

flyspell on large org-file give serious input lag

[–] ispinfx@alien.top 1 points 10 months ago

Your eternal Emacs friend.

[–] TeaTortoise@alien.top 1 points 10 months ago

Two questions about your situation.

  1. How old is your computer? Does it have a decent amount of both processor speed and RAM?
  2. How large are the files that you have open that are giving you lag?

I am nowhere near a power user as I use only emacs for Org-Mode but even with a few of my insanely large PIM files (BookNotes.org which contains the notes and highlights to every every nonfiction books I have read in the last 10+ years) I have never encountered any lag in emacs.