Skip to content
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

Fast conversion to/from ASCII/one-byte strings? #44

Open
dead-claudia opened this issue Sep 12, 2024 · 0 comments
Open

Fast conversion to/from ASCII/one-byte strings? #44

dead-claudia opened this issue Sep 12, 2024 · 0 comments

Comments

@dead-claudia
Copy link

It's a near universal optimization within JS implementations to split strings into two representations: a one-byte and a two-byte. Even the size-optimized runtime XS does it. It brings a massive speed boost and almost halves string memory usage in practice. So, I'd like to see fromCharByteArray and intoCharByteArray that return character codes modulo 256.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant