* [DPDK/ethdev Bug 1694] mlx5: ASAN reports memory leaks with send_to_kernel
@ 2025-04-07 15:47 bugzilla
0 siblings, 0 replies; only message in thread
From: bugzilla @ 2025-04-07 15:47 UTC (permalink / raw)
To: dev
[-- Attachment #1: Type: text/plain, Size: 6720 bytes --]
https://bugs.dpdk.org/show_bug.cgi?id=1694
Bug ID: 1694
Summary: mlx5: ASAN reports memory leaks with send_to_kernel
Product: DPDK
Version: 24.11
Hardware: x86
OS: Linux
Status: UNCONFIRMED
Severity: normal
Priority: Normal
Component: ethdev
Assignee: dev@dpdk.org
Reporter: brian90013@gmail.com
Target Milestone: ---
Hello,
I am very pleased with the extensive DPDK flow support available with the mlx5
driver. However, when testing my own code compiled with ASAN, I notice many
(limited to 5000) reports of indirect memory leaks from libmlx5.so whenever the
send_to_kernel action is used. I can use other actions like DROP, QUEUE, JUMP,
and COUNT without seeing any leaks. I've repeated the test multiple times with
the same total volume of leaked memory each time.
Hardware:
* 42:00.0 Ethernet controller: Mellanox Technologies MT2892 Family [ConnectX-6
Dx]
Software stack:
* Debian 12.9 kernel 6.1.0-32-amd64
* DOCA-roce 2.10.0
* DPDK 24.11.1
* Configured with: meson build -Denable_kmods=true -Db_sanitize=address
-Db_lundef=false -Dbuildtype=debug
Test case:
* Using flow rule described in commit:
https://mails.dpdk.org/archives/dev/2022-September/251470.html
$ sudo dpdk-testpmd --in-memory -- -i
EAL: Detected CPU lcores: 48
EAL: Detected NUMA nodes: 1
EAL: Detected static linkage of DPDK
EAL: Selected IOVA mode 'VA'
EAL: No free 2048 kB hugepages reported on node 0
EAL: 16 hugepages of size 1073741824 reserved, but no mounted hugetlbfs found
for that size
Interactive-mode selected
Warning: NUMA should be configured manually by using --port-numa-config and
--ring-numa-config parameters along with --numa.
testpmd: Flow tunnel offload support might be limited or unavailable on port 0
testpmd: Flow tunnel offload support might be limited or unavailable on port 1
testpmd: create a new mbuf pool <mb_pool_0>: n=523456, size=2176, socket=0
testpmd: preferred mempool ops selected: ring_mp_mc
Configuring Port 0 (socket 0)
Port 0: XX:XX:XX:XX:XX:XX
Configuring Port 1 (socket 0)
Port 1: XX:XX:XX:XX:XX:XX
Checking link statuses...
Done
testpmd> flow create 0 ingress priority 0 group 1 pattern eth type spec 0x0800
type mask 0xffff / end actions send_to_kernel / end
Flow rule #0 created
testpmd> testpmd> quit
Stopping port 0...
Stopping ports...
Done
Stopping port 1...
Stopping ports...
Done
Shutting down port 0...
Closing ports...
Port 0 is closed
Done
Shutting down port 1...
Closing ports...
Port 1 is closed
Done
Bye...
=================================================================
==16057==ERROR: LeakSanitizer: detected memory leaks
Too many leaks! Only the first 5000 leaks encountered will be reported.
Indirect leak of 262184 byte(s) in 21 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f914350693e (/lib/x86_64-linux-gnu/libmlx5.so.1+0x2493e)
Indirect leak of 4184 byte(s) in 21 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f914350698e (/lib/x86_64-linux-gnu/libmlx5.so.1+0x2498e)
Indirect leak of 1792 byte(s) in 28 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f9143541fed (/lib/x86_64-linux-gnu/libmlx5.so.1+0x5ffed)
Indirect leak of 1536 byte(s) in 24 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f914350af81 (/lib/x86_64-linux-gnu/libmlx5.so.1+0x28f81)
Indirect leak of 672 byte(s) in 14 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f9143540ebf (/lib/x86_64-linux-gnu/libmlx5.so.1+0x5eebf)
Indirect leak of 560 byte(s) in 14 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f91435417a3 (/lib/x86_64-linux-gnu/libmlx5.so.1+0x5f7a3)
#2 0x7f9143523ab4 (/lib/x86_64-linux-gnu/libmlx5.so.1+0x41ab4)
Indirect leak of 560 byte(s) in 14 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f91435417a3 (/lib/x86_64-linux-gnu/libmlx5.so.1+0x5f7a3)
#2 0x7f9143523ade (/lib/x86_64-linux-gnu/libmlx5.so.1+0x41ade)
Indirect leak of 288 byte(s) in 4 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f9143524bae (/lib/x86_64-linux-gnu/libmlx5.so.1+0x42bae)
#2 0x7ffc1f4f9bbf ([stack]+0x1ebbf)
Indirect leak of 288 byte(s) in 4 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f9143524ea6 (/lib/x86_64-linux-gnu/libmlx5.so.1+0x42ea6)
Indirect leak of 256 byte(s) in 4 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f914350b6b7 (/lib/x86_64-linux-gnu/libmlx5.so.1+0x296b7)
Indirect leak of 192 byte(s) in 4 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f9143540ebf (/lib/x86_64-linux-gnu/libmlx5.so.1+0x5eebf)
#2 0xbffffffff (<unknown module>)
Indirect leak of 112 byte(s) in 14 object(s) allocated from:
#0 0x7f91436b7ffd in __interceptor_posix_memalign
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:145
#1 0x7f9143523a85 (/lib/x86_64-linux-gnu/libmlx5.so.1+0x41a85)
Indirect leak of 72 byte(s) in 1 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f9143524bae (/lib/x86_64-linux-gnu/libmlx5.so.1+0x42bae)
#2 0x607000006f4f (<unknown module>)
.... text removed for length
Indirect leak of 8 byte(s) in 1 object(s) allocated from:
#0 0x7f91436b83b7 in __interceptor_calloc
../../../../src/libsanitizer/asan/asan_malloc_linux.cpp:77
#1 0x7f914350f19e in mlx5dv_dr_domain_create
(/lib/x86_64-linux-gnu/libmlx5.so.1+0x2d19e)
SUMMARY: AddressSanitizer: 631608 byte(s) leaked in 5154 allocation(s).
--
You are receiving this mail because:
You are the assignee for the bug.
[-- Attachment #2: Type: text/html, Size: 8703 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-04-07 15:47 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-04-07 15:47 [DPDK/ethdev Bug 1694] mlx5: ASAN reports memory leaks with send_to_kernel bugzilla
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).