[darcs-users] how about copying pristine cache files instead of linking them?

Petr Rockai me at mornfall.net
Thu Apr 23 06:16:33 UTC 2009


Hi,

> Thanks to meeting and chatting with you at the hackathon, I have a much
> better grasp of our current --hashed performance problems.
>
> As you explained it, one problem is that on the one hand, hashed
> pristine files can be shared across branches via hard-linking while on
> the other hand, darcs operations in one branch will synch the timestamps
> on those files with their working dir equivalents, thus invalidating the
> timestamps for the other branch.  (So far so good?)
So far so good.

> One question: what if, as a temporary measure, we made a special
> exception that pristine cache files are copied from the caches, rather
> than linked from them.  Patches will still be hard-linked, so we get
> most of the speedups, but pristine cache files will be copied to avoid
> the timestamp problem.  Would this scheme work, i.e. by giving people
> the benefits of hashed repos (robustness, lazy get, caches) without
> making them pay the price of interminable Reading Pristines?
Well, there are two sides to this. Pristine cache size can be far from
negligible -- even though it's compressed, it's still roughly the same size as
your working copy. My rough estimate is that not hardlinking means about 30%
increase of disk space usage per branch... Whether that's reasonable, I can't
tell. It will also make local gets even slower than they already are.

Yours,
   Petr.

-- 
Peter Rockai | me()mornfall!net | prockai()redhat!com
 http://blog.mornfall.net | http://web.mornfall.net

"In My Egotistical Opinion, most people's C programs should be
 indented six feet downward and covered with dirt."
     -- Blair P. Houghton on the subject of C program indentation


More information about the darcs-users mailing list