Changeset 160407 in webkit for trunk/Source/JavaScriptCore/dfg/DFGCSEPhase.cpp
- Timestamp:
- Dec 10, 2013, 6:10:46 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/dfg/DFGCSEPhase.cpp
r160344 r160407 56 56 m_graph.clearReplacements(); 57 57 58 for (BlockIndex blockIndex = m_graph.numBlocks(); blockIndex--;) { 59 BasicBlock* block = m_graph.block(blockIndex); 60 if (!block) 61 continue; 62 63 // All Phis need to already be marked as relevant to OSR. 64 if (!ASSERT_DISABLED) { 65 for (unsigned i = 0; i < block->phis.size(); ++i) 66 ASSERT(block->phis[i]->flags() & NodeRelevantToOSR); 67 } 68 69 for (unsigned i = block->size(); i--;) { 70 Node* node = block->at(i); 71 72 switch (node->op()) { 73 case SetLocal: 74 case GetLocal: // FIXME: The GetLocal case is only necessary until we do https://bugs.webkit.org/show_bug.cgi?id=106707. 75 node->mergeFlags(NodeRelevantToOSR); 76 break; 77 default: 78 node->clearFlags(NodeRelevantToOSR); 79 break; 80 } 81 } 82 } 83 84 for (BlockIndex blockIndex = m_graph.numBlocks(); blockIndex--;) { 85 BasicBlock* block = m_graph.block(blockIndex); 86 if (!block) 87 continue; 88 89 for (unsigned i = block->size(); i--;) { 90 Node* node = block->at(i); 91 if (!node->containsMovHint()) 92 continue; 93 94 ASSERT(node->op() != ZombieHint); 95 node->child1()->mergeFlags(NodeRelevantToOSR); 96 } 97 } 98 58 99 if (m_graph.m_form == SSA) { 59 100 Vector<BasicBlock*> depthFirst; … … 1022 1063 if (cseMode == NormalCSE) 1023 1064 m_graph.performSubstitution(node); 1024 1025 if (node->containsMovHint()) {1026 ASSERT(node->op() != ZombieHint);1027 node->child1()->mergeFlags(NodeRelevantToOSR);1028 }1029 1065 1030 1066 switch (node->op()) { … … 1375 1411 m_lastSeen[i] = UINT_MAX; 1376 1412 1377 // All Phis need to already be marked as relevant to OSR.1378 if (!ASSERT_DISABLED) {1379 for (unsigned i = 0; i < block->phis.size(); ++i)1380 ASSERT(block->phis[i]->flags() & NodeRelevantToOSR);1381 }1382 1383 // Make all of my SetLocal and GetLocal nodes relevant to OSR, and do some other1384 // necessary bookkeeping.1385 for (unsigned i = 0; i < block->size(); ++i) {1386 Node* node = block->at(i);1387 1388 switch (node->op()) {1389 case SetLocal:1390 case GetLocal: // FIXME: The GetLocal case is only necessary until we do https://bugs.webkit.org/show_bug.cgi?id=106707.1391 node->mergeFlags(NodeRelevantToOSR);1392 break;1393 default:1394 node->clearFlags(NodeRelevantToOSR);1395 break;1396 }1397 }1398 1399 1413 for (m_indexInBlock = 0; m_indexInBlock < block->size(); ++m_indexInBlock) { 1400 1414 m_currentNode = block->at(m_indexInBlock);
Note:
See TracChangeset
for help on using the changeset viewer.