aboutsummaryrefslogtreecommitdiff
path: root/gdb/config/sparc
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/config/sparc')
-rw-r--r--gdb/config/sparc/nm-sun4sol2.h10
-rw-r--r--gdb/config/sparc/tm-sun4sol2.h3
2 files changed, 7 insertions, 6 deletions
diff --git a/gdb/config/sparc/nm-sun4sol2.h b/gdb/config/sparc/nm-sun4sol2.h
index 51b5471..adc8231 100644
--- a/gdb/config/sparc/nm-sun4sol2.h
+++ b/gdb/config/sparc/nm-sun4sol2.h
@@ -53,17 +53,17 @@
It will *NOT* be necessary for GDB to step over the watchpoint. */
#define HAVE_CONTINUABLE_WATCHPOINT
-extern int procfs_stopped_by_watchpoint (int);
+extern int procfs_stopped_by_watchpoint (ptid_t);
#define STOPPED_BY_WATCHPOINT(W) \
- procfs_stopped_by_watchpoint(inferior_pid)
+ procfs_stopped_by_watchpoint(inferior_ptid)
/* Use these macros for watchpoint insertion/deletion. */
/* type can be 0: write watch, 1: read watch, 2: access watch (read/write) */
-extern int procfs_set_watchpoint (int, CORE_ADDR, int, int, int);
+extern int procfs_set_watchpoint (ptid_t, CORE_ADDR, int, int, int);
#define target_insert_watchpoint(ADDR, LEN, TYPE) \
- procfs_set_watchpoint (inferior_pid, ADDR, LEN, TYPE, 1)
+ procfs_set_watchpoint (inferior_ptid, ADDR, LEN, TYPE, 1)
#define target_remove_watchpoint(ADDR, LEN, TYPE) \
- procfs_set_watchpoint (inferior_pid, ADDR, 0, 0, 0)
+ procfs_set_watchpoint (inferior_ptid, ADDR, 0, 0, 0)
#endif /* NEW_PROC_API */
diff --git a/gdb/config/sparc/tm-sun4sol2.h b/gdb/config/sparc/tm-sun4sol2.h
index 7642fe3..09f36bb 100644
--- a/gdb/config/sparc/tm-sun4sol2.h
+++ b/gdb/config/sparc/tm-sun4sol2.h
@@ -82,6 +82,7 @@ extern char *sunpro_static_transform_name (char *);
#define HANDLE_SVR4_EXEC_EMULATORS
/* Macros to extract process id and thread id from a composite pid/tid */
-#define PIDGET(PID) (((PID) & 0xffff))
+#define PIDGET0(PID) (((PID) & 0xffff))
+#define PIDGET(PID) ((PIDGET0 (PID) == 0xffff) ? -1 : PIDGET0 (PID))
#define TIDGET(PID) (((PID) & 0x7fffffff) >> 16)
#define MERGEPID(PID, TID) (((PID) & 0xffff) | ((TID) << 16))