interpreting --time output
Giorgos Keramidas
keramida at ceid.upatras.gr
Mon Oct 13 05:36:04 UTC 2008
On Mon, 13 Oct 2008 05:17:24 +0000, "TK Soh" <teekaysoh at gmail.com> wrote:
> I compared mainline's tip to 1.0.1 on Window XP, by running 'hg --time
> status' on the netbean repo:
>
> Hg 1.0.1:
> Time: real 16.408 secs (user 8.281+0.000 sys 6.891+0.000)
>
> mainline tip:
> Time: real 9.269 secs (user 5.078+0.000 sys 2.844+0.000)
>
> The 'real' time is obvious. But I wonder how I should interpret the
> user and sys time.
>
> Also, very often the time data varies from run to run due to varying
> system loading. So, it there anyway I can be sure if the data are
> 'telling the truth'?
Yes, there is bound to be some amount of uncertainty if you run the test
only once. You could run the same tests, in single user mode, multiple
times, and then use something like FreeBSD's ``ministat'' utility to
compare the pairs of real/sys/usr times.
The source of the latest version of ministat is available here:
http://svn.freebsd.org/viewvc/base/head/usr.bin/ministat/ministat.c?revision=HEAD&view=markup
The source includes a small set of FreeBSD-specific bits but it should
be pretty easy to port to Linux too, and it is a very nice utility for
comparing tests that have been run multiple times.
The output of ministat looks like this:
: x a-real
: + b-real
: +------------------------------------------------------------------------------+
: | * |
: | * |
: | * |
: | * |
: | * |
: | * |
: | * |
: | * |
: | * |
: | * |
: | * |
: | * + |
: | * + |
: | * + + |
: | * + x + x + x |
: | *x +x x x* +x x + + x+ + x x x|
: ||__|___M_____A___A______|_________| |
: +------------------------------------------------------------------------------+
: N Min Max Median Avg Stddev
: x 30 0.089 0.408 0.091 0.13531034 0.076856593
: + 30 0.089 0.257 0.091 0.11962069 0.046985875
: No difference proven at 95.0% confidence
The times shown here were obtained by running:
(a) `du -sh' and
(b) `du -shl'
in my `/hg/mercurial' set of repositories, so there isn't a lot of
difference between dataset (a) and (b).
With a more realistic test, the output of ministat is probably going to
be a bit more helpful :)
More information about the Mercurial
mailing list