summaryrefslogtreecommitdiffstats
path: root/scripts/lib/build_perf/html/report.html
diff options
context:
space:
mode:
authorNinette Adhikari <13760198+ninetteadhikari@users.noreply.github.com>2024-05-03 16:43:38 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2024-05-15 16:39:19 +0100
commit314a220280840b5f0f52becc928b16d0ee7d8f2b (patch)
tree1c1ef9222177542aeed9425f509da1bef17ea1bb /scripts/lib/build_perf/html/report.html
parent99861c17e7a47cbbd492f98336439a5ab3e8742e (diff)
downloadpoky-314a220280840b5f0f52becc928b16d0ee7d8f2b.tar.gz
oe-build-perf-report: Improve report styling and add descriptions
Styling updates are added including page margin, labels for x and y axis, tooltip, and section descriptions. (From OE-Core rev: 2a2568fcf1a3f8e467bd814f4fb13dffae8ec61d) Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib/build_perf/html/report.html')
-rw-r--r--scripts/lib/build_perf/html/report.html90
1 files changed, 64 insertions, 26 deletions
diff --git a/scripts/lib/build_perf/html/report.html b/scripts/lib/build_perf/html/report.html
index 653fd985bc..4cd240760a 100644
--- a/scripts/lib/build_perf/html/report.html
+++ b/scripts/lib/build_perf/html/report.html
@@ -24,23 +24,15 @@
24 text-align: left; 24 text-align: left;
25 border-collapse: collapse; 25 border-collapse: collapse;
26} 26}
27.meta-table tr:nth-child(even){background-color: #f2f2f2}
28meta-table th, .meta-table td {
29 padding: 4px;
30}
31.summary { 27.summary {
32 margin: 0;
33 font-size: 14px; 28 font-size: 14px;
34 text-align: left; 29 text-align: left;
35 border-collapse: collapse; 30 border-collapse: collapse;
36} 31}
37summary th, .meta-table td {
38 padding: 4px;
39}
40.measurement { 32.measurement {
41 padding: 8px 0px 8px 8px; 33 padding: 8px 0px 8px 8px;
42 border: 2px solid #f0f0f0; 34 border: 2px solid #f0f0f0;
43 margin-bottom: 10px; 35 margin: 1.5rem 0;
44} 36}
45.details { 37.details {
46 margin: 0; 38 margin: 0;
@@ -60,18 +52,58 @@ summary th, .meta-table td {
60 background-color: #f0f0f0; 52 background-color: #f0f0f0;
61 margin-left: 10px; 53 margin-left: 10px;
62} 54}
63hr { 55.card-container {
64 color: #f0f0f0; 56 border-bottom-width: 1px;
57 padding: 1.25rem 3rem;
58 box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
59 border-radius: 0.25rem;
60}
61body {
62 font-family: 'Helvetica', sans-serif;
63 margin: 3rem 8rem;
64}
65h1 {
66 text-align: center;
65} 67}
66h2 { 68h2 {
67 font-size: 20px; 69 font-size: 1.5rem;
68 margin-bottom: 0px; 70 margin-bottom: 0px;
69 color: #707070; 71 color: #707070;
72 padding-top: 1.5rem;
70} 73}
71h3 { 74h3 {
72 font-size: 16px; 75 font-size: 1.3rem;
73 margin: 0px; 76 margin: 0px;
74 color: #707070; 77 color: #707070;
78 padding: 1.5rem 0;
79}
80h4 {
81 font-size: 14px;
82 font-weight: lighter;
83 line-height: 1.2rem;
84 margin: auto;
85 padding-top: 1rem;
86}
87table {
88 margin-top: 1.5rem;
89 line-height: 2rem;
90}
91tr {
92 border-bottom: 1px solid #e5e7eb;
93}
94tr:first-child {
95 border-bottom: 1px solid #9ca3af;
96}
97tr:last-child {
98 border-bottom: none;
99}
100a {
101 text-decoration: none;
102 font-weight: bold;
103 color: #0000EE;
104}
105a:hover {
106 color: #8080ff;
75} 107}
76</style> 108</style>
77 109
@@ -79,13 +111,14 @@ h3 {
79</head> 111</head>
80 112
81{% macro poky_link(commit) -%} 113{% macro poky_link(commit) -%}
82 <a href="http://git.yoctoproject.org/cgit/cgit.cgi/poky/log/?id={{ commit }}">{{ commit[0:11] }}</a> 114 <a href="http://git.yoctoproject.org/cgit/cgit.cgi/poky/log/?id={{ commit }}">{{ commit[0:11] }}</a>
83{%- endmacro %} 115{%- endmacro %}
84 116
85<body><div style="width: 700px"> 117<body><div>
118 <h1 style="text-align: center;">Performance Test Report</h1>
86 {# Test metadata #} 119 {# Test metadata #}
87 <h2>General</h2> 120 <h2>General</h2>
88 <hr> 121 <h4>The table provides an overview of the comparison between two selected commits from the same branch.</h4>
89 <table class="meta-table" style="width: 100%"> 122 <table class="meta-table" style="width: 100%">
90 <tr> 123 <tr>
91 <th></th> 124 <th></th>
@@ -108,19 +141,21 @@ h3 {
108 141
109 {# Test result summary #} 142 {# Test result summary #}
110 <h2>Test result summary</h2> 143 <h2>Test result summary</h2>
111 <hr> 144 <h4>The test summary presents a thorough breakdown of each test conducted on the branch, including details such as build time and disk space consumption. Additionally, it gives insights into the average time taken for test execution, along with absolute and relative values for a better understanding.</h4>
112 <table class="summary" style="width: 100%"> 145 <table class="summary" style="width: 100%">
146 <tr>
147 <th>Test name</th>
148 <th>Measurement description</th>
149 <th>Mean value</th>
150 <th>Absolute difference</th>
151 <th>Relative difference</th>
152 </tr>
113 {% for test in test_data %} 153 {% for test in test_data %}
114 {% if loop.index is even %}
115 {% set row_style = 'style="background-color: #f2f2f2"' %}
116 {% else %}
117 {% set row_style = 'style="background-color: #ffffff"' %}
118 {% endif %}
119 {% if test.status == 'SUCCESS' %} 154 {% if test.status == 'SUCCESS' %}
120 {% for measurement in test.measurements %} 155 {% for measurement in test.measurements %}
121 <tr {{ row_style }}> 156 <tr {{ row_style }}>
122 {% if loop.index == 1 %} 157 {% if loop.index == 1 %}
123 <td>{{ test.name }}: {{ test.description }}</td> 158 <td><a href=#{{test.name}}>{{ test.name }}: {{ test.description }}</a></td>
124 {% else %} 159 {% else %}
125 {# add empty cell in place of the test name#} 160 {# add empty cell in place of the test name#}
126 <td></td> 161 <td></td>
@@ -149,10 +184,12 @@ h3 {
149 </table> 184 </table>
150 185
151 {# Detailed test results #} 186 {# Detailed test results #}
187 <h2>Test details</h2>
188 <h4>The following section provides details of each test, accompanied by charts representing build time and disk usage over time or by commit number.</h4>
152 {% for test in test_data %} 189 {% for test in test_data %}
153 <h2>{{ test.name }}: {{ test.description }}</h2> 190 <h3 style="color: #000;" id={{test.name}}>{{ test.name }}: {{ test.description }}</h3>
154 <hr>
155 {% if test.status == 'SUCCESS' %} 191 {% if test.status == 'SUCCESS' %}
192 <div class="card-container">
156 {% for measurement in test.measurements %} 193 {% for measurement in test.measurements %}
157 <div class="measurement"> 194 <div class="measurement">
158 <h3>{{ measurement.description }}</h3> 195 <h3>{{ measurement.description }}</h3>
@@ -271,7 +308,8 @@ h3 {
271 {% endif %} 308 {% endif %}
272 {% endif %} 309 {% endif %}
273 </div> 310 </div>
274 {% endfor %} 311 {% endfor %}
312 </div>
275 {# Unsuccessful test #} 313 {# Unsuccessful test #}
276 {% else %} 314 {% else %}
277 <span style="font-size: 150%; font-weight: bold; color: red;">{{ test.status }} 315 <span style="font-size: 150%; font-weight: bold; color: red;">{{ test.status }}