* arch-utils.c (generic_prepare_to_proceed): Allow for having
stopped due to a Ctrl-C as well as breakpoints. * hppa-tdep.c (hppa_prepare_to_proceed): Add FIXME as this may not support thread switches after Ctrl-C. * lin-lwp.c (lin_lwp_prepare_to_proceed): Ditto. * linux-thread.c (linuxthreads_prepare_to_proceed): Ditto. * m3-nat.c (mach3_prepare_to_proceed): Ditto.
This commit is contained in:
parent
b3cc30771b
commit
8849f47dd9
6 changed files with 39 additions and 12 deletions
|
@ -1,3 +1,14 @@
|
||||||
|
2001-06-06 Jonathan Larmour <jlarmour@redhat.com>
|
||||||
|
|
||||||
|
* arch-utils.c (generic_prepare_to_proceed): Allow for having
|
||||||
|
stopped due to a Ctrl-C as well as breakpoints.
|
||||||
|
|
||||||
|
* hppa-tdep.c (hppa_prepare_to_proceed): Add FIXME as this may not
|
||||||
|
support thread switches after Ctrl-C.
|
||||||
|
* lin-lwp.c (lin_lwp_prepare_to_proceed): Ditto.
|
||||||
|
* linux-thread.c (linuxthreads_prepare_to_proceed): Ditto.
|
||||||
|
* m3-nat.c (mach3_prepare_to_proceed): Ditto.
|
||||||
|
|
||||||
2001-06-06 Jim Blandy <jimb@redhat.com>
|
2001-06-06 Jim Blandy <jimb@redhat.com>
|
||||||
|
|
||||||
* gdbarch.sh, gdbarch.c: Revert change of 2001-06-01; all
|
* gdbarch.sh, gdbarch.c: Revert change of 2001-06-01; all
|
||||||
|
|
|
@ -258,9 +258,11 @@ generic_prepare_to_proceed (int select_it)
|
||||||
/* Get the last target status returned by target_wait(). */
|
/* Get the last target status returned by target_wait(). */
|
||||||
get_last_target_status (&wait_ptid, &wait_status);
|
get_last_target_status (&wait_ptid, &wait_status);
|
||||||
|
|
||||||
/* Make sure we were stopped at a breakpoint. */
|
/* Make sure we were stopped either at a breakpoint, or because
|
||||||
|
of a Ctrl-C. */
|
||||||
if (wait_status.kind != TARGET_WAITKIND_STOPPED
|
if (wait_status.kind != TARGET_WAITKIND_STOPPED
|
||||||
|| wait_status.value.sig != TARGET_SIGNAL_TRAP)
|
|| (wait_status.value.sig != TARGET_SIGNAL_TRAP &&
|
||||||
|
wait_status.value.sig != TARGET_SIGNAL_INT))
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -271,14 +273,11 @@ generic_prepare_to_proceed (int select_it)
|
||||||
/* Switched over from WAIT_PID. */
|
/* Switched over from WAIT_PID. */
|
||||||
CORE_ADDR wait_pc = read_pc_pid (wait_ptid);
|
CORE_ADDR wait_pc = read_pc_pid (wait_ptid);
|
||||||
|
|
||||||
/* Avoid switching where it wouldn't do any good, i.e. if both
|
if (wait_pc != read_pc ())
|
||||||
threads are at the same breakpoint. */
|
|
||||||
if (wait_pc != read_pc () && breakpoint_here_p (wait_pc))
|
|
||||||
{
|
{
|
||||||
if (select_it)
|
if (select_it)
|
||||||
{
|
{
|
||||||
/* User hasn't deleted the breakpoint. Switch back to
|
/* Switch back to WAIT_PID thread. */
|
||||||
WAIT_PID and return non-zero. */
|
|
||||||
inferior_ptid = wait_ptid;
|
inferior_ptid = wait_ptid;
|
||||||
|
|
||||||
/* FIXME: This stuff came from switch_to_thread() in
|
/* FIXME: This stuff came from switch_to_thread() in
|
||||||
|
@ -288,8 +287,13 @@ generic_prepare_to_proceed (int select_it)
|
||||||
stop_pc = wait_pc;
|
stop_pc = wait_pc;
|
||||||
select_frame (get_current_frame (), 0);
|
select_frame (get_current_frame (), 0);
|
||||||
}
|
}
|
||||||
|
/* We return 1 to indicate that there is a breakpoint here,
|
||||||
return 1;
|
so we need to step over it before continuing to avoid
|
||||||
|
hitting it straight away. */
|
||||||
|
if (breakpoint_here_p (wait_pc))
|
||||||
|
{
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -4594,7 +4594,10 @@ unwind_command (char *exp, int from_tty)
|
||||||
putting the BPT instruction in and taking it out.
|
putting the BPT instruction in and taking it out.
|
||||||
|
|
||||||
Note that this implementation is potentially redundant now that
|
Note that this implementation is potentially redundant now that
|
||||||
default_prepare_to_proceed() has been added. */
|
default_prepare_to_proceed() has been added.
|
||||||
|
|
||||||
|
FIXME This may not support switching threads after Ctrl-C
|
||||||
|
correctly. The default implementation does support this. */
|
||||||
int
|
int
|
||||||
hppa_prepare_to_proceed (void)
|
hppa_prepare_to_proceed (void)
|
||||||
{
|
{
|
||||||
|
|
|
@ -263,7 +263,10 @@ iterate_over_lwps (int (*callback) (struct lwp_info *, void *), void *data)
|
||||||
layer.
|
layer.
|
||||||
|
|
||||||
Note that this implementation is potentially redundant now that
|
Note that this implementation is potentially redundant now that
|
||||||
default_prepare_to_proceed() has been added. */
|
default_prepare_to_proceed() has been added.
|
||||||
|
|
||||||
|
FIXME This may not support switching threads after Ctrl-C
|
||||||
|
correctly. The default implementation does support this. */
|
||||||
|
|
||||||
int
|
int
|
||||||
lin_lwp_prepare_to_proceed (void)
|
lin_lwp_prepare_to_proceed (void)
|
||||||
|
|
|
@ -1040,7 +1040,10 @@ quit:
|
||||||
return 1 otherwise 0.
|
return 1 otherwise 0.
|
||||||
|
|
||||||
Note that this implementation is potentially redundant now that
|
Note that this implementation is potentially redundant now that
|
||||||
default_prepare_to_proceed() has been added. */
|
default_prepare_to_proceed() has been added.
|
||||||
|
|
||||||
|
FIXME This may not support switching threads after Ctrl-C
|
||||||
|
correctly. The default implementation does support this. */
|
||||||
|
|
||||||
int
|
int
|
||||||
linuxthreads_prepare_to_proceed (int step)
|
linuxthreads_prepare_to_proceed (int step)
|
||||||
|
|
|
@ -1575,6 +1575,9 @@ mach_thread_output_id (int mid)
|
||||||
*
|
*
|
||||||
* Note that this implementation is potentially redundant now that
|
* Note that this implementation is potentially redundant now that
|
||||||
* default_prepare_to_proceed() has been added.
|
* default_prepare_to_proceed() has been added.
|
||||||
|
*
|
||||||
|
* FIXME This may not support switching threads after Ctrl-C
|
||||||
|
* correctly. The default implementation does support this.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
mach3_prepare_to_proceed (int select_it)
|
mach3_prepare_to_proceed (int select_it)
|
||||||
|
|
Loading…
Reference in a new issue