[Top][All Lists]

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

Re: Enabling native compilation by default when libgccjit is present

From: Óscar Fuentes
Subject: Re: Enabling native compilation by default when libgccjit is present
Date: Thu, 09 Dec 2021 08:19:05 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Stefan Monnier <monnier@iro.umontreal.ca>
>> Cc: Michael Heerdegen <michael_heerdegen@web.de>,  Eli Zaretskii
>>  <eliz@gnu.org>,  emacs-devel@gnu.org
>> Date: Wed, 08 Dec 2021 08:52:01 -0500
>> > But how are those warnings different from what the user will get if he
>> > runs `package-install' on a package that causes warnings from the
>> > byte-compiler?
>> - By default, package-install compiles all the new files, one after the
>>   other, in the current Emacs session.  So it tends to emit fewer
>>   warnings than the native compilation (which compiles each file in
>>   a fresh new process) because many more packages have already been
>>   loaded.  This same difference can cause the native-compiled files to
>>   be miscompiled (because of a lack of `require`s) while the .elc files
>>   generated during `package-install` work properly.
>> - Native compilation of a package kicks in when a package that has been
>>   byte-compiled gets loaded in an Emacs session.
>>   So the warnings emitted by native-compilation are always *in addition*
>>   to the warnings that were emitted during `package-install`.
>> - `.eln` files are specific to a particular Emacs executable, so all the
>>   `.elc` files you use will be *re*compiled to `.eln` every time you
>>   start using a new Emacs executable.  For "normal" users this means
>>   every time they upgrade to a new release.  For people who track
>>   `master` it can mean "every other day".
> There's no argument that there are more warnings with
> native-compilation.  The argument is whether these warnings should
> surprise people as something that "never happens otherwise".

What is surprising about the warnings emitted by native-compilation is
that you are doing your work and suddenly a window appears from nowhere
breaking your window layout, distracting you, spilling text you don't
understand and, in any case, are uninsterested on because you have other
work to do. So you bury or kill the buffer, fix your window layout, go
back to work and a while later the damn thing pops up again.

That is incredibly user-hostile.

Now I have

(setq native-comp-async-report-warnings-errors nil)

So much for causing pain to users as a means for improving things.

reply via email to

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