OLD | NEW |
1 // Copyright 2017 the V8 project authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Flags: --allow-natives-syntax | 5 // Flags: --allow-natives-syntax --no-always-opt --crankshaft |
6 | 6 |
7 var source = | 7 var source = |
8 ` | 8 ` |
9 function fib(x) { | 9 function fib(x) { |
10 if (x < 2) return 1; | 10 if (x < 2) return 1; |
11 return fib(x-1) + fib(x-2); | 11 return fib(x-1) + fib(x-2); |
12 } | 12 } |
13 function is_optimized(f) { | 13 function is_optimized(f) { |
14 return (%GetOptimizationStatus(f) & 16) ? "optimized" : "unoptimized"; | 14 return (%GetOptimizationStatus(f) & 16) ? "optimized" : "unoptimized"; |
15 } | 15 } |
(...skipping 242 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
258 .then(() => Protocol.Runtime.evaluate({ expression: "f()" })) | 258 .then(() => Protocol.Runtime.evaluate({ expression: "f()" })) |
259 .then(Protocol.Profiler.takePreciseCoverage) | 259 .then(Protocol.Profiler.takePreciseCoverage) |
260 .then(LogSorted) | 260 .then(LogSorted) |
261 .then(Protocol.Profiler.stopPreciseCoverage) | 261 .then(Protocol.Profiler.stopPreciseCoverage) |
262 .then(Protocol.Profiler.disable) | 262 .then(Protocol.Profiler.disable) |
263 .then(Protocol.Runtime.disable) | 263 .then(Protocol.Runtime.disable) |
264 .then(ClearAndGC) | 264 .then(ClearAndGC) |
265 .then(next); | 265 .then(next); |
266 }, | 266 }, |
267 ]); | 267 ]); |
OLD | NEW |