OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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/method_recognizer.h" | 5 #include "vm/method_recognizer.h" |
6 | 6 |
7 #include "vm/object.h" | 7 #include "vm/object.h" |
8 #include "vm/symbols.h" | 8 #include "vm/symbols.h" |
9 | 9 |
10 namespace dart { | 10 namespace dart { |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 | 134 |
135 #if !defined(DART_PRECOMPILED_RUNTIME) | 135 #if !defined(DART_PRECOMPILED_RUNTIME) |
136 void MethodRecognizer::InitializeState() { | 136 void MethodRecognizer::InitializeState() { |
137 GrowableArray<Library*> libs(3); | 137 GrowableArray<Library*> libs(3); |
138 libs.Add(&Library::ZoneHandle(Library::CoreLibrary())); | 138 libs.Add(&Library::ZoneHandle(Library::CoreLibrary())); |
139 libs.Add(&Library::ZoneHandle(Library::CollectionLibrary())); | 139 libs.Add(&Library::ZoneHandle(Library::CollectionLibrary())); |
140 libs.Add(&Library::ZoneHandle(Library::MathLibrary())); | 140 libs.Add(&Library::ZoneHandle(Library::MathLibrary())); |
141 libs.Add(&Library::ZoneHandle(Library::TypedDataLibrary())); | 141 libs.Add(&Library::ZoneHandle(Library::TypedDataLibrary())); |
142 libs.Add(&Library::ZoneHandle(Library::InternalLibrary())); | 142 libs.Add(&Library::ZoneHandle(Library::InternalLibrary())); |
143 libs.Add(&Library::ZoneHandle(Library::DeveloperLibrary())); | 143 libs.Add(&Library::ZoneHandle(Library::DeveloperLibrary())); |
| 144 libs.Add(&Library::ZoneHandle(Library::AsyncLibrary())); |
144 Function& func = Function::Handle(); | 145 Function& func = Function::Handle(); |
145 | 146 |
146 #define SET_RECOGNIZED_KIND(class_name, function_name, enum_name, type, fp) \ | 147 #define SET_RECOGNIZED_KIND(class_name, function_name, enum_name, type, fp) \ |
147 func = Library::GetFunction(libs, #class_name, #function_name); \ | 148 func = Library::GetFunction(libs, #class_name, #function_name); \ |
148 if (func.IsNull()) { \ | 149 if (func.IsNull()) { \ |
149 OS::PrintErr("Missing %s::%s\n", #class_name, #function_name); \ | 150 OS::PrintErr("Missing %s::%s\n", #class_name, #function_name); \ |
150 UNREACHABLE(); \ | 151 UNREACHABLE(); \ |
151 } \ | 152 } \ |
152 CHECK_FINGERPRINT3(func, class_name, function_name, enum_name, fp); \ | 153 CHECK_FINGERPRINT3(func, class_name, function_name, enum_name, fp); \ |
153 func.set_recognized_kind(k##enum_name); | 154 func.set_recognized_kind(k##enum_name); |
(...skipping 25 matching lines...) Expand all Loading... |
179 | 180 |
180 #undef SET_RECOGNIZED_KIND | 181 #undef SET_RECOGNIZED_KIND |
181 #undef SET_IS_ALWAYS_INLINE | 182 #undef SET_IS_ALWAYS_INLINE |
182 #undef SET_IS_POLYMORPHIC_TARGET | 183 #undef SET_IS_POLYMORPHIC_TARGET |
183 #undef SET_FUNCTION_BIT | 184 #undef SET_FUNCTION_BIT |
184 } | 185 } |
185 #endif // !defined(DART_PRECOMPILED_RUNTIME) | 186 #endif // !defined(DART_PRECOMPILED_RUNTIME) |
186 | 187 |
187 | 188 |
188 } // namespace dart | 189 } // namespace dart |
OLD | NEW |