2003-01-18 13:32:11 +03:00
|
|
|
|
|
|
|
PTQ_HEAD(thread_queue_t, td_thread_st);
|
|
|
|
PTQ_HEAD(sync_queue_t, td_sync_st);
|
|
|
|
|
|
|
|
struct td_proc_st {
|
|
|
|
struct td_proc_callbacks_t *cb;
|
|
|
|
void *arg;
|
|
|
|
|
2004-02-02 23:08:27 +03:00
|
|
|
caddr_t dbgaddr;
|
|
|
|
caddr_t allqaddr;
|
2004-06-03 01:13:42 +04:00
|
|
|
caddr_t runqaddr;
|
|
|
|
caddr_t idleqaddr;
|
|
|
|
caddr_t suspqaddr;
|
2004-02-02 23:08:27 +03:00
|
|
|
caddr_t maxlwpsaddr;
|
|
|
|
caddr_t tsdallocaddr;
|
|
|
|
caddr_t tsddestaddr;
|
|
|
|
|
|
|
|
caddr_t stacksizeaddr;
|
|
|
|
int stacksizelg;
|
|
|
|
size_t stacksize;
|
|
|
|
vaddr_t stackmask;
|
2004-06-10 05:38:29 +04:00
|
|
|
struct reg *regbuf;
|
|
|
|
struct fpreg *fpregbuf;
|
|
|
|
|
2003-01-18 13:32:11 +03:00
|
|
|
struct thread_queue_t threads;
|
|
|
|
struct sync_queue_t syncs;
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
struct td_thread_st {
|
|
|
|
td_proc_t *proc;
|
|
|
|
caddr_t addr;
|
|
|
|
lwpid_t lwp;
|
|
|
|
PTQ_ENTRY(td_thread_st) list;
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
struct td_sync_st {
|
|
|
|
td_proc_t *proc;
|
|
|
|
caddr_t addr;
|
|
|
|
PTQ_ENTRY(td_sync_st) list;
|
|
|
|
};
|
|
|
|
|
|
|
|
#define READ(proc, addr, buf, size) ((proc)->cb->proc_read((proc)->arg, (addr), (buf), (size)))
|
|
|
|
#define WRITE(proc, addr, buf, size) ((proc)->cb->proc_write((proc)->arg, (addr), (buf), (size)))
|
|
|
|
#define LOOKUP(proc, sym, addr) ((proc)->cb->proc_lookup((proc)->arg, (sym), (addr)))
|
2004-06-10 05:38:29 +04:00
|
|
|
#define REGSIZE(proc, regset, size) ((proc)->cb->proc_regsize((proc)->arg, (regset), (size)))
|
2003-01-18 13:32:11 +03:00
|
|
|
#define GETREGS(proc, regset, lwp, buf) ((proc)->cb->proc_getregs((proc)->arg, (regset), (lwp), (buf)))
|
|
|
|
#define SETREGS(proc, regset, lwp, buf) ((proc)->cb->proc_setregs((proc)->arg, (regset), (lwp), (buf)))
|