[PATCH] D146350: [InstCombine] More aggressively try and fold irem/idiv/mul into selects.
Noah Goldstein via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 17 19:05:11 PDT 2023
goldstein.w.n created this revision.
Herald added a subscriber: hiraditya.
Herald added a project: All.
goldstein.w.n requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Don't only do constant cases, also try cases were we can't constant
fold both sides. In the same we can't constant fold both sides, only
do transform if the select is single use.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D146350
Files:
llvm/lib/Transforms/InstCombine/InstCombineMulDivRem.cpp
llvm/test/Transforms/InstCombine/binop-select.ll
llvm/test/Transforms/InstCombine/div.ll
llvm/test/Transforms/InstCombine/rem.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D146350.506260.patch
Type: text/x-patch
Size: 12684 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230318/2ab0319e/attachment.bin>
More information about the llvm-commits
mailing list