Gnus development mailing list
 help / color / mirror / Atom feed
* Reason for nnml article move slowness found
@ 1999-12-09 16:07 Hannu Koivisto
  1999-12-09 17:14 ` Shenghuo ZHU
  0 siblings, 1 reply; 3+ messages in thread
From: Hannu Koivisto @ 1999-12-09 16:07 UTC (permalink / raw)


Greetings,

I decided to learn to use ELP and with its help and by reading the
source I think I now know why moving articles from an nnml group
with many articles to another takes so long.
NNML-REQUEST-MOVE-ARTICLE ends up calling
NNHEADER-ARTICLE-TO-FILE-ALIST about nine times per moving two
articles.  And that's a rather bad thing with a directory with many
files.  NNHEADER-ARTICLE-TO-FILE-ALIST is called by
NNML-UPDATE-FILE-ALIST when NNML-ARTICLE-FILE-ALIST is nil (or
force is applied, but this is not the case here as proved by
tracing).

The nnml.el code is quite spaghetti and does not have many
docstrings or comments and even all the code I write these days is
Lisp, I can't make much sense of the control flow there just by
reading it and see how reseting that alist could be avoided.  It
seems that it is reseted (by reseting I mean setting to NIL) mostly
by NNML-POSSIBLY-CHANGE-DIRECTORY.  I don't know if avoiding
reseting that alist can be reduced to avoiding calls to that
function or if it needs to do rest of its job as it does it
currently and only be smarter about reseting that alist.

Although this is a bit off-topic, is there any tool for, er,
on-demand tracing functions?  That is, I'd like to say "I want
function X traced, and when it is called, I want all the functions
it calls (and they call etc.) automatically traced too (but they
must not be traced if the call originates from some other function
than X)".

-- 
Hannu


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Reason for nnml article move slowness found
  1999-12-09 16:07 Reason for nnml article move slowness found Hannu Koivisto
@ 1999-12-09 17:14 ` Shenghuo ZHU
  1999-12-09 20:59   ` Hannu Koivisto
  0 siblings, 1 reply; 3+ messages in thread
From: Shenghuo ZHU @ 1999-12-09 17:14 UTC (permalink / raw)


>>>>> "Hannu" == Hannu Koivisto <azure@iki.fi> writes:

Hannu> Greetings,

Hannu> I decided to learn to use ELP and with its help and by reading
Hannu> the source I think I now know why moving articles from an nnml
Hannu> group with many articles to another takes so long.
Hannu> NNML-REQUEST-MOVE-ARTICLE ends up calling
Hannu> NNHEADER-ARTICLE-TO-FILE-ALIST about nine times per moving two
Hannu> articles.  And that's a rather bad thing with a directory with
Hannu> many files.  NNHEADER-ARTICLE-TO-FILE-ALIST is called by
Hannu> NNML-UPDATE-FILE-ALIST when NNML-ARTICLE-FILE-ALIST is nil (or
Hannu> force is applied, but this is not the case here as proved by
Hannu> tracing).

[...]

In my experiment, NNHEADER-ARTICLE-TO-FILE-ALIST is called once per
moving article. Now I fixed it in the latest CVS, only once (maybe
twice) in a moving session.


-- 
Shenghuo


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Reason for nnml article move slowness found
  1999-12-09 17:14 ` Shenghuo ZHU
@ 1999-12-09 20:59   ` Hannu Koivisto
  0 siblings, 0 replies; 3+ messages in thread
From: Hannu Koivisto @ 1999-12-09 20:59 UTC (permalink / raw)


Shenghuo ZHU <zsh@cs.rochester.edu> writes:

| In my experiment, NNHEADER-ARTICLE-TO-FILE-ALIST is called once per
| moving article. Now I fixed it in the latest CVS, only once (maybe
| twice) in a moving session.

Thanks, it works /much/ better now.  I could actually move all
those articles and it didn't even take one hour now :)

-- 
Hannu


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~1999-12-09 20:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-12-09 16:07 Reason for nnml article move slowness found Hannu Koivisto
1999-12-09 17:14 ` Shenghuo ZHU
1999-12-09 20:59   ` Hannu Koivisto

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 NNTP newsgroup(s).