On Fri, 26 May 2006, vamsi krishna wrote:

Hello All,

the /proc/<pid>/*map files seems to be binary files, how can I get
list of memory mapping in program ? (specifically those between heap
and stack).

o Is there a more elegant way rather than doing something like
FILE *ptr = popen("pmap <pid>","r"); (reading the standard out of pmap)

can i parse the *map files ? If yes is there any reference I can read it??

The sourcecode for pmap is one, usr/src/cmd/ptools/pmap/pmap.c, in the opensolaris sources.

The manpages for procfs, see proc(4), document the format of /proc/<PID>/map (albeit not /proc/<PID>/xmap, though the source of course tells you how it works - that it's not documented is mostly because we want to be able to extend/modify it ... and hence it's not a stable interface by classification).

FrankH.



Looking forward to hear from you.

Best,
Vamsi.
_______________________________________________
opensolaris-code mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/opensolaris-code

_______________________________________________
opensolaris-code mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/opensolaris-code

Reply via email to