-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
281 lines (242 loc) · 10.8 KB
/
index.html
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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
<!DOCTYPE html>
<!-- Copyright 2013 the V8 project authors. Scroll to the end for full license -->
<html lang="en">
<head>
<meta http-equiv="X-UA-Compatible" value="IE=edge"/>
<meta charset="utf-8"/>
<title>Intika LVP Octane 2.0 JavaScript Benchmark</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="Content-Script-Type" content="text/javascript">
<meta name="description"
content="Intika LVP Octane 2.0 JavaScript Benchmark - the Javascript benchmark for the modern web">
<meta name="author" content="Octane Team Google">
<!-- twitter bootstrap code -->
<script src="js/jquery.js"></script>
<script src="js/bootstrap-transition.js"></script>
<script src="js/bootstrap-collapse.js"></script>
<!-- Octane benchmark code -->
<script type="text/javascript" src="base.js"></script>
<script type="text/javascript" src="regexp.js"></script>
<script type="text/javascript" src="navier-stokes.js"></script>
<script type="text/javascript" src="code-load.js"></script>
<script type="text/javascript" src="zlib.js"></script>
<script type="text/javascript" src="zlib-data.js"></script>
<script type="text/javascript">
var completed = 0;
var benchmarks = BenchmarkSuite.CountBenchmarks();
var success = true;
var latencyBenchmarks = ["Splay", "Mandreel"];
var skipBenchmarks =
typeof skipBenchmarks === "undefined" ? [] : skipBenchmarks;
function ShowBox(name) {
var box = document.getElementById("Box-" + name);
box.style.visibility = 'visible';
var bar = document.getElementById("progress-bar").style.width = ""
+ ((++completed) / benchmarks) * 100 + "%";
latencyBenchmarks.forEach(function(entry) {
if (name.valueOf() === entry.valueOf()) {
var box1 = document.getElementById("Box-" + name + "Latency");
box1.style.visibility = 'visible';
}
});
}
function AddResult(name, result) {
console.log(name + ': ' + result);
var box = document.getElementById("Result-" + name);
box.innerHTML = result;
}
function AddError(name, error) {
console.log(name + ": " + error.message);
if (error == "TypedArrayUnsupported") {
AddResult(name, '<b>Unsupported<\/b>');
} else if (error == "PerformanceNowUnsupported") {
AddResult(name, '<b>Timer error<\/b>');
} else {
AddResult(name, '<b>Error</b>');
}
success = false;
}
function AddScore(score) {
var status = document.getElementById("main-banner");
if (success) {
status.innerHTML = "LVP Octane Score: " + score;
} else {
status.innerHTML = "LVP Octane Score (incomplete): " + score;
}
document.getElementById("progress-bar-container").style.visibility = 'hidden';
document.getElementById("bottom-text").style.visibility = 'visible';
document.getElementById("inside-anchor").removeChild(document.getElementById("bar-appendix"));
document.getElementById("alertbox").style.visibility = 'hidden';
}
function Run() {
document.getElementById("main-banner").innerHTML = "Running Octane...";
// append the progress bar elements..
document.getElementById("bar-appendix").innerHTML = "<br/><div class=\"progress progress-striped\" id=\"progress-bar-container\" style=\"visibility:hidden\"><div class=\"bar\"style=\"width: 0%;\" id=\"progress-bar\"></div></div>";
var anchor = document.getElementById("run-octane");
var parent = document.getElementById("main-container");
parent.appendChild(document.getElementById("inside-anchor"));
parent.removeChild(anchor);
document.getElementById("startup-text").innerHTML="";
document.getElementById("progress-bar-container").style.visibility = 'visible';
BenchmarkSuite.RunSuites({
NotifyStart : ShowBox,
NotifyError : AddError,
NotifyResult : AddResult,
NotifyScore : AddScore
},
skipBenchmarks);
}
function CheckCompatibility() {
// If no Typed Arrays support, show warning label.
var hasTypedArrays = typeof Uint8Array != "undefined"
&& typeof Float64Array != "undefined"
&& typeof (new Uint8Array(0)).subarray != "undefined";
if (!hasTypedArrays) {
console.log("Typed Arrays not supported");
document.getElementById("alertbox").style.display="block";
}
if (window.document.URL.indexOf('skip_zlib=1') >= 0)
skipBenchmarks.push("zlib");
if (window.document.URL.indexOf('auto=1') >= 0)
Run();
}
function Load() {
setTimeout(CheckCompatibility, 200);
}
</script>
<!-- end Octane benchmark code -->
<!-- Le styles -->
<link href="css/bootstrap.css" rel="stylesheet">
<style>
body {
padding-top: 60px;
/* 60px to make the container go all the way to the bottom of the topbar */
}
</style>
<link href="css/bootstrap-responsive.css" rel="stylesheet">
<!-- Le HTML5 shim, for IE6-8 support of HTML5 elements -->
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<!-- Le fav and touch icons -->
<!-- TODO update icons -->
<link rel="shortcut icon" href="ico/favicon.ico">
<link rel="apple-touch-icon-precomposed" sizes="144x144"
href="ico/apple-touch-icon-144-precomposed.png">
<link rel="apple-touch-icon-precomposed" sizes="114x114"
href="ico/apple-touch-icon-114-precomposed.png">
<link rel="apple-touch-icon-precomposed" sizes="72x72"
href="ico/apple-touch-icon-72-precomposed.png">
<link rel="apple-touch-icon-precomposed"
href="ico/apple-touch-icon-57-precomposed.png">
</head>
<body onLoad="Load()">
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="brand" href="#">Intika LVP Octane 2.0</a>
<!--/.nav-collapse -->
</div>
</div>
</div>
<div class="container">
<div class="alert" style="display:none" id="alertbox">
<strong>Warning</strong> This JavaScript engine does not support Typed Arrays. You might want to run the <a href="http://v8.googlecode.com/svn/data/benchmarks/v7/run.html">V8 benchmark v7</a> instead.
</div>
<div id="main-container">
<a id="run-octane" href="javascript:Run()">
<div class="hero-unit" id="inside-anchor">
<h1 align="center" id="main-banner">Start Less-Variable-Possible Octane 2.0</h1>
<div id="bar-appendix"></div>
</div>
</a>
</div>
<div id="startup-text" style="color:white;" align="center">
Please note that <a href="https://v8project.blogspot.com/2017/04/retiring-octane.html">Octane is retired</a> and no longer maintained. For more accurate results, <a href="http://developers.google.com/octane/benchmark">start the browser anew</a> before running the test.
<br/><br/>
<a href="http://developers.google.com/octane/">Documentation</a> - <a href="http://octane-benchmark.googlecode.com/svn/tags/v1/index.html">Run Octane v1</a>
</div>
<div class="header"></div>
<div class="content">
<div class="row">
<div class="span3">
<div class="box" id="Box-RegExp" style="visibility: hidden;">
<a href="http://developers.google.com/octane/benchmark#regexp"
target="_blank" style="float:left; color:#994520">Regexp</a>
<p class="p-result" id="Result-RegExp" style="float:right">...</p>
<span class="label-simple"
style="position: absolute; bottom: 3px; left: 3px;">Strings
& arrays</span>
</div>
</div>
<div class="span3">
<div class="box" id="Box-NavierStokes" style="visibility: hidden;">
<a
href="http://developers.google.com/octane/benchmark#navierstokes"
target="_blank" style="float:left; color:#994520">NavierStokes</a>
<p class="p-result" id="Result-NavierStokes" style="float:right">...</p>
<span class="label-simple"
style="position: absolute; bottom: 3px; left: 3px;">Strings
& arrays</span>
</div>
</div>
<div class="span3">
<div class="box" id="Box-CodeLoad" style="visibility: hidden;">
<a href="http://developers.google.com/octane/benchmark#codeload"
target="_blank" style="float:left; color:#994520">CodeLoad</a>
<p class="p-result" id="Result-CodeLoad" style="float:right">...</p>
<span class="label-simple"
style="position: absolute; bottom: 3px; left: 3px;">Loading
& Parsing</span>
</div>
</div>
<div class="span3">
<div class="box" id="Box-zlib" style="visibility: hidden;">
<a href="http://developers.google.com/octane/benchmark#zlib"
target="_blank" style="float:left; color:#994520">zlib</a>
<p class="p-result" id="Result-zlib" style="float:right">...</p>
<span class="label-simple"
style="position: absolute; bottom: 3px; left: 3px;">asm.js</span>
</div>
</div>
</div>
<!-- /row -->
</div>
<!-- /content -->
<div id="bottom-text" style="color:white; visibility:hidden" align="center">
<br></br>
The final score is the <a href="http://en.wikipedia.org/wiki/Geometric_mean#Properties">geometric mean</a> of the single scores. We suggest to restart the browser before repeating the test.
</div>
</div>
<!-- /container -->
</body>
</html>
<!--
// Copyright 2013 the V8 project authors (http://code.google.com/p/v8/).
// All rights reserved.
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
// copyright notice, this list of conditions and the following
// disclaimer in the documentation and/or other materials provided
// with the distribution.
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived
// from this software without specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-->