Skip to content

Commit

Permalink
Fix SIMD scanning on macOS (using std::simd)
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Parpart <[email protected]>
  • Loading branch information
christianparpart committed Sep 17, 2024
1 parent b85e440 commit e9b6bd7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/libunicode/scan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ size_t detail::scan_for_text_ascii(string_view text, size_t maxColumnCount) noex

// check for control
// TODO check for complex
auto const simd_mask_text = (simd_text < 0x20);
auto const whitespace = stdx::fixed_size_simd<char, numberOfElements>(0x20);
auto const simd_mask_text = (simd_text < whitespace);
if (stdx::popcount(simd_mask_text) > 0)
{
input += stdx::find_first_set(simd_mask_text);
Expand Down

0 comments on commit e9b6bd7

Please sign in to comment.