-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
[stdlib] Micro-optimize utf8 helper functions #3896
[stdlib] Micro-optimize utf8 helper functions #3896
Conversation
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
…k/mojo into micro-optimize-utf8-seq-length
@ConnorGray do you mind taking a look at this since you've been overhauling how we expose the UTF-8 helpers, |
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
Hi @JoeLoser and @ConnorGray I'm back from vacation and had some time today to look over the new Each encoding has its own tricks that are faster for their respective raw data format. Transforming to and from utf32 to then check a byte is wasteful. Going UTF32 is inefficient for mostly ASCII text as well. It is also confusing for people why I was focusing on building out our UTF8 capacity to its maximum with all the little tricks I could find. Then start thinking about whether we want to support UTF32 fully (sidenote: Python is migrating over to UTF8 anyway). IMO the
Edit: I opened a full/better thought through proposal #3988 |
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
Signed-off-by: martinvuyk <[email protected]>
!sync |
✅🟣 This contribution has been merged 🟣✅ Your pull request has been merged to the internal upstream Mojo sources. It will be reflected here in the Mojo repository on the main branch during the next Mojo nightly release, typically within the next 24-48 hours. We use Copybara to merge external contributions, click here to learn more. |
Landed in bdaca0f! Thank you for your contribution 🎉 |
Micro-optimize utf8 helper functions