Created attachment 114133 [details] sample document with macro to reproduce * context - a "big file" containing 500 sheets, 300 formulas per sheet, 15k named ranges - a macro loops over namedranges, modifie the value of each one and copy 3 new cells per row * result such an heavy process has become very slow. it now takes around 1400 seconds to process first analysis using callgrind leads to +80% of time spent in http://opengrok.libreoffice.org/xref/core/sc/source/core/data/document.cxx#3229 that lead to looping over sheets/columns/cells each time http://opengrok.libreoffice.org/xref/core/sc/source/core/data/column3.cxx#1582 a more refined callgrind trace to come ... * attachment the sample document. Hit the the "Go !" button and say ok to the warnbong that th eprocess may take some time The duration is givent at the end of the process (in second) do not forget to enable macros before opening
partial but significant callgrind output http://oooconv.free.fr/tests/bug90042/callgrind.setStringBigDoc.tar.gz document SetString call is pointed mainly called from lcl_PutDataArray
Laurent Godard committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=c79bdd062f657d1be98aa815d9b882d144f35e04 tdf#90042 only handle formula group if useful It will be available in 4.5.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.
Eike Rathke committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=02bea75dd6bc91759e987fafb5dccec6ce92b0c2 only handle formula group if useful, tdf#90042 related It will be available in 4.5.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.
Pending review at https://gerrit.libreoffice.org/15036 for 4-4
Laurent Godard committed a patch related to this issue. It has been pushed to "libreoffice-4-4": http://cgit.freedesktop.org/libreoffice/core/commit/?id=7042961f4d3e383c04f792a60e96d909b7e44363&h=libreoffice-4-4 tdf#90042 only handle formula group if useful It will be available in 4.4.3. 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.
with the patch, time is around 200 seconds, divided by 7