[InstCombine][NFC] Tests for 'unsigned sub overflow' check
----------------------------------------
Name: unsigned sub, overflow, v0
%sub = sub i8 %x, %y
%ov = icmp ugt i8 %sub, %x
=>
%agg = usub_overflow i8 %x, %y
%sub = extractvalue {i8, i1} %agg, 0
%ov = extractvalue {i8, i1} %agg, 1
Done: 1
Optimization is correct!
----------------------------------------
Name: unsigned sub, no overflow, v0
%sub = sub i8 %x, %y
%ov = icmp ule i8 %sub, %x
=>
%agg = usub_overflow i8 %x, %y
%sub = extractvalue {i8, i1} %agg, 0
%not.ov = extractvalue {i8, i1} %agg, 1
%ov = xor %not.ov, -1
Done: 1
Optimization is correct!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@371099
91177308-0d34-0410-b5e6-
96231b3b80d8