Package: emacs;
Reported by: Andy Moreton <andrewjmoreton <at> gmail.com>
Date: Sat, 21 Jan 2023 22:13:02 UTC
Severity: normal
Found in version 29.0.60
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
View this message in rfc822 format
From: help-debbugs <at> gnu.org (GNU bug Tracking System) To: Andy Moreton <andrewjmoreton <at> gmail.com> Subject: bug#60996: closed (Re: bug#60996: 29.0.60; Native compile fails to remove temp file for trampoline) Date: Thu, 26 Jan 2023 06:52:02 +0000
[Message part 1 (text/plain, inline)]
Your bug report #60996: 29.0.60; Native compile fails to remove temp file for trampoline which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 60996 <at> debbugs.gnu.org. -- 60996: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=60996 GNU Bug Tracking System Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Eli Zaretskii <eliz <at> gnu.org> To: Andy Moreton <andrewjmoreton <at> gmail.com> Cc: 60996-done <at> debbugs.gnu.org Subject: Re: bug#60996: 29.0.60; Native compile fails to remove temp file for trampoline Date: Thu, 26 Jan 2023 08:51:49 +0200> From: Andy Moreton <andrewjmoreton <at> gmail.com> > Date: Wed, 25 Jan 2023 23:49:04 +0000 > > On Wed 25 Jan 2023, Eli Zaretskii wrote: > > > Before we close this, I suggest that you try reproducing again, after > > removing the *.eln files from your eln-cache. Basically, as more and > > more *.eln files are produced and deposited there, the lower the > > probability of seeing any problems with native compilation, since > > Emacs stops compiling stuff because it already has what it needs. > > I tried various combinations of cleaning the .eln cache, bootstrap from > a clean tree etc, and leaving or removing trampoline .eln files from > %TEMP% and did not get a reproducibe effect. > > > > (But if you already tried that and still failed, then OK, let's close > > this issue.) > > I also tried running with anti-virus disabled (in case that affected > filesystem activity or timing) without any change. > > Please close this, and we can start again if the problem reappears. OK, done. Thanks for your efforts in trying to decipher this.
[Message part 3 (message/rfc822, inline)]
From: Andy Moreton <andrewjmoreton <at> gmail.com> To: bug-gnu-emacs <at> gnu.org Subject: 29.0.60; Native compile fails to remove temp file for trampoline Date: Sat, 21 Jan 2023 22:12:10 +0000Recently emacs 29 (and master) has started showing an error and backtrace during startup: Debugger entered--Lisp error: (permission-denied "Removing old name" "Permission denied" "c:/Users/ajm/AppData/Local/Temp/comp-lambda-MTAMbr...") delete-file("c:/Users/ajm/AppData/Local/Temp/comp-lambda-MTAMbr...") #f(compiled-function () #<bytecode 0xb2aa5c0c9e24501>)() comp--native-compile((lambda (arg0 &optional arg1 arg2 arg3) (let ((f #'format-mode-line)) (funcall f arg0 arg1 arg2 arg3))) nil nil) comp-trampoline-compile(format-mode-line) comp-subr-trampoline-install(format-mode-line) advice--add-function(:around (#f(compiled-function () #<bytecode 0x3c5d8019df7e91>) . #f(compiled-function (gv--val) #<bytecode 0x8fdecbbba7cb3c2>)) delight--format-mode-line nil) advice-add(format-mode-line :around delight--format-mode-line) require(delight nil t) (not (require 'delight nil t)) (if (not (require 'delight nil t)) (display-warning 'use-package (format "Cannot load %s" 'delight) :error)) (prog1 (if (not (require 'delight nil t)) (display-warning 'use-package (format "Cannot load %s" 'delight) :error)) (let ((elapsed (float-time (time-subtract (current-time) now)))) (if (> elapsed 0.1) (message "%s...done (%.3fs)" "Loading package delight" elapsed) (message "%s...done" "Loading package delight")))) (let ((now (current-time))) (message "%s..." "Loading package delight") (prog1 (if (not (require 'delight nil t)) (display-warning 'use-package (format "Cannot load %s" 'delight) :error)) (let ((elapsed (float-time (time-subtract (current-time) now)))) (if (> elapsed 0.1) (message "%s...done (%.3fs)" "Loading package delight" elapsed) (message "%s...done" "Loading package delight"))))) (condition-case err (let ((now (current-time))) (message "%s..." "Loading package delight") (prog1 (if (not (require 'delight nil t)) (display-warning 'use-package (format "Cannot load %s" 'delight) :error)) (let ((elapsed (float-time (time-subtract ... now)))) (if (> elapsed 0.1) (message "%s...done (%.3fs)" "Loading package delight" elapsed) (message "%s...done" "Loading package delight"))))) ((debug error) (funcall use-package--warning1 :catch err))) load-with-code-conversion("c:/home/ajm/.emacs.d/init.el" "c:/home/ajm/.emacs.d/init.el" t t) load("c:/home/ajm/.emacs.d/init" noerror nomessage) startup--load-user-init-file(#f(compiled-function () #<bytecode -0x1cd3443936cf717e>) #f(compiled-function () #<bytecode -0x1f3c61addc0c4f35>) t) command-line() normal-top-level() Tracing execution of emacs with Process Explorer shows that the temp file used to native compile trampolines is opened and closed repeatedly by emacs, and at the point of the backtrace is still open by the same emacs process. Adding a workaround to .emacs.d/init.el mitigates this problem: (setq comp-enable-subr-trampolines nil) Running "emacs -Q" does not show the problem, but is then less likely to native compile trampolines during startup. I am not sure excactly when this issue started, but I did not see it in emacs-29 or master bootstrapped before this month. AndyM In GNU Emacs 29.0.60 (build 8, x86_64-w64-mingw32) of 2023-01-21 built on QUIETUS Repository revision: b875c9bf67ebf858648a00307c370d7a196aab56 Repository branch: emacs-29 Windowing system distributor 'Microsoft Corp.', version 10.0.19045 System Description: Microsoft Windows 10 Pro (v10.0.2009.19045.2486) Configured using: 'configure --prefix=c:/emacs/29.0.60/mingw64-x86_64-O2-native-aot --cache-file=/c/emacs/git/emacs/emacs-29/build/mingw64-x86_64-O2-native-aot/config.cache --without-compress-install --without-dbus --with-gif --with-gnutls --without-imagemagick --with-jpeg --with-json --with-lcms2 --with-modules --with-native-compilation=aot --with-png --without-pop --with-rsvg --with-sqlite3 --with-tiff --with-tree-sitter --with-xml2 --with-xpm --enable-checking 'CPPFLAGS= -DNO_SHLWAPI_ISOS=1' 'CFLAGS= -O2 -g3 -gdwarf-4 -fdiagnostics-color=never' PKG_CONFIG_PATH=/mingw64/lib/pkgconfig:/mingw64/share/pkgconfig' Configured features: ACL GIF GMP GNUTLS HARFBUZZ JPEG JSON LCMS2 LIBXML2 MODULES NATIVE_COMP NOTIFY W32NOTIFY PDUMPER PNG RSVG SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XPM ZLIB Important settings: value of $LANG: ENG locale-coding-system: cp1252 Major mode: ELisp/l Minor modes in effect: hexl-follow-ascii: t which-function-mode: t global-so-long-mode: t display-fill-column-indicator-mode: t desktop-save-mode: t auto-image-file-mode: t minibuffer-electric-default-mode: t override-global-mode: t tooltip-mode: t global-eldoc-mode: t eldoc-mode: t show-paren-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t auto-composition-mode: t auto-compression-mode: t Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message yank-media rfc822 mml mml-sec epa derived gnus-util mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils add-log time mule-util jka-compr bug-reference dired-aux xcscope autorevert dired-x dired dired-loaddefs sh-script treesit executable time-date vc-svn rnc-mode rng-nxml rng-valid rng-loc rng-uri rng-parse nxml-parse rng-match rng-dt rng-util rng-pttrn nxml-ns nxml-mode nxml-outln nxml-rap sgml-mode facemenu dom nxml-util nxml-enc xmltok lua-mode advice rust-utils rust-mode rust-rustfmt rust-playpen rust-compile rust-cargo meson-mode smie eglot external-completion array filenotify jsonrpc ert ewoc debug backtrace find-func xref flymake-proc flymake thingatpt project hexl grep vc-git diff-mode vc-dispatcher graphviz-dot-mode compile text-property-search xr which-func imenu so-long display-fill-column-indicator desktop frameset cygwin-mount ange-ftp comint ansi-osc ansi-color ring hl-line pcase image-file image-converter edmacro kmacro use-package-bind-key use-package-delight minibuf-eldef delight comp comp-cstr warnings rx bind-key easy-mmode cl-extra help-mode use-package-ensure use-package-core finder-inf yaml-mode-autoloads xr-autoloads rust-mode-autoloads rnc-mode-autoloads powershell-autoloads plantuml-mode-autoloads meson-mode-autoloads markdown-mode-autoloads lua-mode-autoloads htmlize-autoloads haskell-mode-autoloads graphviz-dot-mode-autoloads gnuplot-autoloads gnu-elpa-keyring-update-autoloads epg rfc6068 epg-config gnu-elpa-keyring-update delight-autoloads debbugs-autoloads info dash-autoloads cus-edit pp cus-load icons wid-edit package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json url-vars nsm map byte-opt gv bytecomp byte-compile subr-x gnutls puny cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel dos-w32 ls-lisp disp-table term/w32-win w32-win w32-vars term/common-win tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads w32notify w32 lcms2 multi-tty make-network-process native-compile emacs) Memory information: ((conses 16 388657 216671) (symbols 48 25171 486) (strings 32 119123 37613) (string-bytes 1 3096676) (vectors 16 49749) (vector-slots 8 1397743 432730) (floats 8 85 750) (intervals 56 5657 2026) (buffers 984 25))
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.