HomePhabricator

[WinEHPrepare] Add rudimentary support for the new EH instructions

Description

[WinEHPrepare] Add rudimentary support for the new EH instructions

This adds somewhat basic preparation functionality including:

  • Formation of funclets via coloring basic blocks.
  • Cloning of polychromatic blocks to ensure that funclets have unique program counters.
  • Demotion of values used between different funclets.
  • Some amount of cleanup once we have removed predecessors from basic blocks.
  • Verification that we are left with a CFG that makes some amount of sense.

N.B. Arguments and numbering still need to be done.

Differential Revision: http://reviews.llvm.org/D11750