Re: Performance optimization - svn_stringbuf_appendbyte()
From: Julian Foad <julian.foad_at_wandisco.com>
Date: Thu, 07 Oct 2010 15:07:42 +0100
> New Revision: 997203
Hi Stefan2.
I have been wondering about the actual benefit of such tightly
In my first test, it made no difference whatsoever, because the
- if (str->blocksize > old_len + 1)
which totally disables the optimized code path.
Fixed in r1005437.
That solved, a loop doing a million simple appendbyte calls runs more
But what about that hand-optimization? I wrote a simple version of the
svn_stringbuf_appendbyte0(svn_stringbuf_t *str, char byte)
Here are the results (see full patch attached):
Times: appendbytes appendbyte0 appendbyte (in ms)
This tells me that the hand-optimization is actually harmful and the
Have I made a mistake?
What are the results for your system?
(I'm using GCC 4.4.1 on an Intel Centrino laptop CPU.)
- Julian
|
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.