From: Johannes Schindelin Date: Wed, 23 Jul 2008 13:46:38 GMT Subject: Re: [PATCH] index-pack: never prune base_cache. Message-ID: In-Reply-To: <20080723132031.GC20614@artemis.madism.org> Hi, On Wed, 23 Jul 2008, Pierre Habouzit wrote: > On Wed, Jul 23, 2008 at 01:09:40PM +0000, Johannes Schindelin wrote: > > On Wed, 23 Jul 2008, Björn Steinbrink wrote: > > > The patch itself should be fine. > > > > No, since it opens the whole issue of memory explosion again, the same > > issue Shawn's original patch tried to fix. > > No it won't. Indeed the issue is with fix_unresolved_deltas that > sometimes put at the root of the chain (in base_cache) something that > comes from our store, not the pack we are writing. Then starts a delta > chain resolution. If it comes from our store, we should have _no_ problem reconstructing the object. > It won't explode in memory at all, we just keep the first data of a > delta chain in memory, that's all. It indeed consumes more memory, but > we talk about *one* single object per delta chain because we're too lazy > to memorize where it comes from. It's probably not much of an explosion. "Probably". > We also waste that object even when it's from our own pack. Well, I'd > say "too bad". And I say it's dirty, and since the pack code traditionally is one of the cleanest parts of Git, coming from Nico, let's not change that, okay? Ciao, Dscho