GNU bug report logs -
#44701
28.0.50; [feature/native-comp] Use file-truename when building eln path hash
Previous Next
Reported by: Tad <tadfisher <at> gmail.com>
Date: Tue, 17 Nov 2020 04:25:01 UTC
Severity: normal
Found in version 28.0.50
Done: Andrea Corallo <akrl <at> sdf.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 44701 in the body.
You can then email your comments to 44701 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44701
; Package
emacs
.
(Tue, 17 Nov 2020 04:25:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Tad <tadfisher <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Tue, 17 Nov 2020 04:25:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
It appears that `comp-el-to-eln-filename` uses `expand-file-name` to
determine the absolute filename to
hash. When the filename is a symlink, this results in a cache miss
depending on which path is loaded.
`file-truename' would be the equivalent to `(expand-file-name name
nil)`, except that it would resolve to a
single canonical path (in the absence of hardlinks, which is pathological).
If I may ask, what is the purpose behind the path component of the
hash? I would think a content hash
would suffice to disambiguate files in the .el<->.eln bijection.
Thanks,
Tad
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44701
; Package
emacs
.
(Wed, 18 Nov 2020 08:29:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 44701 <at> debbugs.gnu.org (full text, mbox):
Hi Tad,
Tad <tadfisher <at> gmail.com> writes:
> It appears that `comp-el-to-eln-filename` uses `expand-file-name` to
> determine the absolute filename to
> hash. When the filename is a symlink, this results in a cache miss
> depending on which path is loaded.
>
> `file-truename' would be the equivalent to `(expand-file-name name
> nil)`, except that it would resolve to a
> single canonical path (in the absence of hardlinks, which is pathological).
It might be not 100% trivial as just calling `file-truename' from
`comp-el-to-eln-filename' in place of `expand-file-name'. ATM I'm not
sure is good to call Lisp from there. I'll give it a go.
> If I may ask, what is the purpose behind the path component of the
> hash? I would think a content hash
> would suffice to disambiguate files in the .el<->.eln bijection.
Sure we mainly use it to keep the eln-cache directory clean when
recompiling.
Thanks for reporting.
Andrea
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44701
; Package
emacs
.
(Wed, 18 Nov 2020 17:55:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 44701 <at> debbugs.gnu.org (full text, mbox):
Hi Tad,
could you verify 3ae309bd59 fix the issue for you?
Thanks!
Andrea
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#44701
; Package
emacs
.
(Wed, 18 Nov 2020 20:53:01 GMT)
Full text and
rfc822 format available.
Message #14 received at 44701 <at> debbugs.gnu.org (full text, mbox):
On Wed, Nov 18, 2020 at 9:54 AM Andrea Corallo <akrl <at> sdf.org> wrote:
>
> Hi Tad,
>
> could you verify 3ae309bd59 fix the issue for you?
Yes, this is working now. Here's a transcript:
(comp-el-to-eln-filename
"/nix/store/...-emacs-ace-window-20200606.1259/share/emacs/site-lisp/elpa/ace-window-20200606.1259/ace-window.el")
"/home/tad/.emacs.d/eln-cache/28.0.50-x86_64-pc-linux-gnu-6462edf10bdf79d2b67bce57511338e8/ace-window-d01e56e26487b663b5932fdce1c8c623-99728e8187c8762dea4b86e75d14412a.eln"
(comp-el-to-eln-filename
"/nix/store/...-emacs-packages-deps/share/emacs/site-lisp/elpa/ace-window-20200606.1259/ace-window.el")
"/home/tad/.emacs.d/eln-cache/28.0.50-x86_64-pc-linux-gnu-6462edf10bdf79d2b67bce57511338e8/ace-window-d01e56e26487b663b5932fdce1c8c623-99728e8187c8762dea4b86e75d14412a.eln"
This makes it possible to load AOT-compiled .eln files from the Nix
store, so thank you for implementing this change.
>
> Thanks!
>
> Andrea
Reply sent
to
Andrea Corallo <akrl <at> sdf.org>
:
You have taken responsibility.
(Wed, 18 Nov 2020 20:58:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Tad <tadfisher <at> gmail.com>
:
bug acknowledged by developer.
(Wed, 18 Nov 2020 20:58:01 GMT)
Full text and
rfc822 format available.
Message #19 received at 44701-done <at> debbugs.gnu.org (full text, mbox):
Tad <tadfisher <at> gmail.com> writes:
> This makes it possible to load AOT-compiled .eln files from the Nix
> store, so thank you for implementing this change.
That's good to hear! Thank you for reporting, closing.
Andrea
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 17 Dec 2020 12:24:04 GMT)
Full text and
rfc822 format available.
This bug report was last modified 4 years and 246 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.