[webkit-reviews] review granted: [Bug 53898] Add built-in decoder for UTF-8 for improved performance : [Attachment 81443] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Feb 7 03:59:01 PST 2011


Antti Koivisto <koivisto at iki.fi> has granted Darin Adler <darin at apple.com>'s
request for review:
Bug 53898: Add built-in decoder for UTF-8 for improved performance
https://bugs.webkit.org/show_bug.cgi?id=53898

Attachment 81443: Patch
https://bugs.webkit.org/attachment.cgi?id=81443&action=review

------- Additional Comments from Antti Koivisto <koivisto at iki.fi>
View in context: https://bugs.webkit.org/attachment.cgi?id=81443&action=review

Very nice, r=me.

It certainly looks fast. Did you measure the performance against ICU?

> Source/WebCore/platform/text/TextCodecUTF8.cpp:155
> +    const uint8_t* alignedEnd = reinterpret_cast<const
uint8_t*>(reinterpret_cast<uintptr_t>(end) & ~(sizeof(uintptr_t) - 1));

This would be less magical as inline function.

> Source/WebCore/platform/text/TextCodecUTF8.cpp:183
> +	       if (!(reinterpret_cast<uintptr_t>(source) & (sizeof(uintptr_t) -
1))) {

As would this.


More information about the webkit-reviews mailing list