From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id D9D5AA0562; Fri, 3 Apr 2020 09:55:05 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id B879F1C10F; Fri, 3 Apr 2020 09:54:59 +0200 (CEST) Received: from git-send-mailer.rdmz.labs.mlnx (unknown [37.142.13.130]) by dpdk.org (Postfix) with ESMTP id 6DCA11C0D9 for ; Fri, 3 Apr 2020 09:54:57 +0200 (CEST) From: Xueming Li To: Anatoly Burakov , Ferruh Yigit Cc: dev@dpdk.org, Asaf Penso Date: Fri, 3 Apr 2020 07:54:41 +0000 Message-Id: <1585900482-5234-1-git-send-email-xuemingl@mellanox.com> X-Mailer: git-send-email 1.8.3.1 Subject: [dpdk-dev] [RFC] malloc: add malloc and free log function X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" DPDK uses second level memory allocation management, this makes regular memory profiler tool not applicant. This patch trys to provide a lightweight malloc and free logging, then show leaked memory entries based on logs. This tool only target to malloc and free tracking, for memzone used by ring and mempool, "dump_memzone" in testpmd list them. There will be another example that enable and dump tracking as secondary process. This tool came from Mellanox internal Hackathon, thanks Shahaf Shuler who provided the idea. Xueming Li (1): malloc: add malloc and free log function app/test-pmd/cmdline.c | 61 ++++++++++- doc/guides/testpmd_app_ug/testpmd_funcs.rst | 15 +++ lib/librte_eal/common/eal_memcfg.h | 18 ++++ lib/librte_eal/common/include/rte_malloc.h | 30 +++++- lib/librte_eal/common/malloc_elem.h | 4 +- lib/librte_eal/common/rte_malloc.c | 154 +++++++++++++++++++++++++++- lib/librte_eal/rte_eal_version.map | 2 + 7 files changed, 280 insertions(+), 4 deletions(-) -- 1.8.3.1