From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qk0-f174.google.com (mail-qk0-f174.google.com [209.85.220.174]) by dpdk.org (Postfix) with ESMTP id DDE1239EA for ; Thu, 16 Feb 2017 16:13:45 +0100 (CET) Received: by mail-qk0-f174.google.com with SMTP id p22so18203448qka.0 for ; Thu, 16 Feb 2017 07:13:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=schaman-hu.20150623.gappssmtp.com; s=20150623; h=mime-version:from:date:message-id:subject:to; bh=MAJpL/9cHMSJpzlqmoB7EefnXHOHRKMPWJUyMQ/8Mo8=; b=jGEFqbvr0nv9tAHaAzCevDq5QzXx36vMR3W5RXe3Dwh4EJG595PT7Z8aEElo77IVgF CutI9KX7cMWi3k3WfwHckrJ0zMUUP15yx+HAI4k/6yop/+/RgNFL1B5FCLvkKKYFmwRH Xc6e39pzavWrzl8DLHnPeisrT1IO4lcv5obt0bK79qjsgVFnWugfR++uwEoMeCkEjn4g 8oHUlZFERpgu90QZtXQqkhx1r1tT5qaiIqz1Z/BUEOrFaqOjG6ZRd9tihrr8GriCHJYD fgqeVusKSb8tFsoTbZCGPAdrHyRPtuNDNY4PIKqkSQUl+q1rpkvlsyZ+/CNHdxFY2AMD SY1g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=MAJpL/9cHMSJpzlqmoB7EefnXHOHRKMPWJUyMQ/8Mo8=; b=BFDaoePavRrbzcMm+e91YDWgF9ZvI/CN4Ug2/bJuLAt2dpP83ZbnQC3IhXVibKBTop G1UIqXxPCcPDEEOi0IY4GxxNCd2hxwNKw4nRViqEt6LwDPyF7vlRVhaD7qcyLgH2NGpa 6YHGGRYPFEnaGRBhzzPzTJMgtMuvZXfKhje9QtniVLTiMhm5rZmH+9MlygM6yzZDVKxq W/SXsJp5hGL3N58Re8mZOyhhN1xz1NP7rNftrLAAx0NRIqifPW4uq0p+fH6/3Xj8Jt7O 02IhFEvxhNc6XZ6tqPYTZB8w4u6BflOxZGCmi0w0ATAErMphd8Dk+R/8qaG+Yihfnh7G FasQ== X-Gm-Message-State: AMke39nueZ8h+zZcS2epqG9FdnQtqnt1JWvjfrWW3VxrCRZkmPVEekrSf37wSvQ8kNLKNpcvBvqJwQbhIklyhw== X-Received: by 10.55.75.143 with SMTP id y137mr2363636qka.39.1487258025016; Thu, 16 Feb 2017 07:13:45 -0800 (PST) MIME-Version: 1.0 Received: by 10.237.37.225 with HTTP; Thu, 16 Feb 2017 07:13:44 -0800 (PST) X-Originating-IP: [91.82.100.59] Received: by 10.237.37.225 with HTTP; Thu, 16 Feb 2017 07:13:44 -0800 (PST) From: Zoltan Kiss Date: Thu, 16 Feb 2017 16:13:44 +0100 Message-ID: To: dev@dpdk.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: [dpdk-dev] rte_sched library performance question 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: , X-List-Received-Date: Thu, 16 Feb 2017 15:13:46 -0000 Hi, I'm experimenting a little bit with the scheduler library, and I got some performance numbers which seems to be worse than what I've expected. I'm sending 64 bytes packets on a 10G interface to a separate thread, and my simple test program (based on the qos_sched example) does the following: while (1) { uint16_t ret = rte_ring_sc_dequeue_burst(it.ring, (void**)flushbatch, FLUSH_SIZE); rte_mbuf** t = flushbatch; if (!ret) { /* This call is necessary to make sure the TX completed mbuf's * are returned to the pool even if there is nothing to * transmit */ rte_eth_tx_burst(it.portid, lcore, t, 0); continue; } rte_sched_port_enqueue(it.port, flushbatch, ret); ret = rte_sched_port_dequeue(it.port, flushbatch, FLUSH_SIZE); while (ret) { uint16_t n = rte_eth_tx_burst(it.portid, lcore, t, ret); /* we cannot drop the packets, so re-send */ /* update number of packets to be sent */ ret -= n; t = &t[n]; }; } I run this on a separate thread, another one doing rx and feeding the packets to the ring. When I comment out the enqueue and dequeue part in the code (reducing it to simple l2fwd), I can forward the entire ~14 Mpps traffic, whilst with the scheduler enabled I can only reach ~5.4 Mpps at best. I've tried with a single pipe or with 4k (used rand() to randomly distribute between pipe, everything else (class etc) was set to 0), didn't make a difference. Is this expected? I'm running this on a Xeon E5-2630 0 @ 2.30GHz I've used the following configuration: ; port configuration [port] [port] frame overhead = 24 number of subports per port = 1 number of pipes per subport = 1024 queue sizes = 64 64 64 64 ; Subport configuration [subport 0] tb rate = 1250000000; Bytes per second tb size = 1000000000; Bytes tc 0 rate = 1250000000; Bytes per second tc 1 rate = 1250000000; Bytes per second tc 2 rate = 1250000000; Bytes per second tc 3 rate = 1250000000; Bytes per second tc period = 10; Milliseconds tc oversubscription period = 1000; Milliseconds pipe 0-1024 = 0; These pipes are configured with pipe profile 0 ; Pipe configuration [pipe profile 0] tb rate = 1250000000; Bytes per second tb size = 1000000000; Bytes tc 0 rate = 1250000000; Bytes per second tc 1 rate = 1250000000; Bytes per second tc 2 rate = 1250000000; Bytes per second tc 3 rate = 1250000000; Bytes per second tc period = 10; Milliseconds tc 0 oversubscription weight = 1 tc 1 oversubscription weight = 1 tc 2 oversubscription weight = 1 tc 3 oversubscription weight = 1 tc 0 wrr weights = 1 1 1 1 tc 1 wrr weights = 1 1 1 1 tc 2 wrr weights = 1 1 1 1 tc 3 wrr weights = 1 1 1 1 Regards, Zoltan