From: Milan Zamazal <pdm@zamazal.org>
To: "Dirk Bergstrom" <dirk@juniper.net>
Cc: <gnats-devel@sources.redhat.com>
Subject: Re: fix for PR 219 - large PRs or updates take many minutes to process
Date: Mon, 30 Jul 2001 11:33:00 -0000 [thread overview]
Message-ID: <87g0bey7l8.fsf@blackbird.zamazal.org> (raw)
In-Reply-To: <C0D6C1C24CDBE1449BFEF1B72AFBF3A709A5AD3E@postal.jnpr.net>
>>>>> "DB" == Dirk Bergstrom <dirk@juniper.net> writes:
DB> 1) read sizeof(line)-1 chars from the message (<=1024 chars),
DB> instead of sizeof(buf)-1 chars (2 chars).
DB> 2) add code to keep track of buf's length in a variable, instead
DB> of doing a strlen(buf) for every loop iteration.
DB> the first fix gives a 20-30x improvement (from hours to minutes)
DB> for a 1.4 MB testcase. the second fix gave a 50x improvement
DB> (five minutes to
>> 10 seconds) for the same testcase.
DB> and some cleanup:
DB> xrealloc()ing buf in 4K chunks only when needed, instead of
DB> every loop iteration. doesn't seem to change speed, but it
DB> feels better...
Thanks, Dirk, this is a very useful work! I applied the patch with
minor changes.
Regards,
Milan Zamazal
--
Wasting somebody else's time strikes me as the height of rudeness.
Bill Gates
prev parent reply other threads:[~2001-07-30 11:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-07-23 0:11 Dirk Bergstrom
2001-07-23 0:26 ` Gnatsweb help S Ramesh
2001-07-25 15:48 ` Yngve Svendsen
2001-07-30 11:33 ` Milan Zamazal [this message]
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=87g0bey7l8.fsf@blackbird.zamazal.org \
--to=pdm@zamazal.org \
--cc=dirk@juniper.net \
--cc=gnats-devel@sources.redhat.com \
/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 read-only IMAP folder(s) and NNTP newsgroup(s).