From: Xueming Li <xuemingl@mellanox.com>
To: Anatoly Burakov <anatoly.burakov@intel.com>,
Ferruh Yigit <ferruh.yigit@intel.com>
Cc: dev@dpdk.org, Asaf Penso <asafp@mellanox.com>
Subject: [dpdk-dev] [PATCH v1 0/2] malloc: support malloc and free tracking log
Date: Wed, 8 Apr 2020 04:04:52 +0000 [thread overview]
Message-ID: <1586318694-31358-1-git-send-email-xuemingl@mellanox.com> (raw)
In-Reply-To: <1585900482-5234-2-git-send-email-xuemingl@mellanox.com>
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
<shahafs@mellanox.com> who provided the idea.
V0: initial version
V1: log rte_realloc function
rename log size to req_size, real_size to size(total)
log padding and include padding in total size
rename log "free" field to "type", alloc_free to "paired"
rename malloc_log_index to malloc_log_count
split testpmd part into separate patch
add rte_malloc_log_stop() function
add log entry number check
change log dump detail level from (-1,0,1) to (0,1,2)
Xueming Li (2):
malloc: support malloc and free tracking log
app/testpmd: support malloc and free tracking log
app/test-pmd/cmdline.c | 60 ++++++-
doc/guides/testpmd_app_ug/testpmd_funcs.rst | 15 ++
lib/librte_eal/common/eal_memcfg.h | 26 +++
lib/librte_eal/common/malloc_elem.h | 6 +-
lib/librte_eal/common/rte_malloc.c | 259 +++++++++++++++++++++++++++-
lib/librte_eal/include/rte_malloc.h | 39 ++++-
lib/librte_eal/rte_eal_version.map | 3 +
7 files changed, 399 insertions(+), 9 deletions(-)
--
1.8.3.1
next prev parent reply other threads:[~2020-04-08 4:05 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-03 7:54 [dpdk-dev] [RFC] malloc: add malloc and free log function Xueming Li
2020-04-03 7:54 ` Xueming Li
2020-04-03 9:50 ` Burakov, Anatoly
2020-04-08 4:04 ` Xueming Li [this message]
2020-04-17 8:03 ` [dpdk-dev] [RFC v2 0/2] malloc: support malloc and free tracking log Xueming Li
2020-04-17 8:03 ` [dpdk-dev] [RFC v2 1/2] " Xueming Li
2020-04-17 8:03 ` [dpdk-dev] [RFC v2 2/2] app/testpmd: " Xueming Li
2020-04-21 13:41 ` Iremonger, Bernard
2020-07-30 15:10 ` Somnath Kotur
2020-07-30 15:13 ` Xueming(Steven) Li
2020-07-30 15:30 ` Somnath Kotur
2020-04-08 4:04 ` [dpdk-dev] [PATCH v1 1/2] malloc: " Xueming Li
2020-04-08 5:10 ` Stephen Hemminger
2020-04-08 5:11 ` Stephen Hemminger
2020-04-08 6:45 ` Xueming(Steven) Li
2020-04-08 4:04 ` [dpdk-dev] [PATCH v1 2/2] app/testpmd: " Xueming Li
2020-04-16 10:10 ` Iremonger, Bernard
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=1586318694-31358-1-git-send-email-xuemingl@mellanox.com \
--to=xuemingl@mellanox.com \
--cc=anatoly.burakov@intel.com \
--cc=asafp@mellanox.com \
--cc=dev@dpdk.org \
--cc=ferruh.yigit@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).