|
REAL
Regular Expression Algorithmic Library — constexpr C++20 regex
|
A uniform 16-lane mask interface over NEON and SSE2, so the loops that consume it (pike.hpp, prefilter.hpp) carry no #if ISA branch of their own.
More...
#include "real/version.hpp"#include <array>#include <bit>#include <cstddef>#include <cstdint>#include <cstring>#include <string_view>Namespaces | |
| namespace | real |
| REAL's public API: real::regex, real::static_regex, real::flags and the match/iterator types built on them. | |
| namespace | real::detail |
| DFA construction internals: subset construction over a flattened NFA. Not a stable API. | |
A uniform 16-lane mask interface over NEON and SSE2, so the loops that consume it (pike.hpp, prefilter.hpp) carry no #if ISA branch of their own.
mask_t is opaque and per-ISA (nibble-packed std::uint64_t on NEON, bit-packed std::uint32_t on SSE2): callers touch it only through the lane primitives at the end (empty, first_lane, clear_first, window_all_set, first_clear_lane, next_set_lane). The load functions build masks from member sets, byte ranges, byte pairs and nibble fingerprints, loading bytes by memcpy (MISRA: no pointer type-pun). The x86 SSSE3 and AVX2 functions are built per function (target) where the build lacks the extension, and run only after a cpuid check; avx2_literal_scan is the one whole scan loop here.
No runner compiles both the NEON and the x86 bodies, so none line-covers both: hence this file's COV_FLOOR_IGNORE in the Makefile, the contract being guarded by sanitize, the fuzz corpus and each ISA's own runs over the identical interface.