monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Monotone-devel] Re: http://venge.net/monotone/self-hosting.html


From: Henry Nestler
Subject: [Monotone-devel] Re: http://venge.net/monotone/self-hosting.html
Date: Tue, 14 Jun 2005 18:36:44 +0200
User-agent: Mozilla Thunderbird 0.6 (Windows/20040502)

Frank Ch. Eigler wrote:
Zbynek Winkler <address@hidden> writes:


[...]

~2 hours for downloading monotone complete source with WinXP
1.8GHz, 512MB RAM (eats 100% CPU time).  Means, not downloding. The
verification need the time.  But is only at first connect.  Later
it works faster.

Well... I can see it needs time -- but ~2 hours?? [...]


It seems pretty silly to me too.  How much profiling has been done to
reduce this time?  During a brief strace (taken during various phases
of the 45 minutes of the initial pull on my fast workstation), there
seemed to be ample low-level opportunities for speedup.

Socket I/O and status updating during the pull seemed rather wasteful
for example: a bunch of select-for-1us-delay / select-again / time /
read / write-status system calls in a close loop.  It looks like a
busy wait with lots of unnecessary screen I/O.

Later on during what must have been verification, the db file is
processed with tons more system calls (llseek, read, write, ...), even
though mmap is available and concurrency is not exactly an issue.

But these sorts of micro things must be capable of incremental
improvement.  My big worry is whether algorithmically an excess of
work is imposed on clients.  For example, how necessary is it that
each historical crypto operation be redone/rechecked?  Is it really
essential that each client database be a complete copy of the master,
as opposed to being fetched on demand?

Now I may have a few details wrong in the above, not having examined
monotone internals deeply or lately.  But if the usage scenario of a
new user wanting to fetch a release from a monotone-hosted project is
so overweight compared to other alternatives, that's just not great.

Becaus I had a problem on NFS mount, I view into syscalls with strace, and found a lot of file lockings, file sync, directory open/close, directory sync, file sync on every write to the jurnal file. The strace log was created from a simple "db init". I not know how many system calls are made for a pull from server.

A sugestion from me is a optional parameter to disable "sync" and disable the file block "locking". A lock for the complete opened file should also works faster, as the ~6 locks for write a section. All only for clients on local filesystem. In server mode is a other situation.

Please grep for "F_RDLCK", "O_LARGEFILE", "fsync(5)", to see, what I mean (reported as BUG #12455):

http://savannah.nongnu.org/bugs/download.php?item_id=12455&item_file_id=2608


--
Henry




reply via email to

[Prev in Thread] Current Thread [Next in Thread]