I'm using GNU Emacs 126.96.36.199 (x86_64-pc-linux-gnu, GTK+ Version 2.18.0) and start my Emacs session inside GNU screen. Since I upgraded to Ubuntu 10.04 and the version of
emacs-snapshot there I encounter some problems. Sometimes Emacs hogs all RAM plus the same amount of swap space (2+2GB) and also eats all CPU time. When I send the process a SIGTERM the process stops to eat CPU time, but the huge allocated amount of memory stays. Emacs itself doesn't take any key sequences. So usually I send the process a SIGKILL and it dies.
Now I want to find out where the bug (if there is one) is located and want to do some debugging. I can see no special reason for this behavior. Sometimes it starts after Emacs is freshly started, sometimes I can work a whole day without problems, sometimes it happens in between. So I'm looking for a kind of debugging or monitoring the process. I tried
strace, but this generates too much output. Strace output of a editing session should easily fill my whole harddrive. Running Emacs inside gdb should also not work, because if I remember correctly Ubuntu builds the software without debugging symbols. So do you have any advice how I can find the (possible) bug? What would you suggest?