2
0
mirror of https://github.com/boostorg/uuid.git synced 2026-01-19 04:42:16 +00:00

737 Commits

Author SHA1 Message Date
Peter Dimov
85bc141e43 Minor documentation updates 2026-01-15 17:45:43 +02:00
Peter Dimov
f4bcc0fd2a Update documentation 2026-01-15 15:38:40 +02:00
Peter Dimov
c4678bf9a6 Split Cygwin64 GCC job into two to avoid Appveyor timeout 2026-01-15 02:33:30 +02:00
Peter Dimov
b2c72679ba Update test_uuid_from_string_2 2026-01-14 19:59:07 +02:00
Peter Dimov
884c050576 Add boost::uuid::invalid_uuid exception class 2026-01-14 19:53:21 +02:00
Peter Dimov
bee48932a6 Add test_uuid_from_string_3.cpp 2026-01-14 19:48:35 +02:00
Peter Dimov
0b6a9ade9a Respect the OutputIterator value_type in to_chars 2026-01-13 17:47:01 +02:00
Peter Dimov
aa6c1a7985 std::back_insert_iterator's value_type is void smh 2026-01-13 17:46:30 +02:00
Peter Dimov
6b0dc88eef Add test_to_chars_3.cpp 2026-01-13 15:44:22 +02:00
Peter Dimov
608718786b Merge pull request #190 from Lastique/feature/to_from_chars_sse2
Add SSE2 implementations of `to_chars` and `from_chars`
2026-01-12 16:54:54 +02:00
Andrey Semashev
3af17a4236 Added GitHub Actions jobs for SSSE3 and AVX targets.
The targets verify the respective code paths in SIMD algorithms.
The recently added SSE2 paths are already tested in the other,
unspecialized jobs.

Also added jobs to compile tests with BOOST_UUID_TO_FROM_CHARS_X86_USE_ZMM
and BOOST_UUID_FROM_CHARS_X86_USE_VPERMI2B experimental macros defined.
2026-01-10 12:15:59 +03:00
Andrey Semashev
b135a5d816 Compile tests without running in CI if the CPU lacks required features.
This allows for testing that the ISA-specific code at least compiles,
even if running the tests isn't possible.

The support is only added to b2, CMake still always compiles and runs
the tests to keep using boost_test_jamfile for easier maintenance. In
the future, similar support can be added to CMake as well.
2026-01-10 12:15:59 +03:00
Andrey Semashev
ba77fe2781 Added SSE2 and SSSE3 SIMD implementations of from_chars.
This adds SSE2 and SSSE3 code paths to from_chars_x86.hpp. The performance
effect on Intel Golden Cove (Core i7-12700K), gcc 13.3, in millions of
successful from_chars() calls per second:

Char     | Generic | SSE2            | SSSE3           | SSE4.1          | AVX2            | AVX512v1
=========+=========+=================+=================+=================+=================+================
char     |  40.475 | 327.791 (8.10x) | 465.857 (11.5x) | 555.346 (13.7x) | 504.648 (12.5x) | 539.700 (13.3x)
char16_t |  38.757 | 292.048 (7.54x) | 401.117 (10.3x) | 478.574 (12.3x) | 426.188 (11.0x) | 416.205 (10.7x)
char32_t |  50.200 | 150.900 (3.01x) | 204.588 (4.08x) | 389.882 (7.77x) | 359.591 (7.16x) | 349.663 (6.97x)

In addition, the workarounds to avoid (v)pblendvb instructions have been
extended to Intel Haswell and Broadwell, as these microarchitectures have
poor performance with these instructions (including the SSE4.1 pblendvb).

Two new experimental control macros added: BOOST_UUID_FROM_CHARS_X86_SLOW_PBLENDVB
and BOOST_UUID_FROM_CHARS_X86_USE_PBLENDVB. The former indicates that
(v)pblendvb instructions are slow and should be avoided on the target
microarchitectures. The latter indicates that (v)pblendvb should be used
by the implementation. The latter macro is derived from the former and
takes precedence. As before, these macros can be used for experimenting
and fine tuning performance for specific target CPUs. By default,
BOOST_UUID_FROM_CHARS_X86_SLOW_PBLENDVB is defined for Haswell/Broadwell
or if AVX is detected.

Lastly, made selection between blend-based and shuffle-based character
code conversion in various places unified, controlled by a single
internal macro BOOST_UUID_DETAIL_FROM_CHARS_X86_USE_BLENDS.
2026-01-10 12:15:59 +03:00
Andrey Semashev
97dc5c35ba Added SSE2 SIMD implementation of to_chars.
This adds SSE2 code paths to to_chars_x86.hpp. The performance effect on
Intel Golden Cove (Core i7-12700K), gcc 13.3, in millions of to_chars() calls
per second with a 16-byte aligned output buffer:

Char     | Generic | SSE2            | SSE4.1           | AVX2             | AVX10.1
=========+=========+=================+==================+==================+=================
char     | 202.314 | 564.857 (2.79x) | 1194.772 (5.91x) | 1192.094 (5.89x) | 1191.838 (5.89x)
char16_t | 188.532 | 457.281 (2.43x) |  795.798 (4.22x) |  935.016 (4.96x) |  938.368 (4.98x)
char32_t | 193.151 | 345.612 (1.79x) |  489.620 (2.53x) |  688.829 (3.57x) |  689.617 (3.57x)

Here, Generic column was generated with BOOST_UUID_NO_SIMD defined and
SSE2 with -march=x86-64. SSE2 support can be useful in cases when users
need to be compatible with the base x86-64 ISA.
2026-01-10 12:15:59 +03:00
Andrey Semashev
d53a476a77 Silence -Wstrict-aliasing warning in simd_vector.hpp. 2026-01-10 12:15:59 +03:00
Andrey Semashev
39946fb660 Fix -Wconversion warning in from_chars_x86.hpp. 2026-01-10 12:15:59 +03:00
Peter Dimov
2b229f7449 Update documentation 2026-01-10 02:41:29 +02:00
Peter Dimov
8febad40ed Make string_generator support string-like types like uuid_from_string does 2026-01-09 21:44:26 +02:00
Peter Dimov
190ee28b1d Update documentation 2026-01-09 16:22:07 +02:00
Peter Dimov
0af8de5509 Update documentation 2026-01-09 16:15:39 +02:00
Peter Dimov
11b392d9ff Merge pull request #189 from Lastique/feature/remove_unneeded_includes
Remove unnecessary includes and warning suppression in uuid_io.hpp
2026-01-09 16:14:23 +02:00
Andrey Semashev
22e7ba81a9 Removed unnecessary includes and warning suppression in uuid_io.hpp. 2026-01-09 14:35:03 +03:00
Peter Dimov
095a47fe04 Change the type of pos to std::ptrdiff_t to avoid casts 2026-01-08 22:57:00 +02:00
Peter Dimov
517bfe6972 Include BoostTestJamfile in test/CMakeLists.txt 2026-01-08 18:58:47 +02:00
Peter Dimov
ea77c34803 Make uuid_from_string constexpr 2026-01-08 18:52:56 +02:00
Peter Dimov
d9d396a666 Add test_uuid_from_string_cx.cpp 2026-01-08 18:52:29 +02:00
Peter Dimov
6d5420b09b Add boost_test_jamfile to CMakeLists.txt 2026-01-08 18:40:18 +02:00
Peter Dimov
29c5f57c95 Define BOOST_UUID_REPORT_IMPLEMENTATION in test .cpp files instead of Jamfile 2026-01-08 18:19:15 +02:00
Peter Dimov
d493f92dcd Add uuid_from_string 2026-01-08 16:59:10 +02:00
Peter Dimov
c9f5a8f028 Merge pull request #188 from Lastique/feature/fix_conversion_warning
Fix `-Wsign-conversion` warning with gcc 13.3
2026-01-07 20:49:44 +02:00
Andrey Semashev
663ffa1287 Make cast formatting consistent with the rest of the file. 2026-01-07 20:13:18 +03:00
Andrey Semashev
286b66b385 Fix -Wsign-conversion warning with gcc 13.3. 2026-01-07 20:08:43 +03:00
Peter Dimov
347258c6c8 When BOOST_UUID_NO_SIMD is defined, undef all other SIMD macros, because otherwise the configuration becomes inconsistent 2026-01-06 16:32:16 +02:00
Peter Dimov
e567490082 Fix BOOST_UUID_REPORT_IMPLEMENTATION messages 2026-01-06 16:26:35 +02:00
Peter Dimov
974f7f7387 Add a job with /arch:SSE4.2 that defines BOOST_UUID_USE_SSE41 to ci.yml 2026-01-06 15:48:08 +02:00
Peter Dimov
029527c109 Disable -Wconversion for GCC 5 in test_hash_value.cpp 2026-01-05 20:27:38 +02:00
Peter Dimov
bb5f471431 Switch ARM64 and S390x jobs to 22.04 2026-01-05 19:02:03 +02:00
Peter Dimov
22660ac3ca Cosmetic fixes to configuration.adoc 2026-01-05 18:53:49 +02:00
Peter Dimov
c7caa5b94e Update revision history 2026-01-05 18:52:42 +02:00
Peter Dimov
2b387b4638 Avoid -Wsign-conversion warnings in from_chars_x86.hpp 2026-01-05 17:56:10 +02:00
Peter Dimov
f852d61bee Avoid -Wsign-conversion warnings in to_chars_x86.hpp 2026-01-05 17:44:32 +02:00
Peter Dimov
2b5d078c00 Disable -Wshadow in test_bench_random.cpp for GCC 4.x because of Boost.Timer 2026-01-05 16:54:55 +02:00
Peter Dimov
0b86240e0d Avoid -Wconversion warning in time_generator_v6.hpp under GCC 5 and below 2026-01-05 16:54:55 +02:00
Peter Dimov
eabd000a54 Avoid -Wconversion, -Wsign-conversion warnings in detail/basic_name_generator.hpp under GCC 9 and below 2026-01-05 16:54:55 +02:00
Peter Dimov
520b3632f3 Avoid -Wsign-conversion warning in detail/basic_name_generator.hpp when wchar_t is int32_t 2026-01-05 16:54:55 +02:00
Peter Dimov
da2cb7cc02 Avoid -Wshadow warning in test_tagging.cpp 2026-01-05 16:54:55 +02:00
Peter Dimov
09a6a81b6b Avoid -Wconversion warning in detail/md5.hpp 2026-01-05 16:54:55 +02:00
Peter Dimov
7340079ffd Avoid -Wsign-conversion warnings in test_time_generator_v7_2.cpp 2026-01-05 16:54:54 +02:00
Peter Dimov
b92abf895f Avoid -Wsign-conversion warnings in test_to_chars.cpp 2026-01-05 16:54:54 +02:00
Peter Dimov
40b12ae256 Disable -Wsign-conversion in test_random_generator.cpp 2026-01-05 16:54:54 +02:00