Created attachment 159039 [details] Test xlsx file Steps to reproduce: 1. Open the attached xlsx document. 2. Try to click to second sheet tab (to switch to that tab). --> Very slow switching to the 2nd tab. After successful switch, the soffice.bin process eats 3.6 GB of my RAM, while my system RAM is 8 GB. 3. After successfully switched to the second tab, try to click some cells. --> Very slow navigating between between cells. Reproduced in Version: 7.0.0.0.alpha0+ Build ID: f6f37e3341f2a3ad292af1a923dbc33d81e439c9 CPU threads: 4; OS: Linux 5.5; UI render: default; VCL: gtk3; Locale: zh-CN (zh_CN.UTF-8); UI-Language: en-US Calc: threaded And in 6.3.5.2 Fedora 31 64. Step 2 and 3 is fast in MSO running in my VirtalBox WinXP guest machine with only 1 GB total RAM.
This issue was originally reported on the LibreOffice Chinese discussion forum: https://bbs.libreofficechina.org/forum.php?mod=redirect&tid=2421
Opening the file there is a message that it exceeds the columns number limits. And file crash LibreOffice when I try to go to the second sheet.
Trying loading the document is already quite slow, more than (for a 480KB file on pc with Ryzen 2600 + 32GB) real 0m16,036s user 0m15,769s sys 0m1,313s + I got this warning: Warning loading document ...: The data could not be loaded completely because the maximum number of columns per sheet was exceeded.
Created attachment 159095 [details] perf flamegraph (when loading the file) Here's a Flamegraph retrieved on pc Debian x86-64 with master sources updated today. It corresponds to loading only. I'll attach another Flamegraph about the switching part.
Created attachment 159096 [details] Flamegraph (when switching sheet) I must say that I use gtk3 so with all accessibility mechanism which seems to slow down things.
Tab switching is not very slow for me and memory use does not explode. Kevin: please re-test Version: 7.2.0.0.alpha0+ (x64) / LibreOffice Community Build ID: 9c930c4f3109d123c0831d0fcecf9c8b32e5bbc7 CPU threads: 2; OS: Windows 10.0 Build 19042; UI render: default; VCL: win Locale: fi-FI (fi_FI); UI: en-US Calc: threaded
(In reply to Buovjaga from comment #6) Switching to the 2nd tab is still slow for me in Version: 7.3.4.2 / LibreOffice Community Build ID: 30(Build:2) CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3 Locale: zh-CN (zh_CN.UTF-8); UI: zh-CN Ubuntu package version: 1:7.3.4-0ubuntu0.22.04.1 Calc: threaded and Version: 7.4.0.0.beta1+ / LibreOffice Community Build ID: 6ea86593851c731e2e2b969e458255e4159c80d9 CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3 Locale: zh-CN (zh_CN.UTF-8); UI: zh-CN Calc: threaded
Dear Kevin Suo, To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year. There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present. If you have time, please do the following: Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/ If the bug is present, please leave a comment that includes the information from Help - About LibreOffice. If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice. Please DO NOT Update the version field Reply via email (please reply directly on the bug tracker) Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not appropriate in this case) If you want to do more to help you can test to see if your issue is a REGRESSION. To do so: 1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from https://downloadarchive.documentfoundation.org/libreoffice/old/ 2. Test your bug 3. Leave a comment with your results. 4a. If the bug was present with 3.3 - set version to 'inherited from OOo'; 4b. If the bug was not present in 3.3 - add 'regression' to keyword Feel free to come ask questions or to say hello in our QA chat: https://web.libera.chat/?settings=#libreoffice-qa Thank you for helping us make LibreOffice even better for everyone! Warm Regards, QA Team MassPing-UntouchedBug
Noel Grandin committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/ab4cf371eda16668b875dbd99950034b09d0dc4c use mutex before touching maBuffered2DDecomposition (tdf#131595 related) It will be available in 25.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Noel Grandin committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/303e5631f8119ef69c8ff515e7e47d4cf6ab74c6 use mutex before touching maBuffered2DDecomposition (tdf#131595 related) It will be available in 25.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Noel Grandin committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/e8e1c9cbd58c123cf37681ccff1c417e537a9272 fix deadlock in SystemDependentDataBuffer::flushAll (tdf#131595 related) It will be available in 25.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Noel Grandin committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/8a17b7f0a679ebf21bcfb425186b205d996d129b tdf#131595 Improve drawinglayer flushing mechanism. It will be available in 25.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
There's a slight delay when the switching involves the second tab, but I guess that's in line with commit 8a17b7f0a679ebf21bcfb425186b205d996d129b Quoting a comment: This is a "garbage collection" approach to flushing. We store entries in a set. Every 2 seconds, we scan the set for entries that have not been used for 10 seconds or more, and if so, we flush the buffer primitives in those entries. This mechanism is __deliberately__ not perfect. Sometimes things will be flushed a little too soon, sometimes things will wait a little too long, since we only have a granularity of 2 seconds. But what is gains from not being perfect, is scalability. It is very simple, scales to lots and lots of primitives without needing lots of timers, and performs very little work in the common case.