[all-commits] [llvm/llvm-project] 38992d: [InstCombine] improve fold for icmp-ugt-ashr
ZCBing via All-commits
all-commits at lists.llvm.org
Thu Jun 9 01:22:50 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 38992d2c5e1d671cf5d4f03c7331ce98b2cdda94
https://github.com/llvm/llvm-project/commit/38992d2c5e1d671cf5d4f03c7331ce98b2cdda94
Author: Chenbing Zheng <Chenbing.Zheng at streamcomputing.com>
Date: 2022-06-09 (Thu, 09 Jun 2022)
Changed paths:
M llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp
M llvm/test/Transforms/InstCombine/icmp-shr.ll
Log Message:
-----------
[InstCombine] improve fold for icmp-ugt-ashr
Existing condition for
fold icmp ugt (ashr X, ShAmtC), C --> icmp ugt X, ((C + 1) << ShAmtC) - 1
missed some boundary. It cause this fold don't work for some cases, and the
reason is due to signed number overflow.
Reviewed By: spatel
Differential Revision: https://reviews.llvm.org/D127188
More information about the All-commits
mailing list