From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1062 invoked by alias); 2 Dec 2015 11:32:16 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 1040 invoked by uid 89); 2 Dec 2015 11:32:15 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-pa0-f41.google.com Received: from mail-pa0-f41.google.com (HELO mail-pa0-f41.google.com) (209.85.220.41) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Wed, 02 Dec 2015 11:32:15 +0000 Received: by pabfh17 with SMTP id fh17so39852747pab.0 for ; Wed, 02 Dec 2015 03:32:13 -0800 (PST) X-Received: by 10.67.6.38 with SMTP id cr6mr3810875pad.104.1449055933386; Wed, 02 Dec 2015 03:32:13 -0800 (PST) Received: from E107787-LIN (gcc1-power7.osuosl.org. [140.211.15.137]) by smtp.gmail.com with ESMTPSA id h10sm3866151pat.7.2015.12.02.03.32.10 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Wed, 02 Dec 2015 03:32:12 -0800 (PST) From: Yao Qi To: Ruslan Kabatsayev Cc: gdb-patches@sourceware.org Subject: Re: [PATCH][PR 18702] Fix wrong output of x87 registers due to truncation to double on amd64 References: <564F998D.5080406@gmail.com> Date: Wed, 02 Dec 2015 11:32:00 -0000 In-Reply-To: <564F998D.5080406@gmail.com> (Ruslan Kabatsayev's message of "Sat, 21 Nov 2015 01:07:09 +0300") Message-ID: <86mvttt7be.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2015-12/txt/msg00024.txt.bz2 Ruslan Kabatsayev writes: Hi Ruslan, > When `info float` is used on an AMD64 system, GDB prints floating-point > values of x87 registers with raw contents like 0x361a867a8e0527397ce0 or > 0xc4f988454a1ddd3cfdab wrongly. This happens due to truncation to double, > after which the former becomes 0.0, and the latter becomes negative infin= ity. > This is caused by failed detection of x86-64 host, which results in setti= ng > gdb_host_{float,double,long_double}_format to zeros. > This commit fixes this misdetection. I think your patch is correct, but I am not confident approving it because I know few about floating point stuff. Do you run GDB regression tests? > > gdb/ChangeLog: > > * configure.host: Fix detection of x86_64 host when setting floatformats This line is too long, the max is 74. Sentence should be ended with ".". --=20 Yao (=E9=BD=90=E5=B0=A7)