Bug 129845 - vcl: system caching more expensive than not
Summary: vcl: system caching more expensive than not
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: graphics stack (show other bugs)
Version:
(earliest affected)
6.4.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:7.0.0
Keywords:
Depends on:
Blocks:
 
Reported: 2020-01-06 21:40 UTC by Michael Meeks
Modified: 2020-01-23 21:16 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
profile flamegraph fragment (22.02 KB, image/png)
2020-01-06 21:47 UTC, Michael Meeks
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Meeks 2020-01-06 21:40:10 UTC
The cost of getSystemDependentData tracking for trivial polylines and polygons is horribly expensive. Interestingly - the more of it we do, the worse the cost - since the data stacks up in the background.

I have a patch to avoid blowing this up for headless/ which is particularly important for Android - will attach a profile shot.

From the commit msg:

Interestingly the cache map lookup is rather expensive; why:

polyline output for some trivial impress edits:
        count   # of polylines
        2       2134
        3       141
        4       41
        9       4

polypolygon output for some trivial impress edits:

        count   # of polypolygons       geometry.
        3       54    all single polygon
        4       583   ~all single
        9       52    ~ all paired with a 4 node polygon
        13      2     both single
        32      22    all single
Comment 1 Michael Meeks 2020-01-06 21:40:48 UTC
https://gerrit.libreoffice.org/c/core/+/86313
Comment 2 Michael Meeks 2020-01-06 21:47:27 UTC
Created attachment 156973 [details]
profile flamegraph fragment
Comment 3 Michael Meeks 2020-01-06 21:54:45 UTC
For master:

https://gerrit.libreoffice.org/c/core/+/86314
tdf#129845 vcl: avoid expensive system caching of trivial lines & polygons
Comment 4 Commit Notification 2020-01-07 09:06:41 UTC
Michael Meeks committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/cebeafbf0f9efde6e17604cf2557b8490e7f5347

tdf#129845 vcl: avoid expensive system caching of trivial lines & polygons

It will be available in 6.5.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.
Comment 5 Commit Notification 2020-01-23 16:50:20 UTC
Armin Le Grand committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/2da7a82f6b7a78e1e4b34b0b3c7a27d2b3c47a35

tdf#129845: Better solution using already existing info

It will be available in 6.5.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.