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

Side by Side Diff: runtime/vm/compiler.cc

Issue 1513883002: Polymorphic calls in precompilation invoke megamorphic calls when tests fail (instead of deoptimizi… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: g Created 5 years 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 | « no previous file | runtime/vm/flow_graph_compiler.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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
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
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
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/flow_graph_compiler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698