Feature/from chars rvv - #2
Open
e4d08 wants to merge 2 commits into
Open
Conversation
The BOOST_UUID_USE_RISCV_V config macro is automatically defined when the compiler defines __riscv_v, indicating RISC-V Vector Extension (V 1.0+) support is available. The macro is also added to the BOOST_UUID_NO_SIMD exclusion list.
This adds a RISC-V Vector (RVV) implementation of the from_chars algorithm, ported from the x86 SIMD implementation. The RVV version supports VLEN >= 128 and handles narrow and wide character types (char, char16_t, char32_t). The implementation follows the same structure as from_chars_x86.hpp: deinterleaving of input character pairs, dash validation, hex character validation, and nibble packing. It uses two separate expected dash vectors (one per character pair) instead of x86's single shuffled vector, as RVV's vrgather-based deinterleaving makes this approach more natural. The generic fallback path is preserved: both the x86 and RISC-V SIMD paths dispatch to from_chars_generic when std::is_constant_evaluated() is true.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.