History log of /llvm-project/llvm/include/llvm/Support/KnownBits.h (Results 26 – 50 of 82)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, working, llvmorg-15.0.2, llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1
# 9082c131 29-Jul-2022 Simon Pilgrim <llvm-dev@redking.me.uk>

[Support] Add KnownBits::concat method

Add a method for the various cases where we need to concatenate 2 KnownBits together (BUILD_PAIR and SHIFT_PARTS in particular) - uses the existing APInt::conc

[Support] Add KnownBits::concat method

Add a method for the various cases where we need to concatenate 2 KnownBits together (BUILD_PAIR and SHIFT_PARTS in particular) - uses the existing APInt::concat 'HiBits.concat(LoBits)' convention

Differential Revision: https://reviews.llvm.org/D130557

show more ...


Revision tags: llvmorg-16-init, llvmorg-14.0.6, llvmorg-14.0.5, llvmorg-14.0.4
# a694546f 16-May-2022 Nikita Popov <npopov@redhat.com>

[KnownBits] Add operator==

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

[KnownBits] Add operator==

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 what the eq() method implements,
which returns Optional<bool>).

Differential Revision: https://reviews.llvm.org/D125692

show more ...


Revision tags: llvmorg-14.0.3, llvmorg-14.0.2, llvmorg-14.0.1, llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3, llvmorg-14.0.0-rc2, llvmorg-14.0.0-rc1
# 94453952 06-Feb-2022 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] Add support for X*X self-multiplication (update)

Rename the SelfMultiply argument to make it clearer that the argument must not be undef

Differential Revision: https://reviews.llvm.org/

[KnownBits] Add support for X*X self-multiplication (update)

Rename the SelfMultiply argument to make it clearer that the argument must not be undef

Differential Revision: https://reviews.llvm.org/D108992

show more ...


Revision tags: llvmorg-15-init
# 152d61a8 31-Jan-2022 Kazu Hirata <kazu@google.com>

[llvm] Use = default (NFC)


Revision tags: llvmorg-13.0.1, llvmorg-13.0.1-rc3, llvmorg-13.0.1-rc2
# cbcbbd6a 03-Jan-2022 Craig Topper <craig.topper@sifive.com>

[ValueTracking][SelectionDAG] Rename ComputeMinSignedBits->ComputeMaxSignificantBits. NFC

This function returns an upper bound on the number of bits needed
to represent the signed value. Use "Max" t

[ValueTracking][SelectionDAG] Rename ComputeMinSignedBits->ComputeMaxSignificantBits. NFC

This function returns an upper bound on the number of bits needed
to represent the signed value. Use "Max" to match similar functions
in KnownBits like countMaxActiveBits.

Rename APInt::getMinSignedBits->getSignificantBits. Keeping the old
name around to keep this patch size down. Will do a bulk rename as
follow up.

Rename KnownBits::countMaxSignedBits->countMaxSignificantBits.

Reviewed By: lebedev.ri, RKSimon, spatel

Differential Revision: https://reviews.llvm.org/D116522

show more ...


# db81324c 03-Jan-2022 Craig Topper <craig.topper@sifive.com>

[Support] Add KnownBits::countMaxSignedBits(). Make KnownBits::countMinSignBits() always return at least 1.

Even if we don't have any known bits, we can assume that there is
at least 1 sign bit. Thi

[Support] Add KnownBits::countMaxSignedBits(). Make KnownBits::countMinSignBits() always return at least 1.

Even if we don't have any known bits, we can assume that there is
at least 1 sign bit. This is consistent with ComputeNumSignBits
which always returns at least 1.

Add KnownBits::countMaxSignedBits() which computes the number of
bits needed to represent all signed values with those known bits.
This is the signed equivalent of countMaxActiveBits().

Split from D116469.

Reviewed By: lebedev.ri

Differential Revision: https://reviews.llvm.org/D116500

show more ...


Revision tags: llvmorg-13.0.1-rc1
# 684cbae8 11-Oct-2021 Roman Lebedev <lebedev.ri@gmail.com>

[KnownBits] Introduce `countMaxActiveBits()` and use it in a few places


# a9bceb2b 30-Sep-2021 Jay Foad <jay.foad@amd.com>

[APInt] Stop using soft-deprecated constructors and methods in llvm. NFC.

Stop using APInt constructors and methods that were soft-deprecated in
D109483. This fixes all the uses I found in llvm, exc

[APInt] Stop using soft-deprecated constructors and methods in llvm. NFC.

Stop using APInt constructors and methods that were soft-deprecated in
D109483. This fixes all the uses I found in llvm, except for the APInt
unit tests which should still test the deprecated methods.

Differential Revision: https://reviews.llvm.org/D110807

show more ...


Revision tags: llvmorg-13.0.0, llvmorg-13.0.0-rc4, llvmorg-13.0.0-rc3
# 735f4671 09-Sep-2021 Chris Lattner <clattner@nondot.org>

[APInt] Normalize naming on keep constructors / predicate methods.

This renames the primary methods for creating a zero value to `getZero`
instead of `getNullValue` and renames predicates like `isAl

[APInt] Normalize naming on keep constructors / predicate methods.

This renames the primary methods for creating a zero value to `getZero`
instead of `getNullValue` and renames predicates like `isAllOnesValue`
to simply `isAllOnes`. This achieves two things:

1) This starts standardizing predicates across the LLVM codebase,
following (in this case) ConstantInt. The word "Value" doesn't
convey anything of merit, and is missing in some of the other things.

2) Calling an integer "null" doesn't make any sense. The original sin
here is mine and I've regretted it for years. This moves us to calling
it "zero" instead, which is correct!

APInt is widely used and I don't think anyone is keen to take massive source
breakage on anything so core, at least not all in one go. As such, this
doesn't actually delete any entrypoints, it "soft deprecates" them with a
comment.

Included in this patch are changes to a bunch of the codebase, but there are
more. We should normalize SelectionDAG and other APIs as well, which would
make the API change more mechanical.

Differential Revision: https://reviews.llvm.org/D109483

show more ...


# 0a07ae6e 07-Sep-2021 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] Add support for X*X self-multiplication

Add KnownBits handling and unit tests for X*X self-multiplication cases which guarantee that bit1 of their results will be zero - see PR48683.

ht

[KnownBits] Add support for X*X self-multiplication

Add KnownBits handling and unit tests for X*X self-multiplication cases which guarantee that bit1 of their results will be zero - see PR48683.

https://alive2.llvm.org/ce/z/NN_eaR

The next step will be to add suitable test coverage so this can be enabled in ValueTracking/DAG/GlobalISel - currently only a single Analysis/ScalarEvolution test is affected.

Differential Revision: https://reviews.llvm.org/D108992

show more ...


Revision tags: llvmorg-13.0.0-rc2, llvmorg-13.0.0-rc1, llvmorg-14-init
# 89c1c64c 03-Jul-2021 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] Merge const/non-const KnownBits::extractBits implementations. NFC.

These are identical and can be just const.


Revision tags: llvmorg-12.0.1, llvmorg-12.0.1-rc4, llvmorg-12.0.1-rc3, llvmorg-12.0.1-rc2, llvmorg-12.0.1-rc1, llvmorg-12.0.0, llvmorg-12.0.0-rc5, llvmorg-12.0.0-rc4
# ddbb5873 25-Mar-2021 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] Rename KnownBits::computeForMul to KnownBits::mul. NFCI.

As promised in D98866


# 4ea5475a 02-Apr-2021 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] Add KnownBits::haveNoCommonBitsSet helper. NFCI.

Include exhaustive test coverage.


# 115a42ad 31-Mar-2021 Philip Reames <listmail@philipreames.com>

Add debug printers for KnownBits [nfc]


# a9689721 18-Mar-2021 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] Add knownbits analysis for mulhs/mulu 'multiply high' instructions

Split off from D98857

https://reviews.llvm.org/D98866


Revision tags: llvmorg-12.0.0-rc3, llvmorg-12.0.0-rc2, llvmorg-11.1.0, llvmorg-11.1.0-rc3, llvmorg-12.0.0-rc1, llvmorg-13-init, llvmorg-11.1.0-rc2
# d0dbb046 14-Jan-2021 Simon Pilgrim <llvm-dev@redking.me.uk>

[Support] Remove redundant sign bit tests from KnownBits::getSignedMinValue/getSignedMaxValue

As noted by @foad on rG6895581fd2c1


Revision tags: llvmorg-11.1.0-rc1
# 23b41986 04-Jan-2021 Simon Pilgrim <llvm-dev@redking.me.uk>

[Support] Add KnownBits::icmp helpers.

Check if all possible values for a pair of knownbits give the same icmp result - these are based off the checks performed in InstCombineCompares.cpp and D86578

[Support] Add KnownBits::icmp helpers.

Check if all possible values for a pair of knownbits give the same icmp result - these are based off the checks performed in InstCombineCompares.cpp and D86578.

Add exhaustive unit test coverage - a followup will update InstCombineCompares.cpp to use this.

show more ...


# 6895581f 24-Dec-2020 Simon Pilgrim <llvm-dev@redking.me.uk>

[Support] Add KnownBits::getSignedMinValue/getSignedMaxValue helpers.

Add unit test coverage - a followup will update InstCombineCompares.cpp to use this and could be used by D86578 as well.


# fb468953 23-Dec-2020 Simon Pilgrim <llvm-dev@redking.me.uk>

[Support] Explicitly state that KnownBits::getMinValue/getMaxValue are UNSIGNED values. NFCI.

Update the comment to make this clear, following the same approach as APInt.


Revision tags: llvmorg-11.0.1, llvmorg-11.0.1-rc2
# 9cf4f493 04-Dec-2020 Simon Pilgrim <llvm-dev@redking.me.uk>

[DAG] Move SelectionDAG implementation to KnownBits::setInReg(). NFCI.


Revision tags: llvmorg-11.0.1-rc1
# 9a85643c 13-Nov-2020 Nikita Popov <nikita.ppv@gmail.com>

[KnownBits] Combine abs() implementations

ValueTracking was using a more powerful abs() implementation. Roll
it into KnownBits::abs(). Also add an exhaustive test for abs(),
in both the poisoning an

[KnownBits] Combine abs() implementations

ValueTracking was using a more powerful abs() implementation. Roll
it into KnownBits::abs(). Also add an exhaustive test for abs(),
in both the poisoning and non-poisoning variants.

show more ...


# 89967427 12-Nov-2020 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] Add KnownBits::makeConstant helper. NFCI.

Helper for cases where we need to create a KnownBits from a (fully known) constant value.


# 1a62ca65 11-Nov-2020 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] Add KnownBits::commonBits helper. NFCI.

We have a frequent pattern where we're merging two KnownBits to get the common/shared bits, and I just fell for the gotcha where I tried to use th

[KnownBits] Add KnownBits::commonBits helper. NFCI.

We have a frequent pattern where we're merging two KnownBits to get the common/shared bits, and I just fell for the gotcha where I tried to use the & operator to merge them........

show more ...


# 9fd77104 08-Nov-2020 Simon Pilgrim <llvm-dev@redking.me.uk>

[KnownBits] isNonZero() - avoid expensive countPopulation call. NFC.

We can just check for a null value.


# 20f87d82 06-Nov-2020 Simon Pilgrim <llvm-dev@redking.me.uk>

[InstCombine] computeKnownBitsMul - use KnownBits::isNonZero() helper.

Avoid an expensive isKnownNonZero() call - this is a small cleanup before moving the extra NSW functionality from computeKnownB

[InstCombine] computeKnownBitsMul - use KnownBits::isNonZero() helper.

Avoid an expensive isKnownNonZero() call - this is a small cleanup before moving the extra NSW functionality from computeKnownBitsMul into KnownBits::computeForMul.

show more ...


1234