Reapply optimization of DeoptimizeIf for ia32 broken in r13633.
authormstarzinger@chromium.org <mstarzinger@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Wed, 27 Feb 2013 15:17:27 +0000 (15:17 +0000)
committermstarzinger@chromium.org <mstarzinger@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Wed, 27 Feb 2013 15:17:27 +0000 (15:17 +0000)
R=danno@chromium.org

Review URL: https://codereview.chromium.org/12340113

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@13767 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

src/ia32/lithium-codegen-ia32.cc

index 2df5709..5fc069b 100644 (file)
@@ -897,6 +897,11 @@ void LCodeGen::DeoptimizeIf(Condition cc, LEnvironment* environment) {
     } else {
       __ jmp(entry, RelocInfo::RUNTIME_ENTRY);
     }
+  } else if (!needs_lazy_deopt && frame_is_built_) {
+    // Optimization for ia32 only that skips the indirection through a
+    // jump table entry for conditional deopts if possible.
+    ASSERT(cc != no_condition);
+    __ j(cc, entry, RelocInfo::RUNTIME_ENTRY);
   } else {
     // We often have several deopts to the same entry, reuse the last
     // jump entry if this is the case.