From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id B1706A0AC5 for ; Fri, 3 May 2019 21:03:24 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 3D270293B; Fri, 3 May 2019 21:03:24 +0200 (CEST) Received: from mail-pl1-f169.google.com (mail-pl1-f169.google.com [209.85.214.169]) by dpdk.org (Postfix) with ESMTP id E13012C17 for ; Fri, 3 May 2019 21:03:22 +0200 (CEST) Received: by mail-pl1-f169.google.com with SMTP id y3so3126386plp.0 for ; Fri, 03 May 2019 12:03:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=8hc8nRfPSoSc3P8QdYXXeIku+I52BJ39c3jBz+Qr774=; b=OXtgOcWfkBWgH1B6ZkMBvbfBbST2EUAUiyhaWKj6vBMi8eXsSZYegbIH2iUxSOrsPg tQPztC3C4G9D+j7FNdVhcoHoGN3omU8cEKeCZc2yIcOBiZv73FzLfgs5kSKb18V2GGy3 5Mn2QH1k8GYrsrqMjy7kGmTJaYJIOMEbEOalax5ow25tS9wJqqykUWjeZboAc9t6+hE5 dRQ3Z9O7RDgv8x1x5VA0YMLRd66heL+B1kRVNiPVz1hfymY/dTBJv2jImfqKrMy+El55 ER5hMAhSHUC+7wc1edGffc01hLhinQIsUzDMuqqMutiU/lBYcgXWvRfL5Yzm2uIPJeED 9S9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=8hc8nRfPSoSc3P8QdYXXeIku+I52BJ39c3jBz+Qr774=; b=IfWqLybAYbjOKtbvlwYIfOXmINkrQ6dGuvywMD0VTd6lTqoqmVisEPO+r/GzFS9lwt LHlF7qU3DpLiKxux1ApnQBHZBy5/83nYoMzMV5V63X3CL8ujqDGPzentlK1R0NG/jtfm upPri3SFb80jPfTjkwY7N1ogxDxXlxR/qgGcG2zITvCnzuQwRcFrExNXSe491WYlBQ5E 8FZI6EWamvqzkfw3bn+9/HYlsycWdpOo86B25stKJXBFiYeNNBYyV5VAaMSd8XJMoEDl Fj9GdKKDf1mmasKJiOQGah02A7TFwcgos32gLY28Tgmlq0r3I0dLM4mtgmkIjFW9l5X6 noSw== X-Gm-Message-State: APjAAAXvCr3txnUIX9oEjIs8DiuE/E5WpNDFBhYAhlov173ABIwz3VJv m/qOMCYwZ4sOPbP4JF89f2X1Zw== X-Google-Smtp-Source: APXvYqyc9gaMkhMI98crmkLrz5KuGucOw5ENMjdVJRZI6vv/2/bTqT6ihna2wBGUEYZCcFBDprrL8A== X-Received: by 2002:a17:902:684b:: with SMTP id f11mr4775799pln.96.1556910202049; Fri, 03 May 2019 12:03:22 -0700 (PDT) Received: from hermes.lan (204-195-22-127.wavecable.com. [204.195.22.127]) by smtp.gmail.com with ESMTPSA id y68sm4104554pfy.28.2019.05.03.12.03.21 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 03 May 2019 12:03:21 -0700 (PDT) Date: Fri, 3 May 2019 12:03:14 -0700 From: Stephen Hemminger To: "Burakov, Anatoly" Cc: P Smith , "dev@dpdk.org" Message-ID: <20190503120314.146732cd@hermes.lan> In-Reply-To: References: <899934402.3791304.1556876242992.ref@mail.yahoo.com> <899934402.3791304.1556876242992@mail.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Subject: Re: [dpdk-dev] Memory footprint of a PMD X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Message-ID: <20190503190314.5QT5aIyVLY7DNi6bmzJnWoqCvZNdVbnW12Or_zBKERs@z> On Fri, 3 May 2019 11:02:15 +0100 "Burakov, Anatoly" wrote: > On 03-May-19 10:37 AM, P Smith wrote: > > Hi,=C2=A0=C2=A0=C2=A0=C2=A0 Given that a dpdk driver uses rte_malloc_xx= () and friends to allocate/free its memory what is the best way to find out= the runtime memory footprint of a PMD ? One can use 'malloc_info' to dump = the malloc output in case of general 'malloc' ...but what is the way here s= ince it's all hugepages ? How to know the memory /footprint of my testpmd /= application at different points during run-time?Is there a tool or some API= i can invoke to find out the same? > > Thanks=C2=A0P > > =20 >=20 > I don't think there is a way to do this currently, other than tracing=20 > all PMD's allocations. >=20 > That said, there is an API to find total usage of DPDK memory - look int= =20 > rte_malloc_heap_stats related API's. >=20 rte_malloc and friends allocate from memory pool in huge pages, not the nor= mal malloc heap. The mempool does have compile option for debug which does keep= statistics. Then rte_mempool_dump (or rte_mempool_walk and rte_mempool_dump) can be use= d to show info.