I am sponsoring this case for Ed Pilatowicz. Since this is a simple change in classification of an existing option, I marked it closed approved automatic. If anyone feels this needs more review, let me know and I'll change it to a fast-track.
Thanks, Jerry Template Version: @(#)sac_nextcase 1.66 04/17/08 SMI This information is Copyright 2008 Sun Microsystems 1. Introduction 1.1. Project/Component Working Name: pmadvise/pldd unresolved link map flag 1.2. Name of Document Author/Supplier: Author: Ed Pilatowicz 1.3 Date of This Document: 31 July, 2008 4. Technical Description pmadvise/pldd unresolved link map flag This case requests patch binding. (With an intent to back port this functionality to s10.) New interface stability is documented in the interface table below. A. INTRODUCTION Currently, pmap supports an un-arced -l option (introduced by [1]) which controls how object paths are displayed. If the -l flag is specified, pmap reports the object names as reported by the target processes linker. If the -l flag is not specified, pmap tries a variety of techniques to attempt to determine the real filesystem path to the mapped object. Pmadvise[2] has a special -v mode where it displays output almost identical to pmap output, but annotated to include memory advice settings. B. DESCRIPTION The fix for 6599704[3] moves all the special filesystem object resolution code currently found in pmap into libproc. Doing this provides for more consistent results and allows all libproc consumers to have access to both raw linker object names and the resolved filesystem paths that correspond to those object names. Pmap will continue to function as it currently does, but this new object resolution functionality will be enabled by default for pldd and pmadvise -v. Pmadvise -v will be updated to support a -l flag, who's behavior will mirror that of the pmap -l flag. Pldd will be updated to display resolved filesystem object paths by default, and if a -l flag is specified, the raw linker object paths will be displayed. Here's an example. With the fix for 6599704, if pldd is run against the 'init' process running in an lx branded zone, we will see the following resolved filesystem paths to all loaded objects: ---8<--- root at ns-x4100-5$ pldd 101753 101753: /sbin/init /usr/lib/lx_brand.so.1 /usr/lib/libmapmalloc.so.1 /usr/lib/libc/libc_hwcap2.so.1 /lib/libsocket.so.1 /lib/libnsl.so.1 /export/zones/lx1/root/lib/tls/libc-2.3.2.so /export/zones/lx1/root/lib/ld-2.3.2.so ---8<--- If the -l flag is passed to pldd, then we'll see the raw and unresolved object paths as reported by the linker data in the target process. ---8<--- root at ns-x4100-5$ pldd -l 101753 101753: /sbin/init /native/usr/lib/lx_brand.so.1 /native/usr/lib/libmapmalloc.so.1 /native/lib/libc.so.1 /native/lib/libsocket.so.1 /native/lib/libnsl.so.1 /lib/tls/libc.so.6 /lib/ld-linux.so.2 ---8<--- C. INTERFACES pmadvise, and pldd [-l] option Committed pmadvise, and pldd [-l] output format Uncommitted C. REFERENCES [1] 4088148 truss, gcore, and the /proc tools should use a common library [2] PSARC/2004/484 pmadvise [3] 6599704 libproc should look inside zones for objects D. MANPAGE CHANGES To be determined. The diffs will eventually be included in: 6722171 pmadvise and pldd have new '-l' flags that should be documented 6. Resources and Schedule 6.4. Steering Committee requested information 6.4.1. Consolidation C-team Name: ON 6.5. ARC review type: Automatic 6.6. ARC Exposure: open