public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* [ANNOUNCEMENT] emacs 28.2-2 (64-bit only, TEST)
@ 2022-09-17 11:56 Ken Brown via Cygwin-announce
  2022-09-17 16:53 ` Jim Reisert AD1C
  2022-09-17 19:35 ` Eliot Moss
  0 siblings, 2 replies; 3+ messages in thread
From: Ken Brown via Cygwin-announce @ 2022-09-17 11:56 UTC (permalink / raw)
  To: cygwin

The following packages have been uploaded to the Cygwin distribution as test 
releases.

* emacs-28.2-2
* emacs-basic-28.2-2
* emacs-w32-28.2-2
* emacs-gtk-28.2-2
* emacs-lucid-28.2-2
* emacs-common-28.2-2

This is the same as emacs-28.2-1, but it is built with the native compilation 
feature (explained below).  If you want to test this, create a file

   /var/lib/rebase/userpath.d/<username>

with one line, which is the absolute path to ~/.emacs.d/eln-cache.  For example, 
on my system I have:

   $ cat /var/lib/rebase/userpath.d/kbrown
   /home/kbrown/.emacs.d/eln-cache

If more than one user will be using Emacs on your system, create a file like 
this for each user.

Here is a brief explanation of native compilation:

Many of the editing commands used in Emacs are defined in elisp libraries (*.el 
files).  To make Emacs run faster, these libraries are usually compiled to 
architecture-independent *.elc files, containing "byte-code" representations of 
the functions in the original files.  These byte-code functions are interpreted 
by the Emacs "byte-code interpreter" when they are called.

Native compilation takes this one step further by using gcc to compile the elisp 
libraries to native shared libraries (like DLLs, but with an extension .eln 
instead of .dll).  This results in a substantial speed-up of Emacs.

Some of the .eln files are created at build time.  These are installed in a 
subdirectory of /usr/lib/emacs/<version>/native-lisp.  Others are created as 
needed and are stored by default in a subdirectory of ~/.emacs.d/eln-cache. 
(You can change this default, but then you also have to make the corresponding 
change to /var/lib/rebase/userpath.d/<username>.)

The first few times you run Emacs, it might seem slow to start.  This is because 
it is compiling the elisp libraries that are needed for your init file (usually 
.emacs).  For the same reason, you might see occasional pauses the first time 
you use a command.  But otherwise you should see a noticeable speed-up of Emacs.

To prevent fork failures, the .eln files need to be rebased occasionally, for 
the reasons explained here:

   https://cygwin.com/cygwin-ug-net/highlights.html#ov-hi-process-problems

This is handled by autorebase every time you run setup (which you should do with 
no Cygwin processes running).  But it is not currently done when new .eln files 
are created.  If you ever see a fork failure whose error message refers to a 
.eln file, you should be able to fix it temporarily by exiting emacs and running 
the script

   /usr/bin/emacs_ephemeral_rebase.sh

which rebases the .eln files in ~/.emacs.d/eln-cache.  Alternatively, stop all 
Cygwin processes and run setup.

I don't expect this to happen often, but please make a bug report to the mailing 
list if it does happen.  I'd also like to get feedback from people who try the 
test release for a month or so and don't have any rebase problems.

Ken

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ANNOUNCEMENT] emacs 28.2-2 (64-bit only, TEST)
  2022-09-17 11:56 [ANNOUNCEMENT] emacs 28.2-2 (64-bit only, TEST) Ken Brown via Cygwin-announce
@ 2022-09-17 16:53 ` Jim Reisert AD1C
  2022-09-17 19:35 ` Eliot Moss
  1 sibling, 0 replies; 3+ messages in thread
From: Jim Reisert AD1C @ 2022-09-17 16:53 UTC (permalink / raw)
  To: cygwin

> The following packages have been uploaded to the Cygwin distribution as test
> releases.
>
> * emacs-28.2-2
> * emacs-basic-28.2-2
> * emacs-w32-28.2-2
> * emacs-gtk-28.2-2
> * emacs-lucid-28.2-2
> * emacs-common-28.2-2
>
> This is the same as emacs-28.2-1, but it is built with the native compilation
> feature (explained below).  If you want to test this, create a file

Thanks, Ken.  Working well so far here.

-- 
Jim Reisert AD1C, <jjreisert@alum.mit.edu>, https://ad1c.us

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ANNOUNCEMENT] emacs 28.2-2 (64-bit only, TEST)
  2022-09-17 11:56 [ANNOUNCEMENT] emacs 28.2-2 (64-bit only, TEST) Ken Brown via Cygwin-announce
  2022-09-17 16:53 ` Jim Reisert AD1C
@ 2022-09-17 19:35 ` Eliot Moss
  1 sibling, 0 replies; 3+ messages in thread
From: Eliot Moss @ 2022-09-17 19:35 UTC (permalink / raw)
  To: cygwin, Ken Brown via Cygwin-announce

On 9/17/2022 7:56 AM, Ken Brown via Cygwin-announce wrote:
> The following packages have been uploaded to the Cygwin distribution as test releases.
> 
> * emacs-28.2-2
> * emacs-basic-28.2-2
> * emacs-w32-28.2-2
> * emacs-gtk-28.2-2
> * emacs-lucid-28.2-2
> * emacs-common-28.2-2
> 
> This is the same as emacs-28.2-1, but it is built with the native compilation feature (explained 
> below).

...

> The first few times you run Emacs, it might seem slow to start.  This is
> because it is compiling the elisp libraries that are needed for your init
> file (usually .emacs).  For the same reason, you might see occasional pauses
> the first time you use a command.  But otherwise you should see a noticeable
> speed-up of Emacs.

Actually, I am not seeing that.  The setup as provided does the native
compilation in deferred mode, which forks asynchronous native code
compilation, apparently while continuing to run byte code.  When the native
code is ready, it is swapped in, replacing the interpreted byte code.  So, if
your system has multiple cores (like mine) and is not overloaded, you may not
see slow down - only eventual speed up.

Thank you for this, Ken!

Eliot Moss

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-09-17 19:35 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-17 11:56 [ANNOUNCEMENT] emacs 28.2-2 (64-bit only, TEST) Ken Brown via Cygwin-announce
2022-09-17 16:53 ` Jim Reisert AD1C
2022-09-17 19:35 ` Eliot Moss

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).