| OLD | NEW | 
|    1 // Copyright (c) 2011, the Dart project authors.  Please see the AUTHORS file |    1 // Copyright (c) 2011, 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_entry.h" |    5 #include "vm/dart_entry.h" | 
|    6  |    6  | 
|    7 #include "vm/class_finalizer.h" |    7 #include "vm/class_finalizer.h" | 
|    8 #include "vm/code_generator.h" |    8 #include "vm/code_generator.h" | 
|    9 #include "vm/compiler.h" |    9 #include "vm/compiler.h" | 
|   10 #include "vm/debugger.h" |   10 #include "vm/debugger.h" | 
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   86   Isolate* isolate = thread->isolate(); |   86   Isolate* isolate = thread->isolate(); | 
|   87   if (!function.HasCode()) { |   87   if (!function.HasCode()) { | 
|   88     const Error& error = Error::Handle( |   88     const Error& error = Error::Handle( | 
|   89         zone, Compiler::CompileFunction(thread, function)); |   89         zone, Compiler::CompileFunction(thread, function)); | 
|   90     if (!error.IsNull()) { |   90     if (!error.IsNull()) { | 
|   91       return error.raw(); |   91       return error.raw(); | 
|   92     } |   92     } | 
|   93   } |   93   } | 
|   94   // Now Call the invoke stub which will invoke the dart function. |   94   // Now Call the invoke stub which will invoke the dart function. | 
|   95   invokestub entrypoint = reinterpret_cast<invokestub>( |   95   invokestub entrypoint = reinterpret_cast<invokestub>( | 
|   96       isolate->stub_code()->InvokeDartCodeEntryPoint()); |   96       StubCode::InvokeDartCodeEntryPoint()); | 
|   97   const Code& code = Code::Handle(zone, function.CurrentCode()); |   97   const Code& code = Code::Handle(zone, function.CurrentCode()); | 
|   98   ASSERT(!code.IsNull()); |   98   ASSERT(!code.IsNull()); | 
|   99   ASSERT(Isolate::Current()->no_callback_scope_depth() == 0); |   99   ASSERT(Isolate::Current()->no_callback_scope_depth() == 0); | 
|  100   ScopedIsolateStackLimits stack_limit(isolate); |  100   ScopedIsolateStackLimits stack_limit(isolate); | 
|  101   SuspendLongJumpScope suspend_long_jump_scope(isolate); |  101   SuspendLongJumpScope suspend_long_jump_scope(isolate); | 
|  102 #if defined(USING_SIMULATOR) |  102 #if defined(USING_SIMULATOR) | 
|  103 #if defined(ARCH_IS_64_BIT) |  103 #if defined(ARCH_IS_64_BIT) | 
|  104   // TODO(zra): Change to intptr_t so we have only one case. |  104   // TODO(zra): Change to intptr_t so we have only one case. | 
|  105     return bit_copy<RawObject*, int64_t>(Simulator::Current()->Call( |  105     return bit_copy<RawObject*, int64_t>(Simulator::Current()->Call( | 
|  106         reinterpret_cast<int64_t>(entrypoint), |  106         reinterpret_cast<int64_t>(entrypoint), | 
| (...skipping 465 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  572   const Array& args = Array::Handle(Array::New(kNumArguments)); |  572   const Array& args = Array::Handle(Array::New(kNumArguments)); | 
|  573   args.SetAt(0, map); |  573   args.SetAt(0, map); | 
|  574   args.SetAt(1, key); |  574   args.SetAt(1, key); | 
|  575   args.SetAt(2, value); |  575   args.SetAt(2, value); | 
|  576   const Object& result = Object::Handle(DartEntry::InvokeFunction(function, |  576   const Object& result = Object::Handle(DartEntry::InvokeFunction(function, | 
|  577                                                                   args)); |  577                                                                   args)); | 
|  578   return result.raw(); |  578   return result.raw(); | 
|  579 } |  579 } | 
|  580  |  580  | 
|  581 }  // namespace dart |  581 }  // namespace dart | 
| OLD | NEW |