mirror of
https://github.com/darlinghq/darling-gdb.git
synced 2024-11-24 12:39:59 +00:00
* gdbarch.sh (BREAKPOINT_FROM_PC): Return a const buffer.
* gdbarch.h, gdbarch.c: Regenerate. * defs.h (breakpoint_from_pc_fn): Delete type definition. * target.h (memory_breakpoint_from_pc): Update declaration. * config/mcore/tm-mcore.h (mcore_breakpoint_from_p): Ditto. * arch-utils.c (legacy_breakpoint_from_pc): Update return type. * mcore-tdep.c (mcore_breakpoint_from_pc): Ditto. * mem-break.c (memory_breakpoint_from_pc): Ditto. * rs6000-tdep.c (rs6000_breakpoint_from_pc): Ditto. * s390-tdep.c (s390_breakpoint_from_pc): Ditto * xstormy16-tdep.c (xstormy16_breakpoint_from_pc): Ditto. * mn10300-tdep.c (mn10300_breakpoint_from_pc): Ditto. * mips-tdep.c (mips_breakpoint_from_pc): Ditto. * m68hc11-tdep.c (m68hc11_breakpoint_from_pc): Ditto. * ia64-tdep.c (ia64_breakpoint_from_pc): Ditto. * d10v-tdep.c (d10v_breakpoint_from_pc): Ditto. * arch-utils.c (legacy_breakpoint_from_pc): Ditto.. * mem-break.c (default_memory_insert_breakpoint): Make `bp' a const pointer. * monitor.c (monitor_insert_breakpoint): Ditto. * rs6000-tdep.c (rs6000_software_single_step): Ditto for `breakp'. * config/mcore/tm-mcore.h: Update copyright. * mem-break.c: Ditto. * xstormy16-tdep.c: Ditto.
This commit is contained in:
parent
29f319b84c
commit
f4f9705a2d
@ -1,3 +1,34 @@
|
||||
2002-04-18 Andrew Cagney <cagney@redhat.com>
|
||||
|
||||
* gdbarch.sh (BREAKPOINT_FROM_PC): Return a const buffer.
|
||||
* gdbarch.h, gdbarch.c: Regenerate.
|
||||
|
||||
* defs.h (breakpoint_from_pc_fn): Delete type definition.
|
||||
* target.h (memory_breakpoint_from_pc): Update declaration.
|
||||
* config/mcore/tm-mcore.h (mcore_breakpoint_from_p): Ditto.
|
||||
|
||||
* arch-utils.c (legacy_breakpoint_from_pc): Update return type.
|
||||
* mcore-tdep.c (mcore_breakpoint_from_pc): Ditto.
|
||||
* mem-break.c (memory_breakpoint_from_pc): Ditto.
|
||||
* rs6000-tdep.c (rs6000_breakpoint_from_pc): Ditto.
|
||||
* s390-tdep.c (s390_breakpoint_from_pc): Ditto
|
||||
* xstormy16-tdep.c (xstormy16_breakpoint_from_pc): Ditto.
|
||||
* mn10300-tdep.c (mn10300_breakpoint_from_pc): Ditto.
|
||||
* mips-tdep.c (mips_breakpoint_from_pc): Ditto.
|
||||
* m68hc11-tdep.c (m68hc11_breakpoint_from_pc): Ditto.
|
||||
* ia64-tdep.c (ia64_breakpoint_from_pc): Ditto.
|
||||
* d10v-tdep.c (d10v_breakpoint_from_pc): Ditto.
|
||||
* arch-utils.c (legacy_breakpoint_from_pc): Ditto..
|
||||
|
||||
* mem-break.c (default_memory_insert_breakpoint): Make `bp' a
|
||||
const pointer.
|
||||
* monitor.c (monitor_insert_breakpoint): Ditto.
|
||||
* rs6000-tdep.c (rs6000_software_single_step): Ditto for `breakp'.
|
||||
|
||||
* config/mcore/tm-mcore.h: Update copyright.
|
||||
* mem-break.c: Ditto.
|
||||
* xstormy16-tdep.c: Ditto.
|
||||
|
||||
2002-04-18 Pierre Muller <muller@ics.u-strasbg.fr>
|
||||
|
||||
* p-exp.y: Add precedence rule for '^' token.
|
||||
|
@ -1,5 +1,7 @@
|
||||
/* Dynamic architecture support for GDB, the GNU debugger.
|
||||
Copyright 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
|
||||
|
||||
Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation,
|
||||
Inc.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
@ -55,7 +57,7 @@
|
||||
and optionally adjust the pc to point to the correct memory location
|
||||
for inserting the breakpoint. */
|
||||
|
||||
unsigned char *
|
||||
const unsigned char *
|
||||
legacy_breakpoint_from_pc (CORE_ADDR * pcptr, int *lenptr)
|
||||
{
|
||||
/* {BIG_,LITTLE_}BREAKPOINT is the sequence of bytes we insert for a
|
||||
|
@ -1,5 +1,6 @@
|
||||
/* Parameters for execution on a Motorola MCore.
|
||||
Copyright 1995, 1999, 2000 Free Software Foundation, Inc.
|
||||
|
||||
Copyright 1995, 1999, 2000, 2002 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
@ -62,7 +63,8 @@ extern char *mcore_register_names[];
|
||||
|
||||
/* BREAKPOINT_FROM_PC uses the program counter value to determine
|
||||
the breakpoint that should be used. */
|
||||
extern breakpoint_from_pc_fn mcore_breakpoint_from_pc;
|
||||
extern const unsigned char *mcore_breakpoint_from_pc (CORE_ADDR *pcptr,
|
||||
int *lenptr);
|
||||
#define BREAKPOINT_FROM_PC(PCPTR, LENPTR) mcore_breakpoint_from_pc (PCPTR, LENPTR)
|
||||
|
||||
#define INNER_THAN(LHS,RHS) ((LHS) < (RHS))
|
||||
|
@ -150,7 +150,7 @@ d10v_use_struct_convention (int gcc_p, struct type *type)
|
||||
}
|
||||
|
||||
|
||||
static unsigned char *
|
||||
static const unsigned char *
|
||||
d10v_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
|
||||
{
|
||||
static unsigned char breakpoint[] =
|
||||
|
@ -384,7 +384,6 @@ struct type;
|
||||
typedef int (use_struct_convention_fn) (int gcc_p, struct type * value_type);
|
||||
extern use_struct_convention_fn generic_use_struct_convention;
|
||||
|
||||
typedef unsigned char *(breakpoint_from_pc_fn) (CORE_ADDR * pcptr, int *lenptr);
|
||||
|
||||
/* Annotation stuff. */
|
||||
|
||||
|
@ -3840,7 +3840,7 @@ set_gdbarch_inner_than (struct gdbarch *gdbarch,
|
||||
gdbarch->inner_than = inner_than;
|
||||
}
|
||||
|
||||
unsigned char *
|
||||
const unsigned char *
|
||||
gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr)
|
||||
{
|
||||
if (gdbarch->breakpoint_from_pc == 0)
|
||||
|
@ -1690,8 +1690,8 @@ extern void set_gdbarch_inner_than (struct gdbarch *gdbarch, gdbarch_inner_than_
|
||||
#define BREAKPOINT_FROM_PC(pcptr, lenptr) (legacy_breakpoint_from_pc (pcptr, lenptr))
|
||||
#endif
|
||||
|
||||
typedef unsigned char * (gdbarch_breakpoint_from_pc_ftype) (CORE_ADDR *pcptr, int *lenptr);
|
||||
extern unsigned char * gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr);
|
||||
typedef const unsigned char * (gdbarch_breakpoint_from_pc_ftype) (CORE_ADDR *pcptr, int *lenptr);
|
||||
extern const unsigned char * gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr);
|
||||
extern void set_gdbarch_breakpoint_from_pc (struct gdbarch *gdbarch, gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc);
|
||||
#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (BREAKPOINT_FROM_PC)
|
||||
#error "Non multi-arch definition of BREAKPOINT_FROM_PC"
|
||||
|
@ -544,7 +544,7 @@ F:2:INIT_EXTRA_FRAME_INFO:void:init_extra_frame_info:int fromleaf, struct frame_
|
||||
f:2:SKIP_PROLOGUE:CORE_ADDR:skip_prologue:CORE_ADDR ip:ip::0:0
|
||||
f:2:PROLOGUE_FRAMELESS_P:int:prologue_frameless_p:CORE_ADDR ip:ip::0:generic_prologue_frameless_p::0
|
||||
f:2:INNER_THAN:int:inner_than:CORE_ADDR lhs, CORE_ADDR rhs:lhs, rhs::0:0
|
||||
f:2:BREAKPOINT_FROM_PC:unsigned char *:breakpoint_from_pc:CORE_ADDR *pcptr, int *lenptr:pcptr, lenptr:::legacy_breakpoint_from_pc::0
|
||||
f:2:BREAKPOINT_FROM_PC:const unsigned char *:breakpoint_from_pc:CORE_ADDR *pcptr, int *lenptr:pcptr, lenptr:::legacy_breakpoint_from_pc::0
|
||||
f:2:MEMORY_INSERT_BREAKPOINT:int:memory_insert_breakpoint:CORE_ADDR addr, char *contents_cache:addr, contents_cache::0:default_memory_insert_breakpoint::0
|
||||
f:2:MEMORY_REMOVE_BREAKPOINT:int:memory_remove_breakpoint:CORE_ADDR addr, char *contents_cache:addr, contents_cache::0:default_memory_remove_breakpoint::0
|
||||
v:2:DECR_PC_AFTER_BREAK:CORE_ADDR:decr_pc_after_break::::0:-1
|
||||
|
@ -601,7 +601,7 @@ ia64_memory_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
|
||||
|
||||
/* We don't really want to use this, but remote.c needs to call it in order
|
||||
to figure out if Z-packets are supported or not. Oh, well. */
|
||||
unsigned char *
|
||||
const unsigned char *
|
||||
ia64_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
|
||||
{
|
||||
static unsigned char breakpoint[] =
|
||||
|
@ -270,7 +270,7 @@ m68hc11_register_name (int reg_nr)
|
||||
return m68hc11_register_names[reg_nr];
|
||||
}
|
||||
|
||||
static unsigned char *
|
||||
static const unsigned char *
|
||||
m68hc11_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
|
||||
{
|
||||
static unsigned char breakpoint[] = {0x0};
|
||||
|
@ -62,7 +62,7 @@ CORE_ADDR mcore_skip_prologue (CORE_ADDR pc);
|
||||
|
||||
CORE_ADDR mcore_frame_chain (struct frame_info *fi);
|
||||
|
||||
unsigned char *mcore_breakpoint_from_pc (CORE_ADDR * bp_addr, int *bp_size);
|
||||
const unsigned char *mcore_breakpoint_from_pc (CORE_ADDR * bp_addr, int *bp_size);
|
||||
|
||||
int mcore_use_struct_convention (int gcc_p, struct type *type);
|
||||
|
||||
@ -182,7 +182,7 @@ mcore_dump_insn (char *commnt, CORE_ADDR pc, int insn)
|
||||
instructions are 16 bits, this is all we need, regardless of
|
||||
address. bpkt = 0x0000 */
|
||||
|
||||
unsigned char *
|
||||
const unsigned char *
|
||||
mcore_breakpoint_from_pc (CORE_ADDR * bp_addr, int *bp_size)
|
||||
{
|
||||
static char breakpoint[] =
|
||||
|
@ -1,6 +1,8 @@
|
||||
/* Simulate breakpoints by patching locations in the target system, for GDB.
|
||||
Copyright 1990, 1991, 1992, 1993, 1995, 1997, 1998, 1999, 2000
|
||||
Free Software Foundation, Inc.
|
||||
|
||||
Copyright 1990, 1991, 1992, 1993, 1995, 1997, 1998, 1999, 2000,
|
||||
2002 Free Software Foundation, Inc.
|
||||
|
||||
Contributed by Cygnus Support. Written by John Gilmore.
|
||||
|
||||
This file is part of GDB.
|
||||
@ -40,7 +42,7 @@
|
||||
and optionally adjust the pc to point to the correct memory location
|
||||
for inserting the breakpoint. */
|
||||
|
||||
unsigned char *
|
||||
const unsigned char *
|
||||
memory_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
|
||||
{
|
||||
/* {BIG_,LITTLE_}BREAKPOINT is the sequence of bytes we insert for a
|
||||
@ -86,7 +88,7 @@ int
|
||||
default_memory_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
|
||||
{
|
||||
int val;
|
||||
unsigned char *bp;
|
||||
const unsigned char *bp;
|
||||
int bplen;
|
||||
|
||||
/* Determine appropriate breakpoint contents and size for this address. */
|
||||
@ -108,7 +110,7 @@ default_memory_insert_breakpoint (CORE_ADDR addr, char *contents_cache)
|
||||
int
|
||||
default_memory_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
|
||||
{
|
||||
unsigned char *bp;
|
||||
const unsigned char *bp;
|
||||
int bplen;
|
||||
|
||||
/* Determine appropriate breakpoint contents and size for this address. */
|
||||
|
@ -3712,7 +3712,7 @@ gdb_print_insn_mips (bfd_vma memaddr, disassemble_info *info)
|
||||
(if necessary) to point to the actual memory location where the
|
||||
breakpoint should be inserted. */
|
||||
|
||||
unsigned char *
|
||||
const unsigned char *
|
||||
mips_breakpoint_from_pc (CORE_ADDR * pcptr, int *lenptr)
|
||||
{
|
||||
if (TARGET_BYTE_ORDER == BFD_ENDIAN_BIG)
|
||||
|
@ -188,7 +188,7 @@ mn10300_use_struct_convention (int gcc_p, struct type *type)
|
||||
so we need a single byte breakpoint. Matsushita hasn't defined
|
||||
one, so we defined it ourselves. */
|
||||
|
||||
static unsigned char *
|
||||
const static unsigned char *
|
||||
mn10300_breakpoint_from_pc (CORE_ADDR *bp_addr, int *bp_size)
|
||||
{
|
||||
static char breakpoint[] =
|
||||
|
@ -2078,7 +2078,7 @@ static int
|
||||
monitor_insert_breakpoint (CORE_ADDR addr, char *shadow)
|
||||
{
|
||||
int i;
|
||||
unsigned char *bp;
|
||||
const unsigned char *bp;
|
||||
int bplen;
|
||||
|
||||
monitor_debug ("MON inst bkpt %s\n", paddr (addr));
|
||||
|
@ -759,7 +759,7 @@ ppc_sysv_abi_push_arguments (int nargs, struct value **args, CORE_ADDR sp,
|
||||
int
|
||||
ppc_linux_memory_remove_breakpoint (CORE_ADDR addr, char *contents_cache)
|
||||
{
|
||||
unsigned char *bp;
|
||||
const unsigned char *bp;
|
||||
int val;
|
||||
int bplen;
|
||||
char old_contents[BREAKPOINT_MAX];
|
||||
|
@ -280,7 +280,7 @@ branch_dest (int opcode, int instr, CORE_ADDR pc, CORE_ADDR safety)
|
||||
#define BIG_BREAKPOINT { 0x7d, 0x82, 0x10, 0x08 }
|
||||
#define LITTLE_BREAKPOINT { 0x08, 0x10, 0x82, 0x7d }
|
||||
|
||||
static unsigned char *
|
||||
const static unsigned char *
|
||||
rs6000_breakpoint_from_pc (CORE_ADDR *bp_addr, int *bp_size)
|
||||
{
|
||||
static unsigned char big_breakpoint[] = BIG_BREAKPOINT;
|
||||
@ -301,7 +301,7 @@ rs6000_software_single_step (enum target_signal signal,
|
||||
{
|
||||
CORE_ADDR dummy;
|
||||
int breakp_sz;
|
||||
char *breakp = rs6000_breakpoint_from_pc (&dummy, &breakp_sz);
|
||||
const char *breakp = rs6000_breakpoint_from_pc (&dummy, &breakp_sz);
|
||||
int ii, insn;
|
||||
CORE_ADDR loc;
|
||||
CORE_ADDR breaks[2];
|
||||
|
@ -1700,7 +1700,7 @@ s390_store_struct_return (CORE_ADDR addr, CORE_ADDR sp)
|
||||
|
||||
|
||||
|
||||
static unsigned char *
|
||||
const static unsigned char *
|
||||
s390_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
|
||||
{
|
||||
static unsigned char breakpoint[] = { 0x0, 0x1 };
|
||||
|
@ -1184,7 +1184,8 @@ extern int default_memory_remove_breakpoint (CORE_ADDR, char *);
|
||||
|
||||
extern int default_memory_insert_breakpoint (CORE_ADDR, char *);
|
||||
|
||||
extern breakpoint_from_pc_fn memory_breakpoint_from_pc;
|
||||
extern const unsigned char *memory_breakpoint_from_pc (CORE_ADDR *pcptr,
|
||||
int *lenptr);
|
||||
|
||||
|
||||
/* From target.c */
|
||||
|
@ -1,5 +1,6 @@
|
||||
/* Target-dependent code for the Sanyo Xstormy16a (LC590000) processor.
|
||||
Copyright 2001, Free Software Foundation, Inc.
|
||||
|
||||
Copyright 2001, 2002 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
@ -857,7 +858,7 @@ xstormy16_saved_pc_after_call (struct frame_info *ignore)
|
||||
return pc;
|
||||
}
|
||||
|
||||
static unsigned char *
|
||||
const static unsigned char *
|
||||
xstormy16_breakpoint_from_pc (CORE_ADDR *pcptr, int *lenptr)
|
||||
{
|
||||
static unsigned char breakpoint[] = { 0x06, 0x0 };
|
||||
|
Loading…
Reference in New Issue
Block a user