Skip to content

Conversation

@ChALkeR
Copy link
Collaborator

@ChALkeR ChALkeR commented Nov 30, 2025

Considering this

On the downside, this consumes 64 KiB cache (and +64 KiB for base64url)

On the upside, this improves fallback perf from 5807 to 9576 on Hermes, beating atob() codepath used now (with 7308)
Also significantly improves browser fallbacks (but old browsers are not important)

Likely I'll abandon this due to 128 KiB cache being too large


if (nativeEncoder) {
if (!helpers.fromMap16) {
helpers.fromMap16 = new Uint16Array(_zz + 1) // Warning: 64 KiB
Copy link
Collaborator Author

@ChALkeR ChALkeR Dec 1, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

perhaps a holey array could help here instead
it reduces perf benefit but hermes still wins
need to check mem usage

@ChALkeR ChALkeR force-pushed the master branch 16 times, most recently from a5c78cc to ef95acb Compare December 8, 2025 02:10
@ChALkeR ChALkeR force-pushed the master branch 7 times, most recently from 67fc5e1 to 2d1cb34 Compare December 8, 2025 06:38
@ChALkeR ChALkeR force-pushed the main branch 2 times, most recently from 03b9ba5 to 69efd0c Compare January 22, 2026 06:44
@ChALkeR ChALkeR force-pushed the main branch 7 times, most recently from b2e260a to 9e30190 Compare February 2, 2026 23:09
@ChALkeR ChALkeR marked this pull request as ready for review February 2, 2026 23:41
@ChALkeR ChALkeR marked this pull request as draft February 2, 2026 23:41
@ChALkeR ChALkeR force-pushed the main branch 19 times, most recently from 49c94d8 to d76e939 Compare February 11, 2026 17:47
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

Successfully merging this pull request may close these issues.

1 participant