Ignore:
Timestamp:
Feb 25, 2014, 9:47:29 AM (11 years ago)
Author:
[email protected]
Message:

Unreviewed, roll out http://trac.webkit.org/changeset/164493.

It causes crashes, apparently because it's removing too many barriers. I will investigate
later.

  • bytecode/SpeculatedType.cpp:

(JSC::speculationToAbbreviatedString):

  • bytecode/SpeculatedType.h:
  • dfg/DFGFixupPhase.cpp:

(JSC::DFG::FixupPhase::fixupNode):
(JSC::DFG::FixupPhase::insertStoreBarrier):

  • dfg/DFGNode.h:
  • ftl/FTLCapabilities.cpp:

(JSC::FTL::canCompile):

  • ftl/FTLLowerDFGToLLVM.cpp:

(JSC::FTL::LowerDFGToLLVM::compareEqObjectOrOtherToObject):
(JSC::FTL::LowerDFGToLLVM::equalNullOrUndefined):
(JSC::FTL::LowerDFGToLLVM::isNotNully):
(JSC::FTL::LowerDFGToLLVM::isNully):
(JSC::FTL::LowerDFGToLLVM::speculate):
(JSC::FTL::LowerDFGToLLVM::speculateObjectOrOther):
(JSC::FTL::LowerDFGToLLVM::speculateNotCell):

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/dfg/DFGFixupPhase.cpp

    r164620 r164651  
    10631063            // https://bugs.webkit.org/show_bug.cgi?id=126778
    10641064            m_requiredPhantoms.resize(0);
     1065        // Since StoreBarriers are recursively fixed up so that their children look
     1066        // identical to that of the node they're barrier-ing, we need to avoid adding
     1067        // any Phantoms when processing them because this would invalidate the
     1068        // InsertionSet's invariant of inserting things in a monotonically increasing
     1069        // order. This should be okay anyways because StoreBarriers can't exit.
    10651070        } else
    10661071            addPhantomsIfNecessary();
     
    16111616    void insertStoreBarrier(unsigned indexInBlock, Edge child1, Edge child2 = Edge())
    16121617    {
    1613         if (!child2) {
    1614             m_insertionSet.insertNode(
    1615                 indexInBlock, SpecNone, StoreBarrier, m_currentNode->origin, child1);
    1616             return;
    1617         }
    1618        
    1619         // Figure out some cheap way of avoiding the barrier entirely. In addition to being
    1620         // cheap, we try to make these checks strong: we want to prove as much as possible for
    1621         // the code that follows.
    1622         if (child2->shouldSpeculateInt32()) {
    1623             insertPhantomCheck(indexInBlock, child2.node(), Int32Use);
    1624             return;
    1625         }
    1626         if (child2->shouldSpeculateMachineInt()) {
    1627             insertPhantomCheck(indexInBlock, child2.node(), MachineIntUse);
    1628             return;
    1629         }
    1630         if (child2->shouldSpeculateBoolean()) {
    1631             insertPhantomCheck(indexInBlock, child2.node(), BooleanUse);
    1632             return;
    1633         }
    1634         if (child2->shouldSpeculateOther()) {
    1635             insertPhantomCheck(indexInBlock, child2.node(), OtherUse);
    1636             return;
    1637         }
    1638         if (child2->shouldSpeculateNotCell()) {
    1639             insertPhantomCheck(indexInBlock, child2.node(), NotCellUse);
    1640             return;
    1641         }
    1642        
    1643         m_insertionSet.insertNode(
    1644             indexInBlock, SpecNone, ConditionalStoreBarrier, m_currentNode->origin,
    1645             child1, Edge(child2.node(), UntypedUse));
    1646     }
    1647    
    1648     void insertPhantomCheck(unsigned indexInBlock, Node* node, UseKind useKind)
    1649     {
    1650         m_insertionSet.insertNode(
    1651             indexInBlock, SpecNone, Phantom, m_currentNode->origin, Edge(node, useKind));
    1652         observeUseKindOnNode(node, useKind);
     1618        Node* barrierNode;
     1619        if (!child2)
     1620            barrierNode = m_graph.addNode(SpecNone, StoreBarrier, m_currentNode->origin, Edge(child1.node(), child1.useKind()));
     1621        else {
     1622            barrierNode = m_graph.addNode(SpecNone, ConditionalStoreBarrier, m_currentNode->origin,
     1623                Edge(child1.node(), child1.useKind()), Edge(child2.node(), child2.useKind()));
     1624        }
     1625        m_insertionSet.insert(indexInBlock, barrierNode);
    16531626    }
    16541627
Note: See TracChangeset for help on using the changeset viewer.