Subject: bug#77240: 30.1; Native-comp causing large memory leak

From: Andrea Corallo <[email-masked]>
Date: Mon, 31 Mar 2025 09:23:20 -0400

N Winkel <[email-masked]> writes:

> On 24/03/2025 21:24, Andrea Corallo wrote: 
>
>  My impression is that you are just observing libgccjit running in
> background while we are populating the eln cache.  How long have you
> tried waiting for the compilation to finish (and the memory to be
> released) before coming to the conlusion this is a memory leak?
>
> I've waited until all the memory my system has was full, this was
> emacs using over 10G of memory, with no indication of the increase
> slowing, even though no further .eln files were being compiled.
> Can I somehow check if libgccjit is still running?

I think the expected observation would be like:

1- you have your Emacs process X running, there the mem consumption is
normal.

2- you observe a process Y (child of X) which is another Emacs, this one
is the one doing the actual compilation and is supposed to be the one
going overboard with memory allocation.

Profiling memory allocation in process Y should reveal who it's actually
allocating.

  Andrea