[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn commit: rev 2450 - trunk/subversion/libsvn_wc

From: Ben Collins-Sussman <sussman_at_collab.net>
Date: 2002-07-10 17:06:05 CEST

Justin Erenkrantz <jerenkrantz@apache.org> writes:

> On Wed, Jul 10, 2002 at 04:29:22AM -0500, jerenkrantz@tigris.org wrote:
> > Author: jerenkrantz
> > Date: Wed, 10 Jul 2002 04:29:04 -0500
> > New Revision: 2450
> >
> > Modified:
> > trunk/subversion/libsvn_wc/props.c
> > Log:
> > * subversion/libsvn_wc/props.c
> > (svn_wc__load_prop_file): Open the propfile with APR_BUFFERED so that the
> > single-character reads in svn_io_read_length_line do not result in
> > numerous system calls.
>
> Previously, we were doing the following via svn_hash_read():
>
> read(3, "E", 1) = 1
> read(3, "N", 1) = 1
> read(3, "D", 1) = 1
> read(3, "\n", 1) = 1
> ...
>
> This takes advantage of APR's buffering feature so that we now do:
>
> read(3, "END\n", 4096) = 4
>
> This should make reading the property files a bit faster since we'll
> avoid the multiple read() calls. All I can say is 'ouch!' -- justin

I think our loader (libsvn_repos/load.c) could use this 'buffered'
enhancement as well. I think it's calling a svn_stream_readline
function of some sort, and that function is implemented in the same
inefficient one-byte-at-a-time way. Can someone check into this?

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Jul 10 17:11:00 2002

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.