Mostly a refactoring of the code in PhiNode's Identity and Ideal
which identified phi's receiving a unique value on multiple control
paths, possibly masked by constaint casts and self loops. The
factored code was encapsulated in a new method PhiNode::unique_input.
This fixes a bug caused by PhiNode Identity and Ideal not looking for
the same patterns.
Also, common code was factored out from PhiNode's Identity and Ideal
which looked for patterns like: x = (x==0)?0:x and generalized
to allow constraint casts in the pattern.