[Libreoffice-bugs] [Bug 114251] Hang loading spreadsheet

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Sat Dec 16 13:03:23 UTC 2017


https://bugs.documentfoundation.org/show_bug.cgi?id=114251

Eike Rathke <erack at redhat.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|medium                      |high
                 CC|                            |erack at redhat.com
           Severity|normal                      |major

--- Comment #3 from Eike Rathke <erack at redhat.com> ---
It hangs when threading is enabled, it "only" is slow when threading is
disabled.

Also, any input on sheet COST leads to a waiting time. The conditional
formatting is executed every time after input for each cell where it is applied
and that is visible (plus an extra row which unfortunately hits here because
the window freeze is just above the first row with a conditional format).

The slowness is gone if the commit mentioned above is "undone" by just
returning 1 in ScFormulaCell::GetWeight() as a test, thus not triggering a
group calculation as it is smaller than mnOpenCLMinimumFormulaGroupSize. In
this case, adding messages to the FormulaLogger (e.g,
aScope.addGroupSizeThresholdMessage() that even calls GetWeight() again) for
each cell a group was not executed is suboptimal..

The slowness is also related to the fact that each group is only 2 cells (rows
8 and 9) in each column and doing all group related setup and gathering values
is much more overhead than just calculating the cells.

The worst part then is the SoftwareInterpreter nonsense because it has no clue
about the semantics of ranges and implicit intersections (which this document
heavily uses) and the implications of arrays, and blindly replaces every range
encountered with an array, forcing calculations to array mode where they should
not, e.g. matrix divisions of entire columns just to pick one result element
and throw a million away.

Certainly the weight gathering should be reworked to not hit the threshold for
just a very few cells.

Even more necessarily the SoftwareInterpreterFunc::operator() needs to be
taught when to replace a range with an array and when not.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20171216/e01c7888/attachment.html>


More information about the Libreoffice-bugs mailing list