All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Jérôme Pouiller" <jerome@sysmic.org>
To: Aneesh Bhasin <contact.aneesh@gmail.com>
Cc: "Pádraig Brady" <P@draigbrady.com>,
	"Randy Dunlap" <rdunlap@xenotime.net>,
	linux-newbie <linux-newbie@vger.kernel.org>,
	linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: smap output - unnamed entries and heap
Date: Thu, 17 Mar 2011 23:22:48 +0100	[thread overview]
Message-ID: <201103172322.49055.jerome@sysmic.org> (raw)
In-Reply-To: <AANLkTi=gN=DOU9bQtqdr1s44y5QgLn0W9_oRb9JTMWNa@mail.gmail.com>

On Thursday 17 March 2011 12:46:13 Aneesh Bhasin wrote:
[..]
> However, as I wrote earlier, there a lot of anonymous memory regions
> listed in smap output (with permission rwxp) - and I do not know of
> any way in which I could associate these memory mapping to a
> particular library..
A few years ago, I had a similar need. I made a small library which overload 
malloc (and free) and display caller (using backtrace_symbols function). 
Next I loaded it using LD_PRELOAD. The main problems are :
  * it only work for malloced memory (not mmaped memory)
  * It is difficult to interpred efficiently information provided. Name of 
caller may not be sufficient to understand why memory is allocated.

--
Jérôme Pouiller <jezz@sysmic.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-newbie" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.linux-learn.org/faqs

WARNING: multiple messages have this Message-ID (diff)
From: "Jérôme Pouiller" <jerome@sysmic.org>
To: Aneesh Bhasin <contact.aneesh@gmail.com>
Cc: "Pádraig Brady" <P@draigbrady.com>,
	"Randy Dunlap" <rdunlap@xenotime.net>,
	linux-newbie <linux-newbie@vger.kernel.org>,
	linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: smap output - unnamed entries and heap
Date: Thu, 17 Mar 2011 23:22:48 +0100	[thread overview]
Message-ID: <201103172322.49055.jerome@sysmic.org> (raw)
In-Reply-To: <AANLkTi=gN=DOU9bQtqdr1s44y5QgLn0W9_oRb9JTMWNa@mail.gmail.com>

On Thursday 17 March 2011 12:46:13 Aneesh Bhasin wrote:
[..]
> However, as I wrote earlier, there a lot of anonymous memory regions
> listed in smap output (with permission rwxp) - and I do not know of
> any way in which I could associate these memory mapping to a
> particular library..
A few years ago, I had a similar need. I made a small library which overload 
malloc (and free) and display caller (using backtrace_symbols function). 
Next I loaded it using LD_PRELOAD. The main problems are :
  * it only work for malloced memory (not mmaped memory)
  * It is difficult to interpred efficiently information provided. Name of 
caller may not be sufficient to understand why memory is allocated.

--
Jérôme Pouiller <jezz@sysmic.org>

  reply	other threads:[~2011-03-17 22:22 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-15  9:01 smap output - unnamed entries and heap Aneesh Bhasin
2011-03-15 16:14 ` Randy Dunlap
2011-03-16  5:19   ` Aneesh Bhasin
2011-03-16 14:09     ` Pádraig Brady
2011-03-16 14:09       ` Pádraig Brady
2011-03-17 11:46       ` Aneesh Bhasin
2011-03-17 11:46         ` Aneesh Bhasin
2011-03-17 22:22         ` Jérôme Pouiller [this message]
2011-03-17 22:22           ` Jérôme Pouiller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201103172322.49055.jerome@sysmic.org \
    --to=jerome@sysmic.org \
    --cc=P@draigbrady.com \
    --cc=contact.aneesh@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-newbie@vger.kernel.org \
    --cc=rdunlap@xenotime.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.