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
29 .Fa "struct ps_prochandle *P"
37 .Fa "struct ps_prochandle *P"
42 .Fa "prsyminfo_t *sip"
45 .Fo Pxlookup_by_addr_resolved
46 .Fa "struct ps_prochandle *P"
51 .Fa "prsyminfo_t *sip"
55 .Fa "struct ps_prochandle *P"
56 .Fa "const char *object"
57 .Fa "const char *symbol"
62 .Fa "struct ps_prochandle *P"
64 .Fa "const char *object"
65 .Fa "const char *symbol"
67 .Fa "prsyminfo_t *sip"
72 .Fn Pxlookup_by_addr ,
73 .Fn Pxlookup_by_addr_resolved ,
77 functions look up symbol information in the process handle
79 and fill in the ELF symbol information in
81 with the found symbol.
82 Symbols may be looked up both by address and name.
86 function looks up symbol information corresponding to the address
90 bytes of the symbol's name, including the null terminator will be filled
96 function is identical to the
98 function, except that it also fills in the structure
100 with additional information.
101 The definition of the
107 .Fn Pxlookup_by_addr_resolved
108 function is similar to the
110 function; however, it attempts to resolve the paths present in the
112 to an absolute path on the file system.
116 function attempts to look up a symbol based on its name.
119 argument allows the caller to specify a specific object that was mapped
120 in by the run-time link-editor to search for
123 The system provides three special values which may be passed in for
127 refers to the executable's object (a.out).
134 indicates that every object should be searched.
138 function is similar to the
140 function; however, it allows a link-map identifier,
142 to be specified and also provides additional information about the
143 symbol in the form of the
148 restricts the search for the object named
152 to the specified link-map.
154 There are three special link-map identifiers that may be passed in.
157 indicates that every link-map should be searched.
160 indicates that the base link-map, the one that is used for the
161 executable should be searched.
164 refers to the link-map that is used by the run-time link editor, ld.so.1.
167 function behaves like
171 argument is passed to
173 indicating that every link-map should be searched.
175 Upon successful completion, the
176 .Fn Plookup_by_addr ,
177 .Fn Pxlookup_by_addr ,
178 .Fn Pxlookup_by_addr_resolved ,
179 .Fn Plookup_by_name ,
184 and fill in the symbol information.
187 is returned to indicate that the symbol could not be found.
188 .Sh INTERFACE STABILITY