guile-devel
[Top][All Lists]
Advanced

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

Re: Weak tables harmful to GC?


From: Ludovic Courtès
Subject: Re: Weak tables harmful to GC?
Date: Sat, 21 Oct 2017 18:52:32 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux)

Hello!

address@hidden (Ludovic Courtès) skribis:

> All in all, given that these issues are very likely causes of the
> execution time and memory consumption issues that plague the compiler
> (where we have huge symbol and source property tables), I’m in favor of
> switching back to the 2.0 implementation of weak hash tables.  That can
> be done in an API-compatible way, I think.

The patch below reverts to the 2.0 bucket-and-weak-lists weak hash
tables.

On my benchmark, which calls ‘emit-bytecode’ on a huge piece of code
(corresponding to (gnu packages python)), it runs ~18% faster than
current 2.2; memory usage is reduced by only ~3% at the end.

It appears to work well except under stress: a tight loop as in
<https://bugs.gnu.org/28590> easily triggers the “weak hash table
corruption” message or an assertion failure.

To be continued…

Ludo’.

Attachment: 0001-Remove-weak-tables-and-revert-to-weak-hash-tables.patch
Description: Text Data


reply via email to

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