Revision: 19213
Author:   [email protected]
Date:     Mon Feb 10 08:59:51 2014 UTC
Log:      Drop unused accumulated first time changes/depends.

[email protected]

Review URL: https://codereview.chromium.org/135503004
http://code.google.com/p/v8/source/detail?r=19213

Modified:
 /branches/bleeding_edge/src/hydrogen-gvn.cc
 /branches/bleeding_edge/src/hydrogen-gvn.h

=======================================
--- /branches/bleeding_edge/src/hydrogen-gvn.cc Fri Feb  7 08:59:20 2014 UTC
+++ /branches/bleeding_edge/src/hydrogen-gvn.cc Mon Feb 10 08:59:51 2014 UTC
@@ -535,13 +535,9 @@
                   block->block_id(),
                   GetGVNFlagsString(side_effects).get());

-      GVNFlagSet accumulated_first_time_depends;
-      GVNFlagSet accumulated_first_time_changes;
       HBasicBlock* last = block->loop_information()->GetLastBackEdge();
       for (int j = block->block_id(); j <= last->block_id(); ++j) {
-        ProcessLoopBlock(graph()->blocks()->at(j), block, side_effects,
-                         &accumulated_first_time_depends,
-                         &accumulated_first_time_changes);
+        ProcessLoopBlock(graph()->blocks()->at(j), block, side_effects);
       }
     }
   }
@@ -551,9 +547,7 @@
 void HGlobalValueNumberingPhase::ProcessLoopBlock(
     HBasicBlock* block,
     HBasicBlock* loop_header,
-    GVNFlagSet loop_kills,
-    GVNFlagSet* first_time_depends,
-    GVNFlagSet* first_time_changes) {
+    GVNFlagSet loop_kills) {
   HBasicBlock* pre_header = loop_header->predecessors()->at(0);
GVNFlagSet depends_flags = HValue::ConvertChangesToDependsFlags(loop_kills);
   TRACE_GVN_2("Loop invariant motion for B%d %s\n",
@@ -562,7 +556,6 @@
   HInstruction* instr = block->first();
   while (instr != NULL) {
     HInstruction* next = instr->next();
-    bool hoisted = false;
     if (instr->CheckFlag(HValue::kUseGVN)) {
       TRACE_GVN_4("Checking instruction %d (%s) %s. Loop %s\n",
                   instr->id(),
@@ -589,26 +582,9 @@
           instr->Unlink();
           instr->InsertBefore(pre_header->end());
           if (instr->HasSideEffects()) removed_side_effects_ = true;
-          hoisted = true;
         }
       }
     }
-    if (!hoisted) {
-      // If an instruction is not hoisted, we have to account for its side
-      // effects when hoisting later HTransitionElementsKind instructions.
-      GVNFlagSet previous_depends = *first_time_depends;
-      GVNFlagSet previous_changes = *first_time_changes;
-      first_time_depends->Add(instr->DependsOnFlags());
-      first_time_changes->Add(instr->ChangesFlags());
-      if (!(previous_depends == *first_time_depends)) {
-        TRACE_GVN_1("Updated first-time accumulated %s\n",
-                    GetGVNFlagsString(*first_time_depends).get());
-      }
-      if (!(previous_changes == *first_time_changes)) {
-        TRACE_GVN_1("Updated first-time accumulated %s\n",
-                    GetGVNFlagsString(*first_time_changes).get());
-      }
-    }
     instr = next;
   }
 }
=======================================
--- /branches/bleeding_edge/src/hydrogen-gvn.h  Thu Feb  6 12:35:17 2014 UTC
+++ /branches/bleeding_edge/src/hydrogen-gvn.h  Mon Feb 10 08:59:51 2014 UTC
@@ -52,9 +52,7 @@
   void LoopInvariantCodeMotion();
   void ProcessLoopBlock(HBasicBlock* block,
                         HBasicBlock* before_loop,
-                        GVNFlagSet loop_kills,
-                        GVNFlagSet* accumulated_first_time_depends,
-                        GVNFlagSet* accumulated_first_time_changes);
+                        GVNFlagSet loop_kills);
   bool AllowCodeMotion();
   bool ShouldMove(HInstruction* instr, HBasicBlock* loop_header);

--
--
v8-dev mailing list
[email protected]
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to