From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-it1-f182.google.com (mail-it1-f182.google.com [209.85.166.182]) by dpdk.org (Postfix) with ESMTP id 934EE201 for ; Wed, 14 Nov 2018 14:54:50 +0100 (CET) Received: by mail-it1-f182.google.com with SMTP id a205-v6so18369542itd.4 for ; Wed, 14 Nov 2018 05:54:50 -0800 (PST) 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=Q0G/LdrOv8pYJmoTBnCCj6N0ZQGSjnuowY9cBHSesYA=; b=gMv7rL7cCiqY3OinE4cOnHt5D7c5a+7Hwcc5Qsh9bseRWmRKuhKoz0Lx1iJ5FDvDgc I02pRwmVrzjNnFF1I1tDqaxe8MG1scqeL7qaJ0XXEQT85MXlDXozlmK5Or8Kp6T7Qk7e jrHtqyvdPR7iV0Hf2d2S7Fs0vwFbq8S27C4BpEOeZGAnMkHhOiOXssdFkbKbJAPO8c/K DCtOt7S8VkJTbrEt3UTHyggUSxuySAqfwmxjnRIo7Fv52ansKxwT1GvTvKz/b5Fu+xqE jndYpSvZhynXDr52Fm5hJT02uC8gq48+JZMbuLm4kGdnkif2ghZVXI5FJv9kk2Q5wUp+ LmnA== 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=Q0G/LdrOv8pYJmoTBnCCj6N0ZQGSjnuowY9cBHSesYA=; b=Z6qtPLsNOGqEURvLOjgDzq74t11m0X+hWlybOGo4HXk5GaZabefyg9MWHvn79qon4b 2rSohhScWE1IcyIHkP/hIWyM/fXwsC7+Rkbafz0f1UG5VEbgqHqQd+yQz3/tqBZ3ajRV vb5bQemeiW6wfuE0icMBg7eO/vRnyFSPS3pkaL14hbENSH+f5yRrGRp1wIn3v8xx96u+ u2DkrLeMmehS/TuzS6V7I4XVjS9SuZO4AJB0ykOufHEIRFwRr+pIjjP310YY+CQoanWt GzMyQyMvNHUrPM6Y0YvbPeDAxj+YmZ+DE3quTwJ/Nz9X10QOhIvOxwYbB4ECm6E1zBO8 h5KA== X-Gm-Message-State: AGRZ1gJ488WPZw40Fd0R/UY0hmjhfx2YziI6eup3AfxBIn9A0qU0oCo6 lpdiXviT/9wCpXrUTQuo+MnneDqRhRknrOj6bn9arg== X-Google-Smtp-Source: AJdET5dxWm2ndvhPOQ1Gcx2yA1Cu2ZmCOgHZMsjLLUQJ8fqRQvvD/6VqWf/HuwfBsZ9iPfYRtb+P/6DKGVUanJSTbBA= X-Received: by 2002:a24:1f0d:: with SMTP id d13mr1374664itd.140.1542203689833; Wed, 14 Nov 2018 05:54:49 -0800 (PST) MIME-Version: 1.0 References: <71CBA720-633D-4CFE-805C-606DAAEDD356@intel.com> <3C60E59D-36AD-4382-8CC3-89D4EEB0140D@intel.com> <76959924-D9DB-4C58-BB05-E33107AD98AC@intel.com> In-Reply-To: <76959924-D9DB-4C58-BB05-E33107AD98AC@intel.com> From: Harsh Patel Date: Wed, 14 Nov 2018 19:24:37 +0530 Message-ID: To: keith.wiles@intel.com Cc: users@dpdk.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-users] Query on handling packets X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Nov 2018 13:54:50 -0000 Hello, This is a link to the complete source code of our project :- https://github.com/ns-3-dpdk-integration/ns-3-dpdk For the description of the project, look through this :- https://ns-3-dpdk-integration.github.io/ Once you go through it, you will have a basic understanding of the project. Installation instructions link are provided in the github.io page. In the code we mentioned above, the master branch contains the implementation of the logic using rte_rings which we mentioned at the very beginning of the discussion. There is a branch named "newrxtx" which contains the implementation according to the logic you provided. We would like you to take a look at the code in newrxtx branch. ( https://github.com/ns-3-dpdk-integration/ns-3-dpdk/tree/newrxtx) In the code in this branch, go to ns-allinone-3.28.1/ns-3.28.1/src/fd-net-device/model/ directory. Here we have implemented the DpdkNetDevice model. This model contains the code which implements the whole model providing interaction between ns-3 and DPDK. We would like you take a look at our Read function ( https://github.com/ns-3-dpdk-integration/ns-3-dpdk/blob/newrxtx/ns-allinone-3.28.1/ns-3.28.1/src/fd-net-device/model/dpdk-net-device.cc#L626) and Write function ( https://github.com/ns-3-dpdk-integration/ns-3-dpdk/blob/newrxtx/ns-allinone-3.28.1/ns-3.28.1/src/fd-net-device/model/dpdk-net-device.cc#L576). These contains the logic you suggested. Can you go through this and suggest us some changes or find some mistake in our code? If you need any help or have any doubt, ping us. Thanks and Regards, Harsh & Hrishikesh On Tue, 13 Nov 2018 at 19:17, Wiles, Keith wrote: > > > > On Nov 12, 2018, at 8:25 PM, Harsh Patel > wrote: > > > > Hello, > > It would be really helpful if you can provide us a link (for both Tx and > Rx) to the project you mentioned earlier where you worked on a similar > problem, if possible. > > > > At this time I can not provide a link. I will try and see what I can do, > but do not hold your breath it could be awhile as we have to go thru a lot > of legal stuff. If you can try vtune tool from Intel for x86 systems if you > can get a copy for your platform as it can tell you a lot about the code > and where the performance issues are located. If you are not running Intel > x86 then my code may not work for you, I do not remember if you told me > which platform. > > > > Thanks and Regards, > > Harsh & Hrishikesh. > > > > On Mon, 12 Nov 2018 at 01:15, Harsh Patel > wrote: > > Thanks a lot for all the support. We are looking into our work as of now > and will contact you once we are done checking it completely from our side. > Thanks for the help. > > > > Regards, > > Harsh and Hrishikesh > > > > On Sat, 10 Nov 2018 at 11:47, Wiles, Keith > wrote: > > Please make sure to send your emails in plain text format. The Mac mail > program loves to use rich-text format is the original email use it and I > have told it not only send plain text :-( > > > > > On Nov 9, 2018, at 4:09 AM, Harsh Patel > wrote: > > > > > > We have implemented the logic for Tx/Rx as you suggested. We compared > the obtained throughput with another version of same application that uses > Linux raw sockets. > > > Unfortunately, the throughput we receive in our DPDK application is > less by a good margin. Is this any way we can optimize our implementation > or anything that we are missing? > > > > > > > The PoC code I was developing for DAPI I did not have any performance of > issues it run just as fast with my limited testing. I converted the l3fwd > code and I saw 10G 64byte wire rate as I remember using pktgen to generate > the traffic. > > > > Not sure why you would see a big performance drop, but I do not know > your application or code. > > > > > Thanks and regards > > > Harsh & Hrishikesh > > > > > > On Thu, 8 Nov 2018 at 23:14, Wiles, Keith > wrote: > > > > > > > > >> On Nov 8, 2018, at 4:58 PM, Harsh Patel > wrote: > > >> > > >> Thanks > > >> for your insight on the topic. Transmission is working with the > functions you mentioned. We tried to search for some similar functions for > handling incoming packets but could not find anything. Can you help us on > that as well? > > >> > > > > > > I do not know if a DPDK API set for RX side. But in the DAPI (DPDK > API) PoC I was working on and presented at the DPDK Summit last Sept. In > the PoC I did create a RX side version. The issues it has a bit of tangled > up in the DAPI PoC. > > > > > > The basic concept is a call to RX a single packet does a rx_burst of N > number of packets keeping then in a mbuf list. The code would spin waiting > for mbufs to arrive or return quickly if a flag was set. When it did find > RX mbufs it would just return the single mbuf and keep the list of mbufs > for later requests until the list is empty then do another rx_burst call. > > > > > > Sorry this is a really quick note on how it works. If you need more > details we can talk more later. > > >> > > >> Regards, > > >> Harsh > > >> and Hrishikesh. > > >> > > >> > > >> On Thu, 8 Nov 2018 at 14:26, Wiles, Keith > wrote: > > >> > > >> > > >> > On Nov 8, 2018, at 8:24 AM, Harsh Patel > wrote: > > >> > > > >> > Hi, > > >> > We are working on a project where we are trying to integrate DPDK > with > > >> > another software. We are able to obtain packets from the other > environment > > >> > to DPDK environment in one-by-one fashion. On the other hand DPDK > allows to > > >> > send/receive burst of data packets. We want to know if there is any > > >> > functionality in DPDK to achieve this conversion of single incoming > packet > > >> > to a burst of packets sent on NIC and similarly, conversion of > burst read > > >> > packets from NIC to send it to other environment sequentially? > > >> > > >> > > >> Search in the docs or lib/librte_ethdev directory on > rte_eth_tx_buffer_init, rte_eth_tx_buffer, ... > > >> > > >> > > >> > > >> > Thanks and regards > > >> > Harsh Patel, Hrishikesh Hiraskar > > >> > NITK Surathkal > > >> > > >> Regards, > > >> Keith > > >> > > > > > > Regards, > > > Keith > > > > > > > Regards, > > Keith > > > > Regards, > Keith > >