This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA] dummy frame handling cleanup, plus inferior fun call signal handling improvement
- From: "Ulrich Weigand" <uweigand at de dot ibm dot com>
- To: pedro at codesourcery dot com (Pedro Alves)
- Cc: dje at google dot com (Doug Evans), gdb-patches at sourceware dot org
- Date: Fri, 5 Dec 2008 01:18:00 +0100 (CET)
- Subject: Re: [RFA] dummy frame handling cleanup, plus inferior fun call signal handling improvement
Pedro Alves wrote:
> On Thursday 04 December 2008 22:32:12, Doug Evans wrote:
> > In the original code, is there a case when stop_pc != registers.pc?
>
> Here,
>
> <stopped at 0x1234, thread 1>
> (gdb) set $pc = 0xf00
> (gdb) call func()
Huh. But that case is in fact *broken*, because GDB will use stop_pc
incorrectly: for example, the check whether we are about to continue
at a breakpoint will look at stop_pc, but then continue at $pc. Also,
if we issue a "step", the step range will be set according to the line
at stop_pc, but we will actually continue at $pc ...
It seems to me just about every current user of stop_pc *really* wants
to look at regcache_read_pc (get_current_regcache ()) ...
Bye,
Ulrich
--
Dr. Ulrich Weigand
GNU Toolchain for Linux on System z and Cell BE
Ulrich.Weigand@de.ibm.com