all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Artur Malabarba <bruce.connor.am@gmail.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel <emacs-devel@gnu.org>
Subject: Re: Lazy printing in tabulated-list-mode
Date: Fri, 1 May 2015 19:31:02 +0100	[thread overview]
Message-ID: <CAAdUY-LXtP3jT+beRuHhHFWqwVwNMYBc9ns00pXqriVWWr+uLw@mail.gmail.com> (raw)
In-Reply-To: <CAAdUY-J=3EoSV+iwW9Q3fBnucZwaatp-DiWVpc5PXXoSN-MRsQ@mail.gmail.com>

> You mean it's spent in `insert'?

Here we go. So:

41% of the samples were in garbage collection. I missed that the first
time, but it looks like a pretty big deal.

8% are in sorting the entries.

7% disappear somewhere inside tabulated-list-print-entry.

36% are spent inside tabulated-list-print-col (report snippet pasted
below). Out of which:

11% are completely unacounted for

9% are in the following `if' form, but only 2% and 1% are spend on the
`apply' and the `insert'. So I think that means `get-text-property' is
eating up 6% here?

(if (stringp col-desc)
    (insert (if (get-text-property 0 'help-echo label)
            label
          (propertize label 'help-echo help-echo)))
      (apply 'insert-text-button label (cdr col-desc)))

12% are in a `progn', which I think corresponds to the body of this
`when', but I don't know what's responsible for this.

(when not-last-col
        (when (> pad-right 0) (insert (make-string pad-right ?\s)))
        (insert (propertize
                 (make-string (- next-x x label-width pad-right) ?\s)
                 'display `(space :align-to ,next-x))))

--------------------------------------------------

- tabulated-list-print-col                     2101  36%
 - let*                                        1939  34%
  - let                                         965  16%
   - if                                         702  12%
    - progn                                     699  12%
     - if                                       333   5%
      - progn                                   317   5%
         insert                                  53   0%
     + insert                                   127   2%
     put-text-property                           37   0%
  - if                                          534   9%
   + apply                                      132   2%
   + insert                                      85   1%
  + setq                                         50   0%
    <                                            33   0%
  + and                                          13   0%
    or                                            9   0%



  reply	other threads:[~2015-05-01 18:31 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-30 16:11 Lazy printing in tabulated-list-mode Artur Malabarba
2015-04-30 16:13 ` Artur Malabarba
2015-05-01 13:43 ` Stefan Monnier
2015-05-01 14:03   ` Artur Malabarba
2015-05-01 17:27     ` Stefan Monnier
2015-05-01 18:11       ` Artur Malabarba
2015-05-01 18:12         ` Artur Malabarba
2015-05-01 18:31           ` Artur Malabarba [this message]
2015-05-01 20:46         ` Stefan Monnier
2015-05-02  9:38           ` Artur Malabarba
2015-05-03 16:21             ` Stefan Monnier
2015-05-03 17:02               ` Artur Malabarba
2015-05-04  0:19                 ` Stefan Monnier
2015-05-04  8:21                   ` Artur Malabarba
2015-05-04 10:46                     ` Artur Malabarba
2015-05-04 12:38                     ` Stefan Monnier

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

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

  git send-email \
    --in-reply-to=CAAdUY-LXtP3jT+beRuHhHFWqwVwNMYBc9ns00pXqriVWWr+uLw@mail.gmail.com \
    --to=bruce.connor.am@gmail.com \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.