[all-commits] [llvm/llvm-project] 14ef87: [ValueTracking] usub(a, b) cannot overflow if a >= b.
Florian Hahn via All-commits
all-commits at lists.llvm.org
Fri Feb 7 02:43:24 PST 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: 14ef87bda67d53f351217c4522150e41fb5695e8
https://github.com/llvm/llvm-project/commit/14ef87bda67d53f351217c4522150e41fb5695e8
Author: Florian Hahn <flo at fhahn.com>
Date: 2020-02-07 (Fri, 07 Feb 2020)
Changed paths:
M llvm/lib/Analysis/ValueTracking.cpp
M llvm/test/Transforms/InstCombine/usub-overflow-known-by-implied-cond.ll
Log Message:
-----------
[ValueTracking] usub(a, b) cannot overflow if a >= b.
If we know that a >= b (unsigned), usub.with.overflow(a, b) cannot
overflow. Similarly, if b > a, the same expression overflows.
Reviewers: nikic, RKSimon, lebedev.ri, spatel
Reviewed By: nikic, Gerolf
Differential Revision: https://reviews.llvm.org/D74066
More information about the All-commits
mailing list