Work on useless control flow elimination revealed potential bugs with MIRGraph consistency -- for example, numPredecessors() seems incorrect at times. Problems of this sort can be more readily detected, most importantly by anion, if we write an invariant checker that walks the MIRGraph and asserts on any inconsistency. We would run it after each phase of compilation when in debug mode.
This is a good idea - out of curiosity, are you seeing problems even after fixing bug 676322?
This exists in the tree as AssertGraphInvariants(), checked in with OSR (bug 700108).