From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0065.outbound.protection.outlook.com [104.47.38.65]) by dpdk.org (Postfix) with ESMTP id D35503978 for ; Thu, 14 Jul 2016 19:27:53 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=harmonic.onmicrosoft.com; s=selector1-harmonicinc-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=KMOT3yw6QXnsvUSbtKbQcPbbKCwR6eiaXSRd9uRgT7M=; b=iKwBi7MTmhLPytTpUOrul9DdX0YOB0kZk/80bIyhp4pyzuhVObfshH5WhnJU2nBcLIxUkn0AsxStfWuo4mhoYh9FI/75m+Vu04msC0inAo1dlmImzV2uZdE/nYv6+sd+U0eMEZh+Q2k4wHbcPL3e9Y/Q1zTv4FyDDg6USolt1P8= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Vladyslav.Buslov@harmonicinc.com; Received: from kms.harmonicinc.com (95.67.66.62) by MWHPR11MB1360.namprd11.prod.outlook.com (10.169.235.22) with Microsoft SMTP Server (TLS) id 15.1.528.16; Thu, 14 Jul 2016 17:27:50 +0000 From: Vladyslav Buslov To: , CC: Date: Thu, 14 Jul 2016 20:27:18 +0300 Message-ID: <20160714172719.17502-1-vladyslav.buslov@harmonicinc.com> X-Mailer: git-send-email 2.8.3 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [95.67.66.62] X-ClientProxiedBy: CY1PR1101CA0041.namprd11.prod.outlook.com (10.169.17.51) To MWHPR11MB1360.namprd11.prod.outlook.com (10.169.235.22) X-MS-Office365-Filtering-Correlation-Id: 98cd61a9-96c4-4abc-8322-08d3ac0c2f16 X-Microsoft-Exchange-Diagnostics: 1; MWHPR11MB1360; 2:pzzPyulqzdXTtsw9luYX3aSlcbJM9c4JQJeURqqTQo+rUbV0X5TVHZhSWE683h7hk0d2egNc0BJ9OSdvzGcppRQOAeSAiEB9a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0OR8HzKv7gwyn+UP8zOyQ8JrCuqwMf6y1FRfrZUDkArbt6PRuJFETsO+KoW7EAPMqzq+ibw== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004)(2401047)(5005006)(8121501046)(10201501046)(3002001)(6055026); SRVR:MWHPR11MB1360; BCL:0; PCL:0; RULEID:; SRVR:MWHPR11MB1360; X-Forefront-PRVS: 00032065B2 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(7916002)(189002)(199003)(2906002)(97736004)(5001770100001)(6116002)(77096005)(4326007)(53416004)(3846002)(105586002)(33646002)(42186005)(189998001)(586003)(106356001)(229853001)(1076002)(68736007)(101416001)(81156014)(305945005)(48376002)(86362001)(7846002)(7736002)(50226002)(8676002)(47776003)(66066001)(50986999)(36756003)(5003940100001)(69596002)(50466002)(92566002)(81166006); DIR:OUT; SFP:1101; SCL:1; SRVR:MWHPR11MB1360; H:kms.harmonicinc.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: harmonicinc.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR11MB1360; 23:Tc8qKIKQtxnSJx7m6meyYO8OJSIJBcz8B8TRHRYkb?= =?us-ascii?Q?RKmT0qn7m7IcdEh7ypNxxl59t7A9BaeqMwOuZ3Jwp0CQhoUzCQffGpWiWg0Y?= =?us-ascii?Q?1ZU/d2bSv38lV/dLs21NKhdH9ZgPSn8KZiHXEGq0VLZBaTaU5/0ZwsjpIyrp?= =?us-ascii?Q?kS6RSHEVvng/t73YNfLcx7H/K6BGbQ4PBMHsHy2eHHXZvcBxWlbnYMIoc1V1?= =?us-ascii?Q?rkP43cSYgBv6efMnMiiGn1p9z3mStfmthpn9eJxqfcgC5xt2iGTtFfkacF6B?= =?us-ascii?Q?NCDbmO0gQG3VPP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dI4+HPcdwRNfHY7tyyRqYSZhqWIahgAz71neJgkMb5fPini5FHowWf+GHniw400nqXCMsB9GLaBSAfutMIUUKcZzlq8FheQIZkfje0MnlxlOoepqCYKa/nmm+OI7o9ssAVJvUnyixf6iWT65lbhmzTAqrSnGBaAGQV9M0m45lSRAaJZqIboDdWxNAlmtuyhZgYI5xMeg==; 5:A1kJIWv8IR8FVajdtSCoSAYsadqoLT0zN1f/pH4DLVv6LV5rsF6P4pu72f5hSS2SVtfm0ICNk71Cqvn4T5TDWoQ7VahRqJ6NVJ3rwGiE6H0tyuYmPyytkZfdJIxK+3eXFNJzIELHzr+SjD4rKLl9xg==; 24:wGUyrdwLRFCJbpcxrDFrVOtyz1M7AtdRfSgHGv1WMNfBWqRGW5gJPYYlieXIJV4X8+CU77ldEetD+QWQVg8RwNfVEQqKbr9B547V2Nv7YBs=; 7:bFoAjVkBXE9OmuePcSZvYJgUi9K2kzLgdyLN1/mjE7246/Ibdo+/7oBJAbnbFWi/FApSp/qFY9ydJsbsro+RhqWxZvy7iQ6krOkMs647WrCT6tlYrbBxyZbtIdsFV9Ud6Ekdv4kwFaCKm9XzZ2ebnc84mWcPPFtb0XN6D53vNirfCN4sfFTX5z/C02gh98AOpYdzxT0sXBIVTEMFehvPWfHbfoP5YfpLTYOxvRzFtc7Ofm/0nnhoxffkzI2Y+GKg SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; MWHPR11MB1360; 20:l8m5wpKuB6Cqmj2MU9/fzpNv7RZYGuxOqifZrWRYTi9rkbntKPf2/a+41qFJ8tjCNMsdk5UEFcopIrmZvBIPkroB9UeT4phXi/h9uff75s/yepkpEXpul/UtfHY1kav5CbA5mAsqSnrpQPGWw83+iwGvOy5UXim3Z+4t+CQ5CT4= X-OriginatorOrg: harmonicinc.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Jul 2016 17:27:50.9573 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR11MB1360 Subject: [dpdk-dev] [PATCH] Add missing prefetches to i40e bulk rx path X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Jul 2016 17:27:54 -0000 Hello, Recently I tried to use bulk rx function to reduce CPU usage of rte_eth_rx_burst. However application performance with i40e_recv_pkts_bulk_alloc was significantly worse than with i40e_recv_pkts. (3m less PPS, 0.5 IPC on receiving core) Quick investigation revealed two problems: - First payload cacheline is prefetched in i40e_recv_pkts but not in i40e_recv_pkts_bulk_alloc. - Only first line of next mbuf is prefetched during mbuf init in i40e_rx_alloc_bufs. This causes cache miss at setting 'next' field from mbuf cacheline1 to NULL. Fixing these two small issues significantly reduced CPU time spent in rte_eth_rx_burst and improved PPS compared to both original i40e_recv_pkts_bulk_alloc and i40e_recv_pkts. Regards, Vladyslav Buslov (1): net/i40e: add additional prefetch instructions for bulk rx drivers/net/i40e/i40e_rxtx.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) -- 2.8.3