[PATCH 2 of 6 v2] util: add an elapsed time wrapper

Bryan O'Sullivan bos at serpentine.com
Fri Feb 3 18:00:55 EST 2017


On Fri, Feb 3, 2017 at 2:55 PM, Simon Farnsworth <simonfar at fb.com> wrote:

> We already capture start and exit times in the external wrapper process -
> so your added detail of measuring "useful work" (in addition to "total
> time") tells us if we're seeing a huge overhead in setup/teardown of
> Mercurial.
>

I think you might have missed a bit of crucial detail. If Mercurial sits
for 100 minutes after writing its output to the pager before the user quits
the pager, that's not going to show up as I/O time with your scheme, but it
is going to show up as elapsed time. This is why capturing that measuring
elapsed time is not useful. There's an indeterminate amount of time where
literally nothing is happening (it's not teardown, and it's not overhead,
it's just waiting for the pager) that you need to be able to discount.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mercurial-scm.org/pipermail/mercurial-devel/attachments/20170203/1e2ead64/attachment.html>


More information about the Mercurial-devel mailing list