Reviewers: fschneider,

Message:
This fixes the current failures for no-snapshot debug builders on the waterfall.

Description:
Fix list traversal of optimized functions in deoptimizer.

[email protected]


Please review this at https://chromiumcodereview.appspot.com/10546179/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files:
  M src/deoptimizer.cc


Index: src/deoptimizer.cc
diff --git a/src/deoptimizer.cc b/src/deoptimizer.cc
index 3debf55cd6510a2d3322d3e55f04e0f1bf0977cb..972f24b78070e39c4078ac3bcc7ed1302b60e3a0 100644
--- a/src/deoptimizer.cc
+++ b/src/deoptimizer.cc
@@ -277,10 +277,11 @@ void Deoptimizer::VisitAllOptimizedFunctionsForContext(
   Object* element = context->OptimizedFunctionsListHead();
   while (!element->IsUndefined()) {
     JSFunction* element_function = JSFunction::cast(element);
-    // Get the next link before deoptimizing as deoptimizing will clear the
-    // next link.
-    element = element_function->next_function_link();
+    ASSERT(element_function->IsOptimized());
     visitor->VisitFunction(element_function);
+    // Restart at the head of the list as deoptimizer has removed the
+    // previous head and possibly other links as well.
+    element = context->OptimizedFunctionsListHead();
   }
   visitor->LeaveContext(context);
 }


--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to