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

Unified Diff: runtime/vm/flow_graph_compiler_ia32.cc

Issue 10915026: We can throw an exception but we cannot deoptimize at a runtime call. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: runtime/vm/flow_graph_compiler_ia32.cc
===================================================================
--- runtime/vm/flow_graph_compiler_ia32.cc (revision 11671)
+++ runtime/vm/flow_graph_compiler_ia32.cc (working copy)
@@ -447,8 +447,7 @@
// Clobbers ECX and EDX.
// Returns:
// - true or false in EAX.
-void FlowGraphCompiler::GenerateInstanceOf(intptr_t deopt_id,
- intptr_t token_pos,
+void FlowGraphCompiler::GenerateInstanceOf(intptr_t token_pos,
const AbstractType& type,
bool negate_result,
LocationSummary* locs) {
@@ -491,7 +490,7 @@
__ pushl(EDX); // Instantiator type arguments.
__ LoadObject(EAX, test_cache);
__ pushl(EAX);
- GenerateCallRuntime(deopt_id, token_pos, kInstanceofRuntimeEntry, locs);
+ GenerateCallRuntime(token_pos, kInstanceofRuntimeEntry, locs);
// Pop the parameters supplied to the runtime entry. The result of the
// instanceof runtime call will be left as the result of the operation.
__ Drop(5);
@@ -530,8 +529,7 @@
// - object in EAX for successful assignable check (or throws TypeError).
// Performance notes: positive checks must be quick, negative checks can be slow
// as they throw an exception.
-void FlowGraphCompiler::GenerateAssertAssignable(intptr_t deopt_id,
- intptr_t token_pos,
+void FlowGraphCompiler::GenerateAssertAssignable(intptr_t token_pos,
const AbstractType& dst_type,
const String& dst_name,
LocationSummary* locs) {
@@ -559,8 +557,7 @@
__ pushl(EAX); // Push the source object.
__ PushObject(dst_name); // Push the name of the destination.
__ PushObject(error_message);
- GenerateCallRuntime(deopt_id,
- token_pos,
+ GenerateCallRuntime(token_pos,
kMalformedTypeErrorRuntimeEntry,
locs);
// We should never return here.
@@ -588,7 +585,7 @@
__ PushObject(dst_name); // Push the name of the destination.
__ LoadObject(EAX, test_cache);
__ pushl(EAX);
- GenerateCallRuntime(deopt_id, token_pos, kTypeCheckRuntimeEntry, locs);
+ GenerateCallRuntime(token_pos, kTypeCheckRuntimeEntry, locs);
// Pop the parameters supplied to the runtime entry. The result of the
// type check runtime call is the checked value.
__ Drop(6);
@@ -940,8 +937,7 @@
__ cmpl(EAX, Immediate(Smi::RawValue(parameter_count)));
__ j(EQUAL, &argc_in_range, Assembler::kNearJump);
if (function.IsClosureFunction()) {
- GenerateCallRuntime(Isolate::kNoDeoptId,
- function.token_pos(),
+ GenerateCallRuntime(function.token_pos(),
kClosureArgumentMismatchRuntimeEntry,
prologue_locs);
} else {
@@ -1038,13 +1034,12 @@
}
-void FlowGraphCompiler::GenerateCallRuntime(intptr_t deopt_id,
- intptr_t token_pos,
+void FlowGraphCompiler::GenerateCallRuntime(intptr_t token_pos,
const RuntimeEntry& entry,
LocationSummary* locs) {
ASSERT(!IsLeaf());
__ CallRuntime(entry);
- AddCurrentDescriptor(PcDescriptors::kOther, deopt_id, token_pos);
+ AddCurrentDescriptor(PcDescriptors::kOther, Isolate::kNoDeoptId, token_pos);
RecordSafepoint(locs);
}

Powered by Google App Engine
This is Rietveld 408576698