Description: Fileopen ODT: Slow file opening (since 6.2) Steps to Reproduce: 1. Open the attached file Actual Results: 10 seconds unresponsive Expected Results: 2 seconds Reproducible: Always User Profile Reset: No Additional Info: Version: 6.2.0.0.alpha0+ Build ID: d5a2202f955657e427670a87c2d4e5638884517b CPU threads: 4; OS: Windows 6.3; UI render: default; TinderBox: Win-x86@42, Branch:master, Time: 2018-09-12_02:38:23 Locale: en-US (nl_NL); Calc: CL
Created attachment 144815 [details] Example file
Created attachment 144816 [details] Bibisect log Bisected to author Miklos Vajna <vmiklos@collabora.co.uk> 2018-08-31 18:19:12 +0200 committer Miklos Vajna <vmiklos@collabora.co.uk> 2018-09-03 09:13:32 +0200 commit aeff83240c88435d11590f5e9c6fe9927a508c6a (patch) tree a3b918a7d3164ee428a4df39df7118a87618dfd9 parent 08b5048198d59441cb8033ed14cd17e68c943004 (diff) sw: save more vcl layout calls in SwFntObj This builds on top of commit 436b829f5b904d76039db0818cff5dedf1ae89f1 (sw: save one vcl layout call in SwFntObj::DrawText(), 2018-08-16), but now layouts are shared not only inside SwFntObj::DrawText(), but also between SwFntObj::GetTextSize() and SwFntObj::DrawText(). To get there, create an SwFntObj cache member that stores already calculated vcl layouts. SwFntObj already derives from SwCacheObj, so no need to explicitly expire this cache member. Total number of GenericSalLayout::LayoutText() invocations go down from 8 to 5 with this when pressing a key in Writer.
Scrolling performance regressed to.
So, it seems the performance regression at import time has been introduced in two different commits. it changed from real 0m6.311s user 0m5.801s sys 0m0.422s to real 0m10.751s user 0m10.275s sys 0m0.402s in https://cgit.freedesktop.org/libreoffice/core/commit/?id=aeff83240c88435d11590f5e9c6fe9927a508c6a and later to real 0m19.050s user 0m18.575s sys 0m0.325s in https://cgit.freedesktop.org/libreoffice/core/commit/?id=2a73c9e04ba9379c0561a7e8d531b5633c46ec52 use time OOO_EXIT_POST_STARTUP=1 for the measuring Adding Cc: to Miklos Vajna
Thanks for the quick feedback!
Miklos Vajna committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=570f3c12fdb9db523cdef15c7a03cff82bd8ec15 tdf#119820 sw: optimize SwTextGlyphsKey comparison It will be available in 6.2.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Opening time back to normal real 0m7.111s user 0m6.813s sys 0m0.248s in Version: 6.2.0.0.alpha0+ Build ID: 47a173edb603538521a035157efb6ef684238087 CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; Locale: ca-ES (ca_ES.UTF-8); Calc: threaded @Miklos, Thanks for the quick fix!