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.129.124]) by sourceware.org (Postfix) with ESMTPS id 33FEE385DC16 for ; Wed, 12 Oct 2022 06:51:01 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 33FEE385DC16 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=1665557460; 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=279HFKMU137X81B+8CgyXmW5JE93SfI1c8Siyo4z77Q=; b=MnW7ZKofNeERyGGCuifiD31UCe7b7L+QH9X7FuMUwQm7mWWM/K0A5T0HX0oRyO/Rpb7ix8 YxMeQqJEwAvau2Eo6K5ForxQzy/aPgQVwxz7XaZAuVf0o8zZjWiB+vZroD7d57siIa44nS HQQE1OLit25x5c/KqAskKVoRYcV6ZK8= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-479-n7Z6oTdaNSGWgktMUodvpw-1; Wed, 12 Oct 2022 02:50:59 -0400 X-MC-Unique: n7Z6oTdaNSGWgktMUodvpw-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 817131C051AB for ; Wed, 12 Oct 2022 06:50:59 +0000 (UTC) Received: from abulafia.quesejoda.com (unknown [10.39.193.77]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 5233E4A9265; Wed, 12 Oct 2022 06:50:56 +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 29C6osp5412958 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Wed, 12 Oct 2022 08:50:54 +0200 Received: (from aldyh@localhost) by abulafia.quesejoda.com (8.17.1/8.17.1/Submit) id 29C6osik412957; Wed, 12 Oct 2022 08:50:54 +0200 From: Aldy Hernandez To: GCC patches Cc: Andrew MacLeod , Aldy Hernandez Subject: [COMMITTED] Add stubs for floating point range-op tests. Date: Wed, 12 Oct 2022 08:50:50 +0200 Message-Id: <20221012065050.412900-5-aldyh@redhat.com> In-Reply-To: <20221012065050.412900-1-aldyh@redhat.com> References: <20221012065050.412900-1-aldyh@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.9 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=-12.0 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: gcc/ChangeLog: * range-op-float.cc (frange_float): New. (range_op_float_tests): New. * range-op.cc (range_op_tests): Call range_op_float_tests. --- gcc/range-op-float.cc | 26 ++++++++++++++++++++++++++ gcc/range-op.cc | 3 +++ 2 files changed, 29 insertions(+) diff --git a/gcc/range-op-float.cc b/gcc/range-op-float.cc index 71cdd112b86..22b7418c197 100644 --- a/gcc/range-op-float.cc +++ b/gcc/range-op-float.cc @@ -1612,3 +1612,29 @@ floating_op_table::set (enum tree_code code, range_operator_float &op) gcc_checking_assert (m_range_tree[code] == NULL); m_range_tree[code] = &op; } + +#if CHECKING_P +#include "selftest.h" + +namespace selftest +{ + +// Build an frange from string endpoints. + +inline frange +frange_float (const char *lb, const char *ub, tree type = float_type_node) +{ + REAL_VALUE_TYPE min, max; + gcc_assert (real_from_string (&min, lb) == 0); + gcc_assert (real_from_string (&max, ub) == 0); + return frange (type, min, max); +} + +void +range_op_float_tests () +{ +} + +} // namespace selftest + +#endif // CHECKING_P diff --git a/gcc/range-op.cc b/gcc/range-op.cc index 4d5a033dfa5..16fa1f4f46d 100644 --- a/gcc/range-op.cc +++ b/gcc/range-op.cc @@ -4829,6 +4829,9 @@ range_op_tests () range_op_bitwise_and_tests (); range_op_cast_tests (); range_relational_tests (); + + extern void range_op_float_tests (); + range_op_float_tests (); } } // namespace selftest -- 2.37.3