From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.6 required=5.0 tests=MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,URIBL_BLACK autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 22642 invoked from network); 5 Jun 2021 15:51:09 -0000 Received: from mother.openwall.net (195.42.179.200) by inbox.vuxu.org with ESMTPUTF8; 5 Jun 2021 15:51:09 -0000 Received: (qmail 13542 invoked by uid 550); 5 Jun 2021 15:51:07 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Reply-To: musl@lists.openwall.com Received: (qmail 13523 invoked from network); 5 Jun 2021 15:51:06 -0000 Date: Sat, 5 Jun 2021 11:50:54 -0400 From: Rich Felker To: Srinivasan J Cc: musl@lists.openwall.com Message-ID: <20210605155053.GF13220@brightrain.aerifal.cx> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Subject: Re: [musl] Dumping process heap from the core file On Thu, Jun 03, 2021 at 07:39:54AM +0530, Srinivasan J wrote: > Hi, > Is there an easy way to dump the heap from the process core which > is using musl-libc? The process is using musl-libc version v1.1.24. I > see that there is a _dump_heap() function, but that's not up to date. > I am thinking about using _dump_heap() as reference. But any other > suggestions are welcome. The mallocng heap structures are actually more walkable. There is intentionally no public interface for doing this, but I have some debug code left over from development that you could link into static-linked programs with a particular known musl/mallocng version or patch into libc.so for debugging purposes. I'll dig it up and post it. Ping me if I forget about it. Rich