[PATCH] D152568: [InstCombine] Transform `(binop1 (binop2 (lshift X,Amt),Mask),(lshift Y,Amt))`
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 13 06:42:01 PDT 2023
nikic added inline comments.
================
Comment at: llvm/test/Transforms/InstCombine/or-shifted-masks.ll:133
; CHECK-NEXT: [[I4:%.*]] = and i32 [[I3]], 480
; CHECK-NEXT: [[I5:%.*]] = or i32 [[I4]], [[I2]]
; CHECK-NEXT: br label [[END:%.*]]
----------------
nikic wrote:
> This highlights another possible extension: We can have an extra binop on both sides, not just on one.
Tested this patch together with D151807, and it looks like handling this case would be needed to get the patterns in one instcombine run instead of instcombine,early-cse,instcombine.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D152568/new/
https://reviews.llvm.org/D152568
More information about the llvm-commits
mailing list