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 DA7CD4249E; Fri, 27 Jan 2023 11:28:38 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 79C8140150; Fri, 27 Jan 2023 11:28:38 +0100 (CET) Received: from mail-vk1-f174.google.com (mail-vk1-f174.google.com [209.85.221.174]) by mails.dpdk.org (Postfix) with ESMTP id AC8D540146 for ; Fri, 27 Jan 2023 11:28:36 +0100 (CET) Received: by mail-vk1-f174.google.com with SMTP id v5so2170128vkc.10 for ; Fri, 27 Jan 2023 02:28:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=SEVGxvuqJWb7xP/hFOinKFpg4y4CT4VKKaAzpdMkMHI=; b=NYMU+rLzi+2tyz+ZQfkFpNsYN9iZHIIT/BU7XwhYLIZAi4TGjKa0eRfNAVu3ms5HOT 9j8Bruc2OLcVSCRKCP4Xjgmz9elLcYvVdM9QUEEb/DCGoeUDCqkybLK+Va3v2V2qaHni am8q67/0TiP0z6qPz+BvyHQ1xeWA2cPJ9p2Cmr5XAxi6W57iD4gsYquq6vX/ehMdh4gn HCsoMbPABW8MgdR3zSeg05mcFBsPD79LTS+3/VML3IVjldvrrFYqZhvaz89oM+Xz79Wv ZGpGBBdFI+2KO2xutHngLCxYMCgqjEYd8dt9UVhPsd/MoKhbA0RY3YtQW/LDVrv2WZ0m q8bQ== 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:message-id :reply-to; bh=SEVGxvuqJWb7xP/hFOinKFpg4y4CT4VKKaAzpdMkMHI=; b=ChZis+hbrOJMB8oEb1vysoGxuxOcXWbLH4ORe/Ms1l5O9Dz2VG0mzu6+YzwZJnL0PQ ysugVbE/l0KUTG28WF35l5VWwe8LtLtI2UZtnEqW3Y33xqtoDp0DlMaEtMSCwZX8SCVp U8mymSdp3+69I6JBPWmCa+10tvdRw3QB9Q9ppt5NDmJYTApOLmS6W8j8wg10plGd+Ps6 iA8IIMfhUZ+wkf9udGBCC/6sQJKBdCNZ5xg7xyVDB9fj5PGgv9dL8nuSZ4BnGqSM6lMn xbPx21zKVxSF9NtCvZjvu53HsDnjjVcQ1vwKIIqwtyqC1FnTbjcyWr/Vd8mLoHrcuZcA 5Jdw== X-Gm-Message-State: AFqh2kpKQhr3FbEXnXZPVyoyv91K/gFBbccmvzhvwzTl+80C65CZ9VMq 9+gTq58kz2FJgZZsWPKa9A3op8yHAQBn9rUmkdo= X-Google-Smtp-Source: AMrXdXtd1Y6Tc1JOHepvCYmanzGPF4+3mk7ax4ndahozeY7eVsgLea8p3GiDR/SG9HgxYFc/nbWFVsjHKgIkO15jkIg= X-Received: by 2002:a05:6122:91d:b0:3e1:a746:2b9e with SMTP id j29-20020a056122091d00b003e1a7462b9emr4687194vka.5.1674815315840; Fri, 27 Jan 2023 02:28:35 -0800 (PST) MIME-Version: 1.0 References: <20221212172108.17993-1-syalavarthi@marvell.com> <2166662.Bm8zEkEi59@thomas> <2113604.MHSsGVy7CF@thomas> In-Reply-To: <2113604.MHSsGVy7CF@thomas> From: Jerin Jacob Date: Fri, 27 Jan 2023 15:58:09 +0530 Message-ID: Subject: Re: [EXT] Re: [PATCH v3 0/4] implementation of ML common code To: Thomas Monjalon Cc: Shivah Shankar Shankar Narayan Rao , Srikanth Yalavarthi , "dev@dpdk.org" , Jerin Jacob Kollanukkaran , Anup Prabhu , "ferruh.yigit@amd.com" , "bruce.richardson@intel.com" , "david.marchand@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 On Fri, Jan 27, 2023 at 2:56 PM Thomas Monjalon wrote: > > 27/01/2023 10:02, Jerin Jacob: > > On Fri, Jan 27, 2023 at 2:20 PM Thomas Monjalon wrote: > > > 27/01/2023 07:40, Jerin Jacob: > > > > On Thu, Jan 26, 2023 at 4:27 PM Thomas Monjalon wrote: > > > > > 25/01/2023 15:59, Srikanth Yalavarthi: > > > > > > From: Thomas Monjalon > > > > > > > 25/01/2023 14:25, Srikanth Yalavarthi: > > > > > > > > From: Thomas Monjalon > > > > > > > > > 20/12/2022 18:52, Srikanth Yalavarthi: > > > > > > > > > > This patch series implements the common ML code that can be used > > > > > > > > > > by ML drivers. Common code include functions to convert ML IO type > > > > > > > > > > to string, IO format type to string, function get size of ML IO > > > > > > > > > > type, and functions for converting data types from higher > > > > > > > > > > precision to lower precision and vice-versa. > > > > > > > > > > > > > > > > > > I'm not sure about the path of this code. > > > > > > > > > In general we implement drivers helper in the same directory as the > > > > > > > > > driver and mark it as internal. > > > > > > > > > Would it work here? > > > > > > > > > > > > > > > > We are planning to implement two different ML drivers, ml/cnxk driver > > > > > > > (submitted for review) and a software only driver (part of ML roadmap and > > > > > > > currently WIP). Both the drivers would be using these common functions for > > > > > > > quantization and dequantization. Hence, placed the files in common/ml > > > > > > > directory. > > > > > > > > > > > > > > > > Moreover, these functions are used to convert data from higher to lower > > > > > > > precision or vice-versa and can also be used by future ML drivers for other > > > > > > > platforms. > > > > > > > > > > > > > > I understand, and what you say does not contradict with having this code in > > > > > > > lib/mldev/. > > > > > > > So would you agree to move? > > > > > > > > > > > > These common functions do not have an rte_ml_dev_ prefix. > > > > > > > > > > As it is exported, it should have rte_ prefix. > > > > > > > > The exposed functions are similar to lib/ethdev/sff_* where multiple > > > > driver can "use" it > > > > but not by application directly. > > > > If so, What is the recommendation > > > > a) Keeping driver/common/ml without rte_prefix > > > > b) Keeping in lib/mldev/ with rte_mldev_pmd_ prefix? > > > > > > > > I prefer (a) as it will not pollute lib/mldev. No strong opinion, > > > > either. Let me know your view or any other suggestion? > > > > > > I don't see it as pollution, it comes with the library, > > > so I prefer lib/mldev/ with rte_mldev_pmd_ prefix. > > > > > > > > > > > Is it ok to have non-RTE code in lib/mldev. If yes, we can move to lib/mldev. > > > > > > > > > > Look at lib/ethdev/ethdev_driver.h, it should be similar. > > > > > > > > Here scope is different. See above. > > > > > > No the scope is not different. > > > They are functions used by drivers not by application. > > > > When you say lib/ethdev/ethdev_driver.h. You mean "struct eth_dev_ops" scheme. > > No I don't mean that. Did you check the internal functions in this file? > I mean functions like rte_eth_dev_allocate() or rte_eth_dev_attach_secondary(). Got it. Let's change to rte_ml_pmd_ prefix and add to lib/mldev then. > > >