From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id 607483858299 for ; Mon, 3 Oct 2022 11:08:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 607483858299 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1664795304; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=+Ar7WgmZdVF9hK6pUBXC8O+J72RX1LI64b2EcLGNiMc=; b=gGTuyh75Q2l2WHVoUAsTGRyIqFgBpc9MBInevoVzZxY/nWaClztL86w0xrgQ/53JMQUa5M ZcQk9AqS/BIfBGoTSB7lKlKjrKBmQ/p/6seFzYRYK2g7PdtdHr3x5OODcPP6ZfdeX7hdOb M5NAK2fCWisp/Ub/3XmptEqErqfOA7E= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-140-y3a4izSmP5WChq8KxP746Q-1; Mon, 03 Oct 2022 07:08:20 -0400 X-MC-Unique: y3a4izSmP5WChq8KxP746Q-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id A2D5E1019C8A for ; Mon, 3 Oct 2022 11:08:20 +0000 (UTC) Received: from abulafia.quesejoda.com (unknown [10.39.194.103]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 598102027062; Mon, 3 Oct 2022 11:08:20 +0000 (UTC) Received: from abulafia.quesejoda.com (localhost [127.0.0.1]) by abulafia.quesejoda.com (8.17.1/8.17.1) with ESMTPS id 293B8Ij41075999 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Mon, 3 Oct 2022 13:08:18 +0200 Received: (from aldyh@localhost) by abulafia.quesejoda.com (8.17.1/8.17.1/Submit) id 293B8IYm1075998; Mon, 3 Oct 2022 13:08:18 +0200 From: Aldy Hernandez To: GCC patches Cc: Andrew MacLeod , Aldy Hernandez Subject: [COMMITTED] Do not compare nonzero masks for varying. Date: Mon, 3 Oct 2022 13:08:13 +0200 Message-Id: <20221003110815.1075975-2-aldyh@redhat.com> In-Reply-To: <20221003110815.1075975-1-aldyh@redhat.com> References: <20221003110815.1075975-1-aldyh@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.4 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true X-Spam-Status: No, score=-11.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_NONE,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: 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 | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/gcc/value-range.cc b/gcc/value-range.cc index 6154d73ccf5..ddbcdd67633 100644 --- a/gcc/value-range.cc +++ b/gcc/value-range.cc @@ -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), -- 2.37.1