Both ReturnInst and UnreachableInst exit functions, so we can treat them the same in ADCE and not mark them as live.
The only the CFG nodes corresponding to non-trivial PostDominatorTree roots (i.e. infinite loop blocks) need to be marked as live here for ADCE to work correctly.
Details
Details
Diff Detail
Diff Detail