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

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

Issue 3006923002: Revised "Eliminate dependencies on assemblers and code stubs in precompiled runtime." (Closed)
Patch Set: Explicitly clear unbox_numeric_fields flag in PRODUCT builds Created 3 years, 3 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/runtime_entry.h ('k') | runtime/vm/runtime_entry_arm.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) 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/runtime_entry.h" 5 #include "vm/runtime_entry.h"
6 6
7 #include "vm/assembler.h" 7 #include "vm/assembler.h"
8 #include "vm/ast.h" 8 #include "vm/ast.h"
9 #include "vm/code_patcher.h" 9 #include "vm/code_patcher.h"
10 #include "vm/compiler.h" 10 #include "vm/compiler.h"
(...skipping 1700 matching lines...) Expand 10 before | Expand all | Expand 10 after
1711 // recursive stack trace collection. 1711 // recursive stack trace collection.
1712 intptr_t saved_stacktrace_every = FLAG_stacktrace_every; 1712 intptr_t saved_stacktrace_every = FLAG_stacktrace_every;
1713 FLAG_stacktrace_every = 0; 1713 FLAG_stacktrace_every = 0;
1714 DebuggerStackTrace* stack = isolate->debugger()->StackTrace(); 1714 DebuggerStackTrace* stack = isolate->debugger()->StackTrace();
1715 intptr_t num_frames = stack->Length(); 1715 intptr_t num_frames = stack->Length();
1716 for (intptr_t i = 0; i < num_frames; i++) { 1716 for (intptr_t i = 0; i < num_frames; i++) {
1717 ActivationFrame* frame = stack->FrameAt(i); 1717 ActivationFrame* frame = stack->FrameAt(i);
1718 #ifndef DART_PRECOMPILED_RUNTIME 1718 #ifndef DART_PRECOMPILED_RUNTIME
1719 // Ensure that we have unoptimized code. 1719 // Ensure that we have unoptimized code.
1720 frame->function().EnsureHasCompiledUnoptimizedCode(); 1720 frame->function().EnsureHasCompiledUnoptimizedCode();
1721 const int num_vars = frame->NumLocalVariables();
1722 #else
1723 // Variable locations and number are unknown when precompiling.
1724 const int num_vars = 0;
1721 #endif 1725 #endif
1722 // Variable locations and number are unknown when precompiling.
1723 const int num_vars =
1724 FLAG_precompiled_runtime ? 0 : frame->NumLocalVariables();
1725 TokenPosition unused = TokenPosition::kNoSource; 1726 TokenPosition unused = TokenPosition::kNoSource;
1726 for (intptr_t v = 0; v < num_vars; v++) { 1727 for (intptr_t v = 0; v < num_vars; v++) {
1727 frame->VariableAt(v, &var_name, &unused, &unused, &unused, &var_value); 1728 frame->VariableAt(v, &var_name, &unused, &unused, &unused, &var_value);
1728 } 1729 }
1729 } 1730 }
1730 if (FLAG_stress_async_stacks) { 1731 if (FLAG_stress_async_stacks) {
1731 Debugger::CollectAwaiterReturnStackTrace(); 1732 Debugger::CollectAwaiterReturnStackTrace();
1732 } 1733 }
1733 FLAG_stacktrace_every = saved_stacktrace_every; 1734 FLAG_stacktrace_every = saved_stacktrace_every;
1734 } 1735 }
(...skipping 563 matching lines...) Expand 10 before | Expand all | Expand 10 after
2298 #else 2299 #else
2299 UNREACHABLE(); 2300 UNREACHABLE();
2300 #endif 2301 #endif
2301 } 2302 }
2302 2303
2303 DEFINE_RUNTIME_ENTRY(InitStaticField, 1) { 2304 DEFINE_RUNTIME_ENTRY(InitStaticField, 1) {
2304 const Field& field = Field::CheckedHandle(arguments.ArgAt(0)); 2305 const Field& field = Field::CheckedHandle(arguments.ArgAt(0));
2305 field.EvaluateInitializer(); 2306 field.EvaluateInitializer();
2306 } 2307 }
2307 2308
2309 // Print the stop message.
2310 DEFINE_LEAF_RUNTIME_ENTRY(void, PrintStopMessage, 1, const char* message) {
2311 OS::Print("Stop message: %s\n", message);
2312 }
2313 END_LEAF_RUNTIME_ENTRY
2314
2308 // Use expected function signatures to help MSVC compiler resolve overloading. 2315 // Use expected function signatures to help MSVC compiler resolve overloading.
2309 typedef double (*UnaryMathCFunction)(double x); 2316 typedef double (*UnaryMathCFunction)(double x);
2310 typedef double (*BinaryMathCFunction)(double x, double y); 2317 typedef double (*BinaryMathCFunction)(double x, double y);
2311 2318
2312 DEFINE_RAW_LEAF_RUNTIME_ENTRY( 2319 DEFINE_RAW_LEAF_RUNTIME_ENTRY(
2313 LibcPow, 2320 LibcPow,
2314 2, 2321 2,
2315 true /* is_float */, 2322 true /* is_float */,
2316 reinterpret_cast<RuntimeFunction>(static_cast<BinaryMathCFunction>(&pow))); 2323 reinterpret_cast<RuntimeFunction>(static_cast<BinaryMathCFunction>(&pow)));
2317 2324
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
2383 true /* is_float */, 2390 true /* is_float */,
2384 reinterpret_cast<RuntimeFunction>(static_cast<UnaryMathCFunction>(&tan))); 2391 reinterpret_cast<RuntimeFunction>(static_cast<UnaryMathCFunction>(&tan)));
2385 2392
2386 DEFINE_RAW_LEAF_RUNTIME_ENTRY( 2393 DEFINE_RAW_LEAF_RUNTIME_ENTRY(
2387 LibcAtan, 2394 LibcAtan,
2388 1, 2395 1,
2389 true /* is_float */, 2396 true /* is_float */,
2390 reinterpret_cast<RuntimeFunction>(static_cast<UnaryMathCFunction>(&atan))); 2397 reinterpret_cast<RuntimeFunction>(static_cast<UnaryMathCFunction>(&atan)));
2391 2398
2392 } // namespace dart 2399 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/runtime_entry.h ('k') | runtime/vm/runtime_entry_arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698