GNU bug report logs - #79023
30.1.90; Suspicion of memory leak on internal_redisplay (MacOS)

Previous Next

Package: emacs;

Reported by: Przemysław Alexander Kamiński <przemyslaw <at> kaminski.se>

Date: Tue, 15 Jul 2025 07:14:01 UTC

Severity: normal

Found in version 30.1.90

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Przemysław Alexander Kamiński <alexander <at> kaminski.se>
Cc: rudolf <at> adamkovic.org, 79023 <at> debbugs.gnu.org
Subject: bug#79023: 30.1.90; Suspicion of memory leak on internal_redisplay (MacOS)
Date: Mon, 11 Aug 2025 16:36:27 +0300
> From: Przemysław Alexander Kamiński
>  <alexander <at> kaminski.se>
> Cc: 79023 <at> debbugs.gnu.org
> Date: Mon, 11 Aug 2025 14:09:21 +0200
> 
> 
> I was doing some allocation debugging (it's a build with render block &
> release fixes). It seems I found the problem (30 minute non -Q instance).
> 
>  654.03 MB      69.0%	44835	 	macfont_list
>  654.03 MB      69.0%	44835	 	 font_list_entities
>  654.03 MB      69.0%	44835	 	  font_find_for_lface
>  489.50 MB      51.6%	44541	 	   fontset_find_font
>  489.50 MB      51.6%	44541	 	    fontset_font
>  489.50 MB      51.6%	44541	 	     face_for_char
>  305.78 MB      32.2%	5658	 	      FACE_FOR_CHAR
>  179.89 MB      18.9%	172	 	      FACE_FOR_CHAR
>  164.53 MB      17.3%	294	 	   font_load_for_lface
> 
> I have approx. 500 different fonts which I suppose would explain 10KB
> per allocation. I will check if I can release those cleanly.

This is supposed to cons a list (a Lisp_Object) of relevant fonts,
which is then reclaimed by GC after face_for_char returns (because
there are no references to it).  Is that not what happens on macOS?




This bug report was last modified 1 day ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.