[libc-commits] [libc] [libc][wctype] Add perfect hash map for conversion functions (PR #187670)

LLVM Continuous Integration via libc-commits libc-commits at lists.llvm.org
Sun May 24 12:12:49 PDT 2026


llvm-ci wrote:

LLVM Buildbot has detected a new failure on builder `libc-x86_64-debian-dbg-asan` running on `libc-x86_64-debian` while building `libc` at step 4 "annotate".

Full details are available at: https://lab.llvm.org/buildbot/#/builders/147/builds/45015

<details>
<summary>Here is the relevant piece of the build log for the reference</summary>

```
Step 4 (annotate) failure: 'python ../llvm-zorg/zorg/buildbot/builders/annotated/libc-linux.py ...' (failure)
...
[1379/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.wctype_utils_test.__unit__.__build__.dir/wctype_utils_test.cpp.o
[1380/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.cstddef_test.__unit__.__build__.dir/cstddef_test.cpp.o
[1381/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.integer_literals_test.__unit__.__build__.dir/integer_literals_test.cpp.o
[1382/5430] Building CXX object libc/test/UnitTest/CMakeFiles/LibcTest.unit.dir/LibcTest.cpp.o
[1383/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.bitset_test.__unit__.__build__.dir/bitset_test.cpp.o
[1384/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.int_seq_test.__unit__.__build__.dir/integer_sequence_test.cpp.o
[1385/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.limits_test.__unit__.__build__.dir/limits_test.cpp.o
[1386/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.atomic_test.__unit__.__build__.dir/atomic_test.cpp.o
[1387/5430] Linking CXX static library libc/test/UnitTest/libLibcTest.unit.a
[1388/5430] Building CXX object libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o
FAILED: libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o 
/usr/bin/clang++ -DLIBC_NAMESPACE=__llvm_libc_20_0_0_git -D_DEBUG -I/home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian/libc-x86_64-debian-dbg-asan/llvm-project/libc -I/home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian/libc-x86_64-debian-dbg-asan/build/libc -isystem /home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian/libc-x86_64-debian-dbg-asan/build/libc/include -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wno-comment -Wstring-conversion -Wno-pass-failed -Wmisleading-indentation -Wctad-maybe-unsupported -fno-omit-frame-pointer -fsanitize=address -fdiagnostics-color -g -DLIBC_QSORT_IMPL=LIBC_QSORT_QUICK_SORT -DLIBC_COPT_STRING_LENGTH_IMPL=clang_vector -DLIBC_COPT_FIND_FIRST_CHARACTER_IMPL=word -DLIBC_ADD_NULL_CHECKS -DLIBC_ERRNO_MODE=LIBC_ERRNO_MODE_DEFAULT -DLIBC_THREAD_MODE=LIBC_THREAD_MODE_PLATFORM -DLIBC_COPT_TIMEOUT_ENSURE_MONOTONICITY -DLIBC_CONF_WCTYPE_MODE=LIBC_WCTYPE_MODE_ASCII -DLIBC_COPT_RAW_MUTEX_DEFAULT_SPIN_COUNT=100 -fpie -Wall -Wextra -Wconversion -Wno-sign-conversion -Wimplicit-fallthrough -Wwrite-strings -Wno-c99-extensions -Wno-gnu-imaginary-constant -Wno-pedantic -Wstrict-prototypes -Wextra-semi -Wnewline-eof -Wnonportable-system-include-path -Wthread-safety -DLIBC_TEST=UNIT -Xclang -fconstexpr-steps=10000000 -std=gnu++17 -MD -MT libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o -MF libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o.d -o libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o -c /home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian/libc-x86_64-debian-dbg-asan/llvm-project/libc/test/src/__support/wctype/wctype_perfect_hash_test.cpp
error: unknown argument: '-fconstexpr-steps=10000000'
[1389/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.mutex_test.__unit__.__build__.dir/mutex_test.cpp.o
[1390/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.hash_test.__unit__.__build__.dir/hash_test.cpp.o
[1391/5430] Linking CXX static library libc/test/UnitTest/libLibcFPTestHelpers.unit.a
[1392/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.optional_test.__unit__.__build__.dir/optional_test.cpp.o
[1393/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.math_extras_test.__unit__.__build__.dir/math_extras_test.cpp.o
[1394/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.stringview_test.__unit__.__build__.dir/stringview_test.cpp.o
[1395/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.stringstream_test.__unit__.__build__.dir/stringstream_test.cpp.o
[1396/5430] Building CXX object libc/test/src/__support/OSUtil/linux/CMakeFiles/libc.test.src.__support.OSUtil.linux.sysinfo_test.__unit__.__build__.dir/sysinfo_test.cpp.o
[1397/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.scope_test.__unit__.__build__.dir/scope_test.cpp.o
[1398/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.span_test.__unit__.__build__.dir/span_test.cpp.o
[1399/5430] Building CXX object libc/test/src/__support/OSUtil/linux/x86_64/CMakeFiles/libc.test.src.__support.OSUtil.linux.x86_64.syscall_test.__unit__.__build__.dir/syscall_test.cpp.o
[1400/5430] Building CXX object libc/test/src/__support/time/linux/CMakeFiles/libc.test.src.__support.time.linux.timeout_test.__unit__.__build__.dir/timeout_test.cpp.o
[1401/5430] Building CXX object libc/test/src/__support/FPUtil/CMakeFiles/libc.test.src.__support.FPUtil.rounding_mode_test.__unit__.__build__.dir/rounding_mode_test.cpp.o
[1402/5430] Building CXX object libc/test/src/__support/threads/linux/CMakeFiles/libc.test.src.__support.threads.linux.raw_rwlock_test.__unit__.__build__.dir/raw_rwlock_test.cpp.o
[1403/5430] Building CXX object libc/test/src/__support/wchar/CMakeFiles/libc.test.src.__support.wchar.utf8_to_32_test.__unit__.__build__.dir/utf8_to_32_test.cpp.o
[1404/5430] Building CXX object libc/test/src/__support/wchar/CMakeFiles/libc.test.src.__support.wchar.utf32_to_8_test.__unit__.__build__.dir/utf32_to_8_test.cpp.o
[1405/5430] Building CXX object libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_classification_utils_test.__unit__.__build__.dir/wctype_classification_utils_test.cpp.o
[1406/5430] Building CXX object libc/test/src/__support/File/CMakeFiles/libc.test.src.__support.File.platform_file_test.__unit__.__build__.dir/platform_file_test.cpp.o
[1407/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.string_test.__unit__.__build__.dir/string_test.cpp.o
[1408/5430] Building CXX object libc/test/src/arpa/inet/CMakeFiles/libc.test.src.arpa.inet.htonl.__build__.dir/htonl_test.cpp.o
[1409/5430] Building CXX object libc/test/src/__support/wchar/CMakeFiles/libc.test.src.__support.wchar.wcsnrtombs_test.__unit__.__build__.dir/wcsnrtombs_test.cpp.o
[1410/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.tuple_test.__unit__.__build__.dir/tuple_test.cpp.o
[1411/5430] Building CXX object libc/test/src/__support/wchar/CMakeFiles/libc.test.src.__support.wchar.string_converter_test.__unit__.__build__.dir/string_converter_test.cpp.o
[1412/5430] Building CXX object libc/test/src/__support/File/CMakeFiles/libc.test.src.__support.File.file_test.__unit__.__build__.dir/file_test.cpp.o
[1413/5430] Building CXX object libc/test/src/arpa/inet/CMakeFiles/libc.test.src.arpa.inet.htons.__build__.dir/htons_test.cpp.o
[1414/5430] Building CXX object libc/test/src/__support/threads/CMakeFiles/libc.test.src.__support.threads.futex_utils_test.__unit__.__build__.dir/futex_utils_test.cpp.o
[1415/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.integer_to_string_test.__unit__.__build__.dir/integer_to_string_test.cpp.o
[1416/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.bit_test.__unit__.__build__.dir/bit_test.cpp.o
[1417/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.type_traits_test.__unit__.__build__.dir/type_traits_test.cpp.o
[1418/5430] Building CXX object libc/test/src/__support/FPUtil/CMakeFiles/libc.test.src.__support.FPUtil.fpbits_test.__unit__.__build__.dir/fpbits_test.cpp.o
[1419/5430] Building CXX object libc/test/src/__support/FPUtil/CMakeFiles/libc.test.src.__support.FPUtil.comparison_operations_test.__unit__.__NO_FMA_OPT.__build__.dir/comparison_operations_test.cpp.o
[1420/5430] Building CXX object libc/test/src/__support/FPUtil/CMakeFiles/libc.test.src.__support.FPUtil.comparison_operations_test.__unit__.__build__.dir/comparison_operations_test.cpp.o
[1421/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.big_int_test.__unit__.__build__.dir/big_int_test.cpp.o
ninja: build stopped: subcommand failed.
['ninja', 'libc-unit-tests'] exited with return code 1.
The build step threw an exception...
Step 7 (libc-unit-tests) failure: libc-unit-tests (failure)
...
[1379/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.wctype_utils_test.__unit__.__build__.dir/wctype_utils_test.cpp.o
[1380/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.cstddef_test.__unit__.__build__.dir/cstddef_test.cpp.o
[1381/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.integer_literals_test.__unit__.__build__.dir/integer_literals_test.cpp.o
[1382/5430] Building CXX object libc/test/UnitTest/CMakeFiles/LibcTest.unit.dir/LibcTest.cpp.o
[1383/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.bitset_test.__unit__.__build__.dir/bitset_test.cpp.o
[1384/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.int_seq_test.__unit__.__build__.dir/integer_sequence_test.cpp.o
[1385/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.limits_test.__unit__.__build__.dir/limits_test.cpp.o
[1386/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.atomic_test.__unit__.__build__.dir/atomic_test.cpp.o
[1387/5430] Linking CXX static library libc/test/UnitTest/libLibcTest.unit.a
[1388/5430] Building CXX object libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o
FAILED: libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o 
/usr/bin/clang++ -DLIBC_NAMESPACE=__llvm_libc_20_0_0_git -D_DEBUG -I/home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian/libc-x86_64-debian-dbg-asan/llvm-project/libc -I/home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian/libc-x86_64-debian-dbg-asan/build/libc -isystem /home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian/libc-x86_64-debian-dbg-asan/build/libc/include -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wsuggest-override -Wno-comment -Wstring-conversion -Wno-pass-failed -Wmisleading-indentation -Wctad-maybe-unsupported -fno-omit-frame-pointer -fsanitize=address -fdiagnostics-color -g -DLIBC_QSORT_IMPL=LIBC_QSORT_QUICK_SORT -DLIBC_COPT_STRING_LENGTH_IMPL=clang_vector -DLIBC_COPT_FIND_FIRST_CHARACTER_IMPL=word -DLIBC_ADD_NULL_CHECKS -DLIBC_ERRNO_MODE=LIBC_ERRNO_MODE_DEFAULT -DLIBC_THREAD_MODE=LIBC_THREAD_MODE_PLATFORM -DLIBC_COPT_TIMEOUT_ENSURE_MONOTONICITY -DLIBC_CONF_WCTYPE_MODE=LIBC_WCTYPE_MODE_ASCII -DLIBC_COPT_RAW_MUTEX_DEFAULT_SPIN_COUNT=100 -fpie -Wall -Wextra -Wconversion -Wno-sign-conversion -Wimplicit-fallthrough -Wwrite-strings -Wno-c99-extensions -Wno-gnu-imaginary-constant -Wno-pedantic -Wstrict-prototypes -Wextra-semi -Wnewline-eof -Wnonportable-system-include-path -Wthread-safety -DLIBC_TEST=UNIT -Xclang -fconstexpr-steps=10000000 -std=gnu++17 -MD -MT libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o -MF libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o.d -o libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_perfect_hash_test.__unit__.__build__.dir/wctype_perfect_hash_test.cpp.o -c /home/llvm-libc-buildbot/buildbot-worker/libc-x86_64-debian/libc-x86_64-debian-dbg-asan/llvm-project/libc/test/src/__support/wctype/wctype_perfect_hash_test.cpp
error: unknown argument: '-fconstexpr-steps=10000000'
[1389/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.mutex_test.__unit__.__build__.dir/mutex_test.cpp.o
[1390/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.hash_test.__unit__.__build__.dir/hash_test.cpp.o
[1391/5430] Linking CXX static library libc/test/UnitTest/libLibcFPTestHelpers.unit.a
[1392/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.optional_test.__unit__.__build__.dir/optional_test.cpp.o
[1393/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.math_extras_test.__unit__.__build__.dir/math_extras_test.cpp.o
[1394/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.stringview_test.__unit__.__build__.dir/stringview_test.cpp.o
[1395/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.stringstream_test.__unit__.__build__.dir/stringstream_test.cpp.o
[1396/5430] Building CXX object libc/test/src/__support/OSUtil/linux/CMakeFiles/libc.test.src.__support.OSUtil.linux.sysinfo_test.__unit__.__build__.dir/sysinfo_test.cpp.o
[1397/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.scope_test.__unit__.__build__.dir/scope_test.cpp.o
[1398/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.span_test.__unit__.__build__.dir/span_test.cpp.o
[1399/5430] Building CXX object libc/test/src/__support/OSUtil/linux/x86_64/CMakeFiles/libc.test.src.__support.OSUtil.linux.x86_64.syscall_test.__unit__.__build__.dir/syscall_test.cpp.o
[1400/5430] Building CXX object libc/test/src/__support/time/linux/CMakeFiles/libc.test.src.__support.time.linux.timeout_test.__unit__.__build__.dir/timeout_test.cpp.o
[1401/5430] Building CXX object libc/test/src/__support/FPUtil/CMakeFiles/libc.test.src.__support.FPUtil.rounding_mode_test.__unit__.__build__.dir/rounding_mode_test.cpp.o
[1402/5430] Building CXX object libc/test/src/__support/threads/linux/CMakeFiles/libc.test.src.__support.threads.linux.raw_rwlock_test.__unit__.__build__.dir/raw_rwlock_test.cpp.o
[1403/5430] Building CXX object libc/test/src/__support/wchar/CMakeFiles/libc.test.src.__support.wchar.utf8_to_32_test.__unit__.__build__.dir/utf8_to_32_test.cpp.o
[1404/5430] Building CXX object libc/test/src/__support/wchar/CMakeFiles/libc.test.src.__support.wchar.utf32_to_8_test.__unit__.__build__.dir/utf32_to_8_test.cpp.o
[1405/5430] Building CXX object libc/test/src/__support/wctype/CMakeFiles/libc.test.src.__support.wctype.wctype_classification_utils_test.__unit__.__build__.dir/wctype_classification_utils_test.cpp.o
[1406/5430] Building CXX object libc/test/src/__support/File/CMakeFiles/libc.test.src.__support.File.platform_file_test.__unit__.__build__.dir/platform_file_test.cpp.o
[1407/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.string_test.__unit__.__build__.dir/string_test.cpp.o
[1408/5430] Building CXX object libc/test/src/arpa/inet/CMakeFiles/libc.test.src.arpa.inet.htonl.__build__.dir/htonl_test.cpp.o
[1409/5430] Building CXX object libc/test/src/__support/wchar/CMakeFiles/libc.test.src.__support.wchar.wcsnrtombs_test.__unit__.__build__.dir/wcsnrtombs_test.cpp.o
[1410/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.tuple_test.__unit__.__build__.dir/tuple_test.cpp.o
[1411/5430] Building CXX object libc/test/src/__support/wchar/CMakeFiles/libc.test.src.__support.wchar.string_converter_test.__unit__.__build__.dir/string_converter_test.cpp.o
[1412/5430] Building CXX object libc/test/src/__support/File/CMakeFiles/libc.test.src.__support.File.file_test.__unit__.__build__.dir/file_test.cpp.o
[1413/5430] Building CXX object libc/test/src/arpa/inet/CMakeFiles/libc.test.src.arpa.inet.htons.__build__.dir/htons_test.cpp.o
[1414/5430] Building CXX object libc/test/src/__support/threads/CMakeFiles/libc.test.src.__support.threads.futex_utils_test.__unit__.__build__.dir/futex_utils_test.cpp.o
[1415/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.integer_to_string_test.__unit__.__build__.dir/integer_to_string_test.cpp.o
[1416/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.bit_test.__unit__.__build__.dir/bit_test.cpp.o
[1417/5430] Building CXX object libc/test/src/__support/CPP/CMakeFiles/libc.test.src.__support.CPP.type_traits_test.__unit__.__build__.dir/type_traits_test.cpp.o
[1418/5430] Building CXX object libc/test/src/__support/FPUtil/CMakeFiles/libc.test.src.__support.FPUtil.fpbits_test.__unit__.__build__.dir/fpbits_test.cpp.o
[1419/5430] Building CXX object libc/test/src/__support/FPUtil/CMakeFiles/libc.test.src.__support.FPUtil.comparison_operations_test.__unit__.__NO_FMA_OPT.__build__.dir/comparison_operations_test.cpp.o
[1420/5430] Building CXX object libc/test/src/__support/FPUtil/CMakeFiles/libc.test.src.__support.FPUtil.comparison_operations_test.__unit__.__build__.dir/comparison_operations_test.cpp.o
[1421/5430] Building CXX object libc/test/src/__support/CMakeFiles/libc.test.src.__support.big_int_test.__unit__.__build__.dir/big_int_test.cpp.o
ninja: build stopped: subcommand failed.
['ninja', 'libc-unit-tests'] exited with return code 1.
The build step threw an exception...

```

</details>

https://github.com/llvm/llvm-project/pull/187670


More information about the libc-commits mailing list