unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Basil L. Contovounesios" <contovob@tcd.ie>
To: Boruch Baum <boruch_baum@gmx.com>
Cc: 45926@debbugs.gnu.org
Subject: bug#45926: Tabulated-list-mode wasteful properties
Date: Sun, 17 Jan 2021 13:40:02 +0000	[thread overview]
Message-ID: <87wnwb1y31.fsf@tcd.ie> (raw)
In-Reply-To: <20210117073252.k7f2x35lq3labahe@E15-2016.optimum.net> (Boruch Baum's message of "Sun, 17 Jan 2021 02:32:52 -0500")

[-- Attachment #1: Type: text/plain, Size: 1351 bytes --]

Boruch Baum <boruch_baum@gmx.com> writes:

> Tabulated lists can grow quite large. In fact, the most common use for
> the mode is the *Packages* buffer listing, which for me today clocks in
> at 5211 lines * five columns. In the case of the *Packages* buffer, Performing
>
>    (buffer-substring (point) (line-end-position))
>
> on a sampling of lines yields 'PP eval' buffers of length ~500 - ~700
> characters.
>
> Most of this looks to me to be unnecessary duplicate data. In using the
> mode for my own purpose, I see that the mode is putting all data of all
> columns in an entry (row) in each and every single column, ie the size
> grows exponentially by number of columns (in my personal case, ten
> columns).
>
> This isn't breaking anything, but it looks like bad design unnecessarily
> hogging memory and filling buffers with cruft.

Are you sure the data is actually duplicated and doesn't share
structure?  I evaluated that expression over the xref package, and got
the attached string.  Nothing looks obviously duplicated, except for the
shared #N= and #N# structures.  Also, some of the repetition of shared
structures is probably just due to how string intervals are
represented/printed.

Not that any of this is necessarily optimal, of course, but it's not
immediately alarming to me, either, unless I'm missing something.

-- 
Basil


[-- Attachment #2: pp-eval.el --]
[-- Type: application/emacs-lisp, Size: 3635 bytes --]

  reply	other threads:[~2021-01-17 13:40 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-17  7:32 bug#45926: Tabulated-list-mode wasteful properties Boruch Baum
2021-01-17 13:40 ` Basil L. Contovounesios [this message]
2021-01-17 15:11   ` Boruch Baum
2021-01-19  5:24     ` Lars Ingebrigtsen
2021-03-12  0:52       ` Stefan Kangas
2021-03-12  2:57         ` Boruch Baum
2021-03-12  3:39           ` Stefan Kangas
2021-03-12  5:46             ` Boruch Baum
2021-03-12 11:01               ` Basil L. Contovounesios
2021-04-21  3:35             ` Stefan Kangas
2021-03-12 10:51           ` Basil L. Contovounesios
2021-04-21  4:36             ` Jean Louis
2021-04-21  4:31           ` Jean Louis

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=87wnwb1y31.fsf@tcd.ie \
    --to=contovob@tcd.ie \
    --cc=45926@debbugs.gnu.org \
    --cc=boruch_baum@gmx.com \
    /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).