From patchwork Mon Nov 20 17:39:23 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Ulrich Weigand X-Patchwork-Id: 24390 Received: (qmail 21599 invoked by alias); 20 Nov 2017 17:39:33 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 21589 invoked by uid 89); 20 Nov 2017 17:39:33 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-15.3 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_ASCII_DIVIDERS, KB_WAM_FROM_NAME_SINGLEWORD, KHOP_DYNAMIC, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0a-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.156.1) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 20 Nov 2017 17:39:30 +0000 Received: from pps.filterd (m0098404.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id vAKHakum139955 for ; Mon, 20 Nov 2017 12:39:28 -0500 Received: from e06smtp10.uk.ibm.com (e06smtp10.uk.ibm.com [195.75.94.106]) by mx0a-001b2d01.pphosted.com with ESMTP id 2ec1ug6teb-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Mon, 20 Nov 2017 12:39:27 -0500 Received: from localhost by e06smtp10.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 20 Nov 2017 17:39:25 -0000 Received: from b06cxnps3075.portsmouth.uk.ibm.com (9.149.109.195) by e06smtp10.uk.ibm.com (192.168.101.140) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Mon, 20 Nov 2017 17:39:24 -0000 Received: from d06av26.portsmouth.uk.ibm.com (d06av26.portsmouth.uk.ibm.com [9.149.105.62]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id vAKHdOwg63897722; Mon, 20 Nov 2017 17:39:24 GMT Received: from d06av26.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id CE3E0AE055; Mon, 20 Nov 2017 17:32:41 +0000 (GMT) Received: from d06av26.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B62EAAE051; Mon, 20 Nov 2017 17:32:41 +0000 (GMT) Received: from oc3748833570.ibm.com (unknown [9.152.213.29]) by d06av26.portsmouth.uk.ibm.com (Postfix) with ESMTP; Mon, 20 Nov 2017 17:32:41 +0000 (GMT) Received: by oc3748833570.ibm.com (Postfix, from userid 1000) id A9DF2D802BF; Mon, 20 Nov 2017 18:39:23 +0100 (CET) Subject: Re: Doc update to mention MPFR (Re: [RFC][00/19] Target FP: Precise target floating-point emulation) To: eliz@gnu.org Date: Mon, 20 Nov 2017 18:39:23 +0100 (CET) From: "Ulrich Weigand" Cc: brobecker@adacore.com, gdb-patches@sourceware.org In-Reply-To: <83d14ceue3.fsf@gnu.org> from "Eli Zaretskii" at Nov 20, 2017 07:23:48 PM MIME-Version: 1.0 X-TM-AS-GCONF: 00 x-cbid: 17112017-0040-0000-0000-000003F08D03 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17112017-0041-0000-0000-000025F35161 Message-Id: <20171120173923.A9DF2D802BF@oc3748833570.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-11-20_09:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 impostorscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1709140000 definitions=main-1711200236 Eli Zaretskii wrote: > > *** Changes since GDB 8.0 > > > > +* GDB now uses the GNU MPFR library, if available, to emulate target > > + floating-point arithmetic during expression evaluation when the target > > + uses different floating-point formats than the host. > > + > > This part is OK. > > > + GDB uses GNU MPFR, a library for multiple-precision floating-point > > +computation with correct rounding, to emulate target floating-point > > +arithmetic during expression evaluation when the target uses different > > +floating-point formats than the host. MPFR will be linked in if it is > > +available at build time. At least version 3.1 of GNU MPFR is required. > > +If GNU MPFR it is not available, GDB will fall back to using host > > +floating-point arithmetic. The latest version of GNU MPFR should be > > +available from `http://www.mpfr.org´. > ^ > Some non-ASCII character sneaked in here. > > > +`--with-mpfr' > > + Build GDB with the GNU MPFR library. (Done by default if > > + GNU MPFR is installed and found at configure time.) This library > > + is used to emulate target floating-point arithmetic during expression > > + evaluation when the target uses different floating-point formats than > > + the host. At least version 3.1 of GNU MPFR is required. If GNU MPFR > > I would drop the reference to minimum supported MPFR version here: it > tends to become outdated as time goes by, and I believe the configure > script includes the necessary tests for what we need from MPFR, and > will reject versions that don't fit the bill. > > (It is okay to have the version mentioned in NEWS, as that is a > one-time announcement.) > > Also, please make sure there are 2 spaces between sentences. > > > +@item MPFR > > +@anchor{MPFR} > > +@value{GDBN} can use the GNU MPFR multiple-precision floating-point > > +library. This library may be included with your operating system > > +distribution; if it is not, you can get the latest version from > > +@url{http://www.mpfr.org}. At least version 3.1 of GNU MPFR is > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > Same here. > > > +formats than the host. If GNU MPFR it is not available, GDB will > ^^^ > @value{GDBN} > > The changes are okay with those gotchas fixed. OK, thanks for the review. I've updated the patch below. Thanks, Ulrich gdb/ChangeLog: * NEWS: Document use of GNU MPFR. * README: Likewise. * doc/gdb.texinfo: Likewise Index: binutils-gdb/gdb/NEWS =================================================================== --- binutils-gdb.orig/gdb/NEWS +++ binutils-gdb/gdb/NEWS @@ -3,6 +3,11 @@ *** Changes since GDB 8.0 +* GDB now uses the GNU MPFR library, if available, to emulate target + floating-point arithmetic during expression evaluation when the target + uses different floating-point formats than the host. At least version + 3.1 of GNU MPFR is required. + * GDB now supports access to the guarded-storage-control registers and the software-based guarded-storage broadcast control registers on IBM z14. Index: binutils-gdb/gdb/README =================================================================== --- binutils-gdb.orig/gdb/README +++ binutils-gdb/gdb/README @@ -89,6 +89,14 @@ features. Expat will be linked in if it those features will be disabled. The latest version of Expat should be available from `http://expat.sourceforge.net'. + GDB uses GNU MPFR, a library for multiple-precision floating-point +computation with correct rounding, to emulate target floating-point +arithmetic during expression evaluation when the target uses different +floating-point formats than the host. MPFR will be linked in if it is +available at build time. If GNU MPFR it is not available, GDB will fall +back to using host floating-point arithmetic. The latest version of +GNU MPFR should be available from `http://www.mpfr.org'. + GDB can be used as a cross-debugger, running on a machine of one type while debugging a program running on a machine of another type. See below. @@ -475,6 +483,15 @@ prefer; but you may abbreviate option na have libexpat installed, you can get the latest version from http://expat.sourceforge.net. +`--with-mpfr' + Build GDB with the GNU MPFR library. (Done by default if + GNU MPFR is installed and found at configure time.) This library + is used to emulate target floating-point arithmetic during expression + evaluation when the target uses different floating-point formats than + the host. If GNU MPFR is not available, GDB will fall back to using + host floating-point arithmetic. If your host does not have GNU MPFR + installed, you can get the latest version from http://www.mpfr.org. + `--with-python[=PATH]' Build GDB with Python scripting support. (Done by default if libpython is present and found at configure time.) Python makes Index: binutils-gdb/gdb/doc/gdb.texinfo =================================================================== --- binutils-gdb.orig/gdb/doc/gdb.texinfo +++ binutils-gdb/gdb/doc/gdb.texinfo @@ -34270,6 +34270,21 @@ Branch trace (@pxref{Branch Trace Format @pxref{Branch Trace Configuration Format}) @end itemize +@item MPFR +@anchor{MPFR} +@value{GDBN} can use the GNU MPFR multiple-precision floating-point +library. This library may be included with your operating system +distribution; if it is not, you can get the latest version from +@url{http://www.mpfr.org}. The @file{configure} script will search +for this library in several standard locations; if it is installed +in an unusual path, you can use the @option{--with-libmpfr-prefix} +option to specify its location. + +GNU MPFR is used to emulate target floating-point arithmetic during +expression evaluation when the target uses different floating-point +formats than the host. If GNU MPFR it is not available, @value{GDBN} +will fall back to using host floating-point arithmetic. + @item zlib @cindex compressed debug sections @value{GDBN} will use the @samp{zlib} library, if available, to read