emacs-devel
[Top][All Lists]
Advanced

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

Re: emacs reproducible builds part1 of 2 : eln


From: Andrea Corallo
Subject: Re: emacs reproducible builds part1 of 2 : eln
Date: Sat, 10 Feb 2024 11:35:27 -0500
User-agent: Gnus/5.13 (Gnus v5.13)

Okay did some more investigation on this and I think I've a decent
understanding of the problem, this is not related to the printer but is
entirely on the native compiler.

When we compile 'vendor-specific-keysyms' the native compiler is doing
its value type propagation collecting all possible return values.

This function is returning various possible different lists.

We collect all possible return values iterating over the basic blocks of
the functions, these are stored in hash table so we walk order is I
believe *not* deterministic.  That's the source of the trouble because
these lists gets collected (and then stored into the function type)
inside the eln.

With other type of objects we normalize the list of possible returned
objects (ex symbols) sorting them, but how to do it with list?

Option 1 would be to ignore completly objects behind conses and just
propagating the type (cons).  IOW going from:

(subr-type (native-compile '(lambda (x)
                              (if x
                                  '(1 2)
                                '(2 3)))))

=> (function (t) (member (1 2) (2 3)))

to

=> (function (t) cons)

Option 2 is to sort those lists to keep the computed function type
stable over different compilation runs.

BTW IIUC CL goes for option 1 [1] but at the time I thought it was easy
(and nice as well) to support the full object behind the cons.  Was it a
bad idea?

Thanks

  Andrea

[1] <http://clhs.lisp.se/Body/t_member.htm>



reply via email to

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