From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25831 invoked by alias); 6 Mar 2008 20:27:15 -0000 Received: (qmail 25822 invoked by uid 22791); 6 Mar 2008 20:27:13 -0000 X-Spam-Check-By: sourceware.org Received: from bluesmobile.specifix.com (HELO bluesmobile.specifix.com) (216.129.118.140) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 06 Mar 2008 20:26:54 +0000 Received: from [127.0.0.1] (bluesmobile.specifix.com [216.129.118.140]) by bluesmobile.specifix.com (Postfix) with ESMTP id 32C3F3C533; Thu, 6 Mar 2008 12:26:53 -0800 (PST) Subject: Re: guessing where address belongs to From: Michael Snyder To: Andreas Schwab Cc: Yakov Lerner , gdb@sourceware.org In-Reply-To: References: <1204746687.19253.610.camel@localhost.localdomain> Content-Type: text/plain Date: Thu, 06 Mar 2008 20:28:00 -0000 Message-Id: <1204835212.19253.689.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.10.3 (2.10.3-7.fc7) Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-03/txt/msg00080.txt.bz2 On Thu, 2008-03-06 at 11:05 +0100, Andreas Schwab wrote: > "Yakov Lerner" writes: > > > Gdb has no integration with malloc, correct ? > > Gdb has no way of enumerating all malloced > > pieces ("heap objects"), correct ? > > > > Or gdb does have a way of guessing which "heap > > object" some address X (that points inside the heap) belongs to ? > > The details are highly dependent on the malloc implementation. There is > no way to find that out without intimate knowledge of the > implementation. Yep, and there's no marriage between any given platform and any given malloc implementation. Replacing the malloc from glibc is a fairly common thing to do, for instance. So gdb really has no idea what's in there...