[webkit-reviews] review denied: [Bug 99392] Creating a String from an NSString should check for all 8 bit strings : [Attachment 168818] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Oct 15 20:23:24 PDT 2012


Darin Adler <darin at apple.com> has denied Michael Saboff <msaboff at apple.com>'s
request for review:
Bug 99392: Creating a String from an NSString should check for all 8 bit
strings
https://bugs.webkit.org/show_bug.cgi?id=99392

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

------- Additional Comments from Darin Adler <darin at apple.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=168818&action=review


Please look into putting the fast check for 8-bit characters in ASCIIFastPath.h
instead of here.

> Source/WTF/wtf/text/StringImpl.cpp:1579
> +#if CPU(X86_64)
> +bool containsOnly8BitCharacters(const UChar* characters, unsigned length)

This looks like code that should be in the ASCIIFastPath.h, rather than in this
source file. The same techniques used in charactersAreAllASCII are appropriate
and that function is even better optimized than this code, I believe.

With a bit of work we could probably make the code for charactersAreAllASCII
and charactersAreAll8Bit be generated from a single function template.


More information about the webkit-reviews mailing list