Re: [PATCH] Avoid accessing a slow working copy during diffcore operations.

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

 



Hi,

On Thu, 14 Dec 2006, Alex Riesen wrote:

> On 12/14/06, Johannes Schindelin <Johannes.Schindelin@xxxxxx> wrote:
> > 
> > It is usually cheaper to just read the file, especially if it is still 
> > cached, because the alternative means unpacking the loose object, or 
> > worse, unpacking the packed object _along_ with the objects in its 
> > delta chain.
> 
> But you have to read less, and even that could be in cache as well and 
> unpacking in userspace could be faster than open/write temporary/ read 
> temporary/close/unlink temporary file on a normal system

You have to unpack anyway, since even the loose objects are packed. But to 
reconstruct a deltified object, you have to reconstruct possibly many 
objects.

So yes, if you have it in the working directory (unpacked), it should be 
faster to just read it, especially if it is still in the filesystem cache.

> > Not every OS sucks cache-wise, and you should not make others suffer 
> > for Redmond's shortcomings.
> 
> I'm just do not understand why avoiding temporary file wouldn't help all 
> OSes, even if they do not suck cache-wise.

Ah! But it is not temporary! It is the "working copy", which means the 
file you have in the working directory. IOW it is an unpacked blob, which 
happens to be already unpacked anyway.

Ciao,
Dscho

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]