From: Linus Torvalds <torvalds@linux-foundation.org>
To: Nicolas Pitre <nico@cam.org>
Cc: "Shawn O. Pearce" <spearce@spearce.org>,
Junio C Hamano <junkio@cox.net>,
git@vger.kernel.org
Subject: Re: [PATCH] Limit the size of the new delta_base_cache
Date: Mon, 19 Mar 2007 10:07:43 -0700 (PDT) [thread overview]
Message-ID: <Pine.LNX.4.64.0703191004560.6730@woody.linux-foundation.org> (raw)
In-Reply-To: <alpine.LFD.0.83.0703191218190.18328@xanadu.home>
On Mon, 19 Mar 2007, Nicolas Pitre wrote:
>
> In fact, the bigger is the object, the more effective will be the cache.
Yes. BUT ONLY IF THE CACHE ISN'T SIZE-LIMITED!
Once you limit the size of the cache, you change the whole equation.
It's usually *more* expensive to re-parse two half-sized objects than it
is to parse one large object. So if you have to choose between
throwing out two small objects or throwing out one large one, you
should choose the single large one.
Which totally throws your argument out of the window. It's simply not true
any more: the cache will *not* be more effective the larger the objects
are, because you are ignoring the fact that adding a large object will
*remove* many small ones.
So if I were Junio, I wouldn't accept your patch as it is now. Your
argument is simply fundamentally flawed.
Linus
next prev parent reply other threads:[~2007-03-19 17:08 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-19 5:14 [PATCH] Limit the size of the new delta_base_cache Shawn O. Pearce
2007-03-19 16:10 ` Linus Torvalds
2007-03-19 16:41 ` Nicolas Pitre
2007-03-19 16:54 ` Nicolas Pitre
2007-03-19 17:18 ` Linus Torvalds
2007-03-19 17:07 ` Linus Torvalds [this message]
2007-03-19 17:17 ` Linus Torvalds
2007-03-19 18:08 ` Nicolas Pitre
-- strict thread matches above, loose matches on Subject: below --
2007-03-19 4:48 Shawn O. Pearce
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.64.0703191004560.6730@woody.linux-foundation.org \
--to=torvalds@linux-foundation.org \
--cc=git@vger.kernel.org \
--cc=junkio@cox.net \
--cc=nico@cam.org \
--cc=spearce@spearce.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).