]> granicus.if.org Git - llvm/commit
[InstCombine] Handle usubo always overflow
authorNikita Popov <nikita.ppv@gmail.com>
Wed, 10 Apr 2019 07:10:53 +0000 (07:10 +0000)
committerNikita Popov <nikita.ppv@gmail.com>
Wed, 10 Apr 2019 07:10:53 +0000 (07:10 +0000)
commitb8b80606ab47cffbcac15f6e6664c09bfc0d56e4
treecf6a584d141c7da8d4a67b505e2ca81e163b04b6
parentce684046786bde150f875ca713d12bcb7913c90b
[InstCombine] Handle usubo always overflow

Check AlwaysOverflow condition for usubo. The implementation is the
same as the existing handling for uaddo and umulo. Handling for saddo
and ssubo will follow (smulo doesn't have the necessary ValueTracking
support).

Differential Revision: https://reviews.llvm.org/D60483

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@358052 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/InstCombine/InstCombineCompares.cpp
test/Transforms/InstCombine/with_overflow.ll