[Libreoffice-bugs] [Bug 104332] Thesaurus in the Tools menu causes it to open slowly the first time

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Wed Jun 20 15:38:34 UTC 2018


https://bugs.documentfoundation.org/show_bug.cgi?id=104332

--- Comment #22 from Tor Lillqvist <tml at iki.fi> ---
I have been looking at the delay after typing the first character in Writer in
a LO session. Seeing this requires having a LO built with --with-myspell-dicts
(for typical developers, no idea what it requires for people using end-user
packages).

It is the LightProof Python code that causes most of the slowness.

Here is the "Heaviest Stack Trace" from the TimeProfiler tool in Intruments on
macOS, slightly edited. The number after the dylib name is in milliseconds. One
can see that the first call to pyuno::Adapter::invoke() takes about 300 ms.
(And some temporary SAL_DEBUG output confirms.)

> libdyld.dylib 803.0  start
> soffice 803.0  main /Users/tml/lo/xxx/desktop/source/app/main.c:47
> libsofficeapp.dylib 803.0  soffice_main /Users/tml/lo/xxx/desktop/source/app/sofficemain.cxx:167
> libvcllo.dylib 803.0  SVMain() /Users/tml/lo/xxx/vcl/source/app/svmain.cxx:233
> libvcllo.dylib 803.0  ImplSVMainHook(int*) /Users/tml/lo/xxx/vcl/osx/salinst.cxx:225
> AppKit 803.0  NSApplicationMain
> AppKit 803.0  -[NSApplication run]
> libvcllo.dylib 803.0  -[VCL_NSApplication sendEvent:] /Users/tml/lo/xxx/vcl/osx/vclnsapp.mm:101
> libvcllo.dylib 803.0  AquaSalInstance::handleAppDefinedEvent(NSEvent*) /Users/tml/lo/xxx/vcl/osx/salinst.cxx:463
> libvcllo.dylib 803.0  ImplSVMain() /Users/tml/lo/xxx/vcl/source/app/svmain.cxx:198
> libsofficeapp.dylib 803.0  desktop::Desktop::Main() /Users/tml/lo/xxx/desktop/source/app/app.cxx:1641
> libvcllo.dylib 803.0  Application::Execute() /Users/tml/lo/xxx/vcl/source/app/svapp.cxx:449
> libvcllo.dylib 803.0  ImplYield(bool, bool) /Users/tml/lo/xxx/vcl/source/app/svapp.cxx:469
> libvcllo.dylib 803.0  AquaSalInstance::DoYield(bool, bool) /Users/tml/lo/xxx/vcl/osx/salinst.cxx:628
> libvcllo.dylib 601.0  AquaSalTimer::callTimerCallback() /Users/tml/lo/xxx/vcl/osx/saltimer.cxx:146
> libvcllo.dylib 601.0  Scheduler::ProcessTaskScheduling() /Users/tml/lo/xxx/vcl/source/app/scheduler.cxx:447
> libswlo.dylib 597.0  sw::DocumentTimerManager::DoIdleJobs(Timer*) /Users/tml/lo/xxx/sw/source/core/doc/DocumentTimerManager.cxx:146
> libswlo.dylib 597.0  SwViewShell::LayoutIdle() /Users/tml/lo/xxx/sw/source/core/view/viewsh.cxx:711
> libswlo.dylib 597.0  SwLayIdle::SwLayIdle(SwRootFrame*, SwViewShellImp*) /Users/tml/lo/xxx/sw/source/core/layout/layact.cxx:2097
> libswlo.dylib 597.0  SwLayIdle::DoIdleJob(SwLayIdle::IdleJobType, bool) /Users/tml/lo/xxx/sw/source/core/layout/layact.cxx:2009
> libswlo.dylib 597.0  SwLayIdle::DoIdleJob_(SwContentFrame const*, SwLayIdle::IdleJobType) /Users/tml/lo/xxx/sw/source/core/layout/layact.cxx:1891
> libswlo.dylib 595.0  SwTextFrame::AutoSpell_(SwContentNode const*, int) /Users/tml/lo/xxx/sw/source/core/txtnode/txtedt.cxx:1330
> libswlo.dylib 533.0  SwModule::CreateLngSvcEvtListener() /Users/tml/lo/xxx/sw/source/uibase/app/swmodule.cxx:233
> libswlo.dylib 533.0  SwLinguServiceEventListener::SwLinguServiceEventListener() /Users/tml/lo/xxx/sw/source/uibase/uno/dlelstnr.cxx:51
> libswlo.dylib 533.0  com::sun::star::linguistic2::LinguServiceManager::create(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/workdir/UnoApiHeadersTarget/offapi/normal/com/sun/star/linguistic2/LinguServiceManager.hpp:38
> libuno_cppuhelpergcc3.dylib.3 533.0  non-virtual thunk to cppuhelper::ServiceManager::createInstanceWithContext(rtl::OUString const&, com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/cppuhelper/source/servicemanager.cxx:0
> libuno_cppuhelpergcc3.dylib.3 533.0  cppuhelper::ServiceManager::createInstanceWithContext(rtl::OUString const&, com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/cppuhelper/source/servicemanager.cxx:991
> libuno_cppuhelpergcc3.dylib.3 533.0  cppuhelper::ServiceManager::Data::Implementation::createInstance(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&, bool) /Users/tml/lo/xxx/cppuhelper/source/servicemanager.cxx:667
> libuno_cppuhelpergcc3.dylib.3 533.0  non-virtual thunk to cppu::OFactoryComponentHelper::createInstanceWithContext(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/cppuhelper/source/factory.cxx:0
> libuno_cppuhelpergcc3.dylib.3 533.0  cppu::OFactoryComponentHelper::createInstanceWithContext(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/cppuhelper/source/factory.cxx:374
> libuno_cppuhelpergcc3.dylib.3 533.0  cppu::OSingleFactoryHelper::createInstanceWithContext(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/cppuhelper/source/factory.cxx:175
> libuno_cppuhelpergcc3.dylib.3 533.0  cppu::OSingleFactoryHelper::createInstanceEveryTime(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/cppuhelper/source/factory.cxx:149
> liblnglo.dylib 533.0  LngSvcMgr_CreateInstance(com::sun::star::uno::Reference<com::sun::star::lang::XMultiServiceFactory> const&) /Users/tml/lo/xxx/linguistic/source/lngsvcmgr.cxx:1980
> liblnglo.dylib 533.0  LngSvcMgr::LngSvcMgr() /Users/tml/lo/xxx/linguistic/source/lngsvcmgr.cxx:438
> liblnglo.dylib 533.0  LngSvcMgr::UpdateAll() /Users/tml/lo/xxx/linguistic/source/lngsvcmgr.cxx:664
> liblnglo.dylib 414.0  LngSvcMgr::getAvailableServices(rtl::OUString const&, com::sun::star::lang::Locale const&) /Users/tml/lo/xxx/linguistic/source/lngsvcmgr.cxx:1500
> liblnglo.dylib 313.0  LngSvcMgr::GetAvailableGrammarSvcs_Impl() /Users/tml/lo/xxx/linguistic/source/lngsvcmgr.cxx:1088
> libuno_cppuhelpergcc3.dylib.3 311.0  non-virtual thunk to (anonymous namespace)::ImplementationWrapper::createInstanceWithContext(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/cppuhelper/source/servicemanager.cxx:0
> libuno_cppuhelpergcc3.dylib.3 311.0  (anonymous namespace)::ImplementationWrapper::createInstanceWithContext(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&) /Users/tml/lo/xxx/cppuhelper/source/servicemanager.cxx:587
> libuno_cppuhelpergcc3.dylib.3 306.0  cppuhelper::ServiceManager::loadImplementation(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&, std::__1::shared_ptr<cppuhelper::ServiceManager::Data::Implementation> const&) /Users/tml/lo/xxx/cppuhelper/source/servicemanager.cxx:815
> libgcc3_uno.dylib 306.0  privateSnippetExecutor /Users/tml/lo/xxx/bridges/source/cpp_uno/gcc3_macosx_x86-64/call.cxx:27
> libgcc3_uno.dylib 306.0  cpp_vtable_call /Users/tml/lo/xxx/bridges/source/cpp_uno/gcc3_macosx_x86-64/cpp2uno.cxx:374
> libgcc3_uno.dylib 306.0  cpp2uno_call(bridges::cpp_uno::shared::CppInterfaceProxy*, _typelib_TypeDescription const*, _typelib_TypeDescriptionReference*, int, _typelib_MethodParameter*, void**, void**, void**, unsigned long*) /Users/tml/lo/xxx/bridges/source/cpp_uno/gcc3_macosx_x86-64/cpp2uno.cxx:187
> libinvocadaptlo.dylib 306.0  stoc_invadp::AdapterImpl::invoke(_typelib_TypeDescription const*, void*, void**, _uno_Any**) /Users/tml/lo/xxx/stoc/source/invocation_adapterfactory/iafactory.cxx:466
> libgcc3_uno.dylib 306.0  bridges::cpp_uno::shared::unoInterfaceProxyDispatch(_uno_Interface*, _typelib_TypeDescription const*, void*, void**, _uno_Any**) /Users/tml/lo/xxx/bridges/source/cpp_uno/gcc3_macosx_x86-64/uno2cpp.cxx:0
> libgcc3_uno.dylib 306.0  cpp_call(bridges::cpp_uno::shared::UnoInterfaceProxy*, bridges::cpp_uno::shared::VtableSlot, _typelib_TypeDescriptionReference*, int, _typelib_MethodParameter*, void*, void**, _uno_Any**) /Users/tml/lo/xxx/bridges/source/cpp_uno/gcc3_macosx_x86-64/uno2cpp.cxx:233
> libgcc3_uno.dylib 306.0  gcc3::callVirtualMethod(void*, unsigned int, void*, _typelib_TypeDescriptionReference*, bool, unsigned long*, unsigned int, unsigned long*, double*) /Users/tml/lo/xxx/bridges/source/cpp_uno/gcc3_macosx_x86-64/callvirtualmethod.cxx:77
> libpyuno.dylib 306.0  non-virtual thunk to pyuno::Adapter::invoke(rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::uno::Any> const&, com::sun::star::uno::Sequence<short>&, com::sun::star::uno::Sequence<com::sun::star::uno::Any>&) /Users/tml/lo/xxx/pyuno/source/module/pyuno_adapter.cxx:0
> libpyuno.dylib 306.0  pyuno::Adapter::invoke(rtl::OUString const&, com::sun::star::uno::Sequence<com::sun::star::uno::Any> const&, com::sun::star::uno::Sequence<short>&, com::sun::star::uno::Sequence<com::sun::star::uno::Any>&) /Users/tml/lo/xxx/pyuno/source/module/pyuno_adapter.cxx:250

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20180620/04ea7174/attachment-0001.html>


More information about the Libreoffice-bugs mailing list