HP-UX Reference (11i v2 07/12) - 2 System Calls (vol 5)
t
ttrace(2) ttrace(2)
identical to TT_PROC_SET_IBPT_REGS
and
TT_PROC_SET_DBPT_REGS
respectively in other
respects.
Note: The available breakpoint registers must be shared between process-wide breakpoints and per-
thread breakpoints. If a breakpoint register is currently being used as a process-wide breakpoint
within the target process, it may not be used for a per-thread breakpoint in any thread of the target
process.
Note: These requests are not supported on PA-RISC versions of HP-UX.
TT_LWP_GET_IBPT_REGS
TT_LWP_GET_DBPT_REGS
These requests read per-thread breakpoint values from breakpoint registers. They are identical to
TT_PROC_GET_IBPT_REGS
and TT_PROC_GET_DBPT_REGS
respectively in other respects.
Note: These requests are not supported on PA-RISC versions of HP-UX.
TT_LWP_RDRSEBS
TT_LWP_WRRSEBS
TT_LWP_RDRSEBS_NOATTACH
These requests allow the calling process to access stacked general register values that have not yet
been written to the RSE backing store. data bytes that would have been spilled at addr on the user’s
RSE backing store, had the RSE been flushed, are copied to or from addr2 in the the calling process.
The addr argument must be 8-byte-aligned and conform to
ar.bspstore ≤ addr < ar.bsp. data
must be a multiple of 8 bytes, and addr+data must also conform to
ar.bspstore ≤ addr+data <
ar.bsp. As a special case, to retrieve the final NaT collection, addr ==
ar.bsp | 0x1f8 and
data ==
8 are also accepted.
Note: This facility should be used only to modify values of registers that were dirty when the thread
was stopped. Do not use this facility if the values of ar.bsp or ar.bspstore have been modified.
Note: These requests are not supported on PA-RISC versions of HP-UX.
Non-debug-related Request
There is currently only one non debug-related request:
TT_NDR_GET_FLEV
This call returns the feature level of the operating system and has been introduced to help debugger
developers make their tools more portable from one version to another. 11.0 systems can be identified
by the fact that this call will return an error. Later releases will return the TT_FEATURE_LEVEL
value the operating system was compiled with (see ttrace.h). The release levels for systems newer
than 11.0 are:
Level 5: internal change
Level 6: add DETACH_ON_EXIT
attach option.
Level 7: add
TTEVT_BPT_SSTEP
event.
Level 8: add
TT_PROC_SET_IBPT
, TT_PROC_SET_DBPT, TT_PROC_GET_IBPT
,
TT_PROC_GET_DBPT
, TT_PROC_GET_NUM_IBPT_REGS,
TT_PROC_GET_NUM_DBPT_REGS, TT_PROC_GET_ARGS
, TT_LWP_SET_IBPT,
TT_LWP_SET_DBPT, TT_LWP_GET_IBPT, TT_LWP_GET_DBPT
,
TT_LWP_RDRSEBS, TT_LWP_WRRSEBS, TT_LWP_TBRANCH
requests.
Level 9: add
TT_PROC_GET_SIGMASK, TT_PROC_SET_SIGMASK,
TT_LWP_GET_SIGMASK, TT_LWP_SET_SIGMASK
requests.
Level 10: add
TTEVT_PREFORK, TTEVT_FORK_FAIL
events.
Level 11: allow the
TT_PROC_CORE request to generate user specified core file names.
Level 12: add _NOATTACH requests.
Security Restrictions
For security reasons, ttrace() inhibits the set-user-ID facility on subsequent exec() calls.
Events
As noted earlier, a tracing process can set event flags in the context of a traced process, or its individual
threads, to cause the threads to respond to specific events during their execution. When an event flag is set
HP-UX 11i Version 2: December 2007 Update − 9 − Hewlett-Packard Company 489