emacs-devel
[Top][All Lists]
Advanced

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

Re: Lazy printing in tabulated-list-mode


From: Artur Malabarba
Subject: Re: Lazy printing in tabulated-list-mode
Date: Fri, 1 May 2015 19:31:02 +0100

> 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 via email to

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