Re: [PATCH] Teach "git add" and friends to be paranoid
- From
Dmitry Potapov <dpotapov@gmail.com>
- Date
- Feb 22, 2010, 13:33 UTC
- Message-ID
- <20100222133327.GH10191@dpotapov.dyndns.org>
- In-Reply-To
- <4B827FC6.1090905@gnu.org>
On Mon, Feb 22, 2010 at 01:59:50PM +0100, Paolo Bonzini wrote:
Show 7 quoted lines
> On 02/18/2010 06:36 AM, Junio C Hamano wrote: > > > >In any case, with any size of paranoia, this hurts the sane use case > > Because by mmaping + memcpying you are getting the worst of both > cases: you get a page fault per page like with mmap, and touch > memory twice like with read.
and there is also an extra round of SHA-1 calculation, which I believe is more expensive than memcpy().
Dmitry