History log of /dpdk/lib/eal/x86/include/rte_memcpy.h (Results 1 – 9 of 9)
Revision Date Author Comments
# fba98755 10-Jan-2025 Andre Muezerie <andremue@linux.microsoft.com>

lib: replace packed attributes

MSVC struct packing is not compatible with GCC. Replace macro
__rte_packed with __rte_packed_begin to push existing pack value
and set packing to 1-byte and macro __rt

lib: replace packed attributes

MSVC struct packing is not compatible with GCC. Replace macro
__rte_packed with __rte_packed_begin to push existing pack value
and set packing to 1-byte and macro __rte_packed_end to restore
the pack value prior to the push.

Macro __rte_packed_end is deliberately utilized to trigger a
MSVC compiler warning if no existing packing has been pushed allowing
easy identification of locations where the __rte_packed_begin is
missing.

Signed-off-by: Andre Muezerie <andremue@linux.microsoft.com>

show more ...


# 830d7c98 09-Jul-2024 Morten Brørup <mb@smartsharesystems.com>

eal/x86: improve 16 bytes constant memcpy

When the rte_memcpy() size is 16, the same 16 bytes are copied twice.
In the case where the size is known to be 16 at build time, omit the
duplicate copy.

eal/x86: improve 16 bytes constant memcpy

When the rte_memcpy() size is 16, the same 16 bytes are copied twice.
In the case where the size is known to be 16 at build time, omit the
duplicate copy.

Reduced the amount of effectively copy-pasted code by using #ifdef
inside functions instead of outside functions.

Suggested-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@huawei.com>

show more ...


# 810c007e 31-Jan-2024 Tyler Retzlaff <roretzla@linux.microsoft.com>

eal/x86: remove GCC extension in AVX512 memcpy

Remove use of statement expression syntax in expansion of
MOVEUNALIGNED_LEFT47_IMM and MOVEUNALIGNED_LEFT47 macro expansions.

There appears to be no n

eal/x86: remove GCC extension in AVX512 memcpy

Remove use of statement expression syntax in expansion of
MOVEUNALIGNED_LEFT47_IMM and MOVEUNALIGNED_LEFT47 macro expansions.

There appears to be no need to use the statement expression compiler
extension a simple block should work.

Signed-off-by: Tyler Retzlaff <roretzla@linux.microsoft.com>

show more ...


# 2ef17be8 29-Mar-2023 Leyi Rong <leyi.rong@intel.com>

eal/x86: improve multiple of 64 bytes memcpy performance

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

eal/x86: improve multiple of 64 bytes memcpy performance

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@smartsharesystems.com>
Signed-off-by: Leyi Rong <leyi.rong@intel.com>
Reviewed-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Reviewed-by: David Marchand <david.marchand@redhat.com>

show more ...


# a9cfccbb 20-Aug-2022 Morten Brørup <mb@smartsharesystems.com>

eal/x86: add 256 bytes copy for AVX2

The rte_mov256 function was missing for AVX2.

Fixes: 9144d6bcdefd ("eal/x86: optimize memcpy for SSE and AVX")

Signed-off-by: Morten Brørup <mb@smartsharesyste

eal/x86: add 256 bytes copy for AVX2

The rte_mov256 function was missing for AVX2.

Fixes: 9144d6bcdefd ("eal/x86: optimize memcpy for SSE and AVX")

Signed-off-by: Morten Brørup <mb@smartsharesystems.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>

show more ...


# 11f61ea2 21-Jun-2022 David Marchand <david.marchand@redhat.com>

eal/x86: drop export of internal alignment macro

ALIGNMENT_MASK is only used internally.
Besides it lacks a DPDK-related prefix.
Hide it from external eyes.

Fixes: f5472703c0bd ("eal: optimize alig

eal/x86: drop export of internal alignment macro

ALIGNMENT_MASK is only used internally.
Besides it lacks a DPDK-related prefix.
Hide it from external eyes.

Fixes: f5472703c0bd ("eal: optimize aligned memcpy on x86")
Cc: stable@dpdk.org

Reported-by: Morten Brørup <mb@smartsharesystems.com>
Signed-off-by: David Marchand <david.marchand@redhat.com>

show more ...


# 00901e4d 25-Feb-2022 Luc Pelletier <lucp.at.work@gmail.com>

eal/x86: fix unaligned access for small memcpy

Calls to rte_memcpy for 1 < n < 16 could result in unaligned
loads/stores, which is undefined behaviour according to the C
standard, and strict aliasin

eal/x86: fix unaligned access for small memcpy

Calls to rte_memcpy for 1 < n < 16 could result in unaligned
loads/stores, which is undefined behaviour according to the C
standard, and strict aliasing violations.

The code was changed to use a packed structure that allows aliasing
(using the __may_alias__ attribute) to perform the load/store
operations. This results in code that has the same performance as the
original code and that is also C standards-compliant.

Fixes: af75078fece3 ("first public release")
Cc: stable@dpdk.org

Signed-off-by: Luc Pelletier <lucp.at.work@gmail.com>
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Tested-by: Konstantin Ananyev <konstantin.ananyev@intel.com>

show more ...


# 6de430b7 21-Oct-2021 Eli Britstein <elibr@nvidia.com>

eal/x86: avoid cast-align warning in memcpy functions

Functions and macros in x86 rte_memcpy.h may cause cast-align warnings,
when using strict cast align flag with supporting gcc:
gcc (Ubuntu 9.3.0

eal/x86: avoid cast-align warning in memcpy functions

Functions and macros in x86 rte_memcpy.h may cause cast-align warnings,
when using strict cast align flag with supporting gcc:
gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
CFLAGS="-Wcast-align=strict" make V=1 -C examples/l2fwd clean static

For example:
In file included from main.c:24:
/dpdk/build/include/rte_memcpy.h: In function 'rte_mov16':
/dpdk/build/include/rte_memcpy.h:306:25: warning: cast increases
required alignment of target type [-Wcast-align]
306 | xmm0 = _mm_loadu_si128((const __m128i *)src);
| ^

As the code assumes correct alignment, add first a (void *) or (const
void *) castings, to avoid the warnings.

Fixes: 9484092baad3 ("eal/x86: optimize memcpy for AVX512 platforms")
Cc: stable@dpdk.org

Signed-off-by: Eli Britstein <elibr@nvidia.com>

show more ...


# 99a2dd95 20-Apr-2021 Bruce Richardson <bruce.richardson@intel.com>

lib: remove librte_ prefix from directory names

There is no reason for the DPDK libraries to all have 'librte_' prefix on
the directory names. This prefix makes the directory names longer and also
m

lib: remove librte_ prefix from directory names

There is no reason for the DPDK libraries to all have 'librte_' prefix on
the directory names. This prefix makes the directory names longer and also
makes it awkward to add features referring to individual libraries in the
build - should the lib names be specified with or without the prefix.
Therefore, we can just remove the library prefix and use the library's
unique name as the directory name, i.e. 'eal' rather than 'librte_eal'

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>

show more ...