| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
[libc][NFC] Remove usage of the C keyword I. (#160567) | 10 个月前 | |
[libc] Reduce direct use of errno in src/stdlib and src/__support tests. (#143767) * Get rid of libc_errno assignments in str_to_* __support tests, since those API have been migrated to return error in a struct instead. * Migrate tests for atof and to strto* functions from <stdlib.h> and for strdup from <string.h> to use ErrnoCheckingTest harness. | 1 年前 | |
[libc] fix behavior of strrchr(x, '\0') (#112620) strrchr("foo", '\0') is defined to point to the end of foo, rather than returning NULL. This wasn't caught by tests, since llvm-libc's ASSERT_STREQ(nullptr, ""); is not an assertion error. While I'm here, refactor the test slightly to check for NULL more specifically. I considered adding fancier ASSERTs (and changing the semantics of ASSERT_STREQ), but opted for a more local fix by fair dice roll. | 1 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Fix stale char_ptr for find_first_character_wide read (#166594) On exit from the loop, char_ptr had not been updated to match block_ptr, resulting in erroneous results. Moving all updates out of the loop fixes that. Adjust derefences to always be inside bounds checks. | 8 个月前 | |
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
| 2 年前 | ||
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
[libc] Use anonymous namespace for test helper code (#157203) Tests can be at top-level or inside an anonymous namespace, doesn't matter. But putting their helper code inside anonymous namespaces both makes the code compatible with compiling using -Wmissing-declarations and might let the compiler optimize the test good a bit better. | 10 个月前 | |
| 2 年前 | ||
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Change ctype to be encoding independent (#110574) The previous implementation of the ctype functions assumed ASCII. This patch changes to a switch/case implementation that looks odd, but actually is easier for the compiler to understand and optimize. | 1 年前 | |
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
[libc] Don't rely on LIBC_HAS_SANITIZER when enabling null checks. (#150341) LIBC_HAS_SANITIZER (which is defined if ASan, MSan, or UBSan is enabled) is currently used to implicitly disable null checks, normally enabled via LIBC_ADD_NULL_CHECKS config value. Remove this condition, and rely purely on the config value instead: * LIBC_HAS_SANITIZER will be true even for UBSan modes which doesn't rely on null checks at all (e.g. -fsanitize=alignment) * null checks today (implemented via __builtin_trap) should function normally today even when sanitizer is enabled - trap is still a trap * tests have been migrated to WITH_SIGNAL(-1) which doesn't prescript a particular signal / exit-code, and thus should pass even if sanitizers override the default ones. | 1 年前 | |
[libc] fixed signed char issues in strsep()/strtok()/strtok_r(). (#156705) Also add the missing tests for all the related functions (even the ones that were already right), and add the missing bazel build rules. | 10 个月前 | |
[libc] Reduce direct use of errno in src/stdlib and src/__support tests. (#143767) * Get rid of libc_errno assignments in str_to_* __support tests, since those API have been migrated to return error in a struct instead. * Migrate tests for atof and to strto* functions from <stdlib.h> and for strdup from <string.h> to use ErrnoCheckingTest harness. | 1 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Add strerror and strerror_k to the GPU (#99083) Summary: The GPU ignores errno primarily, but targets want these functions to be defined for certain C standard interfaces. This patch enables them and makes the test function on non-Linux targets. | 2 年前 | |
[libc] Remove the #include <stdlib.h> header (#114453) | 1 年前 | |
| 1 年前 | ||
[libc] add an SVE implementation of strlen (#167259) This PR creates an SVE-based implementation for strlen by translating from the AOR code in tree. Microbenchmark shows improvements against NEON when N>=64. Although both implementations fall behind glibc by a large margin, this may be a good start point to explore SVE implementations. Together with the PR: 1. Added two more tests of strlen with special nul symbols. 2. Added strlen's fuzzer and fix a typo in previous heap fuzzer. === strlen(16 bytes) === libc: 1.56115 ns/call, 9.54499 GiB/s neon: 1.59393 ns/call, 9.34867 GiB/s sve: 1.66097 ns/call, 8.97134 GiB/s === strlen(64 bytes) === libc: 2.06967 ns/call, 28.7991 GiB/s neon: 2.59914 ns/call, 22.9325 GiB/s sve: 2.58628 ns/call, 23.0465 GiB/s === strlen(256 bytes) === libc: 3.74165 ns/call, 63.7202 GiB/s neon: 8.98243 ns/call, 26.5428 GiB/s sve: 7.36426 ns/call, 32.3751 GiB/s === strlen(1024 bytes) === libc: 10.5327 ns/call, 90.5438 GiB/s neon: 34.363 ns/call, 27.7529 GiB/s sve: 26.9329 ns/call, 35.4092 GiB/s === strlen(4096 bytes) === libc: 37.7304 ns/call, 101.104 GiB/s neon: 145.911 ns/call, 26.144 GiB/s sve: 103.208 ns/call, 36.9612 GiB/s === strlen(1048576 bytes) === libc: 9623.4 ns/call, 101.478 GiB/s neon: 36138.2 ns/call, 27.023 GiB/s sve: 26605.6 ns/call, 36.7051 GiB/s | 8 个月前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] Remove the #include <stdlib.h> header (#114453) | 1 年前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] fixed signed char issues in strsep()/strtok()/strtok_r(). (#156705) Also add the missing tests for all the related functions (even the ones that were already right), and add the missing bazel build rules. | 10 个月前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] fixed signed char issues in strsep()/strtok()/strtok_r(). (#156705) Also add the missing tests for all the related functions (even the ones that were already right), and add the missing bazel build rules. | 10 个月前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] fixed signed char issues in strsep()/strtok()/strtok_r(). (#156705) Also add the missing tests for all the related functions (even the ones that were already right), and add the missing bazel build rules. | 10 个月前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 | |
[libc] fixed signed char issues in strsep()/strtok()/strtok_r(). (#156705) Also add the missing tests for all the related functions (even the ones that were already right), and add the missing bazel build rules. | 10 个月前 | |
[libc] fixed signed char issues in strsep()/strtok()/strtok_r(). (#156705) Also add the missing tests for all the related functions (even the ones that were already right), and add the missing bazel build rules. | 10 个月前 | |
[libc] Mass replace enclosing namespace (#67032) 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 | 2 年前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 10 个月前 | ||
| 1 年前 | ||
| 1 年前 | ||
| 2 年前 | ||
| 8 个月前 | ||
| 1 年前 | ||
| 1 年前 | ||
| 2 年前 | ||
| 1 年前 | ||
| 1 年前 | ||
| 10 个月前 | ||
| 2 年前 | ||
| 1 年前 | ||
| 2 年前 | ||
| 1 年前 | ||
| 2 年前 | ||
| 1 年前 | ||
| 2 年前 | ||
| 2 年前 | ||
| 1 年前 | ||
| 1 年前 | ||
| 1 年前 | ||
| 10 个月前 | ||
| 1 年前 | ||
| 2 年前 | ||
| 2 年前 | ||
| 1 年前 | ||
| 1 年前 | ||
| 8 个月前 | ||
| 2 年前 | ||
| 2 年前 | ||
| 2 年前 | ||
| 1 年前 | ||
| 2 年前 | ||
| 10 个月前 | ||
| 2 年前 | ||
| 10 个月前 | ||
| 2 年前 | ||
| 10 个月前 | ||
| 2 年前 | ||
| 10 个月前 | ||
| 10 个月前 | ||
| 2 年前 |