Changeset 198296 in webkit for trunk/Source/JavaScriptCore/dfg/DFGObjectAllocationSinkingPhase.cpp
- Timestamp:
- Mar 16, 2016, 1:12:27 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/dfg/DFGObjectAllocationSinkingPhase.cpp
r194496 r198296 839 839 case NewArrowFunction: 840 840 case NewGeneratorFunction: { 841 if ( node->castOperand<FunctionExecutable*>()->singletonFunction()->isStillValid()) {841 if (isStillValid(node->castOperand<FunctionExecutable*>()->singletonFunction())) { 842 842 m_heap.escape(node->child1().node()); 843 843 break; … … 856 856 857 857 case CreateActivation: { 858 if ( node->castOperand<SymbolTable*>()->singletonScope()->isStillValid()) {858 if (isStillValid(node->castOperand<SymbolTable*>()->singletonScope())) { 859 859 m_heap.escape(node->child1().node()); 860 860 break; … … 2174 2174 } 2175 2175 2176 // This is a great way of asking value->isStillValid() without having to worry about getting 2177 // different answers. It turns out that this analysis works OK regardless of what this 2178 // returns but breaks badly if this changes its mind for any particular InferredValue. This 2179 // method protects us from that. 2180 bool isStillValid(InferredValue* value) 2181 { 2182 return m_validInferredValues.add(value, value->isStillValid()).iterator->value; 2183 } 2184 2176 2185 SSACalculator m_pointerSSA; 2177 2186 SSACalculator m_allocationSSA; … … 2184 2193 CombinedLiveness m_combinedLiveness; 2185 2194 2195 HashMap<InferredValue*, bool> m_validInferredValues; 2196 2186 2197 HashMap<Node*, Node*> m_materializationToEscapee; 2187 2198 HashMap<Node*, Vector<Node*>> m_materializationSiteToMaterializations;
Note:
See TracChangeset
for help on using the changeset viewer.