This is an archive of the discontinued LLVM Phabricator instance.

[ExecutionDepsFix] Don't recurse over the CFG
ClosedPublic

Authored by loladiro on Apr 4 2017, 3:18 PM.

Details

Summary

Use an explicit std::vector instead, to avoid accidentally causing stack overflows
for input with very large CFGs.

Event Timeline

loladiro created this revision.Apr 4 2017, 3:18 PM
mehdi_amini accepted this revision.Apr 4 2017, 3:26 PM
mehdi_amini added inline comments.
lib/CodeGen/ExecutionDepsFix.cpp
710

SmallVector?
Worklist or Workqueue seems a more common name for iterative algorithm I think.

719

Seed the workqueue instead to remove this call.

724

Is it the only use of updateSuccessors? Could be inlined if so, the code seems simple enough.

This revision is now accepted and ready to land.Apr 4 2017, 3:26 PM
This revision was automatically updated to reflect the committed changes.