This is an archive of the discontinued LLVM Phabricator instance.

[RISCV] Fold (sub C, (xor (setcc), 1)) -> (add (setcc), C-1).
ClosedPublic

Authored by craig.topper on Aug 16 2022, 4:36 PM.

Details

Summary

Extracted from D131729 where we handled C==0. It's now generalized
to more constants.

Diff Detail

Event Timeline

craig.topper created this revision.Aug 16 2022, 4:36 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 16 2022, 4:36 PM
craig.topper requested review of this revision.Aug 16 2022, 4:36 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 16 2022, 4:36 PM
reames accepted this revision.Aug 17 2022, 7:59 AM

LGTM

This revision is now accepted and ready to land.Aug 17 2022, 7:59 AM
This revision was landed with ongoing or failed builds.Aug 17 2022, 9:50 AM
This revision was automatically updated to reflect the committed changes.