-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Further optimize find_first_of
#4497
Comments
I think this fallback part (wouldn't be used with Lines 732 to 737 in 8e2d724
|
I now see that it is possible. I agree that it would work here. But I'm not sure whether the bitmap thing is worth doing for narrow string, if the vector algorithm can be used. The bitmap would check up to 256 characters of the needle at a time, but only one character of the source string at a time. The Even for wide characters, the Of course, there's more than just number of comparisons. There are different instructions, with different latencies and throughputs. Overall, the bitmap is expected to use more instructions, but these are the usual fast ones, unlike high latency |
find
basic_string::find_first_of
(or prove it is not possible)The text was updated successfully, but these errors were encountered: