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

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

Issue 183803024: Adds support for ARMv6. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Added tests. Created 6 years, 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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/dart.h" 5 #include "vm/dart.h"
6 6
7 #include "vm/code_observers.h" 7 #include "vm/code_observers.h"
8 #include "vm/cpu.h" 8 #include "vm/cpu.h"
9 #include "vm/dart_api_state.h" 9 #include "vm/dart_api_state.h"
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 ASSERT(thread_pool_ == NULL); 111 ASSERT(thread_pool_ == NULL);
112 thread_pool_ = new ThreadPool(); 112 thread_pool_ = new ThreadPool();
113 { 113 {
114 ASSERT(vm_isolate_ == NULL); 114 ASSERT(vm_isolate_ == NULL);
115 ASSERT(Flags::Initialized()); 115 ASSERT(Flags::Initialized());
116 vm_isolate_ = Isolate::Init("vm-isolate"); 116 vm_isolate_ = Isolate::Init("vm-isolate");
117 StackZone zone(vm_isolate_); 117 StackZone zone(vm_isolate_);
118 HandleScope handle_scope(vm_isolate_); 118 HandleScope handle_scope(vm_isolate_);
119 Heap::Init(vm_isolate_); 119 Heap::Init(vm_isolate_);
120 ObjectStore::Init(vm_isolate_); 120 ObjectStore::Init(vm_isolate_);
121 TargetCPUFeatures::InitOnce();
121 Object::InitOnce(); 122 Object::InitOnce();
122 ArgumentsDescriptor::InitOnce(); 123 ArgumentsDescriptor::InitOnce();
123 StubCode::InitOnce(); 124 StubCode::InitOnce();
124 Symbols::InitOnce(vm_isolate_); 125 Symbols::InitOnce(vm_isolate_);
125 Scanner::InitOnce(); 126 Scanner::InitOnce();
126 Object::CreateInternalMetaData(); 127 Object::CreateInternalMetaData();
127 TargetCPUFeatures::InitOnce();
128 #if defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64) 128 #if defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64)
129 // Dart VM requires at least SSE2. 129 // Dart VM requires at least SSE2.
130 if (!TargetCPUFeatures::sse2_supported()) { 130 if (!TargetCPUFeatures::sse2_supported()) {
131 return "SSE2 is required."; 131 return "SSE2 is required.";
132 } 132 }
133 #endif 133 #endif
134 PremarkingVisitor premarker(vm_isolate_); 134 PremarkingVisitor premarker(vm_isolate_);
135 vm_isolate_->heap()->WriteProtect(false); 135 vm_isolate_->heap()->WriteProtect(false);
136 vm_isolate_->heap()->IterateOldObjects(&premarker); 136 vm_isolate_->heap()->IterateOldObjects(&premarker);
137 vm_isolate_->heap()->WriteProtect(true); 137 vm_isolate_->heap()->WriteProtect(true);
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 return predefined_handles_->handles_.AllocateScopedHandle(); 274 return predefined_handles_->handles_.AllocateScopedHandle();
275 } 275 }
276 276
277 277
278 bool Dart::IsReadOnlyHandle(uword address) { 278 bool Dart::IsReadOnlyHandle(uword address) {
279 ASSERT(predefined_handles_ != NULL); 279 ASSERT(predefined_handles_ != NULL);
280 return predefined_handles_->handles_.IsValidScopedHandle(address); 280 return predefined_handles_->handles_.IsValidScopedHandle(address);
281 } 281 }
282 282
283 } // namespace dart 283 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698