HP-UX Reference (11i v3 07/02) - 2 System Calls (vol 5)

t
ttrace(2) ttrace(2)
TT_PROC_GET_EVENT_MASK
This request returns the process-wide event flags and signal mask values.
The data argument specifies the number of bytes to be read from the context of the traced
process into the ttevent_t data structure in user space pointed to by addr.
The lwpid and addr2 arguments must be set to zero.
The
ttevent_t data structure is as follows:
typedef struct {
sigset_t tte_signals;
ttevents_t tte_events;
tteopt_t tte_opts;
} ttevent_t;
The options provided in tte_opts control the behavior of child processes produced by
fork() and are as follows:
TTEO_NONE = 0x0000
TTEO_NOSTRCCHLD = 0x0001
TTEO_PROC_INHERIT = 0x0002
TTEO_LWP_INHERIT = 0x0004
TTEO_NORM_SIGTRAP = 0x0008
If TTEO_NOSTRCCHLD
is set, the child process resulting from a fork() will not be
traced. This makes it possible for a debugger to debug another debugger. The
TTEO_PROC_INHERIT
and TTEO_LWP_INHERIT options allow events to be inherited
by child processes and threads respectively. Refer to the EVENTS section below.
If
TTEO_NORM_SIGTRAP
is set, the SIGTRAP signal behaves normally. That is, it is get-
ting delivered (the default behavior is to drop these signals).
TT_PROC_SET_EVENT_MASK
This request allows the tracing process to establish events and signals the traced process
will respond to. Refer to the EVENTS section for a description of these events.
The addr argument is a pointer to a
ttevent_t structure to be copied into the target
process. The data argument specifies the number of bytes to be transferred.
The lwpid and addr2 arguments must be set to zero.
TT_PROC_GET_SIGMASK
This request returns the process-wide signal mask value for the target process that was set
using TT_PROC_SET_SIGMASK
.
The data argument specifies the number of bytes to be read from the context of the traced
process into the
ttmask_t data structure in user space pointed by addr.
The lwpid and addr2 arguments must be set to zero.
The ttmask_t data structure is as follows:
typedef struct {
sigset_t ttm_signals;
ttmopt_t ttm_opts;
} ttmask_t;
The options provided in ttm_opts control the behavior of signal masks on child processes
produced by fork() and are as follows:
TTMO_NONE = 0x0000
TTMO_PROC_INHERIT = 0x0001
TTMO_LWP_INHERIT = 0x0002
The TTMO_PROC_INHERIT and TT_LWP_INHERIT option allow signal masks to be
inherited by child processes and threads respectively.
TT_PROC_SET_SIGMASK
This request allows the tracing process to change the signal mask on the target process.
The addr argument is a pointer to a ttmask_t structure to be copied into the target pro-
cess. The data argument specifies the number of bytes to be transferred.
HP-UX 11i Version 3: February 2007 3 Hewlett-Packard Company 499