Diff
Modified: trunk/Source/_javascript_Core/CMakeLists.txt (165868 => 165869)
--- trunk/Source/_javascript_Core/CMakeLists.txt 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/CMakeLists.txt 2014-03-19 04:44:22 UTC (rev 165869)
@@ -142,7 +142,6 @@
dfg/DFGFinalizer.cpp
dfg/DFGFixupPhase.cpp
dfg/DFGFlushFormat.cpp
- dfg/DFGFlushLivenessAnalysisPhase.cpp
dfg/DFGFlushedAt.cpp
dfg/DFGGraph.cpp
dfg/DFGGraphSafepoint.cpp
Modified: trunk/Source/_javascript_Core/ChangeLog (165868 => 165869)
--- trunk/Source/_javascript_Core/ChangeLog 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/ChangeLog 2014-03-19 04:44:22 UTC (rev 165869)
@@ -1,5 +1,34 @@
2014-03-18 Filip Pizlo <[email protected]>
+ Get rid of Flush in SSA
+ https://bugs.webkit.org/show_bug.cgi?id=130440
+
+ Reviewed by Sam Weinig.
+
+ This is basically a red patch. We used to use backwards flow for determining what was
+ flushed, until it became clear that this doesn't make sense. Now the Flush nodes don't
+ accomplish anything. Keeping them around in SSA can only make things hard.
+
+ * CMakeLists.txt:
+ * GNUmakefile.list.am:
+ * _javascript_Core.vcxproj/_javascript_Core.vcxproj:
+ * _javascript_Core.xcodeproj/project.pbxproj:
+ * dfg/DFGBasicBlock.cpp:
+ (JSC::DFG::BasicBlock::SSAData::SSAData):
+ * dfg/DFGBasicBlock.h:
+ * dfg/DFGFlushLivenessAnalysisPhase.cpp: Removed.
+ * dfg/DFGFlushLivenessAnalysisPhase.h: Removed.
+ * dfg/DFGGraph.cpp:
+ (JSC::DFG::Graph::dump):
+ * dfg/DFGPlan.cpp:
+ (JSC::DFG::Plan::compileInThreadImpl):
+ * dfg/DFGSSAConversionPhase.cpp:
+ (JSC::DFG::SSAConversionPhase::run):
+ * ftl/FTLLowerDFGToLLVM.cpp:
+ (JSC::FTL::LowerDFGToLLVM::compileNode):
+
+2014-03-18 Filip Pizlo <[email protected]>
+
Unreviewed, fix iOS production build.
* _javascript_Core.xcodeproj/project.pbxproj:
Modified: trunk/Source/_javascript_Core/GNUmakefile.list.am (165868 => 165869)
--- trunk/Source/_javascript_Core/GNUmakefile.list.am 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/GNUmakefile.list.am 2014-03-19 04:44:22 UTC (rev 165869)
@@ -314,8 +314,6 @@
Source/_javascript_Core/dfg/DFGFixupPhase.h \
Source/_javascript_Core/dfg/DFGFlushFormat.cpp \
Source/_javascript_Core/dfg/DFGFlushFormat.h \
- Source/_javascript_Core/dfg/DFGFlushLivenessAnalysisPhase.cpp \
- Source/_javascript_Core/dfg/DFGFlushLivenessAnalysisPhase.h \
Source/_javascript_Core/dfg/DFGFlushedAt.cpp \
Source/_javascript_Core/dfg/DFGFlushedAt.h \
Source/_javascript_Core/dfg/DFGGenerationInfo.h \
Modified: trunk/Source/_javascript_Core/_javascript_Core.vcxproj/_javascript_Core.vcxproj (165868 => 165869)
--- trunk/Source/_javascript_Core/_javascript_Core.vcxproj/_javascript_Core.vcxproj 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/_javascript_Core.vcxproj/_javascript_Core.vcxproj 2014-03-19 04:44:22 UTC (rev 165869)
@@ -395,7 +395,6 @@
<ClCompile Include="..\dfg\DFGFixupPhase.cpp" />
<ClCompile Include="..\dfg\DFGFlushedAt.cpp" />
<ClCompile Include="..\dfg\DFGFlushFormat.cpp" />
- <ClCompile Include="..\dfg\DFGFlushLivenessAnalysisPhase.cpp" />
<ClCompile Include="..\dfg\DFGGraph.cpp" />
<ClCompile Include="..\dfg\DFGGraphSafepoint.cpp" />
<ClCompile Include="..\dfg\DFGInPlaceAbstractState.cpp" />
@@ -948,7 +947,6 @@
<ClInclude Include="..\dfg\DFGFixupPhase.h" />
<ClInclude Include="..\dfg\DFGFlushedAt.h" />
<ClInclude Include="..\dfg\DFGFlushFormat.h" />
- <ClInclude Include="..\dfg\DFGFlushLivenessAnalysisPhase.h" />
<ClInclude Include="..\dfg\DFGFPRInfo.h" />
<ClInclude Include="..\dfg\DFGGenerationInfo.h" />
<ClInclude Include="..\dfg\DFGGPRInfo.h" />
Modified: trunk/Source/_javascript_Core/_javascript_Core.xcodeproj/project.pbxproj (165868 => 165869)
--- trunk/Source/_javascript_Core/_javascript_Core.xcodeproj/project.pbxproj 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/_javascript_Core.xcodeproj/project.pbxproj 2014-03-19 04:44:22 UTC (rev 165869)
@@ -1249,8 +1249,6 @@
A7D89CF617A0B8CC00773AD8 /* DFGCriticalEdgeBreakingPhase.h in Headers */ = {isa = PBXBuildFile; fileRef = A7D89CE717A0B8CC00773AD8 /* DFGCriticalEdgeBreakingPhase.h */; settings = {ATTRIBUTES = (Private, ); }; };
A7D89CF717A0B8CC00773AD8 /* DFGFlushFormat.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A7D89CE817A0B8CC00773AD8 /* DFGFlushFormat.cpp */; };
A7D89CF817A0B8CC00773AD8 /* DFGFlushFormat.h in Headers */ = {isa = PBXBuildFile; fileRef = A7D89CE917A0B8CC00773AD8 /* DFGFlushFormat.h */; settings = {ATTRIBUTES = (Private, ); }; };
- A7D89CF917A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A7D89CEA17A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.cpp */; };
- A7D89CFA17A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.h in Headers */ = {isa = PBXBuildFile; fileRef = A7D89CEB17A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.h */; settings = {ATTRIBUTES = (Private, ); }; };
A7D89CFB17A0B8CC00773AD8 /* DFGLivenessAnalysisPhase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A7D89CEC17A0B8CC00773AD8 /* DFGLivenessAnalysisPhase.cpp */; };
A7D89CFC17A0B8CC00773AD8 /* DFGLivenessAnalysisPhase.h in Headers */ = {isa = PBXBuildFile; fileRef = A7D89CED17A0B8CC00773AD8 /* DFGLivenessAnalysisPhase.h */; settings = {ATTRIBUTES = (Private, ); }; };
A7D89CFD17A0B8CC00773AD8 /* DFGOSRAvailabilityAnalysisPhase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A7D89CEE17A0B8CC00773AD8 /* DFGOSRAvailabilityAnalysisPhase.cpp */; };
@@ -2798,8 +2796,6 @@
A7D89CE717A0B8CC00773AD8 /* DFGCriticalEdgeBreakingPhase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGCriticalEdgeBreakingPhase.h; path = dfg/DFGCriticalEdgeBreakingPhase.h; sourceTree = "<group>"; };
A7D89CE817A0B8CC00773AD8 /* DFGFlushFormat.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGFlushFormat.cpp; path = dfg/DFGFlushFormat.cpp; sourceTree = "<group>"; };
A7D89CE917A0B8CC00773AD8 /* DFGFlushFormat.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGFlushFormat.h; path = dfg/DFGFlushFormat.h; sourceTree = "<group>"; };
- A7D89CEA17A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGFlushLivenessAnalysisPhase.cpp; path = dfg/DFGFlushLivenessAnalysisPhase.cpp; sourceTree = "<group>"; };
- A7D89CEB17A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGFlushLivenessAnalysisPhase.h; path = dfg/DFGFlushLivenessAnalysisPhase.h; sourceTree = "<group>"; };
A7D89CEC17A0B8CC00773AD8 /* DFGLivenessAnalysisPhase.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGLivenessAnalysisPhase.cpp; path = dfg/DFGLivenessAnalysisPhase.cpp; sourceTree = "<group>"; };
A7D89CED17A0B8CC00773AD8 /* DFGLivenessAnalysisPhase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGLivenessAnalysisPhase.h; path = dfg/DFGLivenessAnalysisPhase.h; sourceTree = "<group>"; };
A7D89CEE17A0B8CC00773AD8 /* DFGOSRAvailabilityAnalysisPhase.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGOSRAvailabilityAnalysisPhase.cpp; path = dfg/DFGOSRAvailabilityAnalysisPhase.cpp; sourceTree = "<group>"; };
@@ -4367,8 +4363,6 @@
0F9D339517FFC4E60073C2BC /* DFGFlushedAt.h */,
A7D89CE817A0B8CC00773AD8 /* DFGFlushFormat.cpp */,
A7D89CE917A0B8CC00773AD8 /* DFGFlushFormat.h */,
- A7D89CEA17A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.cpp */,
- A7D89CEB17A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.h */,
86EC9DB61328DF82002B2AD7 /* DFGGenerationInfo.h */,
86EC9DB71328DF82002B2AD7 /* DFGGraph.cpp */,
86EC9DB81328DF82002B2AD7 /* DFGGraph.h */,
@@ -5086,7 +5080,6 @@
0F2BDC16151C5D4F00CD8910 /* DFGFixupPhase.h in Headers */,
0F9D339717FFC4E60073C2BC /* DFGFlushedAt.h in Headers */,
A7D89CF817A0B8CC00773AD8 /* DFGFlushFormat.h in Headers */,
- A7D89CFA17A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.h in Headers */,
86EC9DC61328DF82002B2AD7 /* DFGGenerationInfo.h in Headers */,
86EC9DC81328DF82002B2AD7 /* DFGGraph.h in Headers */,
0F2FCCFA18A60070001A27F8 /* DFGGraphSafepoint.h in Headers */,
@@ -6287,7 +6280,6 @@
0F2BDC15151C5D4D00CD8910 /* DFGFixupPhase.cpp in Sources */,
0F9D339617FFC4E60073C2BC /* DFGFlushedAt.cpp in Sources */,
A7D89CF717A0B8CC00773AD8 /* DFGFlushFormat.cpp in Sources */,
- A7D89CF917A0B8CC00773AD8 /* DFGFlushLivenessAnalysisPhase.cpp in Sources */,
86EC9DC71328DF82002B2AD7 /* DFGGraph.cpp in Sources */,
0F2FCCF918A60070001A27F8 /* DFGGraphSafepoint.cpp in Sources */,
A704D90517A0BAA8006BA554 /* DFGInPlaceAbstractState.cpp in Sources */,
Modified: trunk/Source/_javascript_Core/dfg/DFGBasicBlock.cpp (165868 => 165869)
--- trunk/Source/_javascript_Core/dfg/DFGBasicBlock.cpp 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/dfg/DFGBasicBlock.cpp 2014-03-19 04:44:22 UTC (rev 165869)
@@ -111,9 +111,7 @@
}
BasicBlock::SSAData::SSAData(BasicBlock* block)
- : flushAtHead(OperandsLike, block->variablesAtHead)
- , flushAtTail(OperandsLike, block->variablesAtHead)
- , availabilityAtHead(OperandsLike, block->variablesAtHead)
+ : availabilityAtHead(OperandsLike, block->variablesAtHead)
, availabilityAtTail(OperandsLike, block->variablesAtHead)
{
}
Modified: trunk/Source/_javascript_Core/dfg/DFGBasicBlock.h (165868 => 165869)
--- trunk/Source/_javascript_Core/dfg/DFGBasicBlock.h 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/dfg/DFGBasicBlock.h 2014-03-19 04:44:22 UTC (rev 165869)
@@ -143,8 +143,6 @@
unsigned innerMostLoopIndices[numberOfInnerMostLoopIndices];
struct SSAData {
- Operands<FlushedAt> flushAtHead;
- Operands<FlushedAt> flushAtTail;
Operands<Availability> availabilityAtHead;
Operands<Availability> availabilityAtTail;
HashSet<Node*> liveAtHead;
Deleted: trunk/Source/_javascript_Core/dfg/DFGFlushLivenessAnalysisPhase.cpp (165868 => 165869)
--- trunk/Source/_javascript_Core/dfg/DFGFlushLivenessAnalysisPhase.cpp 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/dfg/DFGFlushLivenessAnalysisPhase.cpp 2014-03-19 04:44:22 UTC (rev 165869)
@@ -1,208 +0,0 @@
-/*
- * Copyright (C) 2013 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "DFGFlushLivenessAnalysisPhase.h"
-
-#if ENABLE(DFG_JIT)
-
-#include "DFGBasicBlockInlines.h"
-#include "DFGGraph.h"
-#include "DFGInsertionSet.h"
-#include "DFGPhase.h"
-#include "OperandsInlines.h"
-#include "JSCInlines.h"
-
-namespace JSC { namespace DFG {
-
-class FlushLivenessAnalysisPhase : public Phase {
-public:
- FlushLivenessAnalysisPhase(Graph& graph)
- : Phase(graph, "flush-liveness analysis")
- {
- }
-
- bool run()
- {
- ASSERT(m_graph.m_form == SSA);
-
- // Liveness is a backwards analysis; the roots are the blocks that
- // end in a terminal (Return/Unreachable). For now, we
- // use a fixpoint formulation since liveness is a rapid analysis with
- // convergence guaranteed after O(connectivity).
-
- // Start by assuming that everything is dead.
- for (BlockIndex blockIndex = m_graph.numBlocks(); blockIndex--;) {
- BasicBlock* block = m_graph.block(blockIndex);
- if (!block)
- continue;
- block->ssa->flushAtHead.fill(FlushedAt());
- block->ssa->flushAtTail.fill(FlushedAt());
- }
-
- do {
- m_changed = false;
- for (BlockIndex blockIndex = m_graph.numBlocks(); blockIndex--;)
- process(blockIndex);
- } while (m_changed);
-
- Operands<FlushedAt>& root = m_graph.block(0)->ssa->flushAtHead;
- for (unsigned i = root.size(); i--;) {
- if (root.isArgument(i)) {
- if (!root[i]
- || root[i] == FlushedAt(FlushedJSValue, VirtualRegister(root.operandForIndex(i))))
- continue;
- } else {
- if (!root[i])
- continue;
- }
- dataLog(
- "Bad flush liveness analysis result: bad flush liveness at root: ",
- root, "\n");
- dataLog("IR at time of error:\n");
- m_graph.dump();
- CRASH();
- }
-
- return true;
- }
-
-private:
- void process(BlockIndex blockIndex)
- {
- BasicBlock* block = m_graph.block(blockIndex);
- if (!block)
- return;
-
- m_live = block->ssa->flushAtTail;
-
- for (unsigned nodeIndex = block->size(); nodeIndex--;) {
- Node* node = block->at(nodeIndex);
-
- switch (node->op()) {
- case SetLocal: {
- VariableAccessData* variable = node->variableAccessData();
- FlushedAt& current = m_live.operand(variable->local());
- if (!!current && current != variable->flushedAt())
- reportError(node);
- current = FlushedAt();
- break;
- }
-
- case GetArgument: {
- VariableAccessData* variable = node->variableAccessData();
- ASSERT(variable->local() == variable->machineLocal());
- ASSERT(variable->local().isArgument());
- FlushedAt& current = m_live.operand(variable->local());
- if (!!current && current != variable->flushedAt())
- reportError(node);
- current = FlushedAt(FlushedJSValue, node->local());
- break;
- }
-
- case Flush:
- case GetLocal: {
- VariableAccessData* variable = node->variableAccessData();
- FlushedAt& current = m_live.operand(variable->local());
- if (!!current && current != variable->flushedAt())
- reportError(node);
- current = variable->flushedAt();
- break;
- }
-
- default:
- break;
- }
- }
-
- if (m_live == block->ssa->flushAtHead)
- return;
-
- m_changed = true;
- block->ssa->flushAtHead = m_live;
- for (unsigned i = block->predecessors.size(); i--;) {
- BasicBlock* predecessor = block->predecessors[i];
- for (unsigned j = m_live.size(); j--;) {
- FlushedAt& predecessorFlush = predecessor->ssa->flushAtTail[j];
- FlushedAt myFlush = m_live[j];
-
- // Three possibilities:
- // 1) Predecessor format is Dead, in which case it acquires our format.
- // 2) Predecessor format is not Dead but our format is dead, in which
- // case we acquire the predecessor format.
- // 3) Predecessor format is identical to our format, in which case we
- // do nothing.
- // 4) Predecessor format is different from our format and it's not Dead,
- // in which case we have an erroneous set of Flushes and SetLocals.
-
- if (!predecessorFlush) {
- predecessorFlush = myFlush;
- continue;
- }
-
- if (!myFlush) {
- m_live[j] = predecessorFlush;
- continue;
- }
-
- if (predecessorFlush == myFlush)
- continue;
-
- dataLog(
- "Bad Flush merge at edge ", *predecessor, " -> ", *block,
- ", local variable r", m_live.operandForIndex(j), ": ", *predecessor,
- " has ", predecessorFlush, " and ", *block, " has ", myFlush, ".\n");
- dataLog("IR at time of error:\n");
- m_graph.dump();
- CRASH();
- }
- }
- }
-
- NO_RETURN_DUE_TO_CRASH void reportError(Node* node)
- {
- dataLog(
- "Bad flush merge at node ", node, ", r", node->local(), ": node claims ",
- node->variableAccessData()->flushedAt(), " but backwards flow claims ",
- m_live.operand(node->local()), ".\n");
- dataLog("IR at time of error:\n");
- m_graph.dump();
- CRASH();
- }
-
- bool m_changed;
- Operands<FlushedAt> m_live;
-};
-
-bool performFlushLivenessAnalysis(Graph& graph)
-{
- SamplingRegion samplingRegion("DFG Flush-Liveness Analysis Phase");
- return runPhase<FlushLivenessAnalysisPhase>(graph);
-}
-
-} } // namespace JSC::DFG
-
-#endif // ENABLE(DFG_JIT)
-
Deleted: trunk/Source/_javascript_Core/dfg/DFGFlushLivenessAnalysisPhase.h (165868 => 165869)
--- trunk/Source/_javascript_Core/dfg/DFGFlushLivenessAnalysisPhase.h 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/dfg/DFGFlushLivenessAnalysisPhase.h 2014-03-19 04:44:22 UTC (rev 165869)
@@ -1,46 +0,0 @@
-/*
- * Copyright (C) 2013 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef DFGFlushLivenessAnalysisPhase_h
-#define DFGFlushLivenessAnalysisPhase_h
-
-#if ENABLE(DFG_JIT)
-
-#include "DFGCommon.h"
-
-namespace JSC { namespace DFG {
-
-class Graph;
-
-// Computes BasicBlock::ssa->flushFormatAtHead
-
-bool performFlushLivenessAnalysis(Graph&);
-
-} } // namespace JSC::DFG
-
-#endif // ENABLE(DFG_JIT)
-
-#endif // DFGFlushLivenessAnalysisPhase_h
-
Modified: trunk/Source/_javascript_Core/dfg/DFGGraph.cpp (165868 => 165869)
--- trunk/Source/_javascript_Core/dfg/DFGGraph.cpp 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/dfg/DFGGraph.cpp 2014-03-19 04:44:22 UTC (rev 165869)
@@ -453,7 +453,6 @@
case SSA: {
RELEASE_ASSERT(block->ssa);
- out.print(" Flush format: ", block->ssa->flushAtHead, "\n");
out.print(" Availability: ", block->ssa->availabilityAtHead, "\n");
out.print(" Live: ", nodeListDump(block->ssa->liveAtHead), "\n");
out.print(" Values: ", nodeMapDump(block->ssa->valuesAtHead, context), "\n");
@@ -479,7 +478,6 @@
case SSA: {
RELEASE_ASSERT(block->ssa);
- out.print(" Flush format: ", block->ssa->flushAtTail, "\n");
out.print(" Availability: ", block->ssa->availabilityAtTail, "\n");
out.print(" Live: ", nodeListDump(block->ssa->liveAtTail), "\n");
out.print(" Values: ", nodeMapDump(block->ssa->valuesAtTail, context), "\n");
Modified: trunk/Source/_javascript_Core/dfg/DFGPlan.cpp (165868 => 165869)
--- trunk/Source/_javascript_Core/dfg/DFGPlan.cpp 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/dfg/DFGPlan.cpp 2014-03-19 04:44:22 UTC (rev 165869)
@@ -39,7 +39,6 @@
#include "DFGCriticalEdgeBreakingPhase.h"
#include "DFGDCEPhase.h"
#include "DFGFailedFinalizer.h"
-#include "DFGFlushLivenessAnalysisPhase.h"
#include "DFGFixupPhase.h"
#include "DFGGraphSafepoint.h"
#include "DFGIntegerCheckCombiningPhase.h"
@@ -317,7 +316,6 @@
performDCE(dfg); // We rely on this to convert dead SetLocals into the appropriate hint, and to kill dead code that won't be recognized as dead by LLVM.
performStackLayout(dfg);
performLivenessAnalysis(dfg);
- performFlushLivenessAnalysis(dfg);
performOSRAvailabilityAnalysis(dfg);
performWatchpointCollection(dfg);
Modified: trunk/Source/_javascript_Core/dfg/DFGSSAConversionPhase.cpp (165868 => 165869)
--- trunk/Source/_javascript_Core/dfg/DFGSSAConversionPhase.cpp 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/dfg/DFGSSAConversionPhase.cpp 2014-03-19 04:44:22 UTC (rev 165869)
@@ -304,12 +304,7 @@
// to the node specified by variablesAtHead.
// - SetLocal gets NodeMustGenerate if it's flushed, or turns into a
// Check otherwise.
- // - Flush loses its children but remains, because we want to know when a
- // flushed SetLocal's value is no longer needed. This also makes it simpler
- // to reason about the format of a local, since we can just do a backwards
- // analysis (see FlushLivenessAnalysisPhase). As part of the backwards
- // analysis, we say that the type of a local can be either int32, double,
- // value, or dead.
+ // - Flush loses its children and turns into a Phantom.
// - PhantomLocal becomes Phantom, and its child is whatever is specified
// by variablesAtHead.
// - SetArgument turns into GetArgument unless it's a captured variable.
@@ -363,6 +358,7 @@
case Flush: {
node->children.reset();
+ node->convertToPhantom();
// This is only for Upsilons. An Upsilon will only refer to a Flush if
// there were no SetLocals or GetLocals in the block.
node->misc.replacement = block->variablesAtHead.operand(node->local());
Modified: trunk/Source/_javascript_Core/ftl/FTLLowerDFGToLLVM.cpp (165868 => 165869)
--- trunk/Source/_javascript_Core/ftl/FTLLowerDFGToLLVM.cpp 2014-03-19 03:07:27 UTC (rev 165868)
+++ trunk/Source/_javascript_Core/ftl/FTLLowerDFGToLLVM.cpp 2014-03-19 04:44:22 UTC (rev 165869)
@@ -608,7 +608,6 @@
case StoreBarrierWithNullCheck:
compileStoreBarrierWithNullCheck();
break;
- case Flush:
case PhantomLocal:
case SetArgument:
case LoopHint: