Changeset 173534 in webkit
- Timestamp:
- Sep 11, 2014, 1:04:38 PM (12 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 1 added
- 2 edited
-
ChangeLog (modified) (1 diff)
-
dfg/DFGPhantomRemovalPhase.cpp (modified) (2 diffs)
-
tests/stress/remove-phantom-after-setlocal.js (added)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r173531 r173534 1 2014-09-11 Filip Pizlo <fpizlo@apple.com> 2 3 REGRESSION (r172129): Vine pages load as blank 4 https://bugs.webkit.org/show_bug.cgi?id=136655 5 rdar://problem/18281215 6 7 Reviewed by Michael Saboff. 8 9 If lastNode is something that is subject to DCE, then removing the Phantom's reference to something 10 that lastNode references means that the thing being referenced may no longer be kept alive for OSR. 11 Teach PhantomRemovalPhase that it's only safe to do this if lastNode is a Phantom. That's probably too 12 conservative, but that's fine since this is mainly just an optimization to make the IR sane to read and 13 reasonably compact; it's OK if we miss cases here. 14 15 * dfg/DFGPhantomRemovalPhase.cpp: 16 (JSC::DFG::PhantomRemovalPhase::run): 17 * tests/stress/remove-phantom-after-setlocal.js: Added. 18 1 19 2014-09-11 Bear Travis <betravis@adobe.com> 2 20 -
trunk/Source/JavaScriptCore/dfg/DFGPhantomRemovalPhase.cpp
r173069 r173534 94 94 unsigned sourceIndex = 0; 95 95 unsigned targetIndex = 0; 96 Node* lastNode = nullptr;97 96 while (sourceIndex < block->size()) { 98 97 Node* node = block->at(sourceIndex++); 99 98 switch (node->op()) { 100 99 case Phantom: { 101 if (lastNode && (lastNode->origin.forExit != node->origin.forExit || (lastNode->flags() & NodeHasVarArgs))) 102 lastNode = nullptr; 100 Node* lastNode = nullptr; 101 if (sourceIndex > 1) { 102 lastNode = block->at(sourceIndex - 2); 103 if (lastNode->op() != Phantom 104 || lastNode->origin.forExit != node->origin.forExit) 105 lastNode = nullptr; 106 } 103 107 for (unsigned i = 0; i < AdjacencyList::Size; ++i) { 104 108 Edge edge = node->children.child(i); … … 162 166 break; 163 167 } 164 lastNode = node;168 165 169 block->at(targetIndex++) = node; 166 170 }
Note:
See TracChangeset
for help on using the changeset viewer.