When opening some files created by MSO, Libreoffice shows a page for a few moments and after that hangs for a while, and after that initial hang starts showing file normally, although it may work slow when editing such file. Exact hangup time depends on hardware, used interface type and file, but it may last from approximately 30 seconds to dozens of minutes.
To reproduce issue I've created an MSO document and copied a table with a few columns and a lot of rows, and for first column I've merged approximately every 3 rows, after that I've saved document as ODT. Opening such file reproduces issue for me.
Build ID: ac854a4ccfcdcd75e93fbf629b6191821099b0a3
CPU threads: 12; OS: Linux 5.0; UI render: default; VCL: kde5;
Locale: en-US (C); UI-Language: en-US
Created attachment 151234 [details]
A file with 5 pages of table rows. Hangs for approximately 30-60 seconds for me.
Created attachment 151235 [details]
File with 10 pages of table rows, hangs for approximately 2-5 minutes for me.
Created attachment 151236 [details]
File with over 20 pages of table rows, hangs for more than 10 minutes for me.
I've tested it with releases 22.214.171.124, 126.96.36.199 and 188.8.131.52-master, and it happens for all of them. I didn't test earlier releases.
Build ID: 91b2239783dc716bd71ce7962bfd7e341dfe4175
CPU threads: 4; OS: Windows 6.3; UI render: default; VCL: win;
TinderBox: Win-x86@42, Branch:master, Time: 2019-05-08_09:49:32
Locale: nl-NL (nl_NL); UI-Language: en-US
nearly instant opening with
Build ID: f3153a8b245191196a4b6b9abd1d0da16eead600
Created attachment 151248 [details]
On pc Debian x86-64 with master sources updated today and enable-symbols (not enable-dbgutil), the first file doesn't even open after several minutes (Ryzen 2600 + RAM 32 Go)
It looks like it works fine with LO 184.108.40.206 but hangs with LO 220.127.116.11.
Thank you Aleksei for these info.
Let's put earliest version to 18.104.22.168 then.
I've ran bisect and this is my result:
8a800eea613c0f5ad3302136766791dc58880fb3 is the first bad commit
tdf#104425 sw: split rows w/large min height (fix layout loop)
I've confirmed that if I revert this change on current master (there are some revert conflicts which needed to be resolved), attached files are opened almost instantly now, while it took minutes and tens of minutes before.
I guess reverting this change for LO might be not an option, but at least adding a configuration option allowing to choose between correct table formatting and fast table formatting might be a good idea, unless performance can be fixed for current implementation. I didn't look into performance issue in this change yet.
Adding Cc: to Mike Kaganski
Any news on this issue?
(In reply to Aleksei Nikiforov from comment #11)
> Any news on this issue?
You can retest the bug with LO 6.4.1 but no info since there was no comment.
An idea would be to add a flag to the follow row frame indicating that it should not look back for the total row height before when the current height is greater than minimal ... or even not the flag, but simply the "previous height" to avoid looking back at all?
Created attachment 158650 [details]
(In reply to Julien Nabet from comment #12)
> You can retest the bug with LO 6.4.1 but no info since there was no comment.
I've built from sources and tried following version:
Build ID: c92dba0b4728c0ec26c4b83e2c0fbf3284425375
CPU threads: 12; OS: Linux 5.5; UI render: default; VCL: kf5;
Locale: en-US (C); UI-Language: en-US
LO opens example files pretty fast, even larger ones. But on large examle even while it doesn't hangs for long time after opening file anymore, it still hangs for a bit and LO works pretty slow, constantly consuming 100% CPU according to 'top'.
I've tried replacing every word 'text' with phrase 'longer string with some spaces' to see if it'd make LO work slower. Not sure about result, I guess it might work a bit slower. I'm attaching resulting file.
(In reply to Mike Kaganski from comment #13)
> An idea would be to add a flag to the follow row frame indicating that it
> should not look back for the total row height before when the current height
> is greater than minimal ... or even not the flag, but simply the "previous
> height" to avoid looking back at all?
Caching results of size and position calculations might help. But in that case events affecting either size of position should invalidate such caches at least partially.
(In reply to Aleksei Nikiforov from comment #14)
> LO opens example files pretty fast, even larger ones. But on large examle
> even while it doesn't hangs for long time after opening file anymore, it
> still hangs for a bit and LO works pretty slow, constantly consuming 100%
> CPU according to 'top'.
I'll try to retrieve a new Flamegraph with your last attachment.
Created attachment 158658 [details]
Here's a Flamegraph retrieved on pc Debian x86-64 with master sources updated today.