summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2019-05-08 11:49:49 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-05-08 22:56:45 +0100
commitcdce17f82062c04197f4a0e981bd4b76e0def1cb (patch)
tree1beff078f200e5e47285ce50f18f2138adb8cd6b /scripts
parent020911ab590624406f406237f8750b0ea8be320b (diff)
downloadpoky-cdce17f82062c04197f4a0e981bd4b76e0def1cb.tar.gz
scripts/pybootchart/draw: Clarify some variable names
This tweaks some intermediate variable names to make it clearer what is being done. (From OE-Core rev: 50d9af7bcb05823db36e86170ef9ba3a1d6cfeca) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/pybootchartgui/pybootchartgui/draw.py19
1 files changed, 10 insertions, 9 deletions
diff --git a/scripts/pybootchartgui/pybootchartgui/draw.py b/scripts/pybootchartgui/pybootchartgui/draw.py
index 99b3caacc7..b3184411cb 100644
--- a/scripts/pybootchartgui/pybootchartgui/draw.py
+++ b/scripts/pybootchartgui/pybootchartgui/draw.py
@@ -513,18 +513,19 @@ def render_processes_chart(ctx, options, trace, curr_y, w, h, sec_w):
513 y = curr_y+header_h 513 y = curr_y+header_h
514 514
515 offset = trace.min or min(trace.start.keys()) 515 offset = trace.min or min(trace.start.keys())
516 for s in sorted(trace.start.keys()): 516 for start in sorted(trace.start.keys()):
517 for val in sorted(trace.start[s]): 517 for process in sorted(trace.start[start]):
518 if not options.app_options.show_all and \ 518 if not options.app_options.show_all and \
519 trace.processes[val][1] - s < options.app_options.mintime: 519 trace.processes[process][1] - start < options.app_options.mintime:
520 continue 520 continue
521 task = val.split(":")[1] 521 task = process.split(":")[1]
522 #print(val) 522
523 #print(trace.processes[val][1]) 523 #print(process)
524 #print(trace.processes[process][1])
524 #print(s) 525 #print(s)
525 526
526 x = chart_rect[0] + (s - offset) * sec_w 527 x = chart_rect[0] + (start - offset) * sec_w
527 w = ((trace.processes[val][1] - s) * sec_w) 528 w = ((trace.processes[process][1] - start) * sec_w)
528 529
529 #print("proc at %s %s %s %s" % (x, y, w, proc_h)) 530 #print("proc at %s %s %s %s" % (x, y, w, proc_h))
530 col = None 531 col = None
@@ -549,7 +550,7 @@ def render_processes_chart(ctx, options, trace, curr_y, w, h, sec_w):
549 draw_fill_rect(ctx, col, (x, y, w, proc_h)) 550 draw_fill_rect(ctx, col, (x, y, w, proc_h))
550 draw_rect(ctx, PROC_BORDER_COLOR, (x, y, w, proc_h)) 551 draw_rect(ctx, PROC_BORDER_COLOR, (x, y, w, proc_h))
551 552
552 draw_label_in_box(ctx, PROC_TEXT_COLOR, val, x, y + proc_h - 4, w, proc_h) 553 draw_label_in_box(ctx, PROC_TEXT_COLOR, process, x, y + proc_h - 4, w, proc_h)
553 y = y + proc_h 554 y = y + proc_h
554 555
555 return curr_y 556 return curr_y