bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#37006: 27.0.50; garbage collection not happening after 26de2d42


From: Eli Zaretskii
Subject: bug#37006: 27.0.50; garbage collection not happening after 26de2d42
Date: Sun, 11 Aug 2019 20:07:15 +0300

> From: Mattias Engdegård <mattiase@acm.org>
> Date: Sun, 11 Aug 2019 18:23:28 +0200
> Cc: Eli Zaretskii <eliz@gnu.org>, Paul Eggert <eggert@cs.ucla.edu>,
>         37006@debbugs.gnu.org
> 
> Observed on macOS as well. Reason: free_cons has the condition
> 
>  if (INT_ADD_WRAPV (consing_until_gc, sizeof *ptr, &consing_until_gc))
> 
> which will return true (overflow) if consing_until_gc is negative, which is 
> kind of defensible since sizeof is unsigned which causes the sum 
> (consing_until_gc + sizeof *ptr) to be a large unsigned number that doesn't 
> fit into consing_until_gc.
> 
> Clang 10 defines __GNUC__ to 4 which causes intprops.h to not use 
> __builtin_add_overflow despite that being present and working.
> 
> Casting the sizeof should fix it; patch attached.

I believe it should be fixed now.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]