Enable harfbuzz compiler optimizations |
|||
Issue descriptionExperiments with hb-shape show that enabling compiler optimizations improves performance of text shaping (therefore should help layout). Initial tests show an improvement of 10.4% in hindi-line-layout and 12.1% in latin-ebook performance layout tests.
,
Nov 7
Results in a Nexus 5x: https://pinpoint-dot-chromeperf.appspot.com/job/14b944a3e40000
,
Nov 7
Wikipedia page layout time in a Google Pixel shows around 6% performance gain in the time spent doing layout.
,
Nov 7
Impressive!
,
Nov 7
Even though the installed size of the library will be smaller: adenilson@chrome-monster:~/chromium/src/out/optimized$ ls -lha ./libfreetype_harfbuzz.cr.so -rwxr-xr-x 1 adenilson adenilson 853K Nov 6 12:08 ./libfreetype_harfbuzz.cr.so adenilson@chrome-monster:~/chromium/src/out/optimized$ ls -lha ./libfreetype_harfbuzz.cr.so -rwxr-xr-x 1 adenilson adenilson 740K Nov 6 14:41 ./libfreetype_harfbuzz.cr.so The entropy level of the binary libs is higher (i.e. more complex symbols added by the compiler), see the chart. Confirmed the theory that due to higher entropy, the compressed apk will be bigger (i.e. apks are gzipped compressed). adenilson@chrome-monster:~/chromium/src/out/optimized$ ls -lh opt_libfreetype_harfbuzz.cr.so.gz vanilla_libfreetype_harfbuzz.cr.so.gz -rwxr-xr-x 1 adenilson adenilson 433K Nov 7 14:38 opt_libfreetype_harfbuzz.cr.so.gz -rwxr-xr-x 1 adenilson adenilson 421K Nov 7 14:37 vanilla_libfreetype_harfbuzz.cr.so.gz
,
Nov 7
Therefore, the 12KB to 14KB size increase in the library is within the expected.
,
Nov 8
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/7dca8e135107aaadf73f83e2bd49feac120bd2c5 commit 7dca8e135107aaadf73f83e2bd49feac120bd2c5 Author: Adenilson Cavalcanti <adenilson.cavalcanti@arm.com> Date: Thu Nov 08 00:20:00 2018 Enable compiler optimizations on Harfbuzz Experiments with hb-shape show that enabling compiler optimizations improves performance of text shaping (therefore should help layout). Initial tests show an improvement of 10.4% in hindi-line-layout and 12.1% in latin-ebook performance layout tests. Binary-Size: compiler optimized library will increase the size of the apk. Bug: 902782 Change-Id: Iee50a04403ec634efec17be5ef8a72b996711a2f Reviewed-on: https://chromium-review.googlesource.com/c/1321250 Commit-Queue: Adenilson Cavalcanti <cavalcantii@chromium.org> Reviewed-by: Emil A Eklund <eae@chromium.org> Reviewed-by: Behdad Esfahbod <behdad@chromium.org> Reviewed-by: Dominik Röttsches <drott@chromium.org> Cr-Commit-Position: refs/heads/master@{#606240} [modify] https://crrev.com/7dca8e135107aaadf73f83e2bd49feac120bd2c5/third_party/harfbuzz-ng/BUILD.gn
,
Nov 8
In a rock64 ARM board (with low cost/power efficient little quad-cores A53), the performance boost for loading the C++ wikipedia page was 11%.
,
Nov 8
Thank you for working on this!
,
Nov 9
|
|||
►
Sign in to add a comment |
|||
Comment 1 by cbiesin...@chromium.org
, Nov 7Status: Assigned (was: Untriaged)