Subject: Re: What's cooking in git.git (Sep 2021, #08; Mon, 27)

From: Junio C Hamano <[email-masked]>
Date: Tue, 28 Sep 2021 10:25:08 -0700

Ævar Arnfjörð Bjarmason <[email-masked]> writes:

> I haven't poked at it much, but haven't you and Neeraj Singh (CC'd)
> independently come up with two slightly different changes in
> tmp-objdir.c to do the same thing? See the tmp-objdir.c part of:
>
> http://lore.kernel.org/git/543e[email-masked]
>
> And your:
>
> http://lore.kernel.org/git/67d3[email-masked]
>
> I.e. yours has the object database managed outside, his has it added to
> "struct tmp_objdir", but it's the same objdir dance isn't it?

They touch the same tmp-objdir, but unlike the original use in the
receive-pack (i.e. responding to "git push") with the intention to
add the objects collected in them back to the primary, remerge-diff
wants to discard what was added there at the end.  I do not think it
would directly help the bulk-fsync stuff (but I didn't quite see why
bulk-fsync stuff needed to _add_ new functions to tmp-objdir API,
instead of just being a customer of tmp-objdir API), where it wants
to do the same _migrate() dance in the end.