DPDK patches and discussions
 help / color / mirror / Atom feed
From: bugzilla@dpdk.org
To: dev@dpdk.org
Subject: [Bug 1071] Deadlock on memory allocation (rte_memzone_reserve_aligned)
Date: Fri, 26 Aug 2022 14:31:16 +0000	[thread overview]
Message-ID: <bug-1071-3@http.bugs.dpdk.org/> (raw)

https://bugs.dpdk.org/show_bug.cgi?id=1071

            Bug ID: 1071
           Summary: Deadlock on memory allocation
                    (rte_memzone_reserve_aligned)
           Product: DPDK
           Version: 21.11
          Hardware: x86
                OS: Linux
            Status: UNCONFIRMED
          Severity: major
          Priority: Normal
         Component: core
          Assignee: dev@dpdk.org
          Reporter: a.dibacco.ks@gmail.com
  Target Milestone: ---

Created attachment 218
  --> https://bugs.dpdk.org/attachment.cgi?id=218&action=edit
simple_mem_mp program

I launch the attached program on a 56c, 2 numa x86 machine:

The primary (named simple_mem_mp) does the following:

1) Starts a secondary (same image but named simple_mem_mp_sec)
2) Allocates a huge number (512) of 2M pages and release them
3) Starts a few eal threads that also allocate/release other 2M pages forever
4) Waits for the secondary to exit
5) Go to bullet 1


The secondary (same image as primary but named simple_mem_mp_sec):

1) Starts a few eal threads that allocate 100x2M pages and then exit
2) Wait for threads to finish and then exit

The secondary is alive for almost 4 secs before exiting.

After a few iterations a deadlock is experienced. The secondary seems to start
but cannot complete the rte_eal_init and I see that lslocks reports this (a
flock cannot get the lock on /dev/hugepages2M):

simple_mem_mp   171272 FLOCK      WRITE* 0     0          0 /dev/hugepages2M...
simple_mem_mp   171272 FLOCK      WRITE  0     0          0 /dev/hugepages2M...

Here is a log:

Starting core on secondary 14
Starting core on secondary 15
Starting core on secondary 7
Starting core on secondary 8
Starting core on secondary 9
Secondary started
Proc type 1 exiting


EAL: Detected CPU lcores: 56
EAL: Detected NUMA nodes: 2
EAL: Auto-detected process type: SECONDARY
EAL: Detected shared linkage of DPDK
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket_171319_224be24c4ae
EAL: Selected IOVA mode 'VA'
EAL: VFIO support initialized
Starting core on secondary 6
Starting core on secondary 7
Starting core on secondary 8
Starting core on secondary 9
Starting core on secondary 10
Starting core on secondary 11
Secondary started
Starting core on secondary 12
Starting core on secondary 14
Starting core on secondary 15
Starting core on secondary 13
Proc type 1 exiting

EAL: Detected CPU lcores: 56
EAL: Detected NUMA nodes: 2
EAL: Auto-detected process type: SECONDARY
EAL: Detected shared linkage of DPDK
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket_171333_22b0fbb7ab4
EAL: Selected IOVA mode 'VA'
EAL: VFIO support initialized

-- 
You are receiving this mail because:
You are the assignee for the bug.

             reply	other threads:[~2022-08-26 14:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-26 14:31 bugzilla [this message]
2022-09-15 10:15 ` bugzilla

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=bug-1071-3@http.bugs.dpdk.org/ \
    --to=bugzilla@dpdk.org \
    --cc=dev@dpdk.org \
    /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).