Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(610)

Side by Side Diff: test/perf/input/if_10_mod2_test.html

Issue 11683002: Setting up benchmarks and perf utilities (Closed) Base URL: git@github.com:dart-lang/web-ui.git@master
Patch Set: john comments Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « test/perf/input/if_10_mod100_test.html ('k') | test/perf/input/if_1_mod100_test.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <!--
3 Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
4 for details. All rights reserved. Use of this source code is governed by a
5 BSD-style license that can be found in the LICENSE file.
6 -->
7 <html lang="en">
8 <head>
9 <!--
10 This performance test toggles 10 conditionals once every benchmark iteration.
11 -->
12 <meta charset="utf-8">
13 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
14 <script type="application/javascript" src="testing.js"></script>
15 <script type="application/javascript" src="start_dart.js"></script>
16 </head>
17 <body>
18 <template instantiate="if x % 2 == 0"><span>yes</span></template>
19 <template instantiate="if x % 2 == 1"><span>y</span></template>
20 <template instantiate="if x % 2 == 0"><span>yes</span></template>
21 <template instantiate="if x % 2 == 1"><span>y</span></template>
22 <template instantiate="if x % 2 == 0"><span>yes</span></template>
23 <template instantiate="if x % 2 == 1"><span>y</span></template>
24 <template instantiate="if x % 2 == 0"><span>yes</span></template>
25 <template instantiate="if x % 2 == 1"><span>y</span></template>
26 <template instantiate="if x % 2 == 0"><span>yes</span></template>
27 <template instantiate="if x % 2 == 1"><span>y</span></template>
28 <script type="application/dart">
29 import 'dart:html';
30 import 'package:web_ui/web_ui.dart';
31 import 'package:unittest/unittest.dart';
32 import 'perf_common.dart';
33
34 main() {
35 useShadowDom = false;
36 window.setTimeout(() {
37 var bench = new ConditionalBenchmark();
38 perfDone(bench.measure());
39 }, 0);
40 }
41
42 int x = 0;
43
44 class ConditionalBenchmark extends BenchmarkBase {
45 ConditionalBenchmark() : super('if-10-mod2');
46 run() {
47 x++;
48 dispatch();
49 }
50 }
51 </script>
52 </body>
53 </html>
OLDNEW
« no previous file with comments | « test/perf/input/if_10_mod100_test.html ('k') | test/perf/input/if_1_mod100_test.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698