Changeset 225966 in webkit for trunk/Source/JavaScriptCore/dfg/DFGLICMPhase.cpp
- Timestamp:
- Dec 14, 2017, 10:20:07 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/dfg/DFGLICMPhase.cpp
r222007 r225966 221 221 } 222 222 } 223 223 224 224 return changed; 225 225 } … … 298 298 } 299 299 300 // FIXME: We should adjust the Check: flags on the edges of node. There are phases that assume301 // that those flags are correct even if AI is stale.302 // https://bugs.webkit.org/show_bug.cgi?id=148544303 300 data.preHeader->insertBeforeTerminal(node); 304 301 node->owner = data.preHeader; … … 307 304 node->origin.wasHoisted |= addsBlindSpeculation; 308 305 306 // We can trust what AI proves about edge proof statuses when hoisting to the preheader. 307 m_state.trustEdgeProofs(); 308 m_state.initializeTo(data.preHeader); 309 m_interpreter.execute(node); 310 // However, when walking various inner loops below, the proof status of 311 // an edge may be trivially true, even if it's not true in the preheader 312 // we hoist to. We don't allow the below node executions to change the 313 // state of edge proofs. An example of where a proof is trivially true 314 // is if we have two loops, L1 and L2, where L2 is nested inside L1. The 315 // header for L1 dominates L2. We hoist a Check from L1's header into L1's 316 // preheader. However, inside L2's preheader, we can't trust that AI will 317 // tell us this edge is proven. It's proven in L2's preheader because L2 318 // is dominated by L1's header. However, the edge is not guaranteed to be 319 // proven inside L1's preheader. 320 m_state.dontTrustEdgeProofs(); 321 309 322 // Modify the states at the end of the preHeader of the loop we hoisted to, 310 323 // and all pre-headers inside the loop. This isn't a stability bottleneck right now … … 324 337 if (!subPreHeader->cfaDidFinish) 325 338 continue; 339 // We handled this above. 340 if (subPreHeader == data.preHeader) 341 continue; 326 342 m_state.initializeTo(subPreHeader); 327 343 m_interpreter.execute(node); 328 344 } 329 345 330 346 // It just so happens that all of the nodes we currently know how to hoist 331 347 // don't have var-arg children. That may change and then we can fix this
Note:
See TracChangeset
for help on using the changeset viewer.