Subject: bug#11727: is nnimap.el being too slow?

From: John Wiegley <[email-masked]>
Date: Sun, 17 Jun 2012 05:43:09 -0500

I have a list.emacs.devel group on a local Dovecot server (using mdbox as the
backend) which contains 149,420 articles (828 MB worth).

Hitting M-g on this group takes almost 60s.  Does that sound right?

Below are the elp-results.

Thanks,
  John

gnus-topic-get-new-news-this-topic                1           54.531315     54.531315
gnus-group-get-new-news-this-group                1           54.531289     54.531289
gnus-activate-group                               2           54.529050000  27.264525000
nnimap-request-group                              1           54.527728     54.527728
nnimap-update-infos                               1           35.473663     35.473663
nnimap-update-info                                1           35.473615     35.473615
gnus-set-difference                               2           35.44724      17.72362
nnimap-wait-for-response                          1           17.306591     17.306591
nnimap-parse-flags                                1           1.535944      1.535944
gnus-demon-run-callback                           2           0.447165      0.2235825
gnus-save-newsrc-file                             1           0.447087      0.447087
nnheader-accept-process-output                    599         0.3195609999  0.0005334908
nnimap-flags-to-marks                             1           0.211245      0.211245
gnus-topic-prepare-topic                          12          0.158238      0.0131864999
gnus-group-list-all-groups                        1           0.054768      0.054768
gnus-group-list-groups                            1           0.054759      0.054759
gnus-group-prepare-topics                         1           0.054183      0.054183
gnus-group-insert-group-line                      238         0.050939      0.0002140294
gnus-gnus-to-quick-newsrc-format                  1           0.0434        0.0434
gnus-compress-sequence                            10          0.026083      0.0026083
gnus-group-highlight-line                         238         0.0120589999  5.066...e-05
gnus-group-name-decode                            714         0.0111330000  1.559...e-05
gnus-summary-buffer-name                          238         0.0086959999  3.653...e-05
gnus-group-decoded-name                           238         0.0076650000  3.220...e-05
gnus-group-update-eval-form                       238         0.0071720000  3.013...e-05
gnus-group-name-charset                           476         0.0033809999  7.102...e-06
gnus-group-timestamp-delta                        238         0.0029469999  1.238...e-05
gnus-group-get-parameter                          476         0.0028929999  6.077...e-06
gnus-put-text-property-excluding-characters-with-faces  238         0.0019059999  8.008...e-06
gnus-group-update-group                           1           0.001829      0.001829
gnus-run-hooks                                    243         0.0014759999  6.074...e-06
gnus-topic-update-topic-line                      3           0.00146       0.0004866666
gnus-delay-send-queue                             1           0.001271      0.001271
gnus-put-text-property                            491         0.0011860000  2.415...e-06
gnus-find-method-for-group                        288         0.0010550000  3.663...e-06
gnus-topic-update-topics-containing-group         1           0.000982      0.000982
nndraft-request-group                             1           0.000958      0.000958
gnus-topic-find-groups                            15          0.0007529999  5.019...e-05
gnus-group-parameter-value                        476         0.0007180000  1.508...e-06
gnus-topic-insert-topic-line                      15          0.0007030000  4.686...e-05
gnus-add-text-properties                          268         0.0005830000  2.175...e-06
gnus-update-format-specifications                 2           0.000504      0.000252
nndraft-possibly-change-group                     1           0.000466      0.000466
nndraft-open-server                               1           0.000454      0.000454
gnus-dribble-delete-file                          1           0.000392      0.000392
gnus-group-insert-group-line-info                 1           0.000344      0.000344
nnoo-parent-function                              1           0.000342      0.000342
nnmh-request-group                                1           0.000292      0.000292
gnus-parse-format                                 1           0.000257      0.000257
gnus-group-set-mode-line                          3           0.0002270000  7.566...e-05
gnus-parse-complex-format                         1           0.000224      0.000224
gnus-topic-parent-topic                           26          0.000194      7.461...e-06
nnmail-group-pathname                             3           0.0001889999  6.3e-05
gnus-complex-form-to-spec                         2           0.000177      8.85e-05
gnus-topic-goto-topic                             4           0.0001409999  3.524...e-05
gnus-topic-find-topology                          17          0.00014       8.235...e-06
gnus-mode-line-buffer-identification              3           0.0001390000  4.633...e-05
gnus-group-prepare-logic                          237         0.0001329999  5.611...e-07
gnus-agent-possibly-alter-active                  3           0.00013       4.333...e-05
gnus-continuum-version                            4           0.000126      3.15e-05
nndraft-articles                                  1           0.000125      0.000125
gnus-range-length                                 238         0.0001209999  5.084...e-07
gnus-extent-start-open                            250         0.0001189999  4.759...e-07
gnus-group-get-icon                               238         0.0001159999  4.873...e-07
gnus-parse-simple-format                          3           0.0001119999  3.733...e-05
nnmh-possibly-change-directory                    1           0.000103      0.000103
gnus-agent-method-p                               4           8.499...e-05  2.124...e-05
gnus-group-goto-group                             2           7e-05         3.5e-05
gnus-emacs-version                                3           6.8e-05       2.266...e-05
gnus-make-directory                               1           6.8e-05       6.8e-05
gnus-topic-goto-next-group                        1           6.6e-05       6.6e-05
gnus-group-remove-mark                            1           6.5e-05       6.5e-05
gnus-server-opened                                2           6e-05         3e-05
gnus-group-set-parameter                          4           5.9e-05       1.475e-05
gnus-range-difference                             2           5.5e-05       2.75e-05
gnus-request-scan                                 1           5.4e-05       5.4e-05
gnus-group-position-point                         4           5.4e-05       1.35e-05
nnimap-send-command                               2           4.700...e-05  2.350...e-05
gnus-group-mark-group                             1           4.4e-05       4.4e-05
nnimap-decode-gnus-group                          3           3.9e-05       1.3e-05
gnus-prin1-to-string                              2           3.8e-05       1.9e-05
gnus-goto-colon                                   4           3.700...e-05  9.250...e-06
gnus-topic-update-unreads                         27          3.7e-05       1.370...e-06
nnimap-server-opened                              3           3.4e-05       1.133...e-05
nnimap-request-scan                               1           3.1e-05       3.1e-05
gnus-group-next-unread-group                      1           3.1e-05       3.1e-05
gnus-parse-active                                 2           2.8e-05       1.4e-05
nnimap-possibly-change-group                      2           2.7e-05       1.35e-05
gnus-set-work-buffer                              4           2.600...e-05  6.500...e-06
gnus-get-buffer-create                            2           2.5e-05       1.25e-05
nnoo-change-server                                2           2.3e-05       1.15e-05
gnus-close-group                                  1           2.3e-05       2.3e-05
gnus-group-search-forward                         1           2.3e-05       2.3e-05
nnheader-init-server-buffer                       1           1.9e-05       1.9e-05
gnus-get-unread-articles-in-group                 1           1.9e-05       1.9e-05
nnimap-store-info                                 2           1.8e-05       9e-06
gnus-message                                      2           1.7e-05       8.5e-06
gnus-request-update-info                          1           1.7e-05       1.7e-05
gnus-get-function                                 2           1.600...e-05  8.000...e-06
gnus-methods-equal-p                              13          1.500...e-05  1.153...e-06
nnimap-keepalive                                  1           1.5e-05       1.5e-05
gnus-group-process-prefix                         1           1.5e-05       1.5e-05
nnoo-server-opened                                2           1.4e-05       7e-06
nnheader-report                                   2           1.300...e-05  6.500...e-06
nndraft-server-opened                             1           1.2e-05       1.2e-05
gnus-group-topic-p                                1           1.2e-05       1.2e-05
gnus-undo-boundary                                11          1.2e-05       1.090...e-06
nnheader-insert                                   1           1e-05         1e-05
nnmh-server-opened                                1           1e-05         1e-05
nnimap-find-connection                            3           9e-06         3e-06
nnoo-backend                                      1           9e-06         9e-06
gnus-methods-sloppily-equal                       11          9e-06         8.181...e-07
nnheader-replace-duplicate-chars-in-string        3           8e-06         2.666...e-06
gnus-online                                       6           8e-06         1.333...e-06
gnus-group-remove-parameter                       4           8e-06         2e-06
gnus-group-group-name                             3           8e-06         2.666...e-06
gnus-group-topic-unread                           8           8e-06         1e-06
gnus-group-setup-buffer                           1           7e-06         7e-06
gnus-virtual-group-p                              1           6e-06         6e-06
nnoo-current-server                               6           5.999...e-06  1e-06
nnimap-buffer                                     1           5e-06         5e-06
gnus-agent-save-group-info                        1           5e-06         5e-06
gnus-group-topic-name                             1           5e-06         5e-06
gnus-group-group-indentation                      2           4.999...e-06  2.499...e-06
nnoo-parents                                      4           4e-06         1e-06
gnus-info-set-entry                               5           4e-06         8e-07
gnus-alive-p                                      1           4e-06         4e-06
gnus-group-topic-level                            3           4e-06         1.333...e-06
gnus-topic-visible-p                              3           4e-06         1.333...e-06
nnheader-re-read-dir                              2           3e-06         1.5e-06
nnheader-concat                                   1           3e-06         3e-06
nnimap-log-command                                2           2e-06         1e-06
nnoo-variables                                    2           2e-06         1e-06
gnus-remove-denial                                1           2e-06         2e-06
gnus-agent-save-local                             1           2e-06         2e-06
gnus-mouse-face-function                          1           2e-06         2e-06
nnheader-translate-file-chars                     3           1e-06         3.333...e-07
nnheader-cancel-timer                             1           1e-06         1e-06
nnimap-close-group                                1           1e-06         1e-06
gnus-group-default-level                          1           1e-06         1e-06
gnus-dribble-file-name                            1           1e-06         1e-06
gnus-float-time                                   1           1e-06         1e-06
gnus-region-active-p                              1           1e-06         1e-06
gnus-server-status                                2           1e-06         5e-07
gnus-demon-idle-since                             1           1e-06         1e-06
nnimap-find-process-buffer                        1           0.0           0.0