[intl] Speed up String.prototype.localCompare via compareUTF8
The localeCompare for ASCII chars needs to expand the string contents from one-byte representation into two-byte representation, which requires memory copy. This CL skips the representation conversion by using compareUTF8. It can improve the JetStream2 cdjs case by 21% on my machine. Change-Id: I3841dc700e36744aadd9a1ff9fa7d93c84dc04fd Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1624705 Commit-Queue: Jakob Kummerow <jkummerow@chromium.org> Reviewed-by: Jakob Kummerow <jkummerow@chromium.org> Cr-Commit-Position: refs/heads/master@{#62408}
Showing
Please
register
or
sign in
to comment