2 .\" This file and its contents are supplied under the terms of the
3 .\" Common Development and Distribution License ("CDDL"), version 1.0.
4 .\" You may only use this file in accordance with the terms of version
7 .\" A full copy of the text of the CDDL should have accompanied this
8 .\" source. A copy of the CDDL is also available via the Internet at
9 .\" http://www.illumos.org/license/CDDL.
12 .\" Copyright 2015 Joyent, Inc.
15 .Dt PLOOKUP_BY_ADDR 3PROC
19 .Nm Pxlookup_by_addr ,
20 .Nm Pxlookup_by_addr_resolved ,
23 .Nd lookup symbols in a process
30 .Fa "struct ps_prochandle *P"
38 .Fa "struct ps_prochandle *P"
43 .Fa "prsyminfo_t *sip"
46 .Fo Pxlookup_by_addr_resolved
47 .Fa "struct ps_prochandle *P"
52 .Fa "prsyminfo_t *sip"
56 .Fa "struct ps_prochandle *P"
57 .Fa "const char *object"
58 .Fa "const char *symbol"
63 .Fa "struct ps_prochandle *P"
65 .Fa "const char *object"
66 .Fa "const char *symbol"
68 .Fa "prsyminfo_t *sip"
73 .Fn Pxlookup_by_addr ,
74 .Fn Pxlookup_by_addr_resolved ,
78 functions look up symbol information in the process handle
80 and fill in the ELF symbol information in
82 with the found symbol.
83 Symbols may be looked up both by address and name.
87 function looks up symbol information corresponding to the address
91 bytes of the symbol's name, including the null terminator will be filled
97 function is identical to the
99 function, except that it also fills in the structure
101 with additional information.
102 The definition of the
108 .Fn Pxlookup_by_addr_resolved
109 function is similar to the
111 function; however, it attempts to resolve the paths present in the
113 to an absolute path on the file system.
117 function attempts to look up a symbol based on its name.
120 argument allows the caller to specify a specific object that was mapped
121 in by the run-time link-editor to search for
124 The system provides three special values which may be passed in for
128 refers to the executable's object (a.out).
135 indicates that every object should be searched.
139 function is similar to the
141 function; however, it allows a link-map identifier,
143 to be specified and also provides additional information about the
144 symbol in the form of the
149 restricts the search for the object named
153 to the specified link-map.
155 There are three special link-map identifiers that may be passed in.
158 indicates that every link-map should be searched.
161 indicates that the base link-map, the one that is used for the
162 executable should be searched.
165 refers to the link-map that is used by the run-time link editor, ld.so.1.
168 function behaves like
172 argument is passed to
174 indicating that every link-map should be searched.
176 Upon successful completion, the
177 .Fn Plookup_by_addr ,
178 .Fn Pxlookup_by_addr ,
179 .Fn Pxlookup_by_addr_resolved ,
180 .Fn Plookup_by_name ,
185 and fill in the symbol information.
188 is returned to indicate that the symbol could not be found.
189 .Sh INTERFACE STABILITY