From: J. Bruce Fields Date: Wed, 10 Oct 2007 21:53:17 GMT Subject: Re: git branch performance problem? Message-ID: <20071010215317.GC2963@fieldses.org> In-Reply-To: On Wed, Oct 10, 2007 at 06:49:19PM -0300, Han-Wen Nienhuys wrote: > 2007/10/10, Lars Hjemli : > > On 10/10/07, J. Bruce Fields wrote: > > > On Wed, Oct 10, 2007 at 06:30:02PM -0300, Han-Wen Nienhuys wrote: > > > > could it be that GC does not handle cyclic alternates correctly? > > > > > > Does it handle alternates at all? If you run git-gc on a repository > > > which other repositories get objects from, then my impression was that > > > bad things happen. > > > > > > > AFAIK 'git gc' is safe, while 'git gc --prune' will remove loose > > (unreferenced) objects. > > Yes, I think that in this case, gc --prune was run accidentally, but > given that the history of the program invoking git just died, I'm not > sure how to figure that out. > > Maybe gc --prune could follow the alternates and abort if a cycle was detected? Don't the alternates point in the wrong direction? You'd need pointers back from the main repository to the repositories that depend on it for objects. Which would be nice.... --b.