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 1469DA00C4; Thu, 29 Sep 2022 10:30:01 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 01ED340E5A; Thu, 29 Sep 2022 10:30:01 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id 0D95C40694 for ; Thu, 29 Sep 2022 10:29:58 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1664440198; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=CVFri3RBgF/1NBtb1lUuwTWGXZQQCE09tw43bWjgdcQ=; b=Y1V3kORFkvvqtlYSNkl1wUhiQwaMnHwGIuj8LJN2FHE01y1q3nLJxbj+vq/34Cqs8qiAm/ nX8AydJbPPPYPyMj5+E8OpUTqzYK9hwtvEyH/EAwz2n9Y3aVPp76aq79s6TOuDQxhGMtiY MYxDa0a0cYHRZWfhU5Qpx0L55U0QkM4= Received: from mail-pg1-f197.google.com (mail-pg1-f197.google.com [209.85.215.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-387-wn7Hw9MeOsCnINOcAvW3mg-1; Thu, 29 Sep 2022 04:29:57 -0400 X-MC-Unique: wn7Hw9MeOsCnINOcAvW3mg-1 Received: by mail-pg1-f197.google.com with SMTP id i22-20020a63e456000000b0043c096be700so637563pgk.1 for ; Thu, 29 Sep 2022 01:29:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=CVFri3RBgF/1NBtb1lUuwTWGXZQQCE09tw43bWjgdcQ=; b=aMoR0m/M2kDB1r3Abtc2hLugX7Vl1kA5YZi2wDEhyrRDRo1itUomln6/cWf0EDHcOI wlctF0m0fb7fp+NnLgaOFB0RsBQZ5+Al+pqWi99r8W3yYMShZ0Xd3FeeGQGasKWl+UPI 8Le4BbmnJPNh6ILe2h0MKZE9aAjTTCAbGebOj51rPa3dRf2r5UGHatsf1gKpIyqdvUd+ Wl8ZpwPlk8xjGYm8bwE1lK2YLHM3dfwjiTvwZ31vOOxjCXTsAilPunqoK6pHeTUdefHT uXCALDMG7AWuu1FoSpmxfpkBVYc8Kj41xSzwF7WK9xdFKb/79mvCnLaBnO0KW12lkANV BNfQ== X-Gm-Message-State: ACrzQf1La5ecmkqmYMOlD3bynYNZ2KhETxntNNzVO944q2nLjKCB8SWr LN2gMTN6LZWKGnHUxDdv3IgyJtPF3DYqKzUQIIcC7UygjnZUJx7HhB2IfvoZjGsLpMg/cYNUR9B ij0Ll0G55uy47d2xaFRQ= X-Received: by 2002:a17:903:2302:b0:178:286c:86a8 with SMTP id d2-20020a170903230200b00178286c86a8mr2279934plh.172.1664440196248; Thu, 29 Sep 2022 01:29:56 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4XoMl44MJ+B8hFkRzx9wGIZWWpMAArun0LiEkE4X1yiTYX0fPeD/rX0CCCYU8zSeaTBzAR2tICkWc1aGcVp9E= X-Received: by 2002:a17:903:2302:b0:178:286c:86a8 with SMTP id d2-20020a170903230200b00178286c86a8mr2279914plh.172.1664440195940; Thu, 29 Sep 2022 01:29:55 -0700 (PDT) MIME-Version: 1.0 References: <20220519063038.637836-1-amitprakashs@marvell.com> <20220525103352.1806937-1-amitprakashs@marvell.com> In-Reply-To: <20220525103352.1806937-1-amitprakashs@marvell.com> From: David Marchand Date: Thu, 29 Sep 2022 10:29:44 +0200 Message-ID: Subject: Re: [PATCH v4 1/2] mem: telemetry support for memseg and element information To: Amit Prakash Shukla , Anatoly Burakov , bruce.richardson@intel.com, Ciara Power , Dmitry Kozlyuk Cc: dev@dpdk.org, jerinj@marvell.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Added more people involved in the dpdk mem allocator, and telemetry. On Wed, May 25, 2022 at 12:34 PM Amit Prakash Shukla wrote: > > Changes adds telemetry support to display memory occupancy > in memseg and the information of the elements allocated from > a memseg based on arguments provided by user. This patch > adds following endpoints: > > 1. /eal/memseg_list_array > The command displays the memseg list from which the memory > has been allocated. > Example: > --> /eal/memseg_list_array > {"/eal/memseg_list_array": [0, 1]} > > 2. /eal/memseg_list_info, > The command outputs the memsegs, from which the memory is > allocated, for the memseg_list given as input. Command also > supports help. > Example: > --> /eal/memseg_list_info,help > {"/eal/memseg_list_info": "/eal/memseg_list_info,"} We already have something using the top level /help command. This proposed addition does not add much info. --> /help,/eal/memseg_list_info {"/help": {"/eal/memseg_list_info": "Returns memseg list. Parameters: int memseg_list_id"}} --> /eal/memseg_list_info,help {"/eal/memseg_list_info": "/eal/memseg_list_info,"} Please, remove it. I think this series is useful though I did not enter into detail. If nobody has objection, I will merge it once the above comment is handled. > > --> /eal/memseg_list_info,1 > {"/eal/memseg_list_info": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, \ > 12, 13, 14, 15]} > > 3. /eal/memseg_info,, > The command outputs the memseg information based on the > memseg-list and the memseg-id given as input. Command also > supports help. > Example: > --> /eal/memseg_info,help > {"/eal/memseg_info": "/eal/memseg_info,, \ > "} > > --> /eal/memseg_info,0,10 > {"/eal/memseg_info": {"Memseg_list_index": 0, \ > "Memseg_index": 10, "Memseg_list_len": 64, \ > "Start_addr": "0x260000000", "End_addr": "0x280000000", \ > "Size": 536870912}} > > --> /eal/memseg_info,1,15 > {"/eal/memseg_info": {"Memseg_list_index": 1, \ > "Memseg_index": 15, "Memseg_list_len": 64, \ > "Start_addr": "0xb20000000", "End_addr": "0xb40000000", \ > "Size": 536870912}} > > 4. /eal/element_list,,, > The command outputs number of elements in a memseg based > on the heap-id, memseg-list-id and memseg-id given as input. > Command also supports help. > Example: > --> /eal/element_list,help > {"/eal/element_list": "/eal/element_list,, \ > ,"} > > --> /eal/element_list,0,0,63 > {"/eal/element_list": {"Element_count": 52}} > > --> /eal/element_list,0,1,15 > {"/eal/element_list": {"Element_count": 52}} > > 5. /eal/element_info,,,, \ > , > The command outputs element information like element start > address, end address, to which memseg it belongs, element > state, element size. User can give a range of elements to be > printed. Command also supports help. > Example: > --> /eal/element_info,help > {"/eal/element_info": "/eal/element_info,, \ > ,,,"} > > --> /eal/element_info,0,1,15,1,2 > {"/eal/element_info": {"element.1": {"msl_id": 1, \ > "ms_id": 15, "memseg_start_addr": "0xb20000000", \ > "memseg_end_addr": "0xb40000000", \ > "element_start_addr": "0xb201fe680", \ > "element_end_addr": "0xb20bfe700", \ > "element_size": 10485888, "element_state": "Busy"}, \ > "element.2": {"msl_id": 1, "ms_id": 15, \ > "memseg_start_addr": "0xb20000000", \ > "memseg_end_addr": "0xb40000000", \ > "element_start_addr": "0xb20bfe700", \ > "element_end_addr": "0xb215fe780", "element_size": 10485888, \ > "element_state": "Busy"}, "Element_count": 2}} > > Signed-off-by: Amit Prakash Shukla -- David Marchand