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

Re: [PATCH] Disable fsync at transaction commit

From: Greg Hudson <ghudson_at_MIT.EDU>
Date: 2003-02-22 07:20:19 CET

On Fri, 2003-02-21 at 22:48, Branko ╚ibej wrote:
> This patch reduces "make check" time over ra_local on my Windows box
> from 56 to 34 minutes. I'd like to ask people to do two things: measure
> the effects of this patch on their machines, and especially comment on
> the FS configuration mechanism.

I'm not sure I can bring myself to have an opinion on the FS
configuration mechanism. On the one hand, I sympathize with Greg's
concern that svn_config should only be used when there are actual config
files; on the other hand, maybe you should be able to drop a config file
in the repository instead of passing command-line options.

Anyway, I did the grunt work. I used a simplified form of your patch,
which I'll include at the end. The "make check" time appears to drop
from 20 minutes to 18 minutes on my machine with DB_TXN_NOSYNC set. I
have a 700MHz PIII Thinkpad A22P with 384MB of memory.

Here are the results of "time make check". The first two are with the
original code, the third one with the patch. Since the first two runs
were nearly identical (no noticeable caching effects), I didn't have the
patience to run the patched code twice.

  191.280u 43.930s 20:04.26 19.5% 0+0k 0+0io 1152035pf+0w
  193.520u 45.320s 20:05.55 19.8% 0+0k 0+0io 1150689pf+0w
  186.340u 44.550s 18:02.58 21.3% 0+0k 0+0io 1154886pf+0w

commit-tests 28 failed in all three runs, but that should only have
skewed the results slightly if at all.

Index: subversion/libsvn_fs/fs.c
--- subversion/libsvn_fs/fs.c (revision 5014)
+++ subversion/libsvn_fs/fs.c (working copy)
@@ -450,7 +450,14 @@
       "# http://subversion.tigris.org/servlets/ReadMsg?list=dev&msgId=161960\n"
       "set_lg_bsize 262144\n"
- "set_lg_max 1048576\n";
+ "set_lg_max 1048576\n"
+ "#\n"
+ "# Disable fsync of log files on transaction commit. Read the\n"
+ "# documentation abtou DB_TXN_NOSYNC at:\n"
+ "#\n"
+ "# http://www.sleepycat.com/docs/api_c/env_set_flags.html\n"
+ "#\n"
+ "set_flags DB_TXN_NOSYNC\n";
     SVN_ERR (svn_io_file_open (&dbconfig_file, dbconfig_file_name,
                                APR_WRITE | APR_CREATE, APR_OS_DEFAULT,

To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Feb 22 07:21:05 2003

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