Index: runtime/vm/intermediate_language_ia32.cc |
diff --git a/runtime/vm/intermediate_language_ia32.cc b/runtime/vm/intermediate_language_ia32.cc |
index 187e07141d2bb0b0b62fb6cb81ae9b2c0a129f1a..1d2ddbed7f7c777fee186b7a33e4f997ecc5724d 100644 |
--- a/runtime/vm/intermediate_language_ia32.cc |
+++ b/runtime/vm/intermediate_language_ia32.cc |
@@ -711,8 +711,11 @@ Condition TestCidsInstr::EmitComparisonCode(FlowGraphCompiler* compiler, |
__ cmpl(cid_reg, Immediate(test_cid)); |
__ j(EQUAL, result ? labels.true_label : labels.false_label); |
} |
- // No match found, deoptimize or false. |
+ // No match found, deoptimize or default action. |
if (deopt == NULL) { |
+ // If the cid is not in the list, jump to the opposite label from the cids |
+ // that are in the list. These must be all the same (see asserts in the |
+ // constructor). |
Label* target = result ? labels.false_label : labels.true_label; |
if (target != labels.fall_through) { |
__ jmp(target); |