Go to file
Joel Brobecker 35c63cd8ce Problem after hitting breakpoint on Windows (with GDBserver)
When debugging on Windows with GDBserver, the debugger starts
failing after hitting a breakpoint.  For instance:

    (gdb) b foo
    Breakpoint 1 at 0x40177e: file foo.adb, line 5.
    (gdb) cont
    Continuing.

    Breakpoint 1, foo () at foo.adb:5
    5          Put_Line ("Hello World.");  -- STOP
    (gdb) n

    Program received signal SIGSEGV, Segmentation fault.
    0x00401782 in foo () at foo.adb:5
    5          Put_Line ("Hello World.");  -- STOP

There are two issues:

  1. While trying to re-insert a breakpoint that is still inserted
     in memory, insert_bp_location wipes out the breakpoint location's
     shadow_contents.  As a consequence, we cannot restore the proper
     instruction when removing the breakpoint anymore.  That's why
     the inferior's behavior changes when trying to resume after
     the breakpoint was hit.

  2. mem-break.c:default_memory_insert_breakpoint passes a breakpoint
     location's shadow_contents as the buffer for a memory read.
     This reveals a limitation of the various memory-read target
     functions.  This patch documents this limitation and adjust
     the two calls that seem to hit that limitation.

gdb/ChangeLog:

        * breakpoint.c (breakpoint_xfer_memory): Add assertion.
        Update function description.
        (insert_bp_location): Do not wipe bl->target_info out.
        * mem-break.c: #include "gdb_string.h".
        (default_memory_insert_breakpoint): Do not call target_read_memory
        with a pointer to the breakpoint's shadow_contents buffer.  Use
        a local buffer instead.
        * m32r-tdep.c (m32r_memory_insert_breakpoint): Ditto.
2012-03-15 18:33:45 +00:00
bfd * elf64-x86-64.c (elf_x86_64_create_dynamic_sections): Use 2012-03-15 18:20:22 +00:00
binutils PR binutils/3807 2012-03-13 00:41:22 +00:00
config
cpu
elfcpp elfcpp/ 2012-03-13 00:13:08 +00:00
etc
gas gas/ 2012-03-15 11:19:13 +00:00
gdb Problem after hitting breakpoint on Windows (with GDBserver) 2012-03-15 18:33:45 +00:00
gold 2012-03-15 Doug Kwan <dougkwan@google.com> 2012-03-15 18:24:06 +00:00
gprof
include include/ 2012-03-15 12:58:48 +00:00
intl
ld * config/default.exp: Update copyright date. 2012-03-15 01:57:57 +00:00
libdecnumber
libiberty
opcodes include/ 2012-03-15 12:58:48 +00:00
readline
sim sim: ppc: fix compilation on AIX 7.1 due to st_pad name collisions 2012-03-14 05:04:18 +00:00
texinfo
.cvsignore
.gitignore
ChangeLog * configure.ac (enable_libgomp): Remove *-*-irix6*. 2012-03-15 14:13:32 +00:00
compile
config-ml.in
config.guess
config.rpath
config.sub
configure * configure.ac (enable_libgomp): Remove *-*-irix6*. 2012-03-15 14:13:32 +00:00
configure.ac * configure.ac (enable_libgomp): Remove *-*-irix6*. 2012-03-15 14:13:32 +00:00
COPYING
COPYING3
COPYING3.LIB
COPYING.LIB
COPYING.LIBGLOSS
COPYING.NEWLIB
depcomp
djunpack.bat
install-sh
libtool.m4
lt~obsolete.m4
ltgcc.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
MAINTAINERS
Makefile.def
Makefile.in
Makefile.tpl
makefile.vms
missing
mkdep
mkinstalldirs
move-if-change
README
README-maintainer-mode
setup.com
src-release
symlink-tree
ylwrap

		   README for GNU development tools

This directory contains various GNU compilers, assemblers, linkers, 
debuggers, etc., plus their support routines, definitions, and documentation.

If you are receiving this as part of a GDB release, see the file gdb/README.
If with a binutils release, see binutils/README;  if with a libg++ release,
see libg++/README, etc.  That'll give you info about this
package -- supported targets, how to use it, how to report bugs, etc.

It is now possible to automatically configure and build a variety of
tools with one command.  To build all of the tools contained herein,
run the ``configure'' script here, e.g.:

	./configure 
	make

To install them (by default in /usr/local/bin, /usr/local/lib, etc),
then do:
	make install

(If the configure script can't determine your type of computer, give it
the name as an argument, for instance ``./configure sun4''.  You can
use the script ``config.sub'' to test whether a name is recognized; if
it is, config.sub translates it to a triplet specifying CPU, vendor,
and OS.)

If you have more than one compiler on your system, it is often best to
explicitly set CC in the environment before running configure, and to
also set CC when running make.  For example (assuming sh/bash/ksh):

	CC=gcc ./configure
	make

A similar example using csh:

	setenv CC gcc
	./configure
	make

Much of the code and documentation enclosed is copyright by
the Free Software Foundation, Inc.  See the file COPYING or
COPYING.LIB in the various directories, for a description of the
GNU General Public License terms under which you can copy the files.

REPORTING BUGS: Again, see gdb/README, binutils/README, etc., for info
on where and how to report problems.