[InstCombine] remove unnecessary one-use check from (C2 << X) << C1 fold
authorSanjay Patel <spatel@rotateright.com>
Mon, 30 May 2022 19:15:27 +0000 (15:15 -0400)
committerSanjay Patel <spatel@rotateright.com>
Mon, 30 May 2022 19:17:54 +0000 (15:17 -0400)
commitc5d942a4fb21fba404ceb504ed087c297a1af7c3
treecb407291cce8b1040c919649aacdb5d72588fe55
parenta0044389590afa609def60584d5e500a28d2f206
[InstCombine] remove unnecessary one-use check from (C2 << X) << C1 fold

The restriction goes back to:
16f18ed7b555bce51
...but the fold only replaces a shift with a shift, so that's not necessary.
Generalizing to other opcodes is planned as a follow-up.
llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp
llvm/test/Transforms/InstCombine/shift-shift.ll