From: Gisle D. <gi...@tr...> - 2008-04-16 14:35:00
|
(Apologies if this has already been addressed). Some anonymous maps appear in /proc/maps with a name, such as [heap]. Currently, the oprofile daemon keeps track of such names, and they get used in the sample directories to indicate the type of anonymous regions, e.g. {anon:[heap]}. Currently, this can cause a crash: Because there is a delay between a sample being taken and the reading of /proc/pid/maps, the map can have changed from an anonymous map to a named map. If the named map contains /'s, we end up with something like {anon:/usr/lib/....}. The directory parsing code doesn't seem to like /'s inside the curly brackets, and ends up throwing an error from the STL string class (AFAIC). I'm just wondering what the reason was for putting these names in there was? Are there any major objections to removing them? I believe removing the name will have another benefit: In opd_anon.c, all maps of every process with anonymous samples get read from /proc/pid/maps. Some of the programs we're dealing with have several hundred (mostly named) maps. Couple this with a less-than-perfect hashing algorithm, there's a lot of list-walking going on when processing anon samples. Storing all maps, not just the anonymous ones, clearly does not help. Any insight would be much appreciated. Cheers, Gisle -- Gisle Dankel Principal Engineer Transitive Maybrook House, 40 Blackfriars Street, Manchester M3 2EG Phone: +44 (0)161 836 2343 Fax: +44 (0)161 836 2399 www.transitive.com * Eliminate the hardware|software dependency This E-mail and any attachments hereto are strictly confidential and intended solely for the addressee. If you are not the intended addressee please notify the sender by return and delete the message. You must not disclose, forward or copy this E-mail or attachments to any third party without the prior consent of the sender. |