mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-27 01:28:46 +00:00
infrun.c:handle_inferior_event: Move process_event_stop_test goto label.
We only ever call "goto process_event_stop_test;" right after checking
that ecs->random_signal is clear. The code at the
process_event_stop_test label looks like:
/* For the program's own signals, act according to
the signal handling tables. */
if (ecs->random_signal)
{
... random signal handling ...
return;
}
else
{
... the stop tests that actually matter for the goto callers.
}
So this moves the label into the else branch. It'll make converting
process_event_stop_test into a function a bit clearer.
gdb/
2013-10-28 Pedro Alves <palves@redhat.com>
* infrun.c (handle_inferior_event): Move process_event_stop_test
goto label to the else branch of the ecs->random_signal check,
along with FRAME and GDBARCH re-fetching.
This commit is contained in:
@@ -1,3 +1,9 @@
|
||||
2013-10-28 Pedro Alves <palves@redhat.com>
|
||||
|
||||
* infrun.c (handle_inferior_event): Move process_event_stop_test
|
||||
goto label to the else branch of the ecs->random_signal check,
|
||||
along with FRAME and GDBARCH re-fetching.
|
||||
|
||||
2013-10-28 Pedro Alves <palves@redhat.com>
|
||||
|
||||
* infrun.c (switch_back_to_stepped_thread): New function, factored
|
||||
|
||||
14
gdb/infrun.c
14
gdb/infrun.c
@@ -4288,13 +4288,6 @@ Cannot fill $_exitsignal with the correct signal number.\n"));
|
||||
ecs->event_thread->suspend.stop_signal = GDB_SIGNAL_TRAP;
|
||||
}
|
||||
|
||||
process_event_stop_test:
|
||||
|
||||
/* Re-fetch current thread's frame in case we did a
|
||||
"goto process_event_stop_test" above. */
|
||||
frame = get_current_frame ();
|
||||
gdbarch = get_frame_arch (frame);
|
||||
|
||||
/* For the program's own signals, act according to
|
||||
the signal handling tables. */
|
||||
|
||||
@@ -4417,6 +4410,13 @@ process_event_stop_test:
|
||||
CORE_ADDR jmp_buf_pc;
|
||||
struct bpstat_what what;
|
||||
|
||||
process_event_stop_test:
|
||||
|
||||
/* Re-fetch current thread's frame in case we did a
|
||||
"goto process_event_stop_test" above. */
|
||||
frame = get_current_frame ();
|
||||
gdbarch = get_frame_arch (frame);
|
||||
|
||||
what = bpstat_what (ecs->event_thread->control.stop_bpstat);
|
||||
|
||||
if (what.call_dummy)
|
||||
|
||||
Reference in New Issue
Block a user