JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
man pages section 3: Realtime Library Functions     Oracle Solaris 10 1/13 Information Library
search filter icon
search icon

Document Information

Preface

Realtime Library Functions

aiocancel(3AIO)

aio_cancel(3RT)

aio_error(3RT)

aio_fsync(3RT)

aioread(3AIO)

aio_read(3RT)

aio_return(3RT)

aio_suspend(3RT)

aiowait(3AIO)

aio_waitn(3RT)

aiowrite(3AIO)

aio_write(3RT)

clock_getres(3RT)

clock_gettime(3RT)

clock_nanosleep(3RT)

clock_settime(3RT)

door_bind(3DOOR)

door_call(3DOOR)

door_create(3DOOR)

door_cred(3DOOR)

door_info(3DOOR)

door_return(3DOOR)

door_revoke(3DOOR)

door_server_create(3DOOR)

door_ucred(3DOOR)

door_unbind(3DOOR)

door_xcreate(3DOOR)

fdatasync(3RT)

lio_listio(3RT)

mq_close(3RT)

mq_getattr(3RT)

mq_notify(3RT)

mq_open(3RT)

mq_receive(3RT)

mq_reltimedreceive_np(3RT)

mq_reltimedsend_np(3RT)

mq_send(3RT)

mq_setattr(3RT)

mq_timedreceive(3RT)

mq_timedsend(3RT)

mq_unlink(3RT)

nanosleep(3RT)

proc_service(3PROC)

ps_kill(3PROC)

ps_lcontinue(3PROC)

ps_lgetfpregs(3PROC)

ps_lgetregs(3PROC)

ps_lgetxregs(3PROC)

ps_lgetxregsize(3PROC)

ps_lrolltoaddr(3PROC)

ps_lsetfpregs(3PROC)

ps_lsetregs(3PROC)

ps_lsetxregs(3PROC)

ps_lstop(3PROC)

ps_pcontinue(3PROC)

ps_pdread(3PROC)

ps_pdwrite(3PROC)

ps_pglobal_lookup(3PROC)

ps_pglobal_sym(3PROC)

ps_pread(3PROC)

ps_pstop(3PROC)

ps_ptread(3PROC)

ps_ptwrite(3PROC)

ps_pwrite(3PROC)

sched_getparam(3RT)

sched_get_priority_max(3RT)

sched_get_priority_min(3RT)

sched_getscheduler(3RT)

sched_rr_get_interval(3RT)

sched_setparam(3RT)

sched_setscheduler(3RT)

sched_yield(3RT)

sem_close(3RT)

sem_destroy(3RT)

sem_getvalue(3RT)

sem_init(3RT)

sem_open(3RT)

sem_post(3RT)

sem_reltimedwait_np(3RT)

sem_timedwait(3RT)

sem_trywait(3RT)

sem_unlink(3RT)

sem_wait(3RT)

shm_open(3RT)

shm_unlink(3RT)

sigqueue(3RT)

sigtimedwait(3RT)

sigwaitinfo(3RT)

timer_create(3RT)

timer_delete(3RT)

timer_getoverrun(3RT)

timer_gettime(3RT)

timer_settime(3RT)

ps_pstop

, ps_pcontinue

, ps_lstop

, ps_lcontinue

, ps_lrolltoaddr

, ps_kill

- process and LWP control in libthread_db

Synopsis

#include <proc_service.h> 

ps_err_e ps_pstop(struct ps_prochandle *ph);
ps_err_e ps_pcontinue(struct ps_prochandle *ph);
ps_err_e ps_lstop(struct ps_prochandle *ph, lwpid_t lwpid);
ps_err_e ps_lcontinue(struct ps_prochandle *ph,
     lwpid_t lwpid);
ps_err_e ps_lrolltoaddr(struct ps_prochandle *ph,
     lwpid_t lwpid, psaddr_t go_addr, psaddr_t stop_addr);
ps_err_e ps_kill(struct ps_prochandle *ph, int signum);

Description

The ps_pstop() function stops the target process identified by ph, while the ps_pcontinue() function allows it to resume.

The libthread_db() function uses ps_pstop() to freeze the target process while it is under inspection. Within the scope of any single call from outside libthread_db to a libthread_db routine, libthread_db will call ps_pstop(), at most once. If it does, it will call ps_pcontinue() within the scope of the same routine.

The controlling process may already have stopped the target process when it calls libthread_db. In that case, it is not obligated to resume the target process when libthread_db calls ps_pcontinue(). In other words, ps_pstop() is mandatory, while ps_pcontinue() is advisory. After ps_pstop(), the target process must be stopped; after ps_pcontinue(), the target process may be running.

The ps_lstop() and ps_lcontinue() functions stop and resume a single lightweight process (LWP) within the target process ph.

The ps_lrolltoaddr() function is used to roll an LWP forward out of a critical section when the process is stopped. It is also used to run the libthread_db agent thread on behalf of libthread. The ps_lrolltoaddr() function is always called with the target process stopped, that is, there has been a preceding call to ps_pstop(). The specified LWP must be continued at the address go_addr, or at its current address if go_addr is NULL. It should then be stopped when its execution reaches stop_addr. This routine does not return until the LWP has stopped at stop_addr.

The ps_kill() function directs the signal signum to the target process for which the handle is ph. It has the same semantics as kill(2).

Return Values

PS_OK

The call completed successfully. In the case of ps_pstop(), the target process is stopped.

PS_BADLID

For ps_lstop(), ps_lcontinue() and ps_lrolltoaddr(); there is no LWP with id lwipd in the target process.

PS_ERR

The function did not return successfully.

Attributes

See attributes(5) for description of the following attributes:

ATTRIBUTE TYPE
ATTRIBUTE VALUE
MT Level
Safe

See Also

kill(2), libc_db(3LIB), proc_service(3PROC), attributes(5), threads(5)