Re: [PATCH 4/9] refs/reftable: don't recompute committer ident

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

 



Patrick Steinhardt <ps@xxxxxx> writes:

> In order to write reflog entries we need to compute the committer's
> identity as it becomes encoded in the log record itself. In the reftable
> backend, computing the identity is repeated for every single reflog
> entry which we are about to write in a transaction. Needless to say,
> this can be quite a waste of effort when writing many refs with reflog
> entries in a single transaction.

It would have been nice to mention which caller benefits from this
rewrite in the above.

There are four callers of the fill_reftable_log_record() function.
The patch moves the split_ident() call from the callee to these four
callers.  The write_transaction_table() function calls it in a loop,
which should give us a big boost.  For other three callers, they
call it at most twice (i.e. write_copy_table() when deleting the old
one), so their contribution to the boost should be minimal.

Makes sense.





[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