[PATCH] D109515: [AggressiveInstCombine] Add `udiv` and `urem` instrs to TruncInstCombine DAG
Anton Afanasyev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 9 08:49:43 PDT 2021
anton-afanasyev created this revision.
anton-afanasyev added reviewers: lebedev.ri, spatel, RKSimon.
Herald added a subscriber: hiraditya.
anton-afanasyev requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Add `udiv` and `urem` instructions to the DAG post-dominated by `trunc`,
allowing TruncInstCombine to reduce bitwidth of expressions containing these
instructions. It is sufficient to require that all truncated bits of both
operands are zeros: https://alive2.llvm.org/ce/z/yiithn
(`urem` case is identical).
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D109515
Files:
llvm/lib/Transforms/AggressiveInstCombine/TruncInstCombine.cpp
llvm/test/Transforms/AggressiveInstCombine/trunc_udivrem.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D109515.371607.patch
Type: text/x-patch
Size: 7672 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210909/4ff11486/attachment.bin>
More information about the llvm-commits
mailing list