Title: [225149] trunk/Source/_javascript_Core
Revision
225149
Author
[email protected]
Date
2017-11-26 17:15:04 -0800 (Sun, 26 Nov 2017)

Log Message

[DFG] Remove GetLocalUnlinked
https://bugs.webkit.org/show_bug.cgi?id=180017

Reviewed by Saam Barati.

Since DFGArgumentsSimplificationPhase is removed 2 years ago, GetLocalUnlinked is no longer used in DFG.
This patch just removes it.

* dfg/DFGAbstractInterpreterInlines.h:
(JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
* dfg/DFGClobberize.h:
(JSC::DFG::clobberize):
* dfg/DFGCommon.h:
* dfg/DFGDoesGC.cpp:
(JSC::DFG::doesGC):
* dfg/DFGFixupPhase.cpp:
(JSC::DFG::FixupPhase::fixupNode):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::dump):
* dfg/DFGNode.h:
(JSC::DFG::Node::hasUnlinkedLocal):
(JSC::DFG::Node::convertToGetLocalUnlinked): Deleted.
(JSC::DFG::Node::convertToGetLocal): Deleted.
(JSC::DFG::Node::hasUnlinkedMachineLocal): Deleted.
(JSC::DFG::Node::setUnlinkedMachineLocal): Deleted.
(JSC::DFG::Node::unlinkedMachineLocal): Deleted.
* dfg/DFGNodeType.h:
* dfg/DFGPredictionPropagationPhase.cpp:
* dfg/DFGSafeToExecute.h:
(JSC::DFG::safeToExecute):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::compile):
* dfg/DFGStackLayoutPhase.cpp:
(JSC::DFG::StackLayoutPhase::run):
* dfg/DFGValidate.cpp:

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (225148 => 225149)


--- trunk/Source/_javascript_Core/ChangeLog	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/ChangeLog	2017-11-27 01:15:04 UTC (rev 225149)
@@ -1,5 +1,45 @@
 2017-11-26  Yusuke Suzuki  <[email protected]>
 
+        [DFG] Remove GetLocalUnlinked
+        https://bugs.webkit.org/show_bug.cgi?id=180017
+
+        Reviewed by Saam Barati.
+
+        Since DFGArgumentsSimplificationPhase is removed 2 years ago, GetLocalUnlinked is no longer used in DFG.
+        This patch just removes it.
+
+        * dfg/DFGAbstractInterpreterInlines.h:
+        (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
+        * dfg/DFGClobberize.h:
+        (JSC::DFG::clobberize):
+        * dfg/DFGCommon.h:
+        * dfg/DFGDoesGC.cpp:
+        (JSC::DFG::doesGC):
+        * dfg/DFGFixupPhase.cpp:
+        (JSC::DFG::FixupPhase::fixupNode):
+        * dfg/DFGGraph.cpp:
+        (JSC::DFG::Graph::dump):
+        * dfg/DFGNode.h:
+        (JSC::DFG::Node::hasUnlinkedLocal):
+        (JSC::DFG::Node::convertToGetLocalUnlinked): Deleted.
+        (JSC::DFG::Node::convertToGetLocal): Deleted.
+        (JSC::DFG::Node::hasUnlinkedMachineLocal): Deleted.
+        (JSC::DFG::Node::setUnlinkedMachineLocal): Deleted.
+        (JSC::DFG::Node::unlinkedMachineLocal): Deleted.
+        * dfg/DFGNodeType.h:
+        * dfg/DFGPredictionPropagationPhase.cpp:
+        * dfg/DFGSafeToExecute.h:
+        (JSC::DFG::safeToExecute):
+        * dfg/DFGSpeculativeJIT32_64.cpp:
+        (JSC::DFG::SpeculativeJIT::compile):
+        * dfg/DFGSpeculativeJIT64.cpp:
+        (JSC::DFG::SpeculativeJIT::compile):
+        * dfg/DFGStackLayoutPhase.cpp:
+        (JSC::DFG::StackLayoutPhase::run):
+        * dfg/DFGValidate.cpp:
+
+2017-11-26  Yusuke Suzuki  <[email protected]>
+
         Make ArgList::data() private again when we can remove callWasmFunction().
         https://bugs.webkit.org/show_bug.cgi?id=168582
 

Modified: trunk/Source/_javascript_Core/dfg/DFGAbstractInterpreterInlines.h (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGAbstractInterpreterInlines.h	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGAbstractInterpreterInlines.h	2017-11-27 01:15:04 UTC (rev 225149)
@@ -265,14 +265,6 @@
         break;
     }
         
-    case GetLocalUnlinked: {
-        AbstractValue value = m_state.variables().operand(node->unlinkedLocal().offset());
-        if (value.value())
-            m_state.setFoundConstants(true);
-        forNode(node) = value;
-        break;
-    }
-        
     case SetLocal: {
         m_state.variables().operand(node->local()) = forNode(node->child1());
         break;

Modified: trunk/Source/_javascript_Core/dfg/DFGClobberize.h (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGClobberize.h	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGClobberize.h	2017-11-27 01:15:04 UTC (rev 225149)
@@ -747,11 +747,6 @@
         return;
     }
         
-    case GetLocalUnlinked:
-        read(AbstractHeap(Stack, node->unlinkedLocal()));
-        def(HeapLocation(StackLoc, AbstractHeap(Stack, node->unlinkedLocal())), LazyNode(node));
-        return;
-        
     case GetByVal: {
         ArrayMode mode = node->arrayMode();
         LocationKind indexedPropertyLoc = indexedPropertyLocForResultType(node->result());

Modified: trunk/Source/_javascript_Core/dfg/DFGCommon.h (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGCommon.h	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGCommon.h	2017-11-27 01:15:04 UTC (rev 225149)
@@ -156,10 +156,10 @@
 // Describes the form you can expect the entire graph to be in.
 enum GraphForm {
     // LoadStore form means that basic blocks may freely use GetLocal, SetLocal,
-    // GetLocalUnlinked, and Flush for accessing local variables and indicating
-    // where their live ranges ought to be. Data flow between local accesses is
-    // implicit. Liveness is only explicit at block heads (variablesAtHead).
-    // This is only used by the DFG simplifier and is only preserved by same.
+    // and Flush for accessing local variables and indicating where their live
+    // ranges ought to be. Data flow between local accesses is implicit. Liveness
+    // is only explicit at block heads (variablesAtHead). This is only used by
+    // the DFG simplifier and is only preserved by same.
     //
     // For example, LoadStore form gives no easy way to determine which SetLocal's
     // flow into a GetLocal. As well, LoadStore form implies no restrictions on

Modified: trunk/Source/_javascript_Core/dfg/DFGDoesGC.cpp (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGDoesGC.cpp	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGDoesGC.cpp	2017-11-27 01:15:04 UTC (rev 225149)
@@ -64,7 +64,6 @@
     case Phi:
     case Flush:
     case PhantomLocal:
-    case GetLocalUnlinked:
     case SetArgument:
     case BitAnd:
     case BitOr:

Modified: trunk/Source/_javascript_Core/dfg/DFGFixupPhase.cpp (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGFixupPhase.cpp	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGFixupPhase.cpp	2017-11-27 01:15:04 UTC (rev 225149)
@@ -2083,7 +2083,6 @@
         case GetArgument:
         case Flush:
         case PhantomLocal:
-        case GetLocalUnlinked:
         case GetGlobalVar:
         case GetGlobalLexicalVariable:
         case NotifyWrite:

Modified: trunk/Source/_javascript_Core/dfg/DFGGraph.cpp (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGGraph.cpp	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGGraph.cpp	2017-11-27 01:15:04 UTC (rev 225149)
@@ -311,11 +311,6 @@
     }
     if (node->hasUnlinkedLocal()) 
         out.print(comma, node->unlinkedLocal());
-    if (node->hasUnlinkedMachineLocal()) {
-        VirtualRegister operand = node->unlinkedMachineLocal();
-        if (operand.isValid())
-            out.print(comma, "machine:", operand);
-    }
     if (node->hasConstantBuffer()) {
         out.print(comma);
         out.print(node->startConstant(), ":[");

Modified: trunk/Source/_javascript_Core/dfg/DFGNode.h (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGNode.h	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGNode.h	2017-11-27 01:15:04 UTC (rev 225149)
@@ -528,15 +528,6 @@
         children.reset();
     }
     
-    void convertToGetLocalUnlinked(VirtualRegister local)
-    {
-        m_op = GetLocalUnlinked;
-        m_flags &= ~NodeMustGenerate;
-        m_opInfo = local.offset();
-        m_opInfo2 = VirtualRegister().offset();
-        children.reset();
-    }
-    
     void convertToPutStack(StackAccessData* data)
     {
         m_op = PutStack;
@@ -673,15 +664,6 @@
         children = AdjacencyList();
     }
     
-    void convertToGetLocal(VariableAccessData* variable, Node* phi)
-    {
-        ASSERT(m_op == GetLocalUnlinked);
-        m_op = GetLocal;
-        m_opInfo = variable;
-        m_opInfo2 = OpInfoWrapper();
-        children.setChild1(Edge(phi));
-    }
-    
     void convertToToString()
     {
         ASSERT(m_op == ToPrimitive);
@@ -941,7 +923,6 @@
     bool hasUnlinkedLocal()
     {
         switch (op()) {
-        case GetLocalUnlinked:
         case ExtractOSREntryLocal:
         case MovHint:
         case ZombieHint:
@@ -958,23 +939,6 @@
         return VirtualRegister(m_opInfo.as<int32_t>());
     }
     
-    bool hasUnlinkedMachineLocal()
-    {
-        return op() == GetLocalUnlinked;
-    }
-    
-    void setUnlinkedMachineLocal(VirtualRegister reg)
-    {
-        ASSERT(hasUnlinkedMachineLocal());
-        m_opInfo2 = reg.offset();
-    }
-    
-    VirtualRegister unlinkedMachineLocal()
-    {
-        ASSERT(hasUnlinkedMachineLocal());
-        return VirtualRegister(m_opInfo2.as<int32_t>());
-    }
-    
     bool hasStackAccessData()
     {
         switch (op()) {

Modified: trunk/Source/_javascript_Core/dfg/DFGNodeType.h (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGNodeType.h	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGNodeType.h	2017-11-27 01:15:04 UTC (rev 225149)
@@ -99,11 +99,6 @@
     macro(CheckTierUpAndOSREnter, NodeMustGenerate) \
     macro(CheckTierUpAtReturn, NodeMustGenerate) \
     \
-    /* Get the value of a local variable, without linking into the VariableAccessData */\
-    /* network. This is only valid for variable accesses whose predictions originated */\
-    /* as something other than a local access, and thus had their own profiling. */\
-    macro(GetLocalUnlinked, NodeResultJS) \
-    \
     /* Marker for an argument being set at the prologue of a function. */\
     macro(SetArgument, 0) \
     \

Modified: trunk/Source/_javascript_Core/dfg/DFGPredictionPropagationPhase.cpp (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGPredictionPropagationPhase.cpp	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGPredictionPropagationPhase.cpp	2017-11-27 01:15:04 UTC (rev 225149)
@@ -1052,7 +1052,6 @@
 
         case PutByValAlias:
         case DoubleAsInt32:
-        case GetLocalUnlinked:
         case CheckArray:
         case CheckTypeInfoFlags:
         case Arrayify:

Modified: trunk/Source/_javascript_Core/dfg/DFGSafeToExecute.h (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGSafeToExecute.h	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGSafeToExecute.h	2017-11-27 01:15:04 UTC (rev 225149)
@@ -186,7 +186,6 @@
     case Phi:
     case Flush:
     case PhantomLocal:
-    case GetLocalUnlinked:
     case SetArgument:
     case BitAnd:
     case BitOr:

Modified: trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT32_64.cpp (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT32_64.cpp	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT32_64.cpp	2017-11-27 01:15:04 UTC (rev 225149)
@@ -2206,15 +2206,6 @@
         }
         break;
     }
-        
-    case GetLocalUnlinked: {
-        GPRTemporary payload(this);
-        GPRTemporary tag(this);
-        m_jit.load32(JITCompiler::payloadFor(node->unlinkedMachineLocal()), payload.gpr());
-        m_jit.load32(JITCompiler::tagFor(node->unlinkedMachineLocal()), tag.gpr());
-        jsValueResult(tag.gpr(), payload.gpr(), node);
-        break;
-    }
 
     case MovHint: {
         compileMovHint(m_currentNode);

Modified: trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT64.cpp (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT64.cpp	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGSpeculativeJIT64.cpp	2017-11-27 01:15:04 UTC (rev 225149)
@@ -2296,15 +2296,6 @@
         break;
     }
 
-    case GetLocalUnlinked: {
-        GPRTemporary result(this);
-        
-        m_jit.load64(JITCompiler::addressFor(node->unlinkedMachineLocal()), result.gpr());
-        
-        jsValueResult(result.gpr(), node);
-        break;
-    }
-        
     case MovHint: {
         compileMovHint(m_currentNode);
         noResult(node);

Modified: trunk/Source/_javascript_Core/dfg/DFGStackLayoutPhase.cpp (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGStackLayoutPhase.cpp	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGStackLayoutPhase.cpp	2017-11-27 01:15:04 UTC (rev 225149)
@@ -73,15 +73,6 @@
                     break;
                 }
                     
-                case GetLocalUnlinked: {
-                    VirtualRegister operand = node->unlinkedLocal();
-                    if (operand.isArgument())
-                        break;
-                    usedLocals.set(operand.toLocal());
-                    hasNodesThatNeedFixup = true;
-                    break;
-                }
-                    
                 case LoadVarargs:
                 case ForwardVarargs: {
                     LoadVarargsData* data = ""
@@ -212,7 +203,7 @@
                 RELEASE_ASSERT(inlineCallFrame->calleeRecovery.isConstant());
         }
         
-        // Fix GetLocalUnlinked's variable references.
+        // Fix Varargs' variable references.
         if (hasNodesThatNeedFixup) {
             for (BlockIndex blockIndex = m_graph.numBlocks(); blockIndex--;) {
                 BasicBlock* block = m_graph.block(blockIndex);
@@ -221,11 +212,6 @@
                 for (unsigned nodeIndex = block->size(); nodeIndex--;) {
                     Node* node = block->at(nodeIndex);
                     switch (node->op()) {
-                    case GetLocalUnlinked: {
-                        node->setUnlinkedMachineLocal(assign(allocation, node->unlinkedLocal()));
-                        break;
-                    }
-                        
                     case LoadVarargs:
                     case ForwardVarargs: {
                         LoadVarargsData* data = ""

Modified: trunk/Source/_javascript_Core/dfg/DFGValidate.cpp (225148 => 225149)


--- trunk/Source/_javascript_Core/dfg/DFGValidate.cpp	2017-11-26 22:13:08 UTC (rev 225148)
+++ trunk/Source/_javascript_Core/dfg/DFGValidate.cpp	2017-11-27 01:15:04 UTC (rev 225149)
@@ -715,7 +715,6 @@
                     
                 case GetLocal:
                 case SetLocal:
-                case GetLocalUnlinked:
                 case SetArgument:
                 case Phantom:
                     VALIDATE((node), !"bad node type for SSA");
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to