| 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 "platform/assert.h" | 5 #include "platform/assert.h" |
| 6 #include "vm/assembler.h" | 6 #include "vm/assembler.h" |
| 7 #include "vm/class_finalizer.h" | 7 #include "vm/class_finalizer.h" |
| 8 #include "vm/compiler.h" | 8 #include "vm/compiler.h" |
| 9 #include "vm/dart_entry.h" | 9 #include "vm/dart_entry.h" |
| 10 #include "vm/object.h" | 10 #include "vm/object.h" |
| 11 #include "vm/resolver.h" | 11 #include "vm/resolver.h" |
| 12 #include "vm/symbols.h" | 12 #include "vm/symbols.h" |
| 13 #include "vm/unit_test.h" | 13 #include "vm/unit_test.h" |
| 14 | 14 |
| 15 namespace dart { | 15 namespace dart { |
| 16 | 16 |
| 17 // Only ia32 and x64 can run execution tests. | 17 // Compiler only implemented on IA32, X64, and ARM. |
| 18 #if defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64) | 18 #if defined(TARGET_ARCH_IA32) || \ |
| 19 defined(TARGET_ARCH_X64) || \ |
| 20 defined(TARGET_ARCH_ARM) |
| 19 | 21 |
| 20 // Setup function for invocation. | 22 // Setup function for invocation. |
| 21 static void SetupFunction(const char* test_library_name, | 23 static void SetupFunction(const char* test_library_name, |
| 22 const char* test_class_name, | 24 const char* test_class_name, |
| 23 const char* test_static_function_name, | 25 const char* test_static_function_name, |
| 24 bool is_static) { | 26 bool is_static) { |
| 25 // Setup a dart class and function. | 27 // Setup a dart class and function. |
| 26 char script_chars[1024]; | 28 char script_chars[1024]; |
| 27 OS::SNPrint(script_chars, | 29 OS::SNPrint(script_chars, |
| 28 sizeof(script_chars), | 30 sizeof(script_chars), |
| (...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 String::Handle(String::New("dynCall")); | 214 String::Handle(String::New("dynCall")); |
| 213 const Function& super_function = Function::Handle( | 215 const Function& super_function = Function::Handle( |
| 214 Resolver::ResolveDynamic(receiver, | 216 Resolver::ResolveDynamic(receiver, |
| 215 super_function_name, | 217 super_function_name, |
| 216 kNumPositionalArguments, | 218 kNumPositionalArguments, |
| 217 kNumNamedArguments)); | 219 kNumNamedArguments)); |
| 218 EXPECT(!super_function.IsNull()); | 220 EXPECT(!super_function.IsNull()); |
| 219 } | 221 } |
| 220 } | 222 } |
| 221 | 223 |
| 222 #endif // defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64). | 224 #endif // TARGET_ARCH_IA32 || TARGET_ARCH_X64 || TARGET_ARCH_ARM |
| 223 | 225 |
| 224 } // namespace dart | 226 } // namespace dart |
| OLD | NEW |