This adds support for saturating add/sub intrinsics to InstCombine. In particular the following folds are supported:
- sat(X1 + X2) -> add nuw/nsw where known no overflow
- sat(X1 - X2) -> sub nuw/nsw where known no overflow
- sat(X1 uadd X2) -> MAX where known overflow
- sat(X1 usub X2) -> 0 where known overflow
- sat(X ssub C) -> sat(X sadd C) where C != MIN
- sat(sat(X + C1) + C2) -> sat(X + (C1 + C2)) where legal
- sat(sat(X - C1) - C2) -> sat(X + (C1 + C2)) where legal
To properly support this, I've also changed the computeOverflowForUnsignedSub() implementation to return AlwaysOverflows results, for parity with the computeOverflowForUnsignedAdd() implementation.
A possible future improvement for the vector case is to support sat(sat(X + C1) + C2) -> sat(X + (C1 + C2)) style foldings also in the case where C1 and C2 are not constant splats.
Can we reuse this code for the new intrinsics?