Bug 237872 - [PPC] can't print a 128-bit long double variable
[PPC] can't print a 128-bit long double variable
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: gdb (Show other bugs)
rawhide
ppc64 Linux
medium Severity medium
: ---
: ---
Assigned To: Jan Kratochvil
:
Depends On: 237637
Blocks:
  Show dependency treegraph
 
Reported: 2007-04-25 15:47 EDT by Jan Kratochvil
Modified: 2007-11-30 17:12 EST (History)
1 user (show)

See Also:
Fixed In Version: gdb-6.6-12
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-04-25 17:15:13 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Testcase (reproducibility code, not a GDB style testcase). (700 bytes, text/plain)
2007-04-25 15:47 EDT, Jan Kratochvil
no flags Details
Fix. (5.04 KB, patch)
2007-04-25 15:47 EDT, Jan Kratochvil
no flags Details | Diff

  None (edit)
Description Jan Kratochvil 2007-04-25 15:47:18 EDT
---Problem Description---
Gdb can't print a 128-bit long double variable
 
---uname output---
Linux devel 2.6.18-1.2714.el5 #1 SMP Mon Oct 2 17:17:28 EDT 2006 ppc64 ppc64
ppc64 GNU/Linux
 
---Steps to Reproduce---
[root@devbc1-9 brts]# gdb test
GNU gdb Red Hat Linux (6.5-8.fc6rh)
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "ppc64-redhat-linux-gnu"...Using host libthread_db li
                                                                           
brary "/lib64/libthread_db.so.1".

(gdb) b 39
Breakpoint 1 at 0x100006bc: file test.c, line 39.
(gdb) r
Starting program: /home/public/testbucket/brts/test
--- 128 bit Long double
Size of long double = 16

Breakpoint 1, main () at test.c:39
39        long_pld(i, ld2, vp1);  /* break here, print ld2, then continue */
(gdb) p ld2
$1 = Unrecognized 128-bit floating-point type.

 
Test run with the GDB version shipped with RHEL5 GA (unpatched)

>gdb) b 39
Breakpoint 1 at 0x100007e8: file long_double.c, line 39.
(gdb) r
Starting program: /home/luis/binaries/long_double-64
--- 128 bit Long double
Size of long double = 16

Breakpoint 1, main () at long_double.c:39
39        long_pld(i, ld2, vp1);  /* break here, print ld2, then continue */
(gdb) p ld2
$1 = Unrecognized 128-bit floating-point type.
(gdb) 
<

Test run with the patched version of GDB

>
(gdb) b 39
Breakpoint 1 at 0x100007e8: file long_double.c, line 39.
(gdb) r
Starting program: /home/luis/binaries/long_double-64
--- 128 bit Long double
Size of long double = 16

Breakpoint 1, main () at long_double.c:39
39        long_pld(i, ld2, vp1);  /* break here, print ld2, then continue */
(gdb) p ld2
$1 = 2.0000000000000000008673617379884035
(gdb)
<

Testsuite run with no regressions:

Unpatched Version:

# of expected passes            11142
# of unexpected failures        127
# of expected failures          42
# of known failures             61
# of unresolved testcases       1
# of untested testcases         4
# of unsupported tests          13

Patched version

# of expected passes            11174
# of unexpected failures        96
# of expected failures          42
# of known failures             60
# of unresolved testcases       1
# of untested testcases         4
# of unsupported tests          13
Comment 1 Jan Kratochvil 2007-04-25 15:47:18 EDT
Created attachment 153446 [details]
Testcase (reproducibility code, not a GDB style testcase).
Comment 2 Jan Kratochvil 2007-04-25 15:47:59 EDT
Created attachment 153447 [details]
Fix.
Comment 3 Jan Kratochvil 2007-04-25 17:15:13 EDT
Committed to Rawhide:
* Wed Apr 25 2007 Jan Kratochvil <jan.kratochvil@redhat.com> - 6.6-12
- Enable PowerPC to print 128-bit long double variables (BZ 237872).

Testcases already present in GDB before, such as:
{-FAIL,+PASS}: gdb.base/sizeof.exp: print/f padding_long_double.v

Note You need to log in before you can comment on or make changes to this bug.