patch 'eal/x86: improve multiple of 64 bytes memcpy performance' has been queued to stable release 20.11.9

luca.boccassi at gmail.com luca.boccassi at gmail.com
Thu Jun 15 03:32:08 CEST 2023


Hi,

FYI, your patch has been queued to stable release 20.11.9

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 06/17/23. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Queued patches are on a temporary branch at:
https://github.com/bluca/dpdk-stable

This queued commit can be viewed at:
https://github.com/bluca/dpdk-stable/commit/4154fc959d05dfc4462d9c074432d8ba12525796

Thanks.

Luca Boccassi

---
>From 4154fc959d05dfc4462d9c074432d8ba12525796 Mon Sep 17 00:00:00 2001
From: Leyi Rong <leyi.rong at intel.com>
Date: Wed, 29 Mar 2023 17:16:58 +0800
Subject: [PATCH] eal/x86: improve multiple of 64 bytes memcpy performance
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[ upstream commit 2ef17be88e8b26f871cfb0265227341e36f486ea ]

In rte_memcpy_aligned(), one redundant round is taken in the 64 bytes
block copy loops if the size is a multiple of 64. So, let the catch-up
copy the last 64 bytes in this case.

Fixes: f5472703c0bd ("eal: optimize aligned memcpy on x86")

Suggested-by: Morten Brørup <mb at smartsharesystems.com>
Signed-off-by: Leyi Rong <leyi.rong at intel.com>
Reviewed-by: Morten Brørup <mb at smartsharesystems.com>
Acked-by: Bruce Richardson <bruce.richardson at intel.com>
Reviewed-by: David Marchand <david.marchand at redhat.com>
---
 lib/librte_eal/x86/include/rte_memcpy.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_eal/x86/include/rte_memcpy.h b/lib/librte_eal/x86/include/rte_memcpy.h
index d4d7a5cfc8..fd151be708 100644
--- a/lib/librte_eal/x86/include/rte_memcpy.h
+++ b/lib/librte_eal/x86/include/rte_memcpy.h
@@ -846,7 +846,7 @@ rte_memcpy_aligned(void *dst, const void *src, size_t n)
 	}
 
 	/* Copy 64 bytes blocks */
-	for (; n >= 64; n -= 64) {
+	for (; n > 64; n -= 64) {
 		rte_mov64((uint8_t *)dst, (const uint8_t *)src);
 		dst = (uint8_t *)dst + 64;
 		src = (const uint8_t *)src + 64;
-- 
2.39.2

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2023-06-15 01:56:35.431586894 +0100
+++ 0013-eal-x86-improve-multiple-of-64-bytes-memcpy-performa.patch	2023-06-15 01:56:34.519540255 +0100
@@ -1 +1 @@
-From 2ef17be88e8b26f871cfb0265227341e36f486ea Mon Sep 17 00:00:00 2001
+From 4154fc959d05dfc4462d9c074432d8ba12525796 Mon Sep 17 00:00:00 2001
@@ -8,0 +9,2 @@
+[ upstream commit 2ef17be88e8b26f871cfb0265227341e36f486ea ]
+
@@ -21 +23 @@
- lib/eal/x86/include/rte_memcpy.h | 2 +-
+ lib/librte_eal/x86/include/rte_memcpy.h | 2 +-
@@ -24 +26 @@
-diff --git a/lib/eal/x86/include/rte_memcpy.h b/lib/eal/x86/include/rte_memcpy.h
+diff --git a/lib/librte_eal/x86/include/rte_memcpy.h b/lib/librte_eal/x86/include/rte_memcpy.h
@@ -26,2 +28,2 @@
---- a/lib/eal/x86/include/rte_memcpy.h
-+++ b/lib/eal/x86/include/rte_memcpy.h
+--- a/lib/librte_eal/x86/include/rte_memcpy.h
++++ b/lib/librte_eal/x86/include/rte_memcpy.h


More information about the stable mailing list