Commit Graph

14 Commits

Author SHA1 Message Date
Markus Lehtonen 3b17343e6f scripts/buildstats-diff: fix epoch numbers in --ver-diff
Incorrect data was printed (recipe name instead of epoch number) when
displaying changes in epoch.

(From OE-Core rev: 5e2b1bfb684dc76963f692172f7457c2249c3266)

(From OE-Core rev: d3f4ec2ad5e83f52f7d3824cfe1f5a64f2d81bcf)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-02-23 12:49:48 -08:00
Markus Lehtonen 48f79758ea scripts/buildstats-diff: simplify timestamp handling
Simply use floats instead of datetime and timedelta objects for handling
timestamps.

(From OE-Core rev: d97c844f388bd4c52248fe597d5985ef20d5a96d)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2017-01-28 23:32:16 +00:00
Markus Lehtonen 4f5801303e scripts/buildstats-diff: implement --multi option
Makes it possible to average over multiple buildstats. If --multi is
specified (and the given path is a directory) the script will read all
buildstats from the given directory and use averaged values calculated
from them.

All of the buildstats must be from a "similar" build, meaning that no
differences in package versions or tasks are allowed. Otherwise, the
script will exit with an error.

(From OE-Core rev: 315f44ba39e9b13facacd0fd3796fa87329d9d69)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:56 +01:00
Markus Lehtonen a235c1b7c2 scripts/buildstats-diff: make logger msg format a bit more readable
(From OE-Core rev: 49ae4382dd0a71f45989af3679bd35ce2bfa82f8)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:56 +01:00
Markus Lehtonen cbbe51f55f scripts/buildstats-diff: use exception for internal error handling
(From OE-Core rev: 17b27b7a8bfc8b1c9ee274d1ed2d5b57bea13bf5)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:56 +01:00
Markus Lehtonen 4cdf47a569 scripts/buildstats-diff: add walltime to --diff-attr
For comparing the elapsed wall clock time of tests. Default values for
--min-val and --min-absdiff are 5 seconds and 2 seconds.

(From OE-Core rev: 8e7a5beb2ce116bcd87111d190a4ac5d771e8884)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:56 +01:00
Markus Lehtonen c6047cd989 scripts/buildstats-diff: add read_ops and write_ops to --diff-attr
Two new options, making it possible to compare the number of filesystem
operations of tasks. Defaults for --min-val and --min-absdiff are set to
more or less arbitrary 500 and 50 operations, respectively.

(From OE-Core rev: 75292a1de1a59e19198d26b7c1291004a5ca92f3)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:56 +01:00
Markus Lehtonen 44bc3f47a3 scripts/buildstats-diff: add read_bytes and write_bytes to --diff-attr
These are I/O counter values from /proc/<pid>/io and represent the
number of bytes read from / written to the storage layer. Default values
for --min-val and --min-absdiff limits are set to 512kB and 128kB,
respectively.

(From OE-Core rev: 24a12e40caeb05dac13c417f35733761af219f03)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:56 +01:00
Markus Lehtonen 01a2b5823b scripts/buildstats-diff: introduce --diff-attr
A new command line option for choosing which "attribute" of the
buildstats to compare. At first, the already supported 'cputime' is the
only available option. But, refactoring done in this patch should make
it easy to add new attribute types.

(From OE-Core rev: 0782825138731b3f1e6a8e05d723c1d5cd60c90c)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:55 +01:00
Markus Lehtonen e05309194a scripts/buildstats-diff: do not hardcode field widths in output
Dynamically adjust the width of all fields in task diff output. Makes
it easier to print other units than cputime, too.

(From OE-Core rev: 559b858f2a3712ec21debb71681593bd7cf55041)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:55 +01:00
Markus Lehtonen 7113ac9439 scripts/buildstats-diff: implement BSTask class
New class representing buildstats data of a single task.

(From OE-Core rev: 472818a32f96699a6dc9c7c487f38d716678fd7a)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:55 +01:00
Markus Lehtonen 4cc1c430cd scripts/buildstats-diff: rename --min-time and --min-timediff args
Rename these arguments to --min-val and --min-absdiff in preparation for
supporting other "quantities" than just cputime.

(From OE-Core rev: 441336bc1750939c2da2d9e4dc5a6893b283bf68)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:55 +01:00
Markus Lehtonen 58bd0fd62d scripts/buildstats-diff: check that the given directory exists
(From OE-Core rev: 08082b96d8d09215f02e9251f354bb6e8bb3e712)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-10-01 21:45:55 +01:00
Markus Lehtonen 12cd9c01fc scripts: introduce buildstats-diff
New script for comparing buildstats from two separate builds. The script
has two modes: normally it prints the differences in task execution
(cpu) times but using --ver-diff option makes it just print the recipe
version differences without any cpu time data. Other command line
options are provided to alter the sort criteria of the data and to
filter out insignificant differences and/or short tasks.

(From OE-Core rev: e707718374ce1c95769a5f99aa3bfdfc0be685b2)

Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-09-16 15:24:03 +01:00