Bug 109045 - Calendar is loaded several times during loading of pivot table
Summary: Calendar is loaded several times during loading of pivot table
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.0.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Aron Budea
URL:
Whiteboard: target:6.0.0 target:5.4.0
Keywords: perf
Depends on:
Blocks:
 
Reported: 2017-07-10 02:09 UTC by Aron Budea
Modified: 2017-07-18 09:48 UTC (History)
0 users

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Aron Budea 2017-07-10 02:09:58 UTC
This is related to bug 107945, and one issue is that in the following code path, locale is set to en-US, and this alternates with code using regular locale:
ScDPCache::GetLocaleIndependentFormat(...)
http://opengrok.libreoffice.org/xref/core/sc/source/core/data/dpcache.cxx#1197

When there's a switch between program's and en-US locale, the calendar is loaded again and again (if the program locale is not en-US), and for large tables the performance impact can be noticeable.

The issue is that class OnDemandCalendarWrapper doesn't have the same kind of separate buffer for English locale that the similar OnDemandLocaleDataWrapper class has.
See both: http://opengrok.libreoffice.org/xref/core/include/svl/ondemand.hxx
Comment 1 Commit Notification 2017-07-11 12:01:59 UTC
Aron Budea committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=2a22696546ace75c38a72ad13f7383aedd00e06a

tdf#109045: store en calendar separately in OnDemandCalendarWrapper

It will be available in 6.0.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 2 Aron Budea 2017-07-11 14:41:40 UTC
That should do it. Cherry-pick to 5.4 is in progress.
Thanks, Noel!
Comment 3 Michael Meeks 2017-07-11 16:05:11 UTC
Nice work Aron - thanks ! =)
Comment 4 Commit Notification 2017-07-17 19:42:21 UTC
Aron Budea committed a patch related to this issue.
It has been pushed to "libreoffice-5-4":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=c0d9b6f6fb4a39e197297fcb16373d631881e419&h=libreoffice-5-4

tdf#109045: store en calendar separately in OnDemandCalendarWrapper

It will be available in 5.4.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 5 Commit Notification 2017-07-17 20:02:36 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=21394b08475d1d869aa62c1dbb46c3dcc93ae3f0

Defer also loading of the English CalendarWrapper, tdf#109045 follow-up

It will be available in 6.0.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 6 Commit Notification 2017-07-18 06:46:45 UTC
Aron Budea committed a patch related to this issue.
It has been pushed to "libreoffice-5-4-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=6c1a83147c60b999decf12307d2d4313382702ee&h=libreoffice-5-4-0

tdf#109045: store en calendar separately in OnDemandCalendarWrapper

It will be available in 5.4.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Commit Notification 2017-07-18 08:37:45 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-4":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=edc2ba3bddf2d9a4c72a4ca90579c66f229a6a47&h=libreoffice-5-4

Defer also loading of the English CalendarWrapper, tdf#109045 follow-up

It will be available in 5.4.1.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 8 Commit Notification 2017-07-18 09:17:47 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "libreoffice-5-4-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=ee052d7fb032c2b571cdb825d4e73a3715790ef0&h=libreoffice-5-4-0

Defer also loading of the English CalendarWrapper, tdf#109045 follow-up

It will be available in 5.4.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.