From patchwork Wed Feb 16 01:12:39 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gerald Pfeifer X-Patchwork-Id: 83321 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 9CAE0B7125 for ; Wed, 16 Feb 2011 12:12:50 +1100 (EST) Received: (qmail 23416 invoked by alias); 16 Feb 2011 01:12:49 -0000 Received: (qmail 23408 invoked by uid 22791); 16 Feb 2011 01:12:48 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_LOW X-Spam-Check-By: sourceware.org Received: from relay03.pair.com (HELO relay03.pair.com) (209.68.5.17) by sourceware.org (qpsmtpd/0.43rc1) with SMTP; Wed, 16 Feb 2011 01:12:43 +0000 Received: (qmail 65209 invoked from network); 16 Feb 2011 01:12:40 -0000 Received: from 195.135.221.2 (HELO trevally) (195.135.221.2) by relay03.pair.com with SMTP; 16 Feb 2011 01:12:40 -0000 X-pair-Authenticated: 195.135.221.2 Date: Wed, 16 Feb 2011 02:12:39 +0100 (CET) From: Gerald Pfeifer To: gcc-patches@gcc.gnu.org Subject: [doc] Fix -mno-fancy-math-387 Message-ID: MIME-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org The documentation indicates that -mno-fancy-math-387 is the default on FreeBSD, yet I do not see any code actually implementing that, and I verified that the following #include double f(double d) { return __builtin_sin(d); } did generate fsin with -ffast-math as the only option. Richard, http://gcc.gnu.org/ml/gcc-patches/2002-03/msg02001.html was the last time someone really made changes in this area, though the reference to FreeBSD predates your patch where you added OpenBSD and NetBSD for both of which I _do_ see code in config/i386 to that extent, unlike FreeBSD. Am I missing something obvious, or is the patch below okay? Gerald 2011-02-16 Gerald Pfeifer PR target/37072 * doc/invoke.texi (i386 and x86-64 Options): -mno-fancy-math-387 is not actually the default on FreeBSD. Uppercase CPU. Index: doc/invoke.texi =================================================================== --- doc/invoke.texi (revision 170120) +++ doc/invoke.texi (working copy) @@ -12273,9 +12273,9 @@ @opindex mno-fancy-math-387 Some 387 emulators do not support the @code{sin}, @code{cos} and @code{sqrt} instructions for the 387. Specify this option to avoid -generating those instructions. This option is the default on FreeBSD, +generating those instructions. This option is the default on OpenBSD and NetBSD@. This option is overridden when @option{-march} -indicates that the target cpu will always have an FPU and so the +indicates that the target CPU will always have an FPU and so the instruction will not need emulation. As of revision 2.6.1, these instructions are not generated unless you also use the @option{-funsafe-math-optimizations} switch.