On Thu, Oct 9, 2014 at 12:21 PM, Henri Sivonen <hsivo...@hsivonen.fi> wrote:

> It would be even more tragic to miss the opportunity to use 8-bit code
> units for strings in Servo because JS crypto benchmarks use strings.
> What chances are there to retire the use of strings-for-crypto in
> benchmarking? Such a benchmark doesn't represent a reasonable real
> application. A reasonable real application would use the Web Crypto
> API to delegate crypto operations to outside the JS engine or use
> ArrayBuffers to perform byte-oriented operations inside the JS engine.
>

Absolutely, but there are outdated/crappy benchmarks like Sunspider that we
can't regress too much to avoid bad press.

Besides charAt/charCodeAt, what operations do you expect to be
> adversely affected by WTF-8 memory layout?
>

Operations like indexOf, replace, regular expressions matter a lot for
certain benchmarks. An ASCII-only bit would probably help most of those
benchmarks though...


> Considering all the work involved in making Servo into a engine
> suitable for browsing the Web, it seems to me that it would be fair to
> have this work on the todo list among everything else and accept
> non-optimized WTF-8 string object support into SpiderMonkey as a
> compile-time option for the time being.
>

Fair enough. I just want to make sure we are aware of the potential risks,
but I'd be happy to mentor this work or help out on the SpiderMonkey side
when it becomes a priority. It's a bit easier now after the Latin1 changes
but it's still a ton of work.

Jan
_______________________________________________
dev-servo mailing list
dev-servo@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-servo

Reply via email to