You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Avoid repeated branches while iterating StringView
Summary:
`quoteStringForJSON` was operating via indexed access on `StringView`,
performing an `isASCII()` check every iteration and leading to slow
quoting during `JSON.stringify`.
Modify the function to take `UTF16Ref` or `ASCIIRef` directly,
so that it knows the type.
This increases code size slightly while resulting in significant
speedups in `JSON.stringify`.
Reviewed By: neildhar
Differential Revision: D46117526
fbshipit-source-id: e6b849fc8b4e2e748e05d277e36462b8d97ae095
0 commit comments