Gnus development mailing list
 help / color / mirror / Atom feed
From: Daniel Pittman <daniel@rimspace.net>
To: ding@gnus.org
Subject: Re: Huge memory consumption on accessing large newsgroup
Date: Mon, 01 Oct 2007 11:04:54 +1000	[thread overview]
Message-ID: <87odfjprux.fsf@enki.rimspace.net> (raw)
In-Reply-To: <m21wcf9527.fsf@lifelogs.com>

Ted Zlatanov <tzz@lifelogs.com> writes:
> On Sat, 29 Sep 2007 22:04:18 +0100 Gaute Strokkenes <gs234@srcf.ucam.org> wrote:
>
> GS> I wonder if it would be possible to make Gnus work solely with
> GS> compressed ranges (i.e. lists where dotted pairs are used to
> GS> represent runs of consecutive integers)?
>
> GS> Unless there is some deeper reason why this cannot work, I might
> GS> have a stab at it (eventually).
>
> I think this would be a good idea.  

Ah.

> Consider using inversion lists.  

This is almost certainly unnecessary, not to mention that it would
involve building an entire parallel infrastructure to handle them.

The nnimap code had a similar performance killing "feature" where it
would expand two 'range' lists completely, intersect them, then compress
them again.

This was trivially resolved by using the existing code from
`gnus-range.el' to process this on the compressed versions.

You should be able to find the appropriate bit of history tucked away in
the history of the nnimap.el code via CVS.

I am also happy to try and dig up my memories of the work though,
frankly, they were trivial enough.


The one specific advice I would give you:

Write your code so it is "self testing" and run with that for a long
while. I ended up having the code do the gnus-range based calculations
and compare them to the non-range calculations, then signal an error if
they disagreed.

This cost extra CPU time for the couple of weeks I used it in production
but gave me (and, I think, the rest of the list) a much higher sense of
security that the changes were, in practice, correct.

(You might want to leave that in with a debug option to turn it on so
 that the rest of the Gnus CVS userbase also test this, to catch faults
 that your own use doesn't show.

 I didn't do that and I vaguely regret it now.)

> They don't require pairs of integers; each value represents a flip.
> They have other nice properties too, though it's been a while since I
> looked at them so I can't name them.  

Mmm.  The existing Gnus range code is pretty much as efficient, has
lower computational complexity for the operations Gnus uses and is
already existent and tested.

I don't think that you would see sufficient benefit from introducing the
additional data type to justify spending your time on it -- but since I
am not volunteering to do the work I can't tell you how to do it. ;)

Regards,
        Daniel
-- 
Daniel Pittman <daniel@cybersource.com.au>           Phone: 03 9621 2377
Level 4, 10 Queen St, Melbourne             Web: http://www.cyber.com.au
Cybersource: Australia's Leading Linux and Open Source Solutions Company




  parent reply	other threads:[~2007-10-01  1:04 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <87wsw4u21m.fsf@gmx.de>
2007-08-10  9:08 ` Katsumi Yamaoka
2007-08-10 11:39   ` Katsumi Yamaoka
2007-08-10 12:43     ` Sven Joachim
2007-08-13 11:44       ` Katsumi Yamaoka
2007-08-13 17:30         ` Sven Joachim
2007-08-14 11:46           ` Katsumi Yamaoka
2007-09-13 10:27             ` Katsumi Yamaoka
2007-08-10 12:42   ` Sven Joachim
2007-09-29 21:04     ` Gaute Strokkenes
2007-09-30 22:11       ` Ted Zlatanov
2007-10-01  0:29         ` Katsumi Yamaoka
2007-10-01  1:04         ` Daniel Pittman [this message]
2007-10-02  2:13           ` Ted Zlatanov
2007-10-02  3:23             ` Daniel Pittman
2007-10-02 11:11               ` Ted Zlatanov
2007-10-02 12:17                 ` Daniel Pittman
2007-10-02 16:08                   ` Ted Zlatanov
2007-10-03  0:19                     ` Daniel Pittman
2007-10-02 13:33               ` Daniel Pittman

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=87odfjprux.fsf@enki.rimspace.net \
    --to=daniel@rimspace.net \
    --cc=ding@gnus.org \
    /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.
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).