old-cross-binutils/gdb/testsuite
Pedro Alves 433730c973 Fix the x87 FP register printout when issuing the “info float” command.
Consider the following simple program:

.globl  _start
.text
_start:
      fldt    val
.data
      val: .byte 0x00,0x00,0x45,0x07,0x11,0x19,0x22,0xe9,0xfe,0xbf

With current GDB on x86-64 GNU/Linux hosts, after the moment the fldt
command has been executed the register st(0) looks like this,
according to the “info regs” output (TOP=7):

  R7: Valid   0xffffffbffffffffeffffffe922191107450000 -0.910676542908976927

which is clearly wrong (just count its length).  The problem is due to
the printf statement (see patch) printing a promoted integer value of
a char argument "raw[i]", and, since char is signed on x86-64
GNU/Linux, the erroneous “ffffff” are printed for the first three
bytes which turn out to be "negative".  The fix is to use gdb_byte
instead which is unsigned (and is the type of value_contents(), the
type to be used for raw target bytes anyway).  After the fix the value
will be printed correctly:

  R7: Valid   0xbffee922191107450000 -0.910676542908976927

gdb/
2013-04-19  Vladimir Kargov <kargov@gmail.com>
	    Pedro Alves  <palves@redhat.com>

	* i387-tdep.c (i387_print_float_info): Use gdb_byte for pointer to
	value contents.

gdb/testsuite/
2013-04-19  Vladimir Kargov  <kargov@gmail.com>
	    Pedro Alves  <palves@redhat.com>

	* gdb.arch/i386-float.S: New file.
	* gdb.arch/i386-float.exp: New file.
2013-04-19 14:13:30 +00:00
..
boards * boards/dwarf4-gdb-index.exp: Use any existing CC_FOR_TARGET, 2013-01-17 20:17:15 +00:00
config gdb/testsuite/ 2013-03-14 13:34:06 +00:00
gdb.ada Ignore __fu<digits>__ symbols from COFF symbol tables 2013-03-29 02:04:15 +00:00
gdb.arch Fix the x87 FP register printout when issuing the “info float” command. 2013-04-19 14:13:30 +00:00
gdb.asm Update years in copyright notice for the GDB files. 2013-01-01 06:33:28 +00:00
gdb.base PR c++/15176: 2013-04-15 18:09:02 +00:00
gdb.btrace record-btrace: fix assertion when enabling recording after re-run 2013-03-26 07:15:09 +00:00
gdb.cell Update years in copyright notice for the GDB files. 2013-01-01 06:33:28 +00:00
gdb.cp PR c++/13588: 2013-04-15 18:13:01 +00:00
gdb.disasm Update years in copyright notice for the GDB files. 2013-01-01 06:33:28 +00:00
gdb.dwarf2 * lib/dwarf.exp (Dwarf): New proc "tu". 2013-04-17 21:07:09 +00:00
gdb.fortran Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.gdb gdb/ 2013-02-03 15:54:18 +00:00
gdb.go Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.hp gdb/testsuite/ 2013-03-14 13:34:06 +00:00
gdb.java Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.linespec 2013-04-04 Sandra Loosemore <sandra@codesourcery.com> 2013-04-04 20:59:12 +00:00
gdb.mi * gdb.mi/mi-var-create-rtti.exp: Create a variable of 2013-04-18 10:08:08 +00:00
gdb.modula2 Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.multi Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.objc Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.opencl Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.opt Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.pascal Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.python gdb/testsuite/ 2013-03-14 13:34:06 +00:00
gdb.reverse Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.server gdb/testsuite/ 2013-04-09 15:26:44 +00:00
gdb.stabs Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
gdb.threads gdb/testsuite/ 2013-03-15 01:41:29 +00:00
gdb.trace Accept "set foo unlimited" in integer/uinteger/zuinteger_unlimited commands. 2013-04-10 15:11:12 +00:00
gdb.xml Update years in copyright notice for the GDB files. 2013-01-01 06:41:43 +00:00
lib * lib/dwarf.exp (Dwarf): New proc "tu". 2013-04-17 21:07:09 +00:00
aclocal.m4
ChangeLog Fix the x87 FP register printout when issuing the “info float” command. 2013-04-19 14:13:30 +00:00
configure Add tests for the new record-btrace target. 2013-03-11 08:59:00 +00:00
configure.ac Add tests for the new record-btrace target. 2013-03-11 08:59:00 +00:00
dg-extract-results.sh Merge dg-extract-results.sh from gcc upstream (svn 195224). 2013-01-17 14:31:11 +00:00
Makefile.in Add tests for the new record-btrace target. 2013-03-11 08:59:00 +00:00
TODO