This is an archive of the discontinued LLVM Phabricator instance.

[ValueTracking] Add support for `fshl`/`fshr` in `isKnownToBeAPowerOfTwo`
ClosedPublic

Authored by goldstein.w.n on Aug 7 2023, 10:47 AM.

Details

Summary

If the funnel shifts are rotates (op0 == op1) then the number of 1s/0s
don't change so we can just look through op0/op1.

Proofs: https://alive2.llvm.org/ce/z/Pja5yu

Diff Detail

Unit TestsFailed

Event Timeline

goldstein.w.n created this revision.Aug 7 2023, 10:47 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 7 2023, 10:47 AM
goldstein.w.n requested review of this revision.Aug 7 2023, 10:47 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 7 2023, 10:47 AM
nikic accepted this revision.Aug 7 2023, 11:26 AM

LGTM

This revision is now accepted and ready to land.Aug 7 2023, 11:26 AM
This revision was landed with ongoing or failed builds.Aug 9 2023, 12:45 PM
This revision was automatically updated to reflect the committed changes.