Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(364)

Issue 543043002: Implement fast path in UTF8ToUTF16 for pure ASCII strings (Closed)

Created:
6 years, 3 months ago by mnaganov (inactive)
Modified:
6 years, 2 months ago
CC:
chromium-reviews, erikwright+watch_chromium.org, jshin+watch_chromium.org, brettw, darin (slow to review)
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Implement fast path in UTF8ToUTF16 for pure ASCII strings Blink WebString::fromUTF8 are marginally faster than UTF8ToUTF16 on pure ASCII input because they have a fast path for this case. Implement the same thing for base::UTF8ToUTF16 DoIsStringASCII is now a port of charactersAreAllASCII from Blink. BUG=391492 R=brettw@chromium.org, torne@chromium.org Committed: https://crrev.com/6f500092b9396517a40fdf1ca6a5199738e673e9 Cr-Commit-Position: refs/heads/master@{#297158}

Patch Set 1 #

Total comments: 4

Patch Set 2 : Comments addressed, added unit test #

Patch Set 3 : Rebased #

Unified diffs Side-by-side diffs Delta from patch set Stats (+142 lines, -15 lines) Patch
M base/strings/string_util.h View 1 1 chunk +6 lines, -0 lines 0 comments Download
M base/strings/string_util.cc View 1 2 chunks +61 lines, -9 lines 0 comments Download
M base/strings/string_util_unittest.cc View 1 1 chunk +49 lines, -0 lines 0 comments Download
M base/strings/utf_string_conversions.cc View 1 2 chunks +26 lines, -6 lines 0 comments Download

Messages

Total messages: 27 (8 generated)
mnaganov (inactive)
Torne, can you please take a look?
6 years, 3 months ago (2014-09-05 12:22:35 UTC) #2
Torne
Code LGTM, but are we sure that the other callers of IsStringASCII expect it to ...
6 years, 3 months ago (2014-09-05 13:40:51 UTC) #3
mnaganov (inactive)
On 2014/09/05 13:40:51, Torne wrote: > Code LGTM, but are we sure that the other ...
6 years, 3 months ago (2014-09-05 14:29:38 UTC) #4
mnaganov (inactive)
Hi Brett, Can you please take a look at this change? Please see the related ...
6 years, 3 months ago (2014-09-05 14:32:10 UTC) #6
mnaganov (inactive)
On 2014/09/05 14:29:38, mnaganov (cr) wrote: > On 2014/09/05 13:40:51, Torne wrote: > > Code ...
6 years, 3 months ago (2014-09-05 14:35:08 UTC) #7
Torne
OK, seems reasonable to me too from a quick look through codesearch; most uses seem ...
6 years, 3 months ago (2014-09-05 14:42:55 UTC) #8
mnaganov (inactive)
brettw@: Brett, can you please take a look? git blame shows that you authored utf_string_conversions.cc ...
6 years, 3 months ago (2014-09-10 07:56:17 UTC) #9
mnaganov (inactive)
On 2014/09/10 07:56:17, mnaganov (cr) wrote: > brettw@: Brett, can you please take a look? ...
6 years, 3 months ago (2014-09-15 10:38:25 UTC) #10
brettw
I want to be sure to get unit tests for this showing it working for ...
6 years, 3 months ago (2014-09-16 17:14:28 UTC) #11
mnaganov (inactive)
Brett, thanks for your suggestions! I added a test covering various alignment cases. https://codereview.chromium.org/543043002/diff/1/base/strings/string_util.cc File ...
6 years, 3 months ago (2014-09-17 15:15:02 UTC) #12
mnaganov (inactive)
[+thakis, brettw to CC] Nico, can you please take a look at this, as Brett ...
6 years, 3 months ago (2014-09-22 09:38:17 UTC) #14
mnaganov (inactive)
[+darin, thakis to CC] Now, Nico is OOO. The situation is starting to look desperate. ...
6 years, 2 months ago (2014-09-26 08:04:49 UTC) #17
darin (slow to review)
Brett is the better reviewer for string utils.
6 years, 2 months ago (2014-09-26 17:45:13 UTC) #19
brettw
lgtm
6 years, 2 months ago (2014-09-26 17:47:26 UTC) #20
mnaganov (inactive)
Thanks, everyone!
6 years, 2 months ago (2014-09-29 09:28:40 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/543043002/40001
6 years, 2 months ago (2014-09-29 09:30:12 UTC) #23
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/14051)
6 years, 2 months ago (2014-09-29 09:37:54 UTC) #25
mnaganov (inactive)
Committed patchset #3 (id:40001) manually as 6f500092b9396517a40fdf1ca6a5199738e673e9 (presubmit successful).
6 years, 2 months ago (2014-09-29 12:03:04 UTC) #26
commit-bot: I haz the power
6 years, 2 months ago (2014-09-29 12:03:06 UTC) #27
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/6f500092b9396517a40fdf1ca6a5199738e673e9
Cr-Commit-Position: refs/heads/master@{#297158}

Powered by Google App Engine
This is Rietveld 408576698