unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Alan Mackenzie <acm@muc.de>
To: Eli Zaretskii <eliz@gnu.org>
Cc: michael_heerdegen@web.de, gerd.moellmann@gmail.com,
	68200@debbugs.gnu.org, acm@muc.de
Subject: bug#68200: 30.0.50; Emacs reloads init file when calling `documentation'
Date: Thu, 11 Jan 2024 18:10:58 +0000	[thread overview]
Message-ID: <ZaAvMsEmHq6FpeFJ@ACM> (raw)
In-Reply-To: <83r0iqptu5.fsf@gnu.org>

Hello, Eli.

On Tue, Jan 09, 2024 at 14:36:02 +0200, Eli Zaretskii wrote:
> > Date: Mon, 8 Jan 2024 21:22:16 +0000
> > Cc: Eli Zaretskii <eliz@gnu.org>,
> >   Gerd Möllmann <gerd.moellmann@gmail.com>,
> >   68200@debbugs.gnu.org, acm@muc.de
> > From: Alan Mackenzie <acm@muc.de>
> > 
> > In an age when a computer with 1 GB RAM is regarded as small indeed, why
> > are we so concerned about the, at most, few hundred bytes occupied by
> > each doc string?

> Because RAM is always at premium, and because these things add up.

> > Even if certain libraries were given adequate doc
> > strings, that still wouldn't swell the occupied storage to more than...
> > Well, I think there are around 40,000 defuns (etc.) in Emacs (I did scan
> > the source files for this at one time).  If each doc string were on
> > average 1024 bytes, that would come to around 40 MB.  That's negligible
> > these days, surely.

> No, 40MB is far from being negligible.

It's not negligible compared with the rest of Emacs, but is less than ¼%
of the RAM in a machine with 16GB.

> > Eli, what would you say to changing the default of the custom variable
> > byte-compile-dynamic-docstrings to nil?

> Why would that be useful? to hide bugs in code that doesn't work when
> the variable is non-nil?

No, the bug has been fixed.  But, as Michael pointed out, lots of things
are being done with doc strings now which weren't being done when the
dynamic doc strings were introduced.  Indeed, they were surely a
workaround for limited RAM in machines a very long time ago.

Now that we're doing more with doc strings, the inconvenience of not
getting a doc string after editing a source file might well outweigh the
relatively small amount of RAM that these doc strings need.

Hence the suggestion to change the default.

[ .... ]

> Thanks.

-- 
Alan Mackenzie (Nuremberg, Germany).





  reply	other threads:[~2024-01-11 18:10 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-02  1:53 bug#68200: 30.0.50; Emacs reloads init file when calling `documentation' Michael Heerdegen via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-02  2:33 ` Michael Heerdegen via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-02 13:09 ` Eli Zaretskii
2024-01-07  1:40   ` Michael Heerdegen via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-07  5:43     ` Gerd Möllmann
2024-01-07  7:33       ` Eli Zaretskii
2024-01-07 17:20         ` Michael Heerdegen via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-07 17:33         ` Michael Heerdegen via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-08 21:22           ` Alan Mackenzie
2024-01-08 23:09             ` Michael Heerdegen via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-09 11:26               ` Alan Mackenzie
2024-01-10  3:28                 ` bug#68200: File local byte-compile-dynamic-docstrings:nil ignored (was: bug#68200: 30.0.50; Emacs reloads init file when calling `documentation') Michael Heerdegen via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-11 17:59                   ` Alan Mackenzie
2024-01-09 12:36             ` bug#68200: 30.0.50; Emacs reloads init file when calling `documentation' Eli Zaretskii
2024-01-11 18:10               ` Alan Mackenzie [this message]
2024-01-11 19:22                 ` Eli Zaretskii
2024-01-11 19:40                   ` Alan Mackenzie
2024-01-11 19:54             ` Stefan Kangas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZaAvMsEmHq6FpeFJ@ACM \
    --to=acm@muc.de \
    --cc=68200@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=gerd.moellmann@gmail.com \
    --cc=michael_heerdegen@web.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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).