officecfg/registry/schema/org/openoffice/Office/Common.xcs | 2 - sc/qa/unit/subsequent_export_test2.cxx | 14 ++++++++++--- 2 files changed, 12 insertions(+), 4 deletions(-)
New commits: commit 1fe08ae6b383c2222178a21c926480a055a87f99 Author: Noel Grandin <noel.gran...@collabora.co.uk> AuthorDate: Fri May 6 18:46:27 2022 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Sat May 7 08:10:49 2022 +0200 tdf#121740 increase DrawingEngine::OLE_Objects cache limit shaves 5% off the load time for me Change-Id: Ia0ed8caa9300bfe5bcf71cfe844b8c4fdaf0fef6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133962 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/officecfg/registry/schema/org/openoffice/Office/Common.xcs b/officecfg/registry/schema/org/openoffice/Office/Common.xcs index 16d069ffd93a..73b1acbe871d 100644 --- a/officecfg/registry/schema/org/openoffice/Office/Common.xcs +++ b/officecfg/registry/schema/org/openoffice/Office/Common.xcs @@ -1499,7 +1499,7 @@ page through the objects since they do not always need to be loaded from the hard drive.</desc> </info> - <value>20</value> + <value>200</value> </prop> </group> <group oor:name="Writer"> diff --git a/sc/qa/unit/subsequent_export_test2.cxx b/sc/qa/unit/subsequent_export_test2.cxx index 77b8858fcd97..fa55acdf5160 100644 --- a/sc/qa/unit/subsequent_export_test2.cxx +++ b/sc/qa/unit/subsequent_export_test2.cxx @@ -2696,9 +2696,17 @@ void ScExportTest2::testHyperlinkLocationXLSX() void ScExportTest2::testTdf142264ManyChartsToXLSX() { // The cache size for the test should be small enough, to make sure that some charts get - // unloaded in the process, and then loaded on demand properly (default is currently 20) - CPPUNIT_ASSERT_LESS(sal_Int32(40), - officecfg::Office::Common::Cache::DrawingEngine::OLE_Objects::get()); + // unloaded in the process, and then loaded on demand properly (default is currently 200) + comphelper::ScopeGuard g([]() { + std::shared_ptr<comphelper::ConfigurationChanges> pBatch( + comphelper::ConfigurationChanges::create()); + officecfg::Office::Common::Cache::DrawingEngine::OLE_Objects::set(200, pBatch); + return pBatch->commit(); + }); + std::shared_ptr<comphelper::ConfigurationChanges> pBatch( + comphelper::ConfigurationChanges::create()); + officecfg::Office::Common::Cache::DrawingEngine::OLE_Objects::set(20, pBatch); + pBatch->commit(); ScDocShellRef xDocSh = loadDoc(u"many_charts.", FORMAT_ODS); xDocSh = saveAndReload(*xDocSh, FORMAT_XLSX);