[PATCH] D105942: [SCEV] Fix unsound reasoning in howManyLessThans
Philip Reames via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 14 11:41:59 PDT 2021
reames added a comment.
As I mostly expected, my concerning validation result turned out to be a bug in my brute force checker program instead. (C++ promotion rules bite again!) I have checked the logic for this transform on both signed and unsigned comparisons for all 8 bit values of start, end, and stride. The optimized form produces the same answer as both the generic n-bit ceiling logic (used in getUDivCeilSCEV) and an implementation of the N + (D - 1) /D formula using wide types.
Eli, it sounds like you're on board with me landing this. Can I get a LGTM for the record?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105942/new/
https://reviews.llvm.org/D105942
More information about the llvm-commits
mailing list