| 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 1323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1334 | 1334 |
| 1335 if (FLAG_support_debugger) { | 1335 if (FLAG_support_debugger) { |
| 1336 isolate->debugger()->NotifyCompilation(function); | 1336 isolate->debugger()->NotifyCompilation(function); |
| 1337 } | 1337 } |
| 1338 | 1338 |
| 1339 if (FLAG_disassemble && FlowGraphPrinter::ShouldPrint(function)) { | 1339 if (FLAG_disassemble && FlowGraphPrinter::ShouldPrint(function)) { |
| 1340 Disassembler::DisassembleCode(function, optimized); | 1340 Disassembler::DisassembleCode(function, optimized); |
| 1341 } else if (FLAG_disassemble_optimized && | 1341 } else if (FLAG_disassemble_optimized && |
| 1342 optimized && | 1342 optimized && |
| 1343 FlowGraphPrinter::ShouldPrint(function)) { | 1343 FlowGraphPrinter::ShouldPrint(function)) { |
| 1344 // TODO(fschneider): Print unoptimized code along with the optimized code. | |
| 1345 THR_Print("*** BEGIN CODE\n"); | |
| 1346 Disassembler::DisassembleCode(function, true); | 1344 Disassembler::DisassembleCode(function, true); |
| 1347 THR_Print("*** END CODE\n"); | |
| 1348 } | 1345 } |
| 1349 DEBUG_ONLY(CheckInliningIntervals(function)); | 1346 DEBUG_ONLY(CheckInliningIntervals(function)); |
| 1350 return Error::null(); | 1347 return Error::null(); |
| 1351 } else { | 1348 } else { |
| 1352 Thread* const thread = Thread::Current(); | 1349 Thread* const thread = Thread::Current(); |
| 1353 StackZone stack_zone(thread); | 1350 StackZone stack_zone(thread); |
| 1354 Error& error = Error::Handle(); | 1351 Error& error = Error::Handle(); |
| 1355 // We got an error during compilation or it is a bailout from background | 1352 // We got an error during compilation or it is a bailout from background |
| 1356 // compilation (e.g., during parsing with EnsureIsFinalized). | 1353 // compilation (e.g., during parsing with EnsureIsFinalized). |
| 1357 error = thread->sticky_error(); | 1354 error = thread->sticky_error(); |
| (...skipping 755 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2113 } | 2110 } |
| 2114 | 2111 |
| 2115 | 2112 |
| 2116 void BackgroundCompiler::EnsureInit(Thread* thread) { | 2113 void BackgroundCompiler::EnsureInit(Thread* thread) { |
| 2117 UNREACHABLE(); | 2114 UNREACHABLE(); |
| 2118 } | 2115 } |
| 2119 | 2116 |
| 2120 #endif // DART_PRECOMPILED_RUNTIME | 2117 #endif // DART_PRECOMPILED_RUNTIME |
| 2121 | 2118 |
| 2122 } // namespace dart | 2119 } // namespace dart |
| OLD | NEW |