summaryrefslogtreecommitdiff
path: root/libc/src/string/memcmp.cpp
AgeCommit message (Collapse)Author
2025-06-04[libc] Expand usage of libc null checks. (#116262)Aly ElAshram
Fixes #111546 --------- Co-authored-by: alyyelashram <150528548+alyyelashram@users.noreply.github.com>
2024-07-12[libc] Migrate to using LIBC_NAMESPACE_DECL for namespace declaration (#98597)Petr Hosek
This is a part of #97655.
2024-07-12Revert "[libc] Migrate to using LIBC_NAMESPACE_DECL for namespace ↵Mehdi Amini
declaration" (#98593) Reverts llvm/llvm-project#98075 bots are broken
2024-07-11[libc] Migrate to using LIBC_NAMESPACE_DECL for namespace declaration (#98075)Petr Hosek
This is a part of #97655.
2023-09-26[libc] Mass replace enclosing namespace (#67032)Guillaume Chatelet
This is step 4 of https://discourse.llvm.org/t/rfc-customizable-namespace-to-allow-testing-the-libc-when-the-system-libc-is-also-llvms-libc/73079
2023-07-19[libc][NFC] Rename filesGuillaume Chatelet
This patch mostly renames files so it better reflects the function they declare. Reviewed By: michaelrj Differential Revision: https://reviews.llvm.org/D155607
2022-11-02[reland][libc] Switch to new implementation of mem* functionsGuillaume Chatelet
The new framework makes it explicit which processor feature is being used and allows for easier per platform customization: - ARM cpu now uses trivial implementations to reduce code size. - Memcmp, Bcmp and Memmove have been optimized for x86 - Bcmp has been optimized for aarch64. This is a reland of https://reviews.llvm.org/D135134 (b3f1d58, 028414881381) Reviewed By: courbet Differential Revision: https://reviews.llvm.org/D136595
2022-10-27Revert D136595 "[libc] Switch to new implementation of mem* functions"Guillaume Chatelet
This patch seems to introduce bugs on aarch64. Reverting while we investigate the root cause. This reverts commit 02841488138160f9064f334a833d4bf3e80385c6.
2022-10-25[libc] Switch to new implementation of mem* functionsGuillaume Chatelet
The new framework makes it explicit which processor feature is being used and allows for easier per platform customization: - ARM cpu now uses trivial implementations to reduce code size. - Memcmp, Bcmp and Memmove have been optimized for x86 - Bcmp has been optimized for aarch64. This is a reland of https://reviews.llvm.org/D135134 (b3f1d58) Differential Revision: https://reviews.llvm.org/D136595
2022-10-14Revert "[libc] New version of the mem* framework"Sterling Augustine
This reverts commit https://reviews.llvm.org/D135134 (b3f1d58a131eb546aaf1ac165c77ccb89c40d758) That revision appears to have broken Arm memcpy in some subtle ways. Am communicating with the original author to get a good reproduction.
2022-10-14[libc] New version of the mem* frameworkGuillaume Chatelet
This version is more composable and also simpler at the expense of being more explicit and more verbose. It also provides minimal implementations for ARM platforms. Codegen can be checked here https://godbolt.org/z/chf1Y6eGM Differential Revision: https://reviews.llvm.org/D135134
2022-10-14Revert "[libc] New version of the mem* framework"Guillaume Chatelet
This reverts commit 9721687835a7df5da0c9482cf684c11b8ba97f75.
2022-10-14[libc] New version of the mem* frameworkGuillaume Chatelet
This version is more composable and also simpler at the expense of being more explicit and more verbose. It also provides minimal implementations for ARM platforms. Codegen can be checked here https://godbolt.org/z/x19zvE59v Differential Revision: https://reviews.llvm.org/D135134
2022-10-14Revert "[libc] New version of the mem* framework"Guillaume Chatelet
This reverts commit 98bf836f3127a346a81da5ae3e27246935298de4.
2022-10-14[libc] New version of the mem* frameworkGuillaume Chatelet
This version is more composable and also simpler at the expense of being more explicit and more verbose. It also provides minimal implementations for ARM platforms. Codegen can be checked here https://godbolt.org/z/x19zvE59v Differential Revision: https://reviews.llvm.org/D135134
2022-10-13Revert "[libc] New version of the mem* framework"Guillaume Chatelet
This reverts commit d55f2d8ab076298cfd745c05c1b4dfd5583f8b9e.
2022-10-13[libc] New version of the mem* frameworkGuillaume Chatelet
This version is more composable and also simpler at the expense of being more explicit and more verbose. It also provides minimal implementations for ARM platforms. Codegen can be checked here https://godbolt.org/z/x19zvE59v Differential Revision: https://reviews.llvm.org/D135134
2022-10-12Revert "[libc] New version of the mem* framework"Guillaume Chatelet
This reverts commit 4c19439d249256db720e323a446e39d05496732f.
2022-10-12[libc] New version of the mem* frameworkGuillaume Chatelet
This version is more composable and also simpler at the expense of being more explicit and more verbose. This patch is not meant to be submitted but gives an idea of the change. Codegen can be checked in https://godbolt.org/z/6z1dEoWbs by removing the "static inline" before individual functions. Unittests are coming. Suggested review order: - utils - op_base - op_builtin - op_generic - op_x86 / op_aarch64 - *_implementations.h Differential Revision: https://reviews.llvm.org/D135134
2021-11-04[libc][NFC] Allow memcmp to be inlinedGuillaume Chatelet
Similar to D113097 although not strictly necessary for now. It helps keeping the same structure for all memory functions. Differential Revision: https://reviews.llvm.org/D113103
2021-11-02[libc] Add more robust compile time architecture detectionGuillaume Chatelet
We may want to restrict the detected platforms to only `x86_64` and `aarch64`. There are still custom detection in api.td but I don't think we can handle these: - config/linux/api.td:205 - config/linux/api.td:199 Differential Revision: https://reviews.llvm.org/D112818
2021-10-29Revert "[libc] Add more robust compile time architecture detection"Guillaume Chatelet
This reverts commit a72e2499865b55cb007b63673100c06cc85faf97.
2021-10-29[libc] Add more robust compile time architecture detectionGuillaume Chatelet
We may want to restrict the detected platforms to only `x86_64` and `aarch64`. There are still custom detection in api.td but I don't think we can handle these: - config/linux/api.td:205 - config/linux/api.td:199 Differential Revision: https://reviews.llvm.org/D112818
2021-08-20[libc] Align to 32B instead of 16B for optimized memcmpGuillaume Chatelet
2021-08-20[libc] Add an optimized version for memcmpGuillaume Chatelet
Differential Revision: https://reviews.llvm.org/D108406
2021-01-08[libc] Switch to use a macro which does not insert a section for every libc ↵Michael Jones
function. Summary: The new macro also inserts the C alias for the C++ implementations without needing an objcopy based post processing step. The CMake rules have been updated to reflect this. More CMake cleanup can be taken up in future rounds and appropriate TODOs have been added for them. Reviewers: mcgrathr, sivachandra Subscribers:
2020-12-15[libc] Add memcmp implementation.Cheng Wang
Reviewed By: gchatelet Differential Revision: https://reviews.llvm.org/D93009