[llvm] [KnownBits] Remove `hasConflict()` assertions (PR #94568)

via llvm-commits llvm-commits at lists.llvm.org
Fri Jun 7 08:07:19 PDT 2024


================
@@ -752,8 +765,10 @@ TEST(KnownBitsTest, CommonBitsSet) {
           HasCommonBitsSet |= N1.intersects(N2);
         });
       });
-      EXPECT_EQ(!HasCommonBitsSet,
-                KnownBits::haveNoCommonBitsSet(Known1, Known2));
+      if (!Known1.hasConflict() && !Known2.hasConflict()) {
----------------
c8ef wrote:

I believe this is necessary because we permit conflicts in test generation. Therefore, even if we revert the set to zero, these tests will only pass when there are no conflicts.

https://github.com/llvm/llvm-project/pull/94568


More information about the llvm-commits mailing list