Created attachment 114306 [details] sample document with macro to reproduce - hit the Go ! button * use case a big file with 500 sheets and formulas in a macro, removing 250 sheets it takes around 330 seconds
callgrind stuff (13 Mb) available at http://oooconv.free.fr/tests/bug90199/callgrind.removeSheets.tar.gz have a look at callgrind.out.2686.3 ScDocument::DeleteTab
update callgrind.out.2686.3 is partial, only for 227 tab deletion but shows the involved areas
56,769 seconds on a Lenovo T520 from 2012 Dec. Win 7 Pro 64-bit, LibO Version: 4.4.1.2 Build ID: 45e2de17089c24a1fa810c8f975a7171ba4cd432 Locale: fi_FI
(In reply to Beluga from comment #3) > 56,769 seconds on a Lenovo T520 from 2012 Dec. So what are we thinking here? Is this a perf issue, or just a large task that takes a long time? Is the performance any better with older versions of LibreOffice? (e.g. is this a regression?) Status -> NEEDINFO
3.3.0 could not open fully, because number of sheets was exceeded. 3.6.7 completes in 33.666 seconds and this is in an Ubuntu virtual machine, so it seems we have a performance regression in our hands. 4.4.2 on the same Ubuntu VM takes 79.017 seconds. Ubuntu 14.10 64-bit Version: 4.4.2.2 Build ID: 40m0(Build:2) Locale: en_US Version 3.6.7.2 (Build ID: e183d5b)
reproducible with Version: 4.2.0.0.alpha1+
Migrating Whiteboard tags to Keywords: (perf, bibisectRequest)
Noel Grandin committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=60e67b387e79185a33eb07bc03b01cd6d0d0a56b fix O(n^2) in vcl event broadcasting tdf#90199 It will be available in 5.2.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.