-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
101 lines (97 loc) · 3.04 KB
/
index.html
File metadata and controls
101 lines (97 loc) · 3.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<html>
<head>
<meta charset="utf-8"/>
<style>
div.table {
width: 100%;
height: 98%;
display: table;
border-collapse: collapse;
}
div.tr {
display: table-row;
height: 30%;
}
div.td {
width: 50%;
display: table-cell;
}
</style>
<script src="https://www.gstatic.com/charts/loader.js"></script>
<script src="https://code.jquery.com/jquery-1.8.2.js"></script>
<script src="javascripts/jquery.csv.js" type="text/javascript"></script>
<script>
"use strict";
google.charts.load('current', {packages: ['corechart']});
loadCSV('data-metrics-code', function(csv) {
google.charts.setOnLoadCallback(function() {
drawChart(csv, 'Muen kernel code metrics', 'Build', 'Metrics', 'chart_metrics_code');
});
});
loadCSV('data-metrics-complexity', function(csv) {
google.charts.setOnLoadCallback(function() {
drawChart(csv, 'Muen kernel complexity metrics', 'Build', 'Metrics', 'chart_metrics_comp');
});
});
loadCSV('data-metrics-vcs', function(csv) {
google.charts.setOnLoadCallback(function() {
drawChart(csv, 'Muen kernel verification conditions (VCs)', 'Build', 'Count', 'chart_metrics_vcs');
});
});
loadCSV('data-iperf-vm', function(csv) {
google.charts.setOnLoadCallback(function() {
drawChart(csv, 'Muen inter-VM iperf over muennet', 'Build', 'Mbits', 'chart_iperf_vm');
});
});
loadCSV('data-sysbench', function(csv) {
google.charts.setOnLoadCallback(function() {
drawChart(csv, 'Muen sysbench CPU benchmark (--cpu-max-prime=10000)', 'Build', 'Seconds', 'chart_sysbench');
});
});
loadCSV('data-cycles', function(csv) {
google.charts.setOnLoadCallback(function() {
drawChart(csv, 'Muen inter-VM pingpong cycles', 'Build', 'Cycles', 'chart_cycles');
});
});
function loadCSV(file, callback) {
$.get(file, null, function(data) {
var csv = $.csv.toArrays(data, {
onParseValue: $.csv.hooks.castToScalar
});
callback(csv);
}, 'text');
}
function drawChart(dataArray, title, hAxis, vAxis, div) {
var data = google.visualization.arrayToDataTable(dataArray);
var options = {
title: title,
legend: { position: 'top' },
hAxis: { title: hAxis },
vAxis: { title: vAxis },
chartArea: { width : '84%', height: '55%' }
};
var chart = new google.visualization.LineChart(document.getElementById(div));
chart.draw(data, options);
}
</script>
</head>
<body>
<div class="table">
<div class="tr">
<div class="td" id="chart_metrics_code"></div>
<div class="td" id="chart_metrics_comp"></div>
</div>
<div class="tr">
<div class="td" id="chart_metrics_vcs"></div>
<div class="td" id="chart_sysbench"></div>
</div>
<div class="tr">
<div class="td" id="chart_iperf_vm"></div>
<div class="td" id="chart_cycles"/></div>
</div>
</div>
<div id="archive" style="font-size: xx-small;">
Archive: <a href="archive/20170630/index.html">20170630</a>, <a href="archive/20171122/index.html">20171122</a>
</div>
</body>
</html>