[PATCH] D106222: [X86] Don't use known bits to simplify shuffles.

Juneyoung Lee via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jul 18 17:34:34 PDT 2021


aqjune added a comment.

In D106222#2886166 <https://reviews.llvm.org/D106222#2886166>, @efriedma wrote:

> In D106222#2885959 <https://reviews.llvm.org/D106222#2885959>, @RKSimon wrote:
>
>> I think we're going to have to add something to the SelectionDAG::computeKnownBits/ComputeNumSignBits doxygen comments explaining that the value could have the determined known/signbits BUT it could be a poison value (or if a vector any demanded element could be poison value).
>
> Sure, probably all these functions could use a comment like that: computeKnownBits, ComputeNumSignBits, haveNoCommonBitsSet, isKnownToBeAPowerOfTwo, computeOverflowKind, MaskedValueIsAllOnes, MaskedValueIsZero, SignBitIsZero, isKnownNeverNaN, isSplatValue, etc.  And probably the ValueTracking equivalents, too.  (Some of the ValueTracking functions already have comments which subtly indicate this, e.g. "exactly one bit set when defined.")

+1, this clarification looks great to me.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D106222/new/

https://reviews.llvm.org/D106222



More information about the llvm-commits mailing list