summaryrefslogtreecommitdiff
path: root/meta/classes/toaster.bbclass
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2015-12-17 14:54:53 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-12-18 12:18:14 +0000
commit5c3987226cd9669d5fc0993d0541048475af9fcb (patch)
tree6ad4b2e4ee4bce0421feab2addc02cde21ef49b0 /meta/classes/toaster.bbclass
parentb849130f71d3ba32a6fa94c291ca6ce7c7c3b3d1 (diff)
downloadopenembedded-core-5c3987226cd9669d5fc0993d0541048475af9fcb.tar.gz
openembedded-core-5c3987226cd9669d5fc0993d0541048475af9fcb.tar.bz2
openembedded-core-5c3987226cd9669d5fc0993d0541048475af9fcb.zip
toaster: Update for buildstats changes
This updates the toaster class to use the new data format from buildstats. This does mean it will no longer read IO data from older builds, however since that data is completely useless anyway, I don't consider that to be an issue. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/toaster.bbclass')
-rw-r--r--meta/classes/toaster.bbclass12
1 files changed, 4 insertions, 8 deletions
diff --git a/meta/classes/toaster.bbclass b/meta/classes/toaster.bbclass
index d63cff532e..7af495ed7c 100644
--- a/meta/classes/toaster.bbclass
+++ b/meta/classes/toaster.bbclass
@@ -199,8 +199,6 @@ python toaster_collect_task_stats() {
def _read_stats(filename):
cpu_usage = 0
disk_io = 0
- startio = '0'
- endio = '0'
started = '0'
ended = '0'
pn = ''
@@ -215,11 +213,11 @@ python toaster_collect_task_stats() {
if "CPU usage" in statinfo:
cpu_usage = str(statinfo["CPU usage"]).strip('% \n\r')
- if "EndTimeIO" in statinfo:
- endio = str(statinfo["EndTimeIO"]).strip('% \n\r')
+ if "IO write_bytes" in statinfo:
+ disk_io = disk_io + str(statinfo["IO write_bytes"]).strip('% \n\r')
- if "StartTimeIO" in statinfo:
- startio = str(statinfo["StartTimeIO"]).strip('% \n\r')
+ if "IO read_bytes" in statinfo:
+ disk_io = disk_io + str(statinfo["IO read_bytes"]).strip('% \n\r')
if "Started" in statinfo:
started = str(statinfo["Started"]).strip('% \n\r')
@@ -227,8 +225,6 @@ python toaster_collect_task_stats() {
if "Ended" in statinfo:
ended = str(statinfo["Ended"]).strip('% \n\r')
- disk_io = int(endio) - int(startio)
-
elapsed_time = float(ended) - float(started)
cpu_usage = float(cpu_usage)