git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christian Couder <christian.couder@gmail.com>
To: git@vger.kernel.org
Cc: "Junio C Hamano" <gitster@pobox.com>, "Jeff King" <peff@peff.net>,
	"Thomas Rast" <tr@thomasrast.ch>,
	"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>,
	"Christian Couder" <chriscool@tuxfamily.org>,
	"Eric Sunshine" <sunshine@sunshineco.com>,
	"Philip Oakley" <philipoakley@iee.org>
Subject: [PATCH v1 0/2] t/perf: bisect performance regressions
Date: Sun,  8 Apr 2018 11:35:11 +0200	[thread overview]
Message-ID: <20180408093513.17769-1-chriscool@tuxfamily.org> (raw)

This is a small patch series on top of cc/perf-aggregate-sort, which
is next, to add scripts that make it much easier to bisect performance
regressions.

For example if you ran perf test using the perf.conf config file that
contains a "with libpcre", then using:

$ ./aggregate.perl --subsection "with libpcre" --sort-by=regression v2.15.1 v2.16.2 v2.17.0 

you can get a line in the output like:

+8.2% p5302-pack-index.6 14.33(44.50+0.77) 15.50(43.83+0.94) v2.16.2 v2.17.0

and you can now use this output line to bisect where the regression
comes from using:

echo "+8.2% p5302-pack-index.6 14.33(44.50+0.77) 15.50(43.83+0.94) v2.16.2 v2.17.0" | ./bisect_regression --config perf.conf --subsection "with libpcre"

Caveats:

You must make sure that the times are consistent between runs and that
there is a significant time difference between the "good" runs and the
"bad" runs.

For example the following is not easily bisectable:

+100.0% p0000-perf-lib-sanity.2 0.01(0.01+0.01) 0.02(0.02+0.00) v2.15.1 v2.16.2

as the rtime went from 0.01 s to 0.02 s and we only have 0.01 s precision.

Christian Couder (2):
  perf/run: add --subsection option
  t/perf: add scripts to bisect performance regressions

 t/perf/bisect_regression | 73 ++++++++++++++++++++++++++++++++++++++++
 t/perf/bisect_run_script | 47 ++++++++++++++++++++++++++
 t/perf/run               | 56 ++++++++++++++++++++++++------
 3 files changed, 166 insertions(+), 10 deletions(-)
 create mode 100755 t/perf/bisect_regression
 create mode 100755 t/perf/bisect_run_script

-- 
2.17.0.rc1.36.g098d832c9.dirty


             reply	other threads:[~2018-04-08  9:35 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-08  9:35 Christian Couder [this message]
2018-04-08  9:35 ` [PATCH v1 1/2] perf/run: add --subsection option Christian Couder
2018-04-08  9:44   ` Eric Sunshine
2018-04-08  9:35 ` [PATCH v1 2/2] t/perf: add scripts to bisect performance regressions Christian Couder

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180408093513.17769-1-chriscool@tuxfamily.org \
    --to=christian.couder@gmail.com \
    --cc=avarab@gmail.com \
    --cc=chriscool@tuxfamily.org \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    --cc=philipoakley@iee.org \
    --cc=sunshine@sunshineco.com \
    --cc=tr@thomasrast.ch \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).