This is an archive of the discontinued LLVM Phabricator instance.

[RISCV] Fold (xor (sllw 1, x), -1) -> (rolw ~1, x).
ClosedPublic

Authored by craig.topper on Apr 18 2022, 10:41 PM.

Details

Summary

There's an existing generic combine that does this for legal types.
This patch adds a RISCV specific combine for W instructions.

Diff Detail

Event Timeline

craig.topper created this revision.Apr 18 2022, 10:41 PM
Herald added a project: Restricted Project. · View Herald TranscriptApr 18 2022, 10:41 PM
craig.topper requested review of this revision.Apr 18 2022, 10:41 PM
Herald added a project: Restricted Project. · View Herald TranscriptApr 18 2022, 10:41 PM
This revision is now accepted and ready to land.Apr 19 2022, 9:19 AM
This revision was landed with ongoing or failed builds.Apr 19 2022, 3:05 PM
This revision was automatically updated to reflect the committed changes.