This is an archive of the discontinued LLVM Phabricator instance.

[KnownBits] Add operator==
ClosedPublic

Authored by nikic on May 16 2022, 8:24 AM.

Details

Summary

Checking whether two KnownBits are the same is somewhat common, mainly in test code.

I don't think there is a lot of room for confusion with "determine what the KnownBits for an icmp eq would be", as that has a different result type (this is the eq() method implements, which returns Optional<bool>).

Diff Detail

Event Timeline

nikic created this revision.May 16 2022, 8:24 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 16 2022, 8:24 AM
nikic requested review of this revision.May 16 2022, 8:24 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 16 2022, 8:24 AM
craig.topper accepted this revision.May 16 2022, 1:48 PM

This makes sense to me. LGTM

This revision is now accepted and ready to land.May 16 2022, 1:48 PM
This revision was landed with ongoing or failed builds.May 17 2022, 12:39 AM
This revision was automatically updated to reflect the committed changes.