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

Issue 2032943002: Avoid one temporary copy on web fonts decoding (Closed)

Created:
4 years, 6 months ago by bashi
Modified:
4 years, 6 months ago
CC:
ajuma+watch_chromium.org, blink-reviews, blink-reviews-platform-graphics_chromium.org, Rik, chromium-reviews, danakj+watch_chromium.org, dshwang, drott+blinkwatch_chromium.org, krit, f(malita), jbroman, Justin Novosad, pdr+graphicswatchlist_chromium.org, rwlbuis, Stephen Chennney
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Avoid one temporary copy on web fonts decoding Before this CL, we allocated a temporary SharedBuffer to store decoded font data. Since the decoded data is only used to create SkTypeface we don't need to have such abstraction. Create SkTypeface directly from the decoded data. This CL also renamed and moved platform/fonts/opentype/OpenTypeSanitizer to platform/fonts/WebFontDecoder for better naming. BUG=616969 Committed: https://crrev.com/f4e652e1603fdc1c59afc235261648cac4d3ba1e Cr-Commit-Position: refs/heads/master@{#397648}

Patch Set 1 #

Patch Set 2 : #

Total comments: 2

Patch Set 3 : #

Total comments: 2

Patch Set 4 : #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+129 lines, -359 lines) Patch
M third_party/WebKit/LayoutTests/TestExpectations View 1 2 3 1 chunk +2 lines, -0 lines 1 comment Download
M third_party/WebKit/Source/platform/blink_platform.gypi View 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/platform/fonts/FontCustomPlatformData.cpp View 1 2 chunks +7 lines, -20 lines 0 comments Download
A + third_party/WebKit/Source/platform/fonts/WebFontDecoder.h View 1 chunk +22 lines, -12 lines 0 comments Download
A + third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp View 1 2 3 2 chunks +96 lines, -68 lines 0 comments Download
D third_party/WebKit/Source/platform/fonts/opentype/OpenTypeSanitizer.h View 1 chunk +0 lines, -81 lines 0 comments Download
D third_party/WebKit/Source/platform/fonts/opentype/OpenTypeSanitizer.cpp View 1 chunk +0 lines, -176 lines 0 comments Download

Messages

Total messages: 25 (9 generated)
bashi
Sakamoto-san, PTAL? I don't expect this CL contributes to reduce memory consumption and/or performance improvement ...
4 years, 6 months ago (2016-06-02 04:54:07 UTC) #3
Kunihiko Sakamoto
lgtm https://codereview.chromium.org/2032943002/diff/20001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp File third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp (right): https://codereview.chromium.org/2032943002/diff/20001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp#newcode196 third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp:196: return nullptr; Not directly related to this CL, ...
4 years, 6 months ago (2016-06-02 05:50:34 UTC) #4
bashi
Thanks for review, sakamoto-san! eae@, could you do owner's review? https://codereview.chromium.org/2032943002/diff/20001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp File third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp (right): https://codereview.chromium.org/2032943002/diff/20001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp#newcode196 ...
4 years, 6 months ago (2016-06-02 07:22:27 UTC) #6
eae
LGTM https://codereview.chromium.org/2032943002/diff/40001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp File third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp (right): https://codereview.chromium.org/2032943002/diff/40001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp#newcode163 third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp:163: static const size_t maxWebFontSize = 30 * 1024 ...
4 years, 6 months ago (2016-06-02 14:51:18 UTC) #7
bashi
Thanks for review! https://codereview.chromium.org/2032943002/diff/40001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp File third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp (right): https://codereview.chromium.org/2032943002/diff/40001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp#newcode163 third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp:163: static const size_t maxWebFontSize = 30 ...
4 years, 6 months ago (2016-06-02 23:06:56 UTC) #8
eae
On 2016/06/02 23:06:56, bashi1 wrote: > Thanks for review! > > https://codereview.chromium.org/2032943002/diff/40001/third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp > File third_party/WebKit/Source/platform/fonts/WebFontDecoder.cpp ...
4 years, 6 months ago (2016-06-02 23:13:57 UTC) #9
bashi
On 2016/06/02 23:13:57, eae wrote: > On 2016/06/02 23:06:56, bashi1 wrote: > > Thanks for ...
4 years, 6 months ago (2016-06-03 00:33:19 UTC) #11
eae
On 2016/06/03 00:33:19, bashi1 wrote: > On 2016/06/02 23:13:57, eae wrote: > > On 2016/06/02 ...
4 years, 6 months ago (2016-06-03 00:37:37 UTC) #12
bashi
On 2016/06/03 00:37:37, eae wrote: > On 2016/06/03 00:33:19, bashi1 wrote: > > On 2016/06/02 ...
4 years, 6 months ago (2016-06-03 00:42:04 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2032943002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/2032943002/60001
4 years, 6 months ago (2016-06-03 06:35:25 UTC) #16
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 6 months ago (2016-06-03 06:39:46 UTC) #18
commit-bot: I haz the power
Patchset 4 (id:??) landed as https://crrev.com/f4e652e1603fdc1c59afc235261648cac4d3ba1e Cr-Commit-Position: refs/heads/master@{#397648}
4 years, 6 months ago (2016-06-03 06:41:24 UTC) #20
drott
https://codereview.chromium.org/2032943002/diff/60001/third_party/WebKit/LayoutTests/TestExpectations File third_party/WebKit/LayoutTests/TestExpectations (right): https://codereview.chromium.org/2032943002/diff/60001/third_party/WebKit/LayoutTests/TestExpectations#newcode1370 third_party/WebKit/LayoutTests/TestExpectations:1370: crbug.com/616969 fast/text/emoji-web-font.html [ NeedsRebaseline ] How is the emoji-web-font ...
4 years, 6 months ago (2016-06-07 09:01:47 UTC) #22
bashi
On 2016/06/07 09:01:47, drott wrote: > https://codereview.chromium.org/2032943002/diff/60001/third_party/WebKit/LayoutTests/TestExpectations > File third_party/WebKit/LayoutTests/TestExpectations (right): > > https://codereview.chromium.org/2032943002/diff/60001/third_party/WebKit/LayoutTests/TestExpectations#newcode1370 > ...
4 years, 6 months ago (2016-06-07 09:14:34 UTC) #23
drott
On 2016/06/07 at 09:14:34, bashi wrote: > On 2016/06/07 09:01:47, drott wrote: > > https://codereview.chromium.org/2032943002/diff/60001/third_party/WebKit/LayoutTests/TestExpectations ...
4 years, 6 months ago (2016-06-07 09:16:27 UTC) #24
bashi
4 years, 6 months ago (2016-06-07 09:23:55 UTC) #25
Message was sent while issue was closed.
On 2016/06/07 09:16:27, drott wrote:
> On 2016/06/07 at 09:14:34, bashi wrote:
> > On 2016/06/07 09:01:47, drott wrote:
> > >
>
https://codereview.chromium.org/2032943002/diff/60001/third_party/WebKit/Layo...
> > > File third_party/WebKit/LayoutTests/TestExpectations (right):
> > > 
> > >
>
https://codereview.chromium.org/2032943002/diff/60001/third_party/WebKit/Layo...
> > > third_party/WebKit/LayoutTests/TestExpectations:1370: crbug.com/616969
> > > fast/text/emoji-web-font.html [ NeedsRebaseline ]
> > > How is the emoji-web-font result affected?
> > 
> > In this CL I added a warning message when Skia failed to create SkTypeface.
> And the test has been failing for some reason (even before the CL is landed)
on
> some bots so I needed to rebaseline the expectations. There might be a bug but
I
> don't think this causes the regression.
> 
> I see, thanks. The different behavior on the bots might be differing versions
of
> Freetype?

Yeah, it's likely as I wasn't able to repro :(

Powered by Google App Engine
This is Rietveld 408576698