Reviewers: Jakob, Sven Panne,

Message:
PTAL

Description:
Don't double unlink in DCE.

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

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

Affected files:
  M src/hydrogen.cc


Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index 1b02a62c4370147bf4a7dd83f397391bdf757ad7..58a9b78750bb7401bfdc9e167800f8f01d3ef078 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -5436,6 +5436,9 @@ void HGraph::DeadCodeElimination() {

   while (!worklist.is_empty()) {
     HInstruction* instr = worklist.RemoveLast();
+ // This happens when an instruction is used multiple times as operand. That
+    // in turn could happen through GVN.
+    if (!instr->IsLinked()) continue;
     if (FLAG_trace_dead_code_elimination) {
       HeapStringAllocator allocator;
       StringStream stream(&allocator);


--
--
v8-dev mailing list
v8-dev@googlegroups.com
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to