Description: We have received a bug report via our Twitter account @LibreOfficeFR. One of our users, being diabetic, has been noting in a XLS spreadsheet all the aliments he has been eating for a bunch of years now. The document has two sheets and each of them has quite a bunch of rows. Most of the row has direct formatted content and some of them even have conditional formatting rules. While the document loads rapidly on Office, the user complained it was taking a huge time to open on LibreOffice. We have been able to reproduce the issue. While the document loads in instant on Excel (tested with latest Office 365 version), the document opens in about 1m30 on my machine with LibreOffice. The user is still making use of Office 2000. We first thought the issue was due to that old version, but the document is nearly identical when saving from Office 365. The issue is not due to the XLS format either. Converting the document to ods has still the same issue. The same applies if we copy paste the content of each sheet to a brand new document and save to ods directly instead of proceeding to a xls -> ods convertion from an existing XLS file. By removing the direct formatting (by using Ctrl+M), the opening process is shorter of 20 seconds. Arnaud Versini has begun to bisect the issue with cachegrind, and we realized a method calling C++ Vector is being called a lot of time (the hole list being scanned over and over again at each iteration). This is a good start to search of possible optimizations. Joined to this bug report is the XLS file (original file). We are also providing a ods conversion where direct formatting has been removed. Steps to Reproduce: 1. Simpy open the document and see for yourselves. 2. 3. Actual Results: Pretty slow to load Expected Results: Nearly instant loading. Reproducible: Always User Profile Reset: Yes Additional Info:
Created attachment 147463 [details] Original Excel file
Created attachment 147464 [details] Ods conversion without direct formatting
Created attachment 147465 [details] Cachegrind screenshot
(In reply to William Gathoye from comment #0) > We have been able to reproduce the issue. While the document loads in > instant on Excel (tested with latest Office 365 version), the document opens > in about 1m30 on my machine with LibreOffice. i can not confirm a huge delay with Version: 6.1.4.1 (x64) Build-ID: 25073d18caee244880112e52c4a7e71f6081b3a9 CPU-Threads: 4; BS: Windows 10.0; UI-Render: Standard; Gebietsschema: de-DE (de_DE); Calc: Win10 Pro x64, Core i5-3320 2,6 GHZ, 8GB, 256 GB SSD attached *.xls loads (including recalc) within 18 seconds, *.ods takes about 30 seconds. what i noticed: the file has a reference to an external file
Hmm, so opens in about ~3sec to protected view on Excel 2016 On LibreOffice delay is noticeable... On a robust Xeon (E3-1270 @3.50Ghz) / 32GB Windows 10 64-bit en-US (1803) workstation: fully opening in about ~14sec on LibreOffice Version: 6.1.3.2 (x64) Build ID: 86daf60bf00efa86ad547e59e09d6bb77c699acb CPU threads: 8; OS: Windows 10.0; UI render: default (or GL); Locale: en-US (en_US); Calc: CL and about the same ~14sec on LibreOffice master Version: 6.3.0.0.alpha0+ (x64) Build ID: 34d5e910adba4094bba1303284f9552028d0b019 CPU threads: 8; OS: Windows 10.0; UI render: GL (or default); VCL: win; TinderBox: Win-x86_64@42, Branch:master, Time: 2018-12-11_02:09:16 Locale: en-US (en_US); UI-Language: en-US Calc: CL
Major part of the problem seems to be that we insert in a std::vector at random places and this makes a lot of std::unique_ptr move.
it takes 16 seconds in Version: 6.3.0.0.alpha0+ Build ID: e98bcfcc3cdad46620e3d59119b0ac262db88054 CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US Calc: threaded
In Version: 4.4.0.0.alpha2+ Build ID: b21df5a993a3815cf736fe3d2eab73eee646b38e it takes 30 seconds, so the import time has been reduced to half since then.... Since it's 16 seconds on master, which is quite acceptable IMHO, i'll decrease the severity...
Dear William Gathoye, 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://kiwiirc.com/nextclient/irc.freenode.net/#libreoffice-qa Thank you for helping us make LibreOffice even better for everyone! Warm Regards, QA Team MassPing-UntouchedBug
it took 14 sec in Version: 7.3.0.0.alpha0+ (x64) / LibreOffice Community Build ID: 23f17b7ea6fbd2f422c7e40192ae60e4df25224c CPU threads: 4; OS: Windows 10.0 Build 19043; UI render: default; VCL: win Locale: ru-RU (ru_RU); UI: en-US Calc: threaded Julien, could you please create a perfgraph for XLS opening process here?
Created attachment 174991 [details] perf flamegraph Here's a Flamegraph retrieved on pc Debian x86-64 with master sources updated today (38afbf56f0783d7442e63b58ffae9cf111c04edf) + gen rendering.
Noel, here is an else one perf problem in Calc, could you please look at it? Thank you
*** This bug has been marked as a duplicate of bug 81765 ***