summaryrefslogtreecommitdiff
path: root/comphelper
AgeCommit message (Collapse)Author
2021-08-18loplugin:passstuffbyrefNoel Grandin
Change-Id: I4f01eb3842ef198f02af274f54afb2760c820a4b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120655 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-18improve SvxShapeCollection::getByIndexNoel Grandin
Change-Id: I4cca7c0b6344241256d038902069a20ece314358 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120618 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-18avoid constructing OUString on hot path (tdf#105575)Noel Grandin
Change-Id: I7c9925fc7f68cdc9bd1a9c1834daabff09c8cf6e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120604 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-16LOK: introduced Freemium LOK APIPranam Lashkari
also block the uno commands from deny list Change-Id: Iee994411891b73b865e6496403682f996d5e9321 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116384 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Pranam Lashkari <lpranam@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120482 Tested-by: Jenkins
2021-08-15rtl::Static -> thread-safe static localNoel Grandin
Change-Id: Iac0501e6aa35cc3d8e62f6b6e68b76cf70233aae Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120459 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-11no need to allocate KeyedValues separatelyNoel Grandin
Change-Id: If28471436d224e88dfee07f3b8465648867197fd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120291 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-10flatten PropertySetInfo a littleNoel Grandin
Change-Id: I46bc0dc2da9b52d5a2cb1e415328ab1f13a96ff3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120216 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-09Guard read of rCont_.bIsList with rCont_.rMutexStephan Bergmann
...as had been the case prior to 12dce07aec980562fa449fa1884e0e8379d680fb "loplugin:unusedfields - look for fields that can be const, in comphelper" (which this commit partly reverts; the const'ness of OInterfaceIteratorHelper2::bIsList had already been reverted, but for no apparent reason, in 31b0be0f21479323408e128f2e8a1a795e037e74 "improve pahole script and pack a few classes"). That may or may not have been the cause of the apparently-sporadic UITest_sw_table failure at <https://ci.libreoffice.org//job/lo_ubsan/2096/>, > /comphelper/source/container/interfacecontainer2.cxx:54:29: runtime error: member call on address 0x606000ed5d20 which does not point to an object of type 'com::sun::star::uno::XInterface' > 0x606000ed5d20: note: object has invalid vptr > 22 04 00 14 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 be be be be b0 11 46 00 > ^~~~~~~~~~~~~~~~~~~~~~~ > invalid vptr > #0 0x2ab564a71e15 in comphelper::OInterfaceIteratorHelper2::OInterfaceIteratorHelper2(comphelper::OInterfaceContainerHelper2&) /comphelper/source/container/interfacecontainer2.cxx:54:29 > #1 0x2ab57614588f in void comphelper::OInterfaceContainerHelper2::forEach<com::sun::star::document::XDocumentEventListener, comphelper::OInterfaceContainerHelper2::NotifySingleListener<com::sun::star::document::XDocumentEventListener, com::sun::star::document::DocumentEvent> >(comphelper::OInterfaceContainerHelper2::NotifySingleListener<com::sun::star::document::XDocumentEventListener, com::sun::star::document::DocumentEvent> const&) /include/comphelper/interfacecontainer2.hxx:261:31 > #2 0x2ab576144a95 in void comphelper::OInterfaceContainerHelper2::notifyEach<com::sun::star::document::XDocumentEventListener, com::sun::star::document::DocumentEvent>(void (com::sun::star::document::XDocumentEventListener::*)(com::sun::star::document::DocumentEvent const&), com::sun::star::document::DocumentEvent const&) /include/comphelper/interfacecontainer2.hxx:279:5 > #3 0x2ab57613b277 in (anonymous namespace)::SfxGlobalEvents_Impl::implts_notifyListener(com::sun::star::document::DocumentEvent const&) /sfx2/source/notify/globalevents.cxx:505:26 > #4 0x2ab576131faa in (anonymous namespace)::SfxGlobalEvents_Impl::documentEventOccured(com::sun::star::document::DocumentEvent const&) /sfx2/source/notify/globalevents.cxx:256:5 > #5 0x2ab575f4abfc in (anonymous namespace)::NotifySingleListenerIgnoreRE<com::sun::star::document::XDocumentEventListener, com::sun::star::document::DocumentEvent>::operator()(com::sun::star::uno::Reference<com::sun::star::document::XDocumentEventListener> const&) const /sfx2/source/doc/sfxbasemodel.cxx:3200:13 > #6 0x2ab575f002ec in void cppu::OInterfaceContainerHelper::forEach<com::sun::star::document::XDocumentEventListener, (anonymous namespace)::NotifySingleListenerIgnoreRE<com::sun::star::document::XDocumentEventListener, com::sun::star::document::DocumentEvent> >((anonymous namespace)::NotifySingleListenerIgnoreRE<com::sun::star::document::XDocumentEventListener, com::sun::star::document::DocumentEvent> const&) /include/cppuhelper/interfacecontainer.h:292:17 > #7 0x2ab575efdd37 in SfxBaseModel::postEvent_Impl(rtl::OUString const&, com::sun::star::uno::Reference<com::sun::star::frame::XController2> const&) /sfx2/source/doc/sfxbasemodel.cxx:3234:14 > #8 0x2ab575efa257 in SfxBaseModel::Notify(SfxBroadcaster&, SfxHint const&) /sfx2/source/doc/sfxbasemodel.cxx:2883:9 > #9 0x2ab57a796d83 in SfxBroadcaster::Broadcast(SfxHint const&) /svl/source/notify/SfxBroadcaster.cxx:39:24 > #10 0x2ab6010f0e1f in SwLayIdle::SwLayIdle(SwRootFrame*, SwViewShellImp*) /sw/source/core/layout/layact.cxx:2375:24 > #11 0x2ab60385d4e2 in SwViewShell::LayoutIdle() /sw/source/core/view/viewsh.cxx:723:19 > #12 0x2ab5ff549ffa in sw::DocumentTimerManager::DoIdleJobs(Timer*) /sw/source/core/doc/DocumentTimerManager.cxx:177:42 > #13 0x2ab5ff54552a in sw::DocumentTimerManager::LinkStubDoIdleJobs(void*, Timer*) /sw/source/core/doc/DocumentTimerManager.cxx:157:1 > #14 0x2ab599cf5f41 in Link<Timer*, void>::Call(Timer*) const /include/tools/link.hxx:111:45 > #15 0x2ab599cf5498 in Timer::Invoke() /vcl/source/app/timer.cxx:75:21 > #16 0x2ab599b388ea in Scheduler::CallbackTaskScheduling() /vcl/source/app/scheduler.cxx:471:20 > #17 0x2ab59ad34490 in SalTimer::CallCallback() /vcl/inc/saltimer.hxx:54:13 > #18 0x2ab59ad2785c in SvpSalInstance::CheckTimeout(bool) /vcl/headless/svpinst.cxx:215:53 > #19 0x2ab59ad2e67c in SvpSalInstance::DoYield(bool, bool) /vcl/headless/svpinst.cxx:460:21 > #20 0x2ab599c35aa9 in ImplYield(bool, bool) /vcl/source/app/svapp.cxx:465:48 > #21 0x2ab599c34c67 in Application::Yield() /vcl/source/app/svapp.cxx:532:5 > #22 0x2ab599c348ae in Application::Execute() /vcl/source/app/svapp.cxx:444:9 > #23 0x2ab55d699b4b in desktop::Desktop::Main() /desktop/source/app/app.cxx:1603:13 > #24 0x2ab599cde4e9 in ImplSVMain() /vcl/source/app/svmain.cxx:199:35 > #25 0x2ab599ce7510 in SVMain() /vcl/source/app/svmain.cxx:231:12 > #26 0x2ab55d890775 in soffice_main /desktop/source/app/sofficemain.cxx:98:12 > #27 0x4efc6c in sal_main /desktop/source/app/main.c:49:15 > #28 0x4efc46 in main /desktop/source/app/main.c:47:1 > #29 0x2ab55f48e554 in __libc_start_main (/lib64/libc.so.6+0x22554) > #30 0x41b5c1 in _start (/instdir/program/soffice.bin+0x41b5c1) Change-Id: Iaa930f1612a3bb6ad0bcad12f3995b7dbb2e5fa7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120205 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Jenkins
2021-08-08create comphelper:OMultiTypeInterfaceContainerHelperVar2 and use itNoel Grandin
based on OInterfaceContainerHelper2 which is considerably faster than the original OInterfaceContainerHelper Change-Id: Ia8cdbc5ef877a7af3d9193e1bb2faf1595c15470 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120165 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-07create comphelper::OMultiTypeInterfaceContainerHelper2 and use itNoel Grandin
based on OInterfaceContainerHelper2 which is considerably faster than the original OInterfaceContainerHelper Change-Id: I9c8b6d0e5382018824bf7188a26343703abf2d51 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120161 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-08-03Consolidate on C++17 std::scoped_lock instead of std::lock_guardNoel Grandin
as in commit 9376f65a26240441bf9dd6ae1f69886dc9fa60fa Change-Id: I3ad9afd4d113582a214a4a4bc7eea55e38cd6ff9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119927 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-30Fix Nesting Level Bug in ProfileZoneGopi Krishna Menon
Moves the profile zone global nesting variable into the source from header and makes it threadlocal Change-Id: I97751f5c532d8e0e36adb7d9d383bd88f752953f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119662 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-07-30tsan:data race in ThreadPoolTest::testWorkerUsageNoel Grandin
Change-Id: Id63b9f1dd7ed163236837258e8dbad2feb9f1c5e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119695 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-30osl::Mutex->std::mutx in OSequenceOutputStreamNoel Grandin
Change-Id: I1924cc0910c5dfb431b676a0f50f922779920594 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119697 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-30osl::Mutex->std::mutex in SequenceInputStreamNoel Grandin
also (*) check params before taking mutex to minimise the time holding the mutex (*) some methods were missing a lock_guard Change-Id: Iac35328e67f81b38c896f7c1e2a3514b813656c1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119696 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-30osl::Mutex->std::mutex in OAccessibleKeyBindingHelperNoel Grandin
Change-Id: Ib308ede9561a3ff26cfc43bee202f3151fa07392 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119694 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-29osl::Mutex->std::mutex in OSLInputStreamWrapperNoel Grandin
Change-Id: Id67cf7989a47f73b62e48b88c3e6f51efc2ccc46 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119674 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-29osl::Mutex->std::mutex in OSeekableInputWrapperNoel Grandin
Change-Id: Ib6cc0a6b1fcc4685f2ac8c120c86ce79f3036535 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119673 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-23osl::Mutex->std::mutex in AsyncEventNotifierNoel Grandin
and use a vector instead of a deque, becuase then a std::swap makes a nice way of ping-ponging a data buffer back and forth between the producer and consumer sides Change-Id: I11f491b9fde87f0a495df05d306ccee57dcfc6da Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119345 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-18osl::Mutex->std::mutex in NameContainerNoel Grandin
Change-Id: I4d4e8eab2fb281c5ca330c82f2f5fa5d5e18463a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119123 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-18osl::Mutex->std::mutex in SequenceInputStreamServiceNoel Grandin
Change-Id: I3f47f4fbe6d2d65728af7d4715ae8f91c86c5532 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119122 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-17osl::Mutex->std::mutex in SequenceOutputStreamServiceNoel Grandin
Change-Id: I1aaa9ebd76e2376be82b25f2659d4b0f22dc14e1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119113 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-07-15lok: include the label of the status indicatorHenry Castro
Change-Id: Ib2714e3d2b6add54ffba753d3519aeba7a3f1959 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118658 Tested-by: Jenkins Reviewed-by: Andras Timar <andras.timar@collabora.com>
2021-06-29Enable flushing accumulated Trace Events when their number reaches a limitTor Lillqvist
Change-Id: I99ecf56b0faa5c444dbe9e22b8cce035f240c35c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118088 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-06-23The Chrome Trace Event viewer doesn't support nested async eventsTor Lillqvist
Instead of nestable b(egin) and e(nd) events, generate the allegedly deprecated S(tart)' and F(inish) events. Makes the code simpler. (And AsyncEvent is still unused. Unclear whether adding it was based on a misunderstanding.) Change-Id: Ic029b67e0951dda775c0d0af009f2e431ae55e53 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117700 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-06-17Drop the "console" functionality of ProfileZoneTor Lillqvist
It was not used anywhere and had not been cherry-picked to the relevant vendor production branches so apparently it was just some temporary experimentation? It is good to reduce complexity and increase code similarity between branches. Change-Id: Ib6717063f96d901d65ec36d65f3683af31065f2b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117364 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-06-16Adapt implicit OString return value construction to C++23 P2266R1Stephan Bergmann
With the recent implementation of <http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2021/p2266r1.html> "P2266R1: Simpler implicit move" in Clang 13 trunk as <https://github.com/llvm/llvm-project/commit/bf20631782183cd19e0bb7219e908c2bbb01a75f> "[clang] Implement P2266 Simpler implicit move", a --with-latest-c++ build started to fail with > comphelper/source/xml/xmltools.cxx:103:20: error: no viable conversion from returned value of type 'char [39]' to function return type 'rtl::OString' > return str; > ^~~ [...] > include/rtl/string.hxx:277:5: note: candidate constructor [with T = char [39]] not viable: expects an lvalue for 1st argument > OString( T& value, typename libreoffice_internal::NonConstCharArrayDetector< T, libreoffice_internal::Dummy >::Type = libreoffice_internal::Dummy() ) > ^ [...] etc. Change-Id: If34f143a1855fdd7cd22ea3d7594f9381d50a7ec Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117336 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-06-09Fix syntax error in the "arguments" of a TraceEventTor Lillqvist
Change-Id: I68f94311d3e0527955b6ad8d5b49e4e564329e1e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116054 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Tor Lillqvist <tml@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116848 Tested-by: Tor Lillqvist <tml@collabora.com>
2021-06-09Add the possibility to include a set of arguments in Trace EventsTor Lillqvist
Change-Id: I55720baf64bd9b719026c94e4373b6368a1a7106 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116847 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-06-08Simplify Sequences initializations (comphelper+connectivity)Julien Nabet
Change-Id: I8a91f4bd2a1117acb571f1058af18071bc058c9d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116815 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2021-05-28no need to allocate these on the heapNoel Grandin
Change-Id: Ic1a1577ed837d3fa2b7b99474f4cee30300628f6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116290 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-26comphelper: fix the "console" use-case of ProfileZoneMiklos Vajna
m_nCreateTime was changed to NS, nEndTime was still MS, comparing the two is not a great idea. Change-Id: I102990838d1e3d543a356b5ad2d3f68ce1d20623 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116210 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2021-05-03loplugin:stringadd improvement for appending numbersNoel Grandin
I was wrong, the Concat framework already optimised appending numbers by stack-allocating small buffers, so include them in the plugin Change-Id: I922edbdde273c89abfe21d51c5d25dc01c97db25 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115037 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-05-02throw() -> noexcept, part 2/3: Automatic loplugin:noexcept rewriteStephan Bergmann
Change-Id: I076f16d0536b534abf0ced4d76051eadb4c0e033 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114949 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2021-04-29Add SAL_WARN in case ProfileZones are overlapping and not hierarchicalTor Lillqvist
Change-Id: Id09904db762b6d931ab23cce16e55d5213079516 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114834 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-29Make the nested AsyncEvent work more reliablyTor Lillqvist
We must take into consideration that somebody might hold on to a hard reference to such an object. Thus it is not enough to drop the references to it from its parent, that is not necessarily enough to make it destruct. Instead have the parent explicitly cann a function on the children than generates their end events. Also add some documentation. Change-Id: I38180c85072c76af8964c48fa19132b8e1178ee1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114813 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-29Add AsyncEvent::finish() to end a nested AsyncEvent before its parent endsTor Lillqvist
Add unit testing of that, too. Change-Id: Iae5fb6da0b7fcabe8f555d800f065b6f5b4b9982 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114771 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-29Fix syntax error in generated JSONTor Lillqvist
Change-Id: I035a86aa587302985416e65dc6063090f99b49b4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114770 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-29Introduce Async trace events and a unit testTor Lillqvist
Async events are ones that emit separate 'b' (begin) and 'e' (end) traces. (Compare to the Complete event that emit a single 'X' trace that contains both the start timstamp and the duration.) There are two kinds of Async events: Freestanding ones that are not related to other events at all, and nested ones that have to be nested between the 'b' and 'e' events of a parent Async event. Still needs some work, at least a way to end a nested AsyncEvent (cause it to emit the 'e' event) before it gets destructed thanks to the parent being destructed. Change-Id: I3721fa701ad32639b1edc1cfa8db7acde5caf9b4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114756 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-28Introduce a new class NamedEvent to be used by the upcoming AsyncEvent, tooTor Lillqvist
Don't use the term "profile id" as what we mean is the event *name* (as used in the Chrome Trace Event format). Change-Id: Id58a10f4c5f8a095ae75b9bf74131b70659ee701 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114755 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-28Enable turning on trace event recording in a dbgutil build with an env varTor Lillqvist
Change-Id: Ie0efdd2d5da0a45ba5e82be455d36dc777b5efb9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114736 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-28Re-think what the nesting means in ProfileZonesTor Lillqvist
The "Complete" type of Trace Events should be properly nested. Use the nesting counter to verify that. Add a nesting level indication to the ProfileZone object. Assert that it is used properly. Change-Id: I3a1f0e55ea6054dab9baf8550097446f07b0fbf3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114735 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-28Make the console logging in ProfileZone work more sanelyTor Lillqvist
Do not re-assing a value to the m_nCreateTime if bConsole is true. Just use the same code that sets it in the constructor as in the case when recording is on. Change-Id: I1ca3c5aa00e2f8f0faa7ca3433e1eb066413c2a2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114734 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-28Move some static functions from ProfileZone to TraceEvent where they belongTor Lillqvist
Change-Id: I35f3d5d8c0a69a224cf7d3a2decba9c8e13c7dc1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114698 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-28Extend the trace event API with instant eventsTor Lillqvist
Change-Id: I3a93c79f46ffc5768ddaf338789fe2daa225ef4d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114696 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com>
2021-04-28g_nStartTime was unusedTor Lillqvist
Change-Id: I2f4371825f7c528a081e42ee157b21b7fd73b2f6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114660 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Tor Lillqvist <tml@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114665 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114672 Tested-by: Tor Lillqvist <tml@collabora.com>
2021-04-27loplugin:stringadd convert chained append to +Noel Grandin
which can use the more efficient *StringConcat Also fix a crash in stringview plugin which started happening while I working on this. Change-Id: I91a5b9b7707d1594d27d80b73930f5afac8ae608 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114568 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2021-04-27Add also the comma separator between Event Trace eventsTor Lillqvist
Change-Id: I13221b9e6437789a72b6d759de4dd0f4434e0fd8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114160 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114558 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114655 Tested-by: Jenkins
2021-04-27Drop the leftover "sum time" thing from the Event TraceTor Lillqvist
Change-Id: I222da50f3ad113bf3204b4d21df52c9e55cf7cf0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114159 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Tor Lillqvist <tml@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114557 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114654 Tested-by: Jenkins
2021-04-27Refactor ProfileZone and create Chrome Trace Event Format dataTor Lillqvist
Instead of separate B ("begin") and E ("end") duration events, generate X ("complete") events. Only the event JSON objects are generated, not the surrounding array or object. See https://docs.google.com/document/d/1CvAClvFfyA5R-PhYUmn5OOQtYMH4h6I0nSsKchNAySU/preview#heading=h.lc5airzennvk Online now needs work so that the events are written out to a separate file instead of being in the common log file. Change-Id: Ie9363b4cfda862a70e1928ed16350e50a6fee9a5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114142 Tested-by: Tor Lillqvist <tml@collabora.com> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114556 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114653 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>