Hi, All the code is using ARM64, but the title suggests AArch64. What is the difference between AArch64 and ARM64 (and ARMv8)?
04/01/2018 11:20, Herbert Guan: > +/************************************** > + * Beginning of customization section > + **************************************/ > +#define RTE_ARM64_MEMCPY_ALIGN_MASK 0x0F > +#ifndef RTE_ARCH_ARM64_MEMCPY_STRICT_ALIGN > +/* Only src unalignment will be treaed as unaligned copy */ typo: treaed > +#define RTE_ARM64_MEMCPY_IS_UNALIGNED_COPY(dst, src) \ > + ((uintptr_t)(dst) & RTE_ARM64_MEMCPY_ALIGN_MASK) > +#else > +/* Both dst and src unalignment will be treated as unaligned copy */ > +#define RTE_ARM64_MEMCPY_IS_UNALIGNED_COPY(dst, src) \ > + (((uintptr_t)(dst) | (uintptr_t)(src)) & RTE_ARM64_MEMCPY_ALIGN_MASK) > +#endif > + > + > +/* > + * If copy size is larger than threshold, memcpy() will be used. > + * Run "memcpy_perf_autotest" to determine the proper threshold. > + */ > +#define RTE_ARM64_MEMCPY_ALIGNED_THRESHOLD ((size_t)(0xffffffff)) > +#define RTE_ARM64_MEMCPY_UNALIGNED_THRESHOLD ((size_t)(0xffffffff)) > + > +/* > + * The logic of USE_RTE_MEMCPY() can also be modified to best fit platform. > + */ > +#define USE_RTE_MEMCPY(dst, src, n) \ > +((!RTE_ARM64_MEMCPY_IS_UNALIGNED_COPY(dst, src) && \ > +n <= RTE_ARM64_MEMCPY_ALIGNED_THRESHOLD) \ > +|| (RTE_ARM64_MEMCPY_IS_UNALIGNED_COPY(dst, src) && \ > +n <= RTE_ARM64_MEMCPY_UNALIGNED_THRESHOLD)) > + > +/************************************** > + * End of customization section > + **************************************/ Modifying the code to asjust the platform is not easy for deployment. Can we move some customization variables inside the configuration file?