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 4D43E3858426 for ; Fri, 27 Jan 2023 11:50:23 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4D43E3858426 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=1674820222; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references; bh=aYevFWEwdGau7TIVbafB3z0Y48PN6Gfa/syX4WJJObU=; b=DdL1ZjaoRm1xl4B56FdkNcD5BXeN+XqWOppZIMtgo6cJEYRARMKBxRmZDcGYAz8zOUz3/H Q9YK/Tm83WDNaSUQn+f6BABTwUHpCHLLzZ16nCDwo+lz1dLL7DMmlF1032NiCxzn9tiSlA 5ZtTg//RbSeU6GKxDdTigIiuaafWQ88= 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-447-L3BayP1gPoCgrDyi9PQ5uA-1; Fri, 27 Jan 2023 06:50:19 -0500 X-MC-Unique: L3BayP1gPoCgrDyi9PQ5uA-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id DC2513C0DDBC; Fri, 27 Jan 2023 11:50:18 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.39.192.223]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 994BDC15BA0; Fri, 27 Jan 2023 11:50:18 +0000 (UTC) Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.17.1/8.17.1) with ESMTPS id 30RBoF4U686077 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Fri, 27 Jan 2023 12:50:16 +0100 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 30RBoDHm686076; Fri, 27 Jan 2023 12:50:13 +0100 Date: Fri, 27 Jan 2023 12:50:13 +0100 From: Jakub Jelinek To: Xi Ruoyao Cc: gcc-patches@gcc.gnu.org, Richard Biener Subject: Re: [PATCH] testsuite: Use noipa and noinline attributes for pr95115 test Message-ID: Reply-To: Jakub Jelinek References: <20230127114627.243812-1-xry111@xry111.site> MIME-Version: 1.0 In-Reply-To: <20230127114627.243812-1-xry111@xry111.site> X-Scanned-By: MIMEDefang 3.1 on 10.11.54.8 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Spam-Status: No, score=-9.8 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,RCVD_IN_MSPIKE_H2,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: On Fri, Jan 27, 2023 at 07:46:27PM +0800, Xi Ruoyao wrote: > They prevent the compiler from deeming the NaN result "unused" and > remove the calculation raising INVALID exception. See the discussion > in PR107608 for details. > > Tested on x86_64-linux-gnu where the change fixes the test failure. > Ok for trunk? > > gcc/testsuite/ChangeLog: > > * gcc.dg/pr95115.c (x): Add noipa and noinline attributes. noipa implies noinline, so unless one targets both very old gcc versions which didn't have noipa attribute in addition to current ones, it is sufficient to specify just noipa. Otherwise LGTM. > diff --git a/gcc/testsuite/gcc.dg/pr95115.c b/gcc/testsuite/gcc.dg/pr95115.c > index 69c4f83250c..11620acccae 100644 > --- a/gcc/testsuite/gcc.dg/pr95115.c > +++ b/gcc/testsuite/gcc.dg/pr95115.c > @@ -6,7 +6,7 @@ > #include > #include > > -double > +__attribute__ ((noipa, noinline)) double > x (void) > { > double d = __builtin_inf (); > -- > 2.39.1 Jakub