Index: runtime/vm/flow_graph_optimizer.cc |
diff --git a/runtime/vm/flow_graph_optimizer.cc b/runtime/vm/flow_graph_optimizer.cc |
index 460295d4b194459612c2a1f629a73605fd316e73..82541e0f72bfcb65ad6cad5626eb18fabdb3bb09 100644 |
--- a/runtime/vm/flow_graph_optimizer.cc |
+++ b/runtime/vm/flow_graph_optimizer.cc |
@@ -52,7 +52,6 @@ DECLARE_FLAG(bool, precompilation); |
DECLARE_FLAG(bool, polymorphic_with_deopt); |
DECLARE_FLAG(bool, trace_cha); |
DECLARE_FLAG(bool, trace_field_guards); |
-DECLARE_FLAG(bool, warn_on_javascript_compatibility); |
// Quick access to the current isolate and zone. |
#define I (isolate()) |
@@ -164,14 +163,6 @@ bool FlowGraphOptimizer::TryCreateICData(InstanceCallInstr* call) { |
// to megamorphic call. |
return false; |
} |
- if (FLAG_warn_on_javascript_compatibility) { |
- // Do not make the instance call megamorphic if the callee needs to decode |
- // the calling code sequence to lookup the ic data and verify if a warning |
- // has already been issued or not. |
- if (call->ic_data()->MayCheckForJSWarning()) { |
- return false; |
- } |
- } |
GrowableArray<intptr_t> class_ids(call->ic_data()->NumArgsTested()); |
ASSERT(call->ic_data()->NumArgsTested() <= call->ArgumentCount()); |
for (intptr_t i = 0; i < call->ic_data()->NumArgsTested(); i++) { |
@@ -2980,15 +2971,6 @@ void FlowGraphOptimizer::ReplaceWithInstanceOf(InstanceCallInstr* call) { |
} |
const ICData& unary_checks = |
ICData::ZoneHandle(Z, call->ic_data()->AsUnaryClassChecks()); |
- if (FLAG_warn_on_javascript_compatibility && |
- !unary_checks.IssuedJSWarning() && |
- (type.IsIntType() || type.IsDoubleType() || !type.IsInstantiated())) { |
- // No warning was reported yet for this type check, either because it has |
- // not been executed yet, or because no problematic combinations of instance |
- // type and test type have been encountered so far. A warning may still be |
- // reported, so do not replace the instance call. |
- return; |
- } |
if ((unary_checks.NumberOfChecks() > 0) && |
(unary_checks.NumberOfChecks() <= FLAG_max_polymorphic_checks)) { |
ZoneGrowableArray<intptr_t>* results = |
@@ -3070,15 +3052,6 @@ void FlowGraphOptimizer::ReplaceWithTypeCast(InstanceCallInstr* call) { |
ASSERT(!type.IsMalformedOrMalbounded()); |
const ICData& unary_checks = |
ICData::ZoneHandle(Z, call->ic_data()->AsUnaryClassChecks()); |
- if (FLAG_warn_on_javascript_compatibility && |
- !unary_checks.IssuedJSWarning() && |
- (type.IsIntType() || type.IsDoubleType() || !type.IsInstantiated())) { |
- // No warning was reported yet for this type check, either because it has |
- // not been executed yet, or because no problematic combinations of instance |
- // type and test type have been encountered so far. A warning may still be |
- // reported, so do not replace the instance call. |
- return; |
- } |
if ((unary_checks.NumberOfChecks() > 0) && |
(unary_checks.NumberOfChecks() <= FLAG_max_polymorphic_checks)) { |
ZoneGrowableArray<intptr_t>* results = |