Bug 113090 - CPU usage when typing (holding a key) has increased with 2% between LibO5.0 and LibO6
Summary: CPU usage when typing (holding a key) has increased with 2% between LibO5.0 a...
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
(earliest affected) release
Hardware: All All
: medium normal
Assignee: Not Assigned
Keywords: bibisected, perf, regression
Depends on:
Blocks: VCL-Scheduler DirectWrite-Regression
  Show dependency treegraph
Reported: 2017-10-13 09:12 UTC by Telesto
Modified: 2017-10-18 11:42 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:

Bibisect log (5.18 KB, text/plain)
2017-10-13 09:14 UTC, Telesto

Note You need to log in before you can comment on or make changes to this bug.
Description Telesto 2017-10-13 09:12:16 UTC
Not sure if this quality's as a bug, because it's a artificial approach. However, there is a negative trend developing.

Some stats for holding the 'a' key for 5 rows
LibO6     -> 4,5%
LibO 5.4. -> 4.5%
LibO5.3.0 -> 3.7%
LibO5.2.5 -> 2,93%
LibO5.0   -> 1,83%

Steps to Reproduce:
1. Open Writer
2. Disable Spell Checking
3. Hold the 'a' key for 5 rows

Actual Results:  
The CPU usage is increasing with nearly every major version

Expected Results:
Back to pre-5.0

Reproducible: Always

User Profile Reset: No

Additional Info:
Found in:
Build ID: c5a93cad149618bbd43632f1660a558c34bdbf7e
CPU threads: 4; OS: Windows 6.3; UI render: default; 
TinderBox: Win-x86@42, Branch:master, Time: 2017-10-07_01:04:25
Locale: nl-NL (nl_NL); Calc: CL

User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:52.0) Gecko/20100101 Firefox/52.0
Comment 1 Telesto 2017-10-13 09:14:33 UTC
Created attachment 136946 [details]
Bibisect log

I have bibisected the 1% bump between LibO4.4.8.2 and LibO5 to the following range:

$ git bisect bad 3f4cc8db52a676c8bb37ebcf9996e73ef3240f0d is the first bad commit
commit 3f4cc8db52a676c8bb37ebcf9996e73ef3240f0d
Author: Norbert Thiebaud <nthiebaud@gmail.com>
Date:   Mon May 25 22:26:52 2015 -0500

    source 9b4abcd1c45a646a1ac9120fe1c489ba6bb44e95

    source 9b4abcd1c45a646a1ac9120fe1c489ba6bb44e95
    source acaafc03e623ac25d4408605f34d50618926c5d0
    source 567f51192483059ec57c16a6045141746d4b01f9
    source ef6f2490a697e7c23fea40c567f751db05f1bbbf
    source 2c0189a8a3aeb3668bf6de1ea1958ba475b80a38
    source 3da65dc8982167517f19e80a288b049118bc3d23
    source 2a0b6705724c4ea65b56eb0f45bccfa253d9fdc2
    source 59619dbe971852d5cd35dcc3f78eda9bebeb99aa
    source e7c2b4b981b9b43c31fa442d5596b7a765dbe699
    source 6f4dc6af39ecf2f90155205ad097601a8b2f602c
    source ca3700c42238e71684ec1d5f5eacaea4b1ca3b30
    source 8da61f23384c7f3f2850a6362765506e4e078862
    source d05a64df34fd143670cb939b72abfb32d6b714c7
    source 01f406bc28f53acc5a2734af637aa8074a5d1813
    source b6bb2e9315c9bc3338eaf066df40a969eb4774aa
    source d851e1e3c29afd3315cc763144c6eb92fbef5054
    source 7e2a0df7e7b4551698d1d7172ef12ad1e0fd8826
    source b11dba5be288ca5aaed1403093033708f7091c42
    source 49439d4a67b06227e56a2855c856e3482323a28a
    source ff52f4e417eb4de5e85388a48a650429b1880762
    source d411dca1ea6bfccb7090d4ceab15119253cac5bf
    source f384496d125255a94bfd5978e0cbe44d6d046adb
    source f33d6800fbdc42aa75477e31be0bba5a4a5a52c1
    source 8f9b0c869222e57f738bc25d51cc6364e3c6a65a
    source 00717355c2d10bacbae46941b82247d74fd89108
    source 2d95bc0510d43c11bb3bd03f590e24ba3d7ca30f
    source ddd4a787ebde1b47e5ddfbd5995e2a0fe6b22ee2
    source 0e10b34342bd7b94b69f2eac8c9b1df89a2725f3
    source b380220bc1404ed5a9daa1a28f70696e84543f61
    source 5bd1106c3758c8cb0c19b09799970440501fde02
    source 3f64e7c16a63fdc330e108cd74182c615d229bb6
    source 4c3cea26b84cc70a67ff4eda99b842d8786a3628
    source 256c5c3f28ef70b70d38e2e07dfca4baab654612
    source 57656eb1fae5ae6c4d3b7542a385a93ff434e4e7
    source 49524c6dcf04b9dadef8d2b084cf26abcf70b8a9
    source 826143684d2697a8620373dce18fa5f24332d5cb
    source d8305248f687ffa522b56955508d82d60ad5b8c6
    source a74efa665c8199899cd778900de686e2b8710fee
    source e6e8a060ecc6e4fd51cfe88e00d841d546ed5915

:040000 040000 ad77b1a03396af9c8460d94e13cf1c28e5bf54bc dbf71bf6a72509169933f08eb57842c37a266627 M      instdir
Comment 2 Telesto 2017-10-13 09:19:43 UTC
The 0,8% bump between LibO5.3 and LibO5.4 started with:
author	Khaled Hosny <khaledhosny@eglug.org>	2017-03-03 03:15:14 (GMT)
committer	Khaled Hosny <khaledhosny@eglug.org>	2017-03-03 13:22:53 (GMT)
commit a51b7a1c3a7e7cf7b0c733e1dec40288278c1884 (patch)
tree 6452088195b6c0ad617e7a6b9f97ecc8672d321e
parent 5742868ccf030b2c0f03538d030bd18bd5666bdb (diff)
tdf#103831, tdf#100986: Force using GDI when needed
Our DirectWrite renderer is incomplete and can’t handle rotated text or text
with horizontal scaling, so route these two through GDI for now.

However the problem still exits in the most recent builds (with this commit). So the cause has changed, with similar results. Could it be a scheduler change?
Comment 3 Xisco Faulí 2017-10-18 10:50:41 UTC
It should be better after d05a64df34fd143670cb939b72abfb32d6b714c7.
Comment 4 Xisco Faulí 2017-10-18 11:31:56 UTC
OTOH, I don't consider an increase of 2% really a bug...