Rename InlineCallFrame:: getCallerSkippingDeadFrames to something more descriptive
authormsaboff@apple.com <msaboff@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 3 Nov 2015 20:02:02 +0000 (20:02 +0000)
committermsaboff@apple.com <msaboff@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 3 Nov 2015 20:02:02 +0000 (20:02 +0000)
https://bugs.webkit.org/show_bug.cgi?id=150832

Reviewed by Geoffrey Garen.

Renamed InlineCallFrame::getCallerSkippingDeadFrames() to getCallerSkippingTailCalls().
Did similar renaming to helper InlineCallFrame::computeCallerSkippingTailCalls() and
InlineCallFrame::getCallerInlineFrameSkippingTailCalls().

* bytecode/InlineCallFrame.h:
(JSC::InlineCallFrame::computeCallerSkippingTailCalls):
(JSC::InlineCallFrame::getCallerSkippingTailCalls):
(JSC::InlineCallFrame::getCallerInlineFrameSkippingTailCalls):
(JSC::InlineCallFrame::computeCallerSkippingDeadFrames): Deleted.
(JSC::InlineCallFrame::getCallerSkippingDeadFrames): Deleted.
(JSC::InlineCallFrame::getCallerInlineFrameSkippingDeadFrames): Deleted.
* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::allInlineFramesAreTailCalls):
(JSC::DFG::ByteCodeParser::currentCodeOrigin):
(JSC::DFG::ByteCodeParser::getPredictionWithoutOSRExit):
* dfg/DFGGraph.cpp:
(JSC::DFG::Graph::isLiveInBytecode):
* dfg/DFGGraph.h:
(JSC::DFG::Graph::forAllLocalsLiveInBytecode):
* dfg/DFGOSRExitCompilerCommon.cpp:
(JSC::DFG::reifyInlinedCallFrames):
* dfg/DFGPreciseLocalClobberize.h:
(JSC::DFG::PreciseLocalClobberizeAdaptor::readTop):
* dfg/DFGSpeculativeJIT32_64.cpp:
(JSC::DFG::SpeculativeJIT::emitCall):
* dfg/DFGSpeculativeJIT64.cpp:
(JSC::DFG::SpeculativeJIT::emitCall):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::DFG::LowerDFGToLLVM::codeOriginDescriptionOfCallSite):
* interpreter/StackVisitor.cpp:
(JSC::StackVisitor::gotoNextFrame):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@191965 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/bytecode/InlineCallFrame.h
Source/JavaScriptCore/dfg/DFGByteCodeParser.cpp
Source/JavaScriptCore/dfg/DFGGraph.cpp
Source/JavaScriptCore/dfg/DFGGraph.h
Source/JavaScriptCore/dfg/DFGOSRExitCompilerCommon.cpp
Source/JavaScriptCore/dfg/DFGPreciseLocalClobberize.h
Source/JavaScriptCore/dfg/DFGSpeculativeJIT32_64.cpp
Source/JavaScriptCore/dfg/DFGSpeculativeJIT64.cpp
Source/JavaScriptCore/ftl/FTLLowerDFGToLLVM.cpp
Source/JavaScriptCore/interpreter/StackVisitor.cpp

index febf60332c019928f81bd38fe8bbafb74cdb3fed..b42dad695942c5ccd3ced69fa9fc03bb785559e8 100644 (file)
@@ -1,3 +1,42 @@
+2015-11-03  Michael Saboff  <msaboff@apple.com>
+
+        Rename InlineCallFrame:: getCallerSkippingDeadFrames to something more descriptive
+        https://bugs.webkit.org/show_bug.cgi?id=150832
+
+        Reviewed by Geoffrey Garen.
+
+        Renamed InlineCallFrame::getCallerSkippingDeadFrames() to getCallerSkippingTailCalls().
+        Did similar renaming to helper InlineCallFrame::computeCallerSkippingTailCalls() and
+        InlineCallFrame::getCallerInlineFrameSkippingTailCalls().
+
+        * bytecode/InlineCallFrame.h:
+        (JSC::InlineCallFrame::computeCallerSkippingTailCalls):
+        (JSC::InlineCallFrame::getCallerSkippingTailCalls):
+        (JSC::InlineCallFrame::getCallerInlineFrameSkippingTailCalls):
+        (JSC::InlineCallFrame::computeCallerSkippingDeadFrames): Deleted.
+        (JSC::InlineCallFrame::getCallerSkippingDeadFrames): Deleted.
+        (JSC::InlineCallFrame::getCallerInlineFrameSkippingDeadFrames): Deleted.
+        * dfg/DFGByteCodeParser.cpp:
+        (JSC::DFG::ByteCodeParser::allInlineFramesAreTailCalls):
+        (JSC::DFG::ByteCodeParser::currentCodeOrigin):
+        (JSC::DFG::ByteCodeParser::getPredictionWithoutOSRExit):
+        * dfg/DFGGraph.cpp:
+        (JSC::DFG::Graph::isLiveInBytecode):
+        * dfg/DFGGraph.h:
+        (JSC::DFG::Graph::forAllLocalsLiveInBytecode):
+        * dfg/DFGOSRExitCompilerCommon.cpp:
+        (JSC::DFG::reifyInlinedCallFrames):
+        * dfg/DFGPreciseLocalClobberize.h:
+        (JSC::DFG::PreciseLocalClobberizeAdaptor::readTop):
+        * dfg/DFGSpeculativeJIT32_64.cpp:
+        (JSC::DFG::SpeculativeJIT::emitCall):
+        * dfg/DFGSpeculativeJIT64.cpp:
+        (JSC::DFG::SpeculativeJIT::emitCall):
+        * ftl/FTLLowerDFGToLLVM.cpp:
+        (JSC::FTL::DFG::LowerDFGToLLVM::codeOriginDescriptionOfCallSite):
+        * interpreter/StackVisitor.cpp:
+        (JSC::StackVisitor::gotoNextFrame):
+
 2015-11-02  Filip Pizlo  <fpizlo@apple.com>
 
         B3/Air should use bubble sort for their insertion sets, because it's faster than std::stable_sort
index 6d61b36ffcea3a5fd2e622284cb32ced6a77ccea..04108bf138e070526304ebb09a826c3e9c404d4b 100644 (file)
@@ -146,7 +146,7 @@ struct InlineCallFrame {
         return isTail(static_cast<Kind>(kind));
     }
 
-    static CodeOrigin* computeCallerSkippingDeadFrames(InlineCallFrame* inlineCallFrame, Kind* callerCallKind = nullptr)
+    static CodeOrigin* computeCallerSkippingTailCalls(InlineCallFrame* inlineCallFrame, Kind* callerCallKind = nullptr)
     {
         CodeOrigin* codeOrigin;
         bool tailCallee;
@@ -167,14 +167,14 @@ struct InlineCallFrame {
         return codeOrigin;
     }
 
-    CodeOrigin* getCallerSkippingDeadFrames(Kind* callerCallKind = nullptr)
+    CodeOrigin* getCallerSkippingTailCalls(Kind* callerCallKind = nullptr)
     {
-        return computeCallerSkippingDeadFrames(this, callerCallKind);
+        return computeCallerSkippingTailCalls(this, callerCallKind);
     }
 
-    InlineCallFrame* getCallerInlineFrameSkippingDeadFrames()
+    InlineCallFrame* getCallerInlineFrameSkippingTailCalls()
     {
-        CodeOrigin* caller = getCallerSkippingDeadFrames();
+        CodeOrigin* caller = getCallerSkippingTailCalls();
         return caller ? caller->inlineCallFrame : nullptr;
     }
     
index f5912d67464dcde749a8eb97d52578cdb249beb2..7aec5909b606a98d65d6306936565c21ee9a7198 100644 (file)
@@ -652,7 +652,7 @@ private:
 
     bool allInlineFramesAreTailCalls()
     {
-        return !inlineCallFrame() || !inlineCallFrame()->getCallerSkippingDeadFrames();
+        return !inlineCallFrame() || !inlineCallFrame()->getCallerSkippingTailCalls();
     }
 
     CodeOrigin currentCodeOrigin()
@@ -815,7 +815,7 @@ private:
                         prediction = SpecFullTop;
                         break;
                     }
-                    CodeOrigin* codeOrigin = inlineCallFrame()->getCallerSkippingDeadFrames();
+                    CodeOrigin* codeOrigin = inlineCallFrame()->getCallerSkippingTailCalls();
                     if (!codeOrigin) {
                         prediction = SpecFullTop;
                         break;
index 6d7e35065a5679dc5ec92e087e65552092f97fc5..0c80b675d93c6e25b2120c407eecfecd06bfc22c 100644 (file)
@@ -1000,7 +1000,7 @@ bool Graph::isLiveInBytecode(VirtualRegister operand, CodeOrigin codeOrigin)
             && static_cast<size_t>(reg.toArgument()) < inlineCallFrame->arguments.size())
             return true;
         
-        codeOriginPtr = inlineCallFrame->getCallerSkippingDeadFrames();
+        codeOriginPtr = inlineCallFrame->getCallerSkippingTailCalls();
 
         // The first inline call frame could be an inline tail call
         if (!codeOriginPtr)
index 4a798d258c44670347153c1e7ab2b85ca0649e74..7ca0ac79ddc9dbd7d770eb65d534fe677e031a3d 100644 (file)
@@ -762,7 +762,7 @@ public:
             for (VirtualRegister reg = exclusionStart; reg < exclusionEnd; reg += 1)
                 functor(reg);
             
-            codeOriginPtr = inlineCallFrame->getCallerSkippingDeadFrames();
+            codeOriginPtr = inlineCallFrame->getCallerSkippingTailCalls();
 
             // The first inline call frame could be an inline tail call
             if (!codeOriginPtr)
index 0aacd0491c5c543d66d63e471a0154df32e155f5..180f65d51c254c07d893f3784320fd8064d36d3d 100644 (file)
@@ -143,11 +143,11 @@ void reifyInlinedCallFrames(CCallHelpers& jit, const OSRExitBase& exit)
     jit.storePtr(AssemblyHelpers::TrustedImmPtr(jit.baselineCodeBlock()), AssemblyHelpers::addressFor((VirtualRegister)JSStack::CodeBlock));
 
     const CodeOrigin* codeOrigin;
-    for (codeOrigin = &exit.m_codeOrigin; codeOrigin && codeOrigin->inlineCallFrame; codeOrigin = codeOrigin->inlineCallFrame->getCallerSkippingDeadFrames()) {
+    for (codeOrigin = &exit.m_codeOrigin; codeOrigin && codeOrigin->inlineCallFrame; codeOrigin = codeOrigin->inlineCallFrame->getCallerSkippingTailCalls()) {
         InlineCallFrame* inlineCallFrame = codeOrigin->inlineCallFrame;
         CodeBlock* baselineCodeBlock = jit.baselineCodeBlockFor(*codeOrigin);
         InlineCallFrame::Kind trueCallerCallKind;
-        CodeOrigin* trueCaller = inlineCallFrame->getCallerSkippingDeadFrames(&trueCallerCallKind);
+        CodeOrigin* trueCaller = inlineCallFrame->getCallerSkippingTailCalls(&trueCallerCallKind);
         GPRReg callerFrameGPR = GPRInfo::callFrameRegister;
 
         if (!trueCaller) {
index 45e5cbd4075b5008d27720786ca388321196a24a..e16e0a4bab7af523c7515dfe3c77a7175c8e3775 100644 (file)
@@ -140,7 +140,7 @@ private:
                 m_read(VirtualRegister(i));
         
             // Read all of the inline arguments and call frame headers that we didn't already capture.
-            for (InlineCallFrame* inlineCallFrame = m_node->origin.semantic.inlineCallFrame; inlineCallFrame; inlineCallFrame = inlineCallFrame->getCallerInlineFrameSkippingDeadFrames()) {
+            for (InlineCallFrame* inlineCallFrame = m_node->origin.semantic.inlineCallFrame; inlineCallFrame; inlineCallFrame = inlineCallFrame->getCallerInlineFrameSkippingTailCalls()) {
                 for (unsigned i = inlineCallFrame->arguments.size(); i-- > 1;)
                     m_read(VirtualRegister(inlineCallFrame->stackOffset + virtualRegisterForArgument(i).offset()));
                 if (inlineCallFrame->isClosureCall)
index 295900392742cb3e7e598600140e6cc2a4cc2379..4d6908fc9a601a668de2816039e3604b95f06bd6 100644 (file)
@@ -855,10 +855,10 @@ void SpeculativeJIT::emitCall(Node* node)
     JITCompiler::JumpList slowPath;
 
     CodeOrigin staticOrigin = node->origin.semantic;
-    ASSERT(!isTail || !staticOrigin.inlineCallFrame || !staticOrigin.inlineCallFrame->getCallerSkippingDeadFrames());
-    ASSERT(!isEmulatedTail || (staticOrigin.inlineCallFrame && staticOrigin.inlineCallFrame->getCallerSkippingDeadFrames()));
+    ASSERT(!isTail || !staticOrigin.inlineCallFrame || !staticOrigin.inlineCallFrame->getCallerSkippingTailCalls());
+    ASSERT(!isEmulatedTail || (staticOrigin.inlineCallFrame && staticOrigin.inlineCallFrame->getCallerSkippingTailCalls()));
     CodeOrigin dynamicOrigin =
-        isEmulatedTail ? *staticOrigin.inlineCallFrame->getCallerSkippingDeadFrames() : staticOrigin;
+        isEmulatedTail ? *staticOrigin.inlineCallFrame->getCallerSkippingTailCalls() : staticOrigin;
     CallSiteIndex callSite = m_jit.recordCallSiteAndGenerateExceptionHandlingOSRExitIfNeeded(dynamicOrigin, m_stream->size());
     m_jit.emitStoreCallSiteIndex(callSite);
     
index 99aaddfa510eed43d15e9d21c86bea16da42e1ca..d0b750901e57e3e986a19b56b2976e51ca2b6fde 100644 (file)
@@ -820,10 +820,10 @@ void SpeculativeJIT::emitCall(Node* node)
     }
 
     CodeOrigin staticOrigin = node->origin.semantic;
-    ASSERT(!isTail || !staticOrigin.inlineCallFrame || !staticOrigin.inlineCallFrame->getCallerSkippingDeadFrames());
-    ASSERT(!isEmulatedTail || (staticOrigin.inlineCallFrame && staticOrigin.inlineCallFrame->getCallerSkippingDeadFrames()));
+    ASSERT(!isTail || !staticOrigin.inlineCallFrame || !staticOrigin.inlineCallFrame->getCallerSkippingTailCalls());
+    ASSERT(!isEmulatedTail || (staticOrigin.inlineCallFrame && staticOrigin.inlineCallFrame->getCallerSkippingTailCalls()));
     CodeOrigin dynamicOrigin =
-    isEmulatedTail ? *staticOrigin.inlineCallFrame->getCallerSkippingDeadFrames() : staticOrigin;
+    isEmulatedTail ? *staticOrigin.inlineCallFrame->getCallerSkippingTailCalls() : staticOrigin;
 
     CallSiteIndex callSite = m_jit.recordCallSiteAndGenerateExceptionHandlingOSRExitIfNeeded(dynamicOrigin, m_stream->size());
     m_jit.emitStoreCallSiteIndex(callSite);
index e22e8039f8ab0512c0521a08257508cfa4e96e6e..8fc2f88b99dec829969edf2aab534a9b9fcca18e 100644 (file)
@@ -8744,7 +8744,7 @@ private:
             // to baz and baz is inlined in bar. And then baz makes a tail-call to jaz,
             // and jaz is inlined in baz. We want the callframe for jaz to appear to 
             // have caller be bar.
-            codeOrigin = *codeOrigin.inlineCallFrame->getCallerSkippingDeadFrames();
+            codeOrigin = *codeOrigin.inlineCallFrame->getCallerSkippingTailCalls();
         }
 
         return codeOrigin;
index de924cdbe533fac22f33ecf270c664877dce06ad..c0c03d280192288a8cb92a001127457682315f5d 100644 (file)
@@ -59,7 +59,7 @@ void StackVisitor::gotoNextFrame()
 #if ENABLE(DFG_JIT)
     if (m_frame.isInlinedFrame()) {
         InlineCallFrame* inlineCallFrame = m_frame.inlineCallFrame();
-        CodeOrigin* callerCodeOrigin = inlineCallFrame->getCallerSkippingDeadFrames();
+        CodeOrigin* callerCodeOrigin = inlineCallFrame->getCallerSkippingTailCalls();
         if (!callerCodeOrigin) {
             while (inlineCallFrame) {
                 readInlinedFrame(m_frame.callFrame(), &inlineCallFrame->directCaller);