Hi,

On 27-02-2025 13:52, Paul Gevers wrote:
On 27-02-2025 13:23, Sean Whitton wrote:
Here are some more thoughts on top of trying emacs-pgtk from sid:

- Maybe actually it's only your compositor that is hanging, not actually
   the whole system.
   Can you SSH back into your own system from another one?


No, my laptop is my only device where I have a keyboard and screen attached.


I think you are right here. Today I had audio on and am using cpulimit to limit emacs to 20%. Today I found I can reliably (temporarily) hang my system with emacs-gtk, but not with emacs-pgtk. All I need to do is start emacs and press the down key long enough to go more than one line down (there is a delay between going down one line and scrolling further). Once the bottom of the buffer is reached, I hear a ping and if I keep pressing the pings come in high repetition (with some hickups once every so many seconds) and it seems that now my system is able to respond to my mouse with a huge delay (30 seconds or so). I'm not sure if before it would respond as well, or if this is due to the cpulimt. I wrote above "temporarily" because I had one occasion where waiting was enough to return to normal operation, so it seems to depend on how many "key down" presses needed to be processed. On an other occasion I waited 20 minutes or so before giving up and doing a hard reboot.

- If it really is hanging the whole system, use ulimit or some systemd
   mechanism to impose resource limits on Emacs, so that it can't make
   the entire system hang.


As described above, limiting emacs doesn't seem to solve the problem, so I think emacs-gtk triggers a problem in the composer (but emacs-pgtk doesn't).

A message I didn't spotted before in the journal is this one:
kwin_wayland_drm: The main thread was hanging temporarily!

- In either case, try to get gdb attached to it, and interrupt it, to
   try to find out what code it's in when it happens.  I.e. try to get a
   backtrace.  etc/DEBUG in src:emacs has some good information.


Let me try emacs from sid for some time and if that doesn't hang anymore, let's assume the issue got fixed. If not, I pursue these routes. Please be aware that I only used gdb before with explicit instructions on what to do, I'm not experienced with it at all.


I started one run of emacs with gdb, but once I triggered the hang, I didn't know how to get gdb to do anything, as my system wasn't responding.

Paul

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature

Reply via email to