De-inline gdb_cpu_signal() because we need to convert the trap vectors

related to breakpoints and single stepping into SIGTRAP so gdb(1) knows
why the remote target has stopped. In particular, gdb(1) needs to know
if the reason is something of its own doing.
This commit is contained in:
Marcel Moolenaar 2004-08-07 21:40:52 +00:00
parent bc31d0a1d7
commit 7d9a8b1cd5
2 changed files with 11 additions and 7 deletions

View File

@ -136,6 +136,16 @@ gdb_cpu_setreg(int regnum, register_t val)
}
}
int
gdb_cpu_signal(int vector, int dummy __unused)
{
if (vector == IA64_VEC_BREAK || vector == IA64_VEC_SINGLE_STEP_TRAP)
return (SIGTRAP);
/* Add 100 so GDB won't translate the vector into signal names. */
return (vector + 100);
}
int
gdb_cpu_query(void)
{

View File

@ -40,15 +40,9 @@ gdb_cpu_regsz(int regnum)
return ((regnum >= 128 && regnum < 256) ? 16 : 8);
}
static __inline int
gdb_cpu_signal(int vector, int dummy __unused)
{
/* Add 100 so GDB won't translate the vector into signal names. */
return (vector + 100);
}
void *gdb_cpu_getreg(int, size_t *);
void gdb_cpu_setreg(int, register_t);
int gdb_cpu_signal(int, int);
int gdb_cpu_query(void);
#endif /* !_MACHINE_GDB_MACHDEP_H_ */