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 974943858C66 for ; Mon, 18 Sep 2023 11:32:44 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 974943858C66 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=1695036764; 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=kpZf3sUfhXspXEClI8YqxTwLWTfm9lG0vtAkDB8O0n8=; b=HNrRXtUk+8PiYJ1Lz7+xRrrM9xP1iT0756gHlf2FUHkIh+jNvScH79SGe5a1Zb9UuivaS2 10LJrpmJ9ttKU+4A7ENLZChgK+50emheOd0FsyUB7esfW0iKXAVfMt5P5Vwn9b5V5uvGDF hNuD0yU9PTerI0z2yybwJ/G9mpu4Vuc= Received: from mimecast-mx02.redhat.com (mx-ext.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-549-PLR5l0sSM-m4Hc3EP7RoUQ-1; Mon, 18 Sep 2023 07:32:38 -0400 X-MC-Unique: PLR5l0sSM-m4Hc3EP7RoUQ-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 6FCFC3C025BC; Mon, 18 Sep 2023 11:32:38 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.45.224.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3023BC15BB8; Mon, 18 Sep 2023 11:32:38 +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 38IBWadA025719 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Mon, 18 Sep 2023 13:32:36 +0200 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 38IBWZqT025718; Mon, 18 Sep 2023 13:32:35 +0200 Date: Mon, 18 Sep 2023 13:32:35 +0200 From: Jakub Jelinek To: Martin Uecker Cc: Richard Biener , Alexander Monakov , Florian Weimer , gcc@gcc.gnu.org Subject: Re: Concerns regarding the -ffp-contract=fast default Message-ID: Reply-To: Jakub Jelinek References: <87r0n01z18.fsf@oldenburg3.str.redhat.com> <21e46cef-1fbf-df87-608d-52b7f894dea7@ispras.ru> MIME-Version: 1.0 In-Reply-To: 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=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,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 Mon, Sep 18, 2023 at 01:26:54PM +0200, Martin Uecker wrote: > > I think that changing the default to =standard without -ffast-math is > > reasonable. > > IIRC the standard allows such default if it's indicated, so it doesn't require > > =off anywhere. > > The C standard requires a pragma to turn control it on and off,  > which GCC does not support. The default is then implementation > defined. Perhaps we should add some initial hammer approach for the pragma, like if you ever use the pragma to turn it somewhere off, it is turned off globally, or ditto per function. Might be far easier than trying to make it precise that contraction is allowed in this expression and not in this subexpression of that etc. Of course, making it precise is the ultimate goal. Jakub