]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Do not compare nonzero masks for varying.
authorAldy Hernandez <aldyh@redhat.com>
Sat, 1 Oct 2022 20:25:52 +0000 (22:25 +0200)
committerAldy Hernandez <aldyh@redhat.com>
Mon, 3 Oct 2022 11:06:25 +0000 (13:06 +0200)
There is no need to compare nonzero masks when comparing two VARYING
ranges, as they are always the same when range types are the same.

gcc/ChangeLog:

* value-range.cc (irange::legacy_equal_p): Remove nonozero mask
check when comparing VR_VARYING ranges.

gcc/value-range.cc

index 6154d73ccf5dccb0b89e5fb8a4937090ea0a441c..ddbcdd67633171d59a048d55ba6bf11c02040822 100644 (file)
@@ -1233,10 +1233,7 @@ irange::legacy_equal_p (const irange &other) const
   if (m_kind == VR_UNDEFINED)
     return true;
   if (m_kind == VR_VARYING)
-    {
-      return (range_compatible_p (type (), other.type ())
-             && vrp_operand_equal_p (m_nonzero_mask, other.m_nonzero_mask));
-    }
+    return range_compatible_p (type (), other.type ());
   return (vrp_operand_equal_p (tree_lower_bound (0),
                               other.tree_lower_bound (0))
          && vrp_operand_equal_p (tree_upper_bound (0),