Re: [PATCH v4 12/15] bugreport: count loose objects
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Dec 13, 2019, 21:51 UTC
- Message-ID
- <xmqqv9qjhp28.fsf@gitster-ct.c.googlers.com>
- In-Reply-To
- <20191213004312.169753-13-emilyshaffer@google.com>
Emily Shaffer <emilyshaffer@google.com> writes:
Show 7 quoted lines
> The number of unpacked objects in a user's repository may help us > understand the root of the problem they're seeing, especially if a > command is running unusually slowly. > > Rather than directly invoking 'git-count-objects', which may sometimes > fail unexpectedly on Git for Windows, manually count the contents of > .git/objects.
Is for_each_loose_object() or for_each_loose_file_in_objdir() not sufficient? We really do *not* want a redundant implementation of something we already use elsewhere in the system, especially for the purpose of this program, because you would end up reporting what you computed in a way that may be quite different from what the rest of the system that is actually used by the end users computes.