HomePhabricator

[RISCV] Add another isel pattern for slliu.w.

Authored by craig.topper on Jan 20 2021, 2:52 PM.

Description

[RISCV] Add another isel pattern for slliu.w.

Previously we only matched (and (shl X, C1), 0xffffffff << C1)
which matches the InstCombine canonicalization order. But its
possible to see (shl (and X, 0xffffffff), C1) if the pattern
is introduced in SelectionDAG. For example, through expansion of
a GEP.

Details