DPDK usage discussions
 help / color / mirror / Atom feed
* unable to run sample application with addressSanitizer
@ 2023-01-05  8:08 Balakrishnan K
  2023-01-05 17:06 ` Stephen Hemminger
  0 siblings, 1 reply; 4+ messages in thread
From: Balakrishnan K @ 2023-01-05  8:08 UTC (permalink / raw)
  To: users

[-- Attachment #1: Type: text/plain, Size: 3230 bytes --]

Hi All,
  I am trying to run dpdk helloworld example with ASAN tool to check the memory leak.
Following the below page as reference
https://doc.dpdk.org/guides/prog_guide/asan.html

after compiling the dpdk with options "meson setup -Dbuildtype=debug  -Db_sanitize=address -Dexamples=helloworld build"

program getting aborted can anyone help me on this why I am unable to use ASAN with helloworld sample.

Snipped of  the error :

./build/examples/dpdk-helloworld -l 0-3 -n 4
EAL: Detected 72 lcore(s)
EAL: Detected 2 NUMA nodes
EAL: WARNING! Base virtual address hint (0x100005000 != 0x7f2a56500000) not respected!
EAL:    This may cause issues with mapping memory into secondary processes
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket
=================================================================
==29612== ERROR: AddressSanitizer: global-buffer-overflow on address 0x000005837bd0 at pc 0xc39598 bp 0x7ffede705bc0 sp 0x7ffede705bb0
READ of size 2 at 0x000005837bd0 thread T0
    #0 0xc39597 (/home/balki/dev/dpdk-20.11/build/examples/dpdk-helloworld+0xc39597)
    #1 0xc3bbb3 (/home/balki/dev/dpdk-20.11/build/examples/dpdk-helloworld+0xc3bbb3)
    #2 0xad8832 (/home/balki/dev/dpdk-20.11/build/examples/dpdk-helloworld+0xad8832)
    #3 0xb2bdff (/home/balki/dev/dpdk-20.11/build/examples/dpdk-helloworld+0xb2bdff)
    #4 0x4083eb (/home/balki/dev/dpdk-20.11/build/examples/dpdk-helloworld+0x4083eb)
    #5 0x7f2a51aaa554 (/usr/lib64/libc-2.17.so+0x22554)
    #6 0x4082c8 (/home/balki/dev/dpdk-20.11/build/examples/dpdk-helloworld+0x4082c8)
0x000005837bd0 is located 48 bytes to the left of global variable 'otx2_ree_ops (../drivers/regex/octeontx2/otx2_regexdev.c)' (0x5837c00) of size 144
0x000005837bd0 is located 4 bytes to the right of global variable 'pci_id_ree_table (../drivers/regex/octeontx2/otx2_regexdev.c)' (0x5837bc0) of size 12
Shadow bytes around the buggy address:
  0x000080afef20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x000080afef30: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x000080afef40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x000080afef50: 00 00 00 00 00 00 00 00 00 f9 f9 f9 f9 f9 f9 f9
  0x000080afef60: 00 f9 f9 f9 f9 f9 f9 f9 00 00 00 00 00 00 00 00
=>0x000080afef70: 00 00 00 00 00 00 00 00 00 04[f9]f9 f9 f9 f9 f9
  0x000080afef80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x000080afef90: 00 00 f9 f9 f9 f9 f9 f9 00 00 00 00 00 00 00 00
  0x000080afefa0: 00 00 00 00 00 f9 f9 f9 f9 f9 f9 f9 00 00 00 00
  0x000080afefb0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
  0x000080afefc0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07
  Heap left redzone:     fa
  Heap righ redzone:     fb
  Freed Heap region:     fd
  Stack left redzone:    f1
  Stack mid redzone:     f2
  Stack right redzone:   f3
  Stack partial redzone: f4
  Stack after return:    f5
  Stack use after scope: f8
  Global redzone:        f9
  Global init order:     f6
  Poisoned by user:      f7
  ASan internal:         fe
==29612== ABORTING


Regards,
Bala


[-- Attachment #2: Type: text/html, Size: 9423 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread
* unable to run sample application with addressSanitizer
@ 2023-01-05  6:43 Balakrishnan K
  2023-01-05  8:06 ` Balakrishnan K
  0 siblings, 1 reply; 4+ messages in thread
From: Balakrishnan K @ 2023-01-05  6:43 UTC (permalink / raw)
  To: users

[-- Attachment #1: Type: text/html, Size: 3013 bytes --]

[-- Attachment #2: message_v3.rpmsg --]
[-- Type: application/x-microsoft-rpmsg-message, Size: 28616 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-01-05 17:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-05  8:08 unable to run sample application with addressSanitizer Balakrishnan K
2023-01-05 17:06 ` Stephen Hemminger
  -- strict thread matches above, loose matches on Subject: below --
2023-01-05  6:43 Balakrishnan K
2023-01-05  8:06 ` Balakrishnan K

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).