diff options
| author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-02-10 15:54:31 +0000 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-02-11 11:44:19 +0000 |
| commit | a24b1786664ce8086f4e5b40843adc35bb2de736 (patch) | |
| tree | eb0691196a2be55f9cdb03d8ce3424466b32b44f /scripts/oe-build-perf-report | |
| parent | 723bb4240ae86a6e16e2e331cbbf5114ebe25528 (diff) | |
| download | poky-a24b1786664ce8086f4e5b40843adc35bb2de736.tar.gz | |
oe-build-perf-report: Use commit_time if available
Currently, the perf report charts use start_time which is when the build
is run. If running builds for commits in the past, this is inaccurate so
switch to using the recently added commit_time if the field is present.
Over time, the reports will switch to using the more accurate values.
(From OE-Core rev: 8c22efd444b0b1486c43f01b41cba891a47c7520)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/oe-build-perf-report')
| -rwxr-xr-x | scripts/oe-build-perf-report | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/oe-build-perf-report b/scripts/oe-build-perf-report index 6c3c726ee3..a36f3c1bca 100755 --- a/scripts/oe-build-perf-report +++ b/scripts/oe-build-perf-report | |||
| @@ -338,7 +338,11 @@ def print_html_report(data, id_comp, buildstats): | |||
| 338 | commit_num = get_data_item(meta, 'layers.meta.commit_count') | 338 | commit_num = get_data_item(meta, 'layers.meta.commit_count') |
| 339 | commit = get_data_item(meta, 'layers.meta.commit') | 339 | commit = get_data_item(meta, 'layers.meta.commit') |
| 340 | # Add start_time for both test measurement types of sysres and disk usage | 340 | # Add start_time for both test measurement types of sysres and disk usage |
| 341 | start_time = test_i['start_time'][0] | 341 | try: |
| 342 | # Use the commit_time if available, falling back to start_time | ||
| 343 | start_time = get_data_item(meta, 'layers.meta.commit_time') | ||
| 344 | except KeyError: | ||
| 345 | start_time = test_i['start_time'][0] | ||
| 342 | samples.append(measurement_stats(meas_i, '', start_time)) | 346 | samples.append(measurement_stats(meas_i, '', start_time)) |
| 343 | samples[-1]['commit_num'] = commit_num | 347 | samples[-1]['commit_num'] = commit_num |
| 344 | samples[-1]['commit'] = commit | 348 | samples[-1]['commit'] = commit |
