Added new functions to the debugger API:

{set,clear}_debugger_{break,watch}point(), allowing to set/clear break
and watchpoints for the calling team. When a break/watchpoint is hit,
the team enters the debugger. Handy in situations when the program in
question can't really be started in a debugger (or it would be
complicated to do so). The functions work only as long as no debugger is
installed for the team.

We clear the arch specific team and thread debug infos now, when a new
debugger is installed, thus clearing break- and watchpoints.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20396 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold
2007-03-20 16:20:13 +00:00
parent a1394a90ad
commit 44b5d72b5a
5 changed files with 110 additions and 5 deletions
+10
View File
@@ -29,6 +29,16 @@ extern status_t remove_team_debugger(team_id team);
extern status_t debug_thread(thread_id thread);
extern void wait_for_debugger(void);
// EXPERIMENTAL: Self-debugging functions. Will fail when a team debugger is
// installed. A breakpoint/watchpoint hit will cause the default debugger to
// be installed for the team.
extern status_t set_debugger_breakpoint(void *address);
extern status_t clear_debugger_breakpoint(void *address);
extern status_t set_debugger_watchpoint(void *address, uint32 type,
int32 length);
extern status_t clear_debugger_watchpoint(void *address);
// team debugging flags
enum {
// event mask: If a flag is set, any of the team's threads will stop when