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

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

Issue 1584223006: Remove signature classes from the VM. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: sync Created 4 years, 11 months 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 | « runtime/vm/code_generator.cc ('k') | runtime/vm/dart_api_impl.cc » ('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 264 matching lines...) Expand 10 before | Expand all | Expand 10 after
275 RawError* Compiler::CompileClass(const Class& cls) { 275 RawError* Compiler::CompileClass(const Class& cls) {
276 ASSERT(Thread::Current()->IsMutatorThread()); 276 ASSERT(Thread::Current()->IsMutatorThread());
277 // If class is a top level class it is already parsed. 277 // If class is a top level class it is already parsed.
278 if (cls.IsTopLevel()) { 278 if (cls.IsTopLevel()) {
279 return Error::null(); 279 return Error::null();
280 } 280 }
281 // If the class is already marked for parsing return immediately. 281 // If the class is already marked for parsing return immediately.
282 if (cls.is_marked_for_parsing()) { 282 if (cls.is_marked_for_parsing()) {
283 return Error::null(); 283 return Error::null();
284 } 284 }
285 // If the class is a signature class there is no need to try and 285 // If the class is a typedef class there is no need to try and
286 // compile it. Just finalize it directly. 286 // compile it. Just finalize it directly.
287 if (cls.IsSignatureClass()) { 287 if (cls.IsTypedefClass()) {
288 #if defined(DEBUG) 288 #if defined(DEBUG)
289 const Type& type = Type::Handle( 289 const Class& closure_cls = Class::Handle(
290 Isolate::Current()->object_store()->function_impl_type()); 290 Isolate::Current()->object_store()->closure_class());
291 const Class& type_cls = Class::Handle(type.type_class()); 291 ASSERT(closure_cls.is_finalized());
292 ASSERT(type_cls.is_finalized());
293 #endif 292 #endif
294 LongJumpScope jump; 293 LongJumpScope jump;
295 if (setjmp(*jump.Set()) == 0) { 294 if (setjmp(*jump.Set()) == 0) {
296 ClassFinalizer::FinalizeClass(cls); 295 ClassFinalizer::FinalizeClass(cls);
297 return Error::null(); 296 return Error::null();
298 } else { 297 } else {
299 Thread* thread = Thread::Current(); 298 Thread* thread = Thread::Current();
300 Isolate* isolate = thread->isolate(); 299 Isolate* isolate = thread->isolate();
301 Error& error = Error::Handle(thread->zone()); 300 Error& error = Error::Handle(thread->zone());
302 error = isolate->object_store()->sticky_error(); 301 error = isolate->object_store()->sticky_error();
(...skipping 1740 matching lines...) Expand 10 before | Expand all | Expand 10 after
2043 } 2042 }
2044 2043
2045 2044
2046 void BackgroundCompiler::EnsureInit(Thread* thread) { 2045 void BackgroundCompiler::EnsureInit(Thread* thread) {
2047 UNREACHABLE(); 2046 UNREACHABLE();
2048 } 2047 }
2049 2048
2050 #endif // DART_PRECOMPILED_RUNTIME 2049 #endif // DART_PRECOMPILED_RUNTIME
2051 2050
2052 } // namespace dart 2051 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/code_generator.cc ('k') | runtime/vm/dart_api_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698