OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #include "vm/compiler.h" | 5 #include "vm/compiler.h" |
6 | 6 |
7 #include "vm/assembler.h" | 7 #include "vm/assembler.h" |
8 | 8 |
9 #include "vm/ast_printer.h" | 9 #include "vm/ast_printer.h" |
10 #include "vm/block_scheduler.h" | 10 #include "vm/block_scheduler.h" |
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
424 | 424 |
425 // We may reattempt compilation if the function needs to be assembled using | 425 // We may reattempt compilation if the function needs to be assembled using |
426 // far branches on ARM and MIPS. In the else branch of the setjmp call, | 426 // far branches on ARM and MIPS. In the else branch of the setjmp call, |
427 // done is set to false, and use_far_branches is set to true if there is a | 427 // done is set to false, and use_far_branches is set to true if there is a |
428 // longjmp from the ARM or MIPS assemblers. In all other paths through this | 428 // longjmp from the ARM or MIPS assemblers. In all other paths through this |
429 // while loop, done is set to true. use_far_branches is always false on ia32 | 429 // while loop, done is set to true. use_far_branches is always false on ia32 |
430 // and x64. | 430 // and x64. |
431 bool done = false; | 431 bool done = false; |
432 // volatile because the variable may be clobbered by a longjmp. | 432 // volatile because the variable may be clobbered by a longjmp. |
433 volatile bool use_far_branches = false; | 433 volatile bool use_far_branches = false; |
434 volatile bool use_speculative_inlining = true; | 434 volatile bool use_speculative_inlining = |
| 435 FLAG_max_speculative_inlining_attempts > 0; |
435 GrowableArray<intptr_t> inlining_black_list; | 436 GrowableArray<intptr_t> inlining_black_list; |
436 | 437 |
437 while (!done) { | 438 while (!done) { |
438 const intptr_t prev_deopt_id = thread->deopt_id(); | 439 const intptr_t prev_deopt_id = thread->deopt_id(); |
439 thread->set_deopt_id(0); | 440 thread->set_deopt_id(0); |
440 LongJumpScope jump; | 441 LongJumpScope jump; |
441 const intptr_t val = setjmp(*jump.Set()); | 442 const intptr_t val = setjmp(*jump.Set()); |
442 if (val == 0) { | 443 if (val == 0) { |
443 FlowGraph* flow_graph = NULL; | 444 FlowGraph* flow_graph = NULL; |
444 | 445 |
(...skipping 1530 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1975 } | 1976 } |
1976 | 1977 |
1977 | 1978 |
1978 void BackgroundCompiler::EnsureInit(Thread* thread) { | 1979 void BackgroundCompiler::EnsureInit(Thread* thread) { |
1979 UNREACHABLE(); | 1980 UNREACHABLE(); |
1980 } | 1981 } |
1981 | 1982 |
1982 #endif // DART_PRECOMPILED | 1983 #endif // DART_PRECOMPILED |
1983 | 1984 |
1984 } // namespace dart | 1985 } // namespace dart |
OLD | NEW |