From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2BCA5A0A0F for ; Wed, 30 Jun 2021 16:48:14 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id F325940141; Wed, 30 Jun 2021 16:48:13 +0200 (CEST) Received: from mail-qk1-f178.google.com (mail-qk1-f178.google.com [209.85.222.178]) by mails.dpdk.org (Postfix) with ESMTP id A8A8D40040 for ; Wed, 30 Jun 2021 16:48:12 +0200 (CEST) Received: by mail-qk1-f178.google.com with SMTP id b2so2649976qka.7 for ; Wed, 30 Jun 2021 07:48:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=bn6+Tun+L0pr+ra7ZbUxbVgLbCX+5i/znh9Hpv4tqr8=; b=SlAapFwsB8DC3RdcQO/NWY7scNV7cNxVtuRL+vuu66G0AZ3pFUgHzPsoD7fWXgULw+ d3+iZtT0EbsbCKTss5siWJyF7i/mgCCptJSniUb2hs67mgSiyyEVDhgWZejdjU2MJqKK m2+9RYQESUEHQsd9Lz2nUIGtSjaEhrzjJrcLMzo1xwvaqGc3U43nobioKrn42A2df8Bp xaRZcS4x62rXbxPf0bs9vk5kakUYgL2IAUSUggiaMvYXoN7M0S6WBqn5NWSSx+j3c+jU IUQyail/L55ADP2PfL+jLNzyGxQbqGjXqxXBw1xn1FDte3s34x5bwjvaZoX3B6Rc91Bn ObHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=bn6+Tun+L0pr+ra7ZbUxbVgLbCX+5i/znh9Hpv4tqr8=; b=duZE6fQaNPHuSYQytxPTPNmD8nP4A9xLsyOB41Gc1H668fCOigI7T2kzsw0/9g7dIX EJTEp0by/eaxIroLv1LhGopIxUMotPcphVapCWeFeHoRmXEZPTg2JFjQ6YseOa4bGRfi F1MCjG461L3PvsFOcCVYptmgh8OQsniK09YM8Hqg1tY4rIaHma8rl9p7zQFCDaL2n7bu 4P+vdscDyBWgJdDxmaDHz/ACSFvltus0GW6N9HOGOMQRu31naNbrAC1FVfU9CM1o++/Z pXwQ6ysymBVY2ok8igoSeEo1BzIHPY2HFIRnz6cDjLHzGY+xeLS7tLmTSPqLNw6yFUOV 0Vgg== X-Gm-Message-State: AOAM533vpMMfmY6l4TcZ9SvzmFqnRulNbOqk42nbIPAwMP4O+2ndH5vo H55t6vSWVhbpsWek9/r+fzuqaOw7WTLG5d+YXGRWpOEozLwVtg== X-Google-Smtp-Source: ABdhPJyQfal/AeBW2fOC6Lnjg0gqdkVn2YmGIAp9C+d5jdwZD3Fj/B75U7zo7HZBHzAlfJFlaz8OnijETgWkwCBssX4= X-Received: by 2002:a37:6888:: with SMTP id d130mr37722333qkc.265.1625064492134; Wed, 30 Jun 2021 07:48:12 -0700 (PDT) MIME-Version: 1.0 References: <26c96412-1f06-2ad5-6d0e-00a8125dc81e@filipjaniszewski.com> In-Reply-To: <26c96412-1f06-2ad5-6d0e-00a8125dc81e@filipjaniszewski.com> From: Muhammad Zain-ul-Abideen Date: Wed, 30 Jun 2021 19:48:01 +0500 Message-ID: To: Filip Janiszewski Cc: users Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: Re: [dpdk-users] rte_mempool_get returning null X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: users-bounces@dpdk.org Sender: "users" I am thinking you are also freeing the objects allocated after their use? On Wed, Jun 30, 2021, 6:51 PM Filip Janiszewski < contact@filipjaniszewski.com> wrote: > Hi, > > What would be the reason for rte_mempool_get returning null even if > rte_mempool_avail_count returns a big positive number? I know is > positive since I've added a print in my code to test that.. > > I've a strange issue where once I extract N items from the pool (where N > is the exact size of the pool) then the rte_mempool_get fails even if in > between the N extraction I've replenished the pool with rte_mempool_put > so that rte_mempool_avail_count is always positive. > > The pool is created like this: > > data_pool_ = rte_mempool_create( > fdo_str_name, > config_->chunk_count, > chunk_size, > 0, // cache_size > 0, // private_data_size > nullptr, // mp_init > nullptr, // mp_init_arg > nullptr, // obj_init > nullptr, // obj_init_arg > config_->host_socket_id, > 0 ); > > Producer and consumer are running on separate threads, but that should > not be the issue since the creation flag is 0 (Multi producer/Multi > consumer). So in my scenario is chunk_count is say 128, then after 128 > GET operations I get null even if I PUT back 128 items before this last > GET (and again, rte_mempool_avail_count is 128...) > > Is weird, since this is happening since I've upgraded to 21.02 from > 20.02.1, may I have messed up the compilation of the new DPDK? How can I > investigate this issue? > > Thanks > > -- > BR, Filip > +48 666 369 823 >