|
From: | Paul Eggert |
Subject: | Re: MPS signals and Emacs |
Date: | Mon, 22 Apr 2024 12:41:49 -0700 |
User-agent: | Mozilla Thunderbird |
On 2024-04-22 00:49, Gerd Möllmann wrote:
There are ambigupus and there are exact referenes. An object references from at least one ambiguos reference cannot be moved, others can.
It's not merely a question of ambiguous vs exact references. It's also a question of hashing.
For example, the Emacs Lisp internals hash references with low-level functions like sxhash_eq's call to XHASH, to implement functions like make-hash-table. If exact references are moved, hashing them won't work because their XHASH values will change. Does the MPS branch use exact references for any Lisp object visible to the Elisp programmer? If so, won't there be subtle bugs with make-hash-table and the like? Or does the MPS branch work around this issue by rebuilding every hash table after a GC?
Also, does the MPS branch have similar workarounds for every other place the C code uses XHASH, XLI, XPNTR, etc.? For example, suppose GC occurs during sort_overlays, so that compare_overlays (which uses XLI) is no longer a total ordering, which means qsort has undefined behavior?
[Prev in Thread] | Current Thread | [Next in Thread] |