Re: [PATCH 7/7] shortlog: implement `--group=trailer` in terms of `--group=<format>`

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Oct 10, 2022 at 09:50:42PM -0400, Jeff King wrote:

> I spent a fair bit of time optimizing the regular author/committer paths
> (and I think if we restore the skip-the-dedup logic I mentioned earlier
> for those, they should be equivalent, as they already use
> format_commit_message()). But the internals of the trailer code are
> already so slow I doubt it makes much of a difference either way here.
> 
> The one thing that could hurt is that multiple trailers now require
> multiple format calls, which may load the commit object for each one. I
> think _probably_ not because we'd hopefully have it cached in the commit
> slab via the save_commit_buffer mechanism. Though I guess if we used the
> commit graph in the first place, we would need to load it. We'd also
> likely reencode, but that's a noop on utf8 commits, so it's probably not
> worth worrying about.

Looking at it more carefully, your new code also does an individual
trailer parse for each trailer. And that code is also really slow, and
better if we call it only once.

-Peff



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux