| 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 291 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 302 } | 302 } |
| 303 } | 303 } |
| 304 | 304 |
| 305 Thread* const thread = Thread::Current(); | 305 Thread* const thread = Thread::Current(); |
| 306 Isolate* const isolate = thread->isolate(); | 306 Isolate* const isolate = thread->isolate(); |
| 307 StackZone zone(thread); | 307 StackZone zone(thread); |
| 308 // We remember all the classes that are being compiled in these lists. This | 308 // We remember all the classes that are being compiled in these lists. This |
| 309 // also allows us to reset the marked_for_parsing state in case we see an | 309 // also allows us to reset the marked_for_parsing state in case we see an |
| 310 // error. | 310 // error. |
| 311 VMTagScope tagScope(thread, VMTag::kCompileClassTagId); | 311 VMTagScope tagScope(thread, VMTag::kCompileClassTagId); |
| 312 TimelineDurationScope tds(thread, |
| 313 thread->isolate()->GetCompilerStream(), |
| 314 "CompileClass"); |
| 315 if (tds.enabled()) { |
| 316 tds.SetNumArguments(1); |
| 317 tds.CopyArgument( |
| 318 0, |
| 319 "class", |
| 320 const_cast<char*>(cls.ToCString())); |
| 321 } |
| 322 |
| 312 GrowableHandlePtrArray<const Class> parse_list(thread->zone(), 4); | 323 GrowableHandlePtrArray<const Class> parse_list(thread->zone(), 4); |
| 313 GrowableHandlePtrArray<const Class> patch_list(thread->zone(), 4); | 324 GrowableHandlePtrArray<const Class> patch_list(thread->zone(), 4); |
| 314 | 325 |
| 315 // Parse the class and all the interfaces it implements and super classes. | 326 // Parse the class and all the interfaces it implements and super classes. |
| 316 LongJumpScope jump; | 327 LongJumpScope jump; |
| 317 if (setjmp(*jump.Set()) == 0) { | 328 if (setjmp(*jump.Set()) == 0) { |
| 318 if (FLAG_trace_compiler) { | 329 if (FLAG_trace_compiler) { |
| 319 THR_Print("Compiling Class '%s'\n", cls.ToCString()); | 330 THR_Print("Compiling Class '%s'\n", cls.ToCString()); |
| 320 } | 331 } |
| 321 | 332 |
| (...skipping 1555 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1877 } | 1888 } |
| 1878 | 1889 |
| 1879 | 1890 |
| 1880 void BackgroundCompiler::EnsureInit(Thread* thread) { | 1891 void BackgroundCompiler::EnsureInit(Thread* thread) { |
| 1881 UNREACHABLE(); | 1892 UNREACHABLE(); |
| 1882 } | 1893 } |
| 1883 | 1894 |
| 1884 #endif // DART_PRECOMPILED | 1895 #endif // DART_PRECOMPILED |
| 1885 | 1896 |
| 1886 } // namespace dart | 1897 } // namespace dart |
| OLD | NEW |