/**
* Make store aligned when copy size exceeds 512 bytes
*/
- dstofss = 32 - ((uintptr_t)dst & 0x1F);
+ dstofss = (uintptr_t)dst & 0x1F;
if (dstofss > 0) {
+ dstofss = 32 - dstofss;
n -= dstofss;
rte_mov32((uint8_t *)dst, (const uint8_t *)src);
src = (const uint8_t *)src + dstofss;
* unaligned copy functions require up to 15 bytes
* backwards access.
*/
- dstofss = 16 - ((uintptr_t)dst & 0x0F) + 16;
+ dstofss = (uintptr_t)dst & 0x0F;
if (dstofss > 0) {
+ dstofss = 16 - dstofss + 16;
n -= dstofss;
rte_mov32((uint8_t *)dst, (const uint8_t *)src);
src = (const uint8_t *)src + dstofss;
dst = (uint8_t *)dst + dstofss;
- srcofs = ((uintptr_t)src & 0x0F);
}
+ srcofs = ((uintptr_t)src & 0x0F);
/**
* For aligned copy