Ignore:
Timestamp:
Apr 22, 2015, 7:36:08 PM (10 years ago)
Author:
[email protected]
Message:

Nodes should have an optional epoch field
https://bugs.webkit.org/show_bug.cgi?id=144084

Reviewed by Ryosuke Niwa and Mark Lam.

This makes it easier to do epoch-based analyses on nodes. I plan to do just that in
https://bugs.webkit.org/show_bug.cgi?id=143735. Currently the epoch field is not yet
used.

  • dfg/DFGCPSRethreadingPhase.cpp:

(JSC::DFG::CPSRethreadingPhase::canonicalizeGetLocalFor):

  • dfg/DFGCSEPhase.cpp:
  • dfg/DFGEpoch.h:

(JSC::DFG::Epoch::fromUnsigned):
(JSC::DFG::Epoch::toUnsigned):

  • dfg/DFGGraph.cpp:

(JSC::DFG::Graph::clearReplacements):
(JSC::DFG::Graph::clearEpochs):

  • dfg/DFGGraph.h:

(JSC::DFG::Graph::performSubstitutionForEdge):

  • dfg/DFGNode.h:

(JSC::DFG::Node::Node):
(JSC::DFG::Node::replaceWith):
(JSC::DFG::Node::replacement):
(JSC::DFG::Node::setReplacement):
(JSC::DFG::Node::epoch):
(JSC::DFG::Node::setEpoch):

  • dfg/DFGSSAConversionPhase.cpp:

(JSC::DFG::SSAConversionPhase::run):

File:
1 edited

Legend:

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

    r183094 r183162  
    195195            if (otherNode->op() == GetLocal) {
    196196                // Replace all references to this GetLocal with otherNode.
    197                 node->replacement = otherNode;
     197                node->setReplacement(otherNode);
    198198                return;
    199199            }
    200200           
    201201            ASSERT(otherNode->op() == SetLocal);
    202             node->replacement = otherNode->child1().node();
     202            node->setReplacement(otherNode->child1().node());
    203203            return;
    204204        }
Note: See TracChangeset for help on using the changeset viewer.