OLD | NEW |
(Empty) | |
| 1 // Copyright 2017 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 // This benchmark is based on the six-speed benchmark build output. |
| 6 // Copyright 2014 Kevin Decker <https://github.com/kpdecker/six-speed/> |
| 7 |
| 8 new BenchmarkSuite('ES5', [1000], [ |
| 9 new Benchmark('ES5', false, false, 0, ES5), |
| 10 ]); |
| 11 |
| 12 function ES5() { |
| 13 "use strict"; |
| 14 function fn(arg, other) { |
| 15 arg = arg === undefined ? 1 : arg; |
| 16 other = other === undefined ? 3 : other; |
| 17 return other; |
| 18 } |
| 19 |
| 20 fn(); |
| 21 fn(2); |
| 22 fn(2, 4); |
| 23 } |
OLD | NEW |