+2004-01-17 Daniel Jacobowitz <drow@mvista.com>
+
+ * breakpoint.c (must_shift_inst_regs): Delete.
+ (bpstat_stop_status): Delete references to DECR_PC_AFTER_HW_BREAK
+ and SHIFT_INST_REGS.
+ * infcmd.c (step_1, step_1_continuation): Delete references to
+ SHIFT_INST_REGS.
+ * infrun.c (keep_going): Likewise.
+ * target.h (DECR_PC_AFTER_HW_BREAK): Don't define.
+ * config/i386/nm-i386.h (DECR_PC_AFTER_HW_BREAK): Likewise.
+
2004-01-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS): Delete.
/* Everything about breakpoints, for GDB.
Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994,
- 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 Free Software
- Foundation, Inc.
+ 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
+ Free Software Foundation, Inc.
This file is part of GDB.
B ? (TMP=B->next, 1): 0; \
B = TMP)
-/* True if SHIFT_INST_REGS defined, false otherwise. */
-
-int must_shift_inst_regs =
-#if defined(SHIFT_INST_REGS)
-1
-#else
-0
-#endif
- ;
-
/* True if breakpoint hit counts should be displayed in breakpoint info. */
int show_breakpoint_hit_counts = 1;
if (b->type == bp_hardware_breakpoint)
{
- if (b->loc->address != (*pc - DECR_PC_AFTER_HW_BREAK))
+ if (b->loc->address != *pc)
continue;
if (overlay_debugging /* unmapped overlay section */
&& section_is_overlay (b->loc->section)
if (real_breakpoint && bs)
{
- if (bs->breakpoint_at->type == bp_hardware_breakpoint)
- {
- if (DECR_PC_AFTER_HW_BREAK != 0)
- {
- *pc = *pc - DECR_PC_AFTER_HW_BREAK;
- write_pc (*pc);
- }
- }
- else
+ if (bs->breakpoint_at->type != bp_hardware_breakpoint)
{
- if (DECR_PC_AFTER_BREAK != 0 || must_shift_inst_regs)
+ if (DECR_PC_AFTER_BREAK != 0)
{
*pc = bp_addr;
-#if defined (SHIFT_INST_REGS)
- SHIFT_INST_REGS ();
-#else /* No SHIFT_INST_REGS. */
write_pc (bp_addr);
-#endif /* No SHIFT_INST_REGS. */
}
}
}
/* Native macro definitions for GDB on an Intel i[3456]86.
- Copyright 2001 Free Software Foundation, Inc.
+ Copyright 2001, 2004 Free Software Foundation, Inc.
This file is part of GDB.
#define target_remove_hw_breakpoint(addr, shadow) \
i386_remove_hw_breakpoint (addr, shadow)
-#define DECR_PC_AFTER_HW_BREAK 0
-
/* child_post_startup_inferior used to
reset all debug registers by calling i386_cleanup_dregs (). */
#define CHILD_POST_STARTUP_INFERIOR
/* Memory-access and commands for "inferior" process, for GDB.
Copyright 1986, 1987, 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995,
- 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
+ 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GDB.
if (!stop_step)
break;
-
- /* FIXME: On nexti, this may have already been done (when we hit the
- step resume break, I think). Probably this should be moved to
- wait_for_inferior (near the top). */
-#if defined (SHIFT_INST_REGS)
- SHIFT_INST_REGS ();
-#endif
}
if (!single_inst || skip_subroutines)
count = arg->next->next->data.integer;
if (stop_step)
- {
- /* FIXME: On nexti, this may have already been done (when we hit the
- step resume break, I think). Probably this should be moved to
- wait_for_inferior (near the top). */
-#if defined (SHIFT_INST_REGS)
- SHIFT_INST_REGS ();
-#endif
- step_once (skip_subroutines, single_inst, count - 1);
- }
+ step_once (skip_subroutines, single_inst, count - 1);
else
if (!single_inst || skip_subroutines)
do_exec_cleanups (ALL_CLEANUPS);
if (stop_signal == TARGET_SIGNAL_TRAP && !signal_program[stop_signal])
stop_signal = TARGET_SIGNAL_0;
-#ifdef SHIFT_INST_REGS
- /* I'm not sure when this following segment applies. I do know,
- now, that we shouldn't rewrite the regs when we were stopped
- by a random signal from the inferior process. */
- /* FIXME: Shouldn't this be based on the valid bit of the SXIP?
- (this is only used on the 88k). */
-
- if (!bpstat_explains_signal (stop_bpstat)
- && (stop_signal != TARGET_SIGNAL_CHLD) && !stopped_by_random_signal)
- SHIFT_INST_REGS ();
-#endif /* SHIFT_INST_REGS */
resume (currently_stepping (ecs), stop_signal);
}
/* Interface between GDB and target environments, including files and processes
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+ 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
Contributed by Cygnus Support. Written by John Gilmore.
(*current_target.to_stopped_data_address) ()
#endif
-/* If defined, then we need to decr pc by this much after a hardware break-
- point. Presumably this overrides DECR_PC_AFTER_BREAK... */
-
-#ifndef DECR_PC_AFTER_HW_BREAK
-#define DECR_PC_AFTER_HW_BREAK 0
-#endif
-
/* Sometimes gdb may pick up what appears to be a valid target address
from a minimal symbol, but the value really means, essentially,
"This is an index into a table which is populated when the inferior