Print this page
8158 Want named threads API
9857 proc manpages should have LIBRARY section
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/man/man3proc/Paddr_to_ctf.3proc.man.txt
+++ new/usr/src/man/man3proc/Paddr_to_ctf.3proc.man.txt
1 1 PADDR_TO_CTF(3PROC) Process Control Library Functions PADDR_TO_CTF(3PROC)
2 2
3 3 NAME
4 4 Paddr_to_ctf, Plmid_to_ctf, Pname_to_ctf - lookup CTF data
5 5
6 -SYNOPSIS
6 +LIBRARY
7 7 Process Control Library (libproc, -lproc)
8 +
9 +SYNOPSIS
8 10 #include <libproc.h>
9 11
10 12 ctf_file_t *
11 13 Paddr_to_ctf(struct ps_prochandle *P, uintptr_t addr);
12 14
13 15 ctf_file_t *
14 16 Plmid_to_ctf(struct ps_prochandle *P, Lmid_t lmid, const char *name);
15 17
16 18 ctf_file_t *
17 19 Pname_to_ctf(struct ps_prochandle *P, const char *name);
18 20
19 21 DESCRIPTION
20 22 The Paddr_to_ctf(), Plmid_to_ctf(), and Pname_to_ctf() functions lookup
21 23 CTF (Compact C Type Format) data, for use with libctf, from the process
22 24 represented by the handle P. In all cases, the CTF sections of both the
23 25 running executable and its shared libraries are searched.
24 26
25 27 The CTF container returned is valid as long as the process handle P is
26 28 valid. That is, until a call to Prelease(3PROC) is made. Further,
27 29 consumers must not close the CTF container.
28 30
29 31 The Paddr_to_ctf() function attempts to find the CTF section, if any,
30 32 that exists for the address addr. Note, not all addresses correspond to
31 33 memory regions that have CTF data. For example, if a user creates a
32 34 region of anonymous memory through the mmap(2) function, then it will not
33 35 have any corresponding CTF information.
34 36
35 37 The Pname_to_ctf() function looks up the object named name and returns
36 38 the corresponding CTF section, if any exists. Two special values may be
37 39 used for name. The macro PR_OBJ_EXEC refers to the executable object
38 40 itself and the macro PR_OBJ_LDSO refers to the object ld.so.1.
39 41
40 42 The Plmid_to_ctf() function is similar to Pname_to_ctf(). It allows the
41 43 passing of a link-map identifier, lmid, which constricts the search of
42 44 the object named with name to that link-map. The special value of
43 45 PR_LMID_EVERY indicates that every link-map should be searched, which is
44 46 equivalent in behavior to the Pname_to_ctf() function.
45 47
46 48 RETURN VALUES
47 49 Upon successful completion, the Paddr_to_ctf(), Plmid_to_ctf(), and
48 50 Pname_to_ctf() functions return a pointer to the corresponding CTF
49 51 container. Otherwise, if none exists then NULL is returned.
50 52
51 53 INTERFACE STABILITY
52 54 Uncommitted
53 55
54 56 MT-LEVEL
55 57 See LOCKING in libproc(3LIB).
56 58
57 59 SEE ALSO
58 60 libproc(3LIB), ctf(4)
59 61
60 62 illumos May 11, 2016 illumos
↓ open down ↓ |
43 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX