summaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorSanjay Patel <spatel@rotateright.com>2021-12-20 09:10:50 -0500
committerSanjay Patel <spatel@rotateright.com>2021-12-20 09:10:50 -0500
commit892c731681df962064828334531f59d29eb8473a (patch)
treee0130b54d9a58f46a6e9e0b0cb29151c92d949fc /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parentfcaf290d0278bb83387e1a1d972c55e08b8c40e3 (diff)
[Support] improve known bits analysis for leading zeros of multiply
Instead of summing leading zeros on the input operands, multiply the max possible values of those inputs and count the leading zeros of the result. This can give us an extra zero bit (typically in cases where one of the operands is a known constant). This allows folding away the remaining 'add' ops in the motivating bug (modeled in the PhaseOrdering IR test): https://github.com/llvm/llvm-project/issues/48399 Fixes #48399 Differential Revision: https://reviews.llvm.org/D115969
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions