[all-commits] [llvm/llvm-project] b5f04d: [libc] Use different alignment for memcpy between ...
Guillaume Chatelet via All-commits
all-commits at lists.llvm.org
Mon Apr 26 12:30:47 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: b5f04d81a2c0b01db32ed7c1685be37e6bdce171
https://github.com/llvm/llvm-project/commit/b5f04d81a2c0b01db32ed7c1685be37e6bdce171
Author: Guillaume Chatelet <gchatelet at google.com>
Date: 2021-04-26 (Mon, 26 Apr 2021)
Changed paths:
M libc/src/string/aarch64/memcpy.cpp
M libc/src/string/memcpy.cpp
M libc/src/string/memory_utils/memcpy_utils.h
M libc/src/string/x86/memcpy.cpp
M libc/test/src/string/memory_utils/memcpy_utils_test.cpp
Log Message:
-----------
[libc] Use different alignment for memcpy between ARM and x86.
Aligned copy used to be 'destination aligned' for x86 but this decision was reverted in D93457 where we noticed that it was better for ARM to be 'source aligned'.
More benchmarking confirmed that it can be up to 30% faster to align copy to destination for x86. This Patch offers both implementations and switches x86 back to destination aligned.
It also fixes alignment to 32 byte on x86.
Differential Revision: https://reviews.llvm.org/D101296
More information about the All-commits
mailing list