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 547783858C74 for ; Fri, 27 Jan 2023 12:14:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 547783858C74 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=1674821680; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=1HLsW9LwQBnDSOyGbufmFQb3dFDhuqvH8NvqA04vdsY=; b=fKrzD+Yi0WwoP2jU1VVI3Yk/lWKYQd1T7KCflF5NGrmTSQ5OU6dprmMHN4l/42zL3gBSo9 7SvSpFjwlhiKs1c5PSB8EexfgM7UQsHUo2iDUJHRbd5RUgjR7fl9cSrKqcIlj8LW6MRDL2 R+ra59m2yd0r2QW0nLr+FSEakf7gWBE= 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-668-LVlJWRcbMwOKG1cIbTuwwA-1; Fri, 27 Jan 2023 07:14:36 -0500 X-MC-Unique: LVlJWRcbMwOKG1cIbTuwwA-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 858B385A588; Fri, 27 Jan 2023 12:14:36 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.39.192.223]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 46B02492B01; Fri, 27 Jan 2023 12:14:36 +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 30RCEXDV686219 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Fri, 27 Jan 2023 13:14:33 +0100 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 30RCEW3e686218; Fri, 27 Jan 2023 13:14:32 +0100 Date: Fri, 27 Jan 2023 13:14:32 +0100 From: Jakub Jelinek To: Xi Ruoyao Cc: gcc-patches@gcc.gnu.org, Richard Biener Subject: Re: Pushed: [PATCH] testsuite: Use noipa attribute for pr95115 test Message-ID: Reply-To: Jakub Jelinek References: <20230127114627.243812-1-xry111@xry111.site> <2d4b190ab7eed64f800dc637c90ea6ecdffb53ab.camel@xry111.site> MIME-Version: 1.0 In-Reply-To: <2d4b190ab7eed64f800dc637c90ea6ecdffb53ab.camel@xry111.site> X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,BODY_8BITS,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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 08:08:26PM +0800, Xi Ruoyao via Gcc-patches wrote: > On Fri, 2023-01-27 at 12:50 +0100, Jakub Jelinek wrote: > > 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. > > Pushed with only noipa. I must have some flawed memory abort the > interaction between noipa and noinline. Thanks for pointing that out! /* A "noipa" function attribute implies "noinline", "noclone" and "no_icf" for those targets that support it. */ if (TREE_CODE (*node) == FUNCTION_DECL && attributes && lookup_attribute ("noipa", attributes) != NULL && lookup_attribute_spec (get_identifier ("noipa"))) { if (lookup_attribute ("noinline", attributes) == NULL) attributes = tree_cons (get_identifier ("noinline"), NULL, attributes); if (lookup_attribute ("noclone", attributes) == NULL) attributes = tree_cons (get_identifier ("noclone"), NULL, attributes); if (lookup_attribute ("no_icf", attributes) == NULL) attributes = tree_cons (get_identifier ("no_icf"), NULL, attributes); } plus various spots check just for "noipa", so noipa isn't just equivalent to noinline, noclone, no_icf. Jakub